All this is okay and now i have Cannot decode response.
Statut détaillé
UNKNOWN: Cannot decode response (add --debug option to display returned content)
======> request send
POST http://localhost:80/
Accept: application/json
User-Agent: centreon::plugins::backend::http::useragent
Content-Type: application/json
{"password":"pass","command":"listDisks","login":"user","host":"10.157.222.42"}
======> response done
HTTP/1.1 302 Found
Connection: Keep-Alive
Date: Mon, 13 Jun 2022 12:46:37 GMT
Location: http://localhost/centreon
Server: Apache
Content-Length: 209
Content-Type: text/html; charset=iso-8859-1
Client-Date: Mon, 13 Jun 2022 12:46:37 GMT
Client-Peer: 127.0.0.1:80
Client-Response-Num: 1
Keep-Alive: timeout=5, max=100
Title: 302 Found
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>302 Found</title>
</head><body>
<h1>Found</h1>
<p>The document has moved <a href="http://localhost/centreon">here</a>.</p>
</body></html>
======> request send
GET http://localhost/centreon
Accept: application/json
User-Agent: centreon::plugins::backend::http::useragent
======> response done
HTTP/1.1 301 Moved Permanently
Date: Mon, 13 Jun 2022 12:46:37 GMT
Location: http://localhost/centreon/
Server: Apache
Content-Length: 234
Content-Type: text/html; charset=iso-8859-1
Client-Date: Mon, 13 Jun 2022 12:46:37 GMT
Client-Peer: 127.0.0.1:80
Client-Response-Num: 2
Title: 301 Moved Permanently
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>301 Moved Permanently</title>
</head><body>
<h1>Moved Permanently</h1>
<p>The document has moved <a href="http://localhost/centreon/">here</a>.</p>
</body></html>
======> request send
GET http://localhost/centreon/
Accept: application/json
User-Agent: centreon::plugins::backend::http::useragent
======> response done
HTTP/1.1 302 Found
Cache-Control: no-store, no-cache, must-revalidate
Date: Mon, 13 Jun 2022 12:46:37 GMT
Pragma: no-cache
Location: ./install/upgrade.php
Server: Apache
Content-Type: text/html; charset=UTF-8
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Client-Date: Mon, 13 Jun 2022 12:46:37 GMT
Client-Peer: 127.0.0.1:80
Client-Response-Num: 3
Client-Transfer-Encoding: chunked
Link: <./Themes/Centreon-2/login.css>; rel="stylesheet"; type="text/css"
Link: <./img/favicon.ico>; rel="shortcut icon"
Refresh: 840
Set-Cookie: PHPSESSID=c812idsc8c70t257cbruimfvdd; path=/;HttpOnly;SameSite=Strict
Title: Centreon - IT & Network Monitoring
X-Frame-Options: sameorigin
X-Meta-Generator: Centreon - Copyright (C) 2005 - 2021 Open Source Matters. All rights reserved.
X-Meta-Robots: index, nofollow
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>Centreon - IT & Network Monitoring</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Generator" content="Centreon - Copyright (C) 2005 - 2021 Open Source Matters. All rights reserved." />
<meta name="robots" content="index, nofollow" />
<meta http-equiv="refresh" content="840">
<link href="./Themes/Centreon-2/login.css" rel="stylesheet" type="text/css">
<link rel="shortcut icon" href="./img/favicon.ico">
<script type="text/javascript" src="./include/common/javascript/jquery/jquery.min.js"></script>
</head>
<body OnLoad="document.login.useralias.focus();">
<form action="./index.php" method="post" name="login" style="height:370px">
<div class="login_wrapper">
<div class="LoginInvitLogo">
<div class="error_msg" style="visibility: hidden">
<span class='msg'></span>
</div>
<img src="img/centreon.png" alt="Centreon Logo" title="Centreon Logo" />
</div>
<div class="logintab">
<table id="logintab1" style="text-align:center;" align="center">
<tr>
<td align='right'></td>
<td><input placeholder="Login" class="inputclassic" autocomplete="off" name="useralias" type="text" /></td>
</tr>
<tr>
<td align='right'></td>
<td><input placeholder="Password" class="inputclassicPass" name="password" type="password" /></td>
</tr>
<tr>
<td colspan="2" align='center'><input class="btc bt_info" name="submitLogin" value="Connect" type="submit" /></td>
</tr>
</table>
</div>
<div class="LoginInvitVersion">
<span id="LoginInvitcpy">
© <a href="mailto:contact@centreon.com">Centreon</a> 2005 - 2021
</span>
<br>
<span>
v. 21.10.4
</span>
</div>
</div>
<input name="centreon_token" type="hidden" value="c95eecc30d5bc7f4474007d36247abe8" />
</form>
<script type="text/javascript">
jQuery(() => {
jQuery('formrname="login"]').submit(() => {
jQuery('inputytype="submit"]').prop('disabled', true)
jQuery.ajax({
url: './authentication/providers/configurations/local',
data: JSON.stringify({
login: jQuery('inputyname="useralias"]').val(),
password: jQuery('inputyname="password"]').val()
}),
method: 'POST',
contentType: 'application/json'
}).done((res) => {
window.location.href = res.redirect_uri
}).fail((err) => {
if (err.status === 401) {
if (err?.responseJSON?.message) {
jQuery('span.msg').text(err.responseJSON.message)
} else {
jQuery('span.msg').text('Your credentials are incorrect')
}
} else {
jQuery('span.msg').text('Internal server error')
}
jQuery('div.error_msg').css('visibility', '')
}).always(() => {
jQuery('inputytype="submit"]').prop('disabled', false)
})
return false;
});
});
if (window.location.href.match(/\/index.php\?disconnect=1/)) {
localStorage.removeItem('centreonPlatformData');
}
// check :
// - if login page is in an iframe
// - if iframe url is login page with disconnect parameter
if (window.location.href !== window.parent.location.href
&& window.location.href.match(/\/index.php\?disconnect=1/)
) {
// send event to be manage by react app (redirect to login page)
var event = new CustomEvent(
'react.href.disconnect',
{
detail: {
href: window.location.href
}
}
);
window.parent.dispatchEvent(event);
}
</script>
</body>
</html>
======> request send
GET http://localhost/centreon/install/upgrade.php
Accept: application/json
User-Agent: centreon::plugins::backend::http::useragent
======> response done
HTTP/1.1 200 OK
Cache-Control: no-store, no-cache, must-revalidate
Date: Mon, 13 Jun 2022 12:46:37 GMT
Pragma: no-cache
Server: Apache
Content-Type: text/html; charset=UTF-8
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Client-Date: Mon, 13 Jun 2022 12:46:37 GMT
Client-Peer: 127.0.0.1:80
Client-Response-Num: 4
Client-Transfer-Encoding: chunked
Content-Style-Type: text/css
Link: <../img/favicon.ico>; rel="shortcut icon"
Link: <../Themes/Centreon-2/style.css>; rel="stylesheet"; type="text/css"
Link: <./install.css>; rel="stylesheet"; type="text/css"
Link: <./pub_install.css>; rel="stylesheet"; type="text/css"
Set-Cookie: PHPSESSID=4dqgkrfi7e5c9mub6vpf3u367h; path=/;HttpOnly;SameSite=Strict
Title: Centreon Installation
X-Frame-Options: sameorigin
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta http-equiv="Content-Style-Type" content="text/css">
<title>Centreon Installation</title>
<link rel="shortcut icon" href="../img/favicon.ico">
<link rel="stylesheet" href="../Themes/Centreon-2/style.css" type="text/css">
<link rel="stylesheet" href="./install.css" type="text/css">
<link rel="stylesheet" href="./pub_install.css" type="text/css">
<script type="text/javascript" src="../include/common/javascript/jquery/jquery.min.js"></script>
<script type="text/javascript" src="../include/common/javascript/jquery/jquery-ui.js"></script>
<script type="text/javascript">jQuery.noConflict();</script>
<script type='text/javascript'>
jQuery().ready(function () {
var curstep = 1;
jQuery('#installationContent').load('./step_upgrade/step' + curstep + '.php');
});
/**
* Go back to previous page
*
* @param int stepNumber
* @return void
*/
function jumpTo(stepNumber) {
jQuery('#installationContent').load('./step_upgrade/step' + stepNumber + '.php');
}
/**
* Do background process
*
* @param boolean async
* @param string url
* @param array data
* @param function callbackOnSuccess
* @return void
*/
function doProcess(async, url, data, callbackOnSuccess) {
jQuery.ajax({
type: 'POST',
url: url,
data: data,
success: callbackOnSuccess,
async: async
});
}
</script>
</head>
<body rightmargin="0" topmargin="0" leftmargin="0">
<div id='installationFrame'>
<div id='installationContent'></div>
</div>
</body>
</html>