Skip to content
Snippets Groups Projects
Commit 1c946ae6 authored by Marco Malavolti's avatar Marco Malavolti
Browse files

Changed some check_result messages

parent 899b6722
Branches
Tags
No related merge requests found
......@@ -395,7 +395,7 @@ def check_idp_response_selenium(sp,idp,test):
header = f"<h1>SP {sp['entityID']} - METADATA NOT FOUND</h1><h2>[PAGE_SOURCE]</h2>"
stored = store_page_source(idp,sp,test,pgsrc,header)
if (stored):
return (idp['entityID'],sp['entityID'],check_time,"No-eduGAIN-Metadata",webdriver_error)
return (idp['entityID'],sp['entityID'],check_time,"No-SP-Metadata-Error",webdriver_error)
idp_error = re.search(e_p.IDPERROR, pgsrc, re.IGNORECASE)
if (idp_error):
......@@ -405,7 +405,7 @@ def check_idp_response_selenium(sp,idp,test):
header = f"<h1>SP {sp['entityID']} - IDP Error</h1><h2>[PAGE_SOURCE]</h2>"
stored = store_page_source(idp,sp,test,pgsrc,header)
if (stored):
return (idp['entityID'],sp['entityID'],check_time,"IdP-Error",webdriver_error)
return (idp['entityID'],sp['entityID'],check_time,"IdP-Generic-Error",webdriver_error)
load_js = re.search(e_p.JAVASCRIPT, pgsrc, re.IGNORECASE)
if (load_js):
......@@ -448,7 +448,7 @@ def check_idp_response_selenium(sp,idp,test):
header = f"<h1>SP {sp['entityID']} - METADATA NOT FOUND</h1><h2>[PAGE_SOURCE]</h2>"
stored = store_page_source(idp,sp,test,pgsrc,header)
if (stored):
return (idp['entityID'],sp['entityID'],check_time,"No-eduGAIN-Metadata",webdriver_error)
return (idp['entityID'],sp['entityID'],check_time,"No-SP-Metadata-Error",webdriver_error)
else:
try:
response = requests.get(f"{driver.current_url}", timeout=e_p.ECCS_REQUESTSTIMEOUT)
......@@ -471,7 +471,7 @@ def check_idp_response_selenium(sp,idp,test):
pgsrc = ""
stored = store_page_source(idp,sp,test,pgsrc,header)
if (stored):
return (idp['entityID'],sp['entityID'],check_time,"IdP-Error",webdriver_error)
return (idp['entityID'],sp['entityID'],check_time,"403-Forbidden",webdriver_error)
except requests.exceptions.SSLError as e:
if ('unable to get local issuer certificate' not in str(e)):
......
......@@ -189,12 +189,17 @@ input[type=checkbox] {
margin-left: -100px;
}
.tooltip-no-edugain-metadata {
.tooltip-no-sp-metadata-error {
width: 400px;
margin-left: -200px;
}
.tooltip-idp-error {
.tooltip-idp-generic-error {
width: 180px;
margin-left: -84px;
}
.tooltip-403-forbidden {
width: 180px;
margin-left: -84px;
}
......
......@@ -193,7 +193,7 @@ function getHostname(url) {
function getCheckResult(checkResult){
if (checkResult == "OK"){
return '<div class="tooltip">OK <span class="tooltiptext tooltip-top tooltip-ok">The IdP is consuming correctly the eduGAIN metadata and return a valid login page</span></div> '+infoCircle;
return '<div class="tooltip">OK <span class="tooltiptext tooltip-top tooltip-ok">The IdP is consuming correctly the SP metadata and returns a valid login page</span></div> '+infoCircle;
}
else if (checkResult == "Timeout"){
return '<div class="tooltip">Timeout <span class="tooltiptext tooltip-top tooltip-timeout">The IdP does not load a valid login page within 60 seconds</span></div> '+infoCircle;
......@@ -204,11 +204,14 @@ function getCheckResult(checkResult){
else if (checkResult == "Connection-Error"){
return '<div class="tooltip">Connection Error <span class="tooltiptext tooltip-top tooltip-connection-error">Check failed due a connection error</span></div> '+infoCircle;
}
else if (checkResult == "No-eduGAIN-Metadata"){
return '<div class="tooltip">No-eduGAIN-Metadata <span class="tooltiptext tooltip-top tooltip-no-edugain-metadata">The IdP is not consuming correctly edugGAIN metadata stream</span></div> '+infoCircle
else if (checkResult == "No-SP-Metadata-Error"){
return '<div class="tooltip">No-SP-Metadata-Error <span class="tooltiptext tooltip-top tooltip-no-sp-metadata-error">The IdP is not consuming correctly the SP metadata</span></div> '+infoCircle
}
else if (checkResult == "IdP-Error"){
return '<div class="tooltip">IdP-Error <span class="tooltiptext tooltip-top tooltip-idp-error">The IdP reported an error</span></div> '+infoCircle
else if (checkResult == "IdP-Generic-Error"){
return '<div class="tooltip">IdP-Generic-Error <span class="tooltiptext tooltip-top tooltip-idp-generic-error">The IdP reported an error</span></div> '+infoCircle
}
else if (checkResult == "403-Forbidden"){
return '<div class="tooltip">403-Forbidden <span class="tooltiptext tooltip-top tooltip-403-forbidden">The IdP reported a "403 Forbidden" error</span></div> '+infoCircle
}
else if (checkResult == "SSL-Error"){
return '<div class="tooltip">SSL-Error <span class="tooltiptext tooltip-top tooltip-ssl-error">The IdP has a problem on its SSL certificate</span></div> '+infoCircle;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment