Commit df3c1efb authored by Xavier Guimard's avatar Xavier Guimard

Handle 404 and 502 error codes (fixes: #1211)

parent 68707a0b
......@@ -21,7 +21,9 @@ PerlModule Lemonldap::NG::Handler
# Common error page and security parameters
ErrorDocument 403 http://auth.__DNSDOMAIN__/lmerror/403
ErrorDocument 404 http://auth.__DNSDOMAIN__/lmerror/404
ErrorDocument 500 http://auth.__DNSDOMAIN__/lmerror/500
ErrorDocument 502 http://auth.__DNSDOMAIN__/lmerror/502
ErrorDocument 503 http://auth.__DNSDOMAIN__/lmerror/503
<VirtualHost __VHOSTLISTEN__>
......
......@@ -21,7 +21,9 @@ PerlModule Lemonldap::NG::Handler
# Common error page and security parameters
ErrorDocument 403 http://auth.__DNSDOMAIN__/lmerror/403
ErrorDocument 404 http://auth.__DNSDOMAIN__/lmerror/404
ErrorDocument 500 http://auth.__DNSDOMAIN__/lmerror/500
ErrorDocument 502 http://auth.__DNSDOMAIN__/lmerror/502
ErrorDocument 503 http://auth.__DNSDOMAIN__/lmerror/503
<VirtualHost __VHOSTLISTEN__>
......
......@@ -21,7 +21,9 @@ PerlModule Lemonldap::NG::Handler
# Common error page and security parameters
ErrorDocument 403 http://auth.__DNSDOMAIN__/lmerror/403
ErrorDocument 404 http://auth.__DNSDOMAIN__/lmerror/404
ErrorDocument 500 http://auth.__DNSDOMAIN__/lmerror/500
ErrorDocument 502 http://auth.__DNSDOMAIN__/lmerror/502
ErrorDocument 503 http://auth.__DNSDOMAIN__/lmerror/503
<VirtualHost __VHOSTLISTEN__>
......
......@@ -748,7 +748,7 @@ sub lmError {
# Error code
$templateParams{"ERROR$_"} = ( $httpError == $_ ? 1 : 0 )
foreach ( 403, 500, 503 );
foreach ( 403, 404, 500, 502, 503 );
return $self->sendHtml( $req, 'error', params => \%templateParams );
}
......
......@@ -144,6 +144,7 @@
"newPassword":"New password",
"newPwdSentTo":"A confirmation has been sent to your mail address.",
"noHistory":"This is your first connection, welcome!",
"notFound": "Not found: you try to access to an unavailable page",
"oidcConsent":"The application %s would like to know:",
"openidAp":"Do you agree to provide the following parameters?",
"openIdExample":"for example:http://myopenid.org/toto",
......@@ -155,6 +156,7 @@
"otherSessions":"Other active sessions",
"password": "Password",
"ppGrace": "authentications remaining, change your password!",
"proxyError": "Bad gateway: unable to join remote server",
"pwdChange":"Password change",
"pwd":"Password",
"pwdResetAlreadyIssued":"A password reset request was already issued on ",
......
......@@ -144,6 +144,7 @@
"newPassword":"New password",
"newPwdSentTo":"A confirmation has been sent to your mail address.",
"noHistory":"This is your first connection, welcome!",
"notFound": "Not found: you try to access to an unavailable page",
"oidcConsent":"The application %s would like to know:",
"openidAp":"Do you agree to provide the following parameters?",
"openIdExample":"for example:http://myopenid.org/toto",
......@@ -155,6 +156,7 @@
"otherSessions":"Other active sessions",
"password": "Password",
"ppGrace": "authentications remaining, change your password!",
"proxyError": "Bad gateway: unable to join remote server",
"pwdChange":"Password change",
"pwd":"Password",
"pwdResetAlreadyIssued":"A password reset request was already issued on ",
......
......@@ -144,6 +144,7 @@
"newPassword":"New password",
"newPwdSentTo":"A confirmation has been sent to your mail address.",
"noHistory":"This is your first connection, welcome!",
"notFound": "Not found: you try to access to an unavailable page",
"oidcConsent":"The application %s would like to know:",
"openidAp":"Do you agree to provide the following parameters?",
"openIdExample":"for example:http://myopenid.org/toto",
......@@ -155,6 +156,7 @@
"otherSessions":"Other active sessions",
"password": "Password",
"ppGrace": "authentications remaining, change your password!",
"proxyError": "Bad gateway: unable to join remote server",
"pwdChange":"Password change",
"pwd":"Password",
"pwdResetAlreadyIssued":"A password reset request was already issued on ",
......
......@@ -144,6 +144,7 @@
"newPassword":"Nouveau mot de passe",
"newPwdSentTo":"Une confirmation a été envoyée à votre adresse mail.",
"noHistory":"Ceci est votre première connexion, bienvenue !",
"notFound": "Non trouvé: vous tentez d'accéder à une page non disponible",
"oidcConsent":"L'application %s voudrait connaître :",
"openidAp":"Consentez-vous à communiquer les paramètres suivants&nbsp;?",
"openIdExample":"par exemple :http://myopenid.org/toto",
......@@ -155,6 +156,7 @@
"otherSessions":"Autres sessions ouvertes",
"password": "Mot-de-passe",
"ppGrace": "authentifications restantes, changez votre mot de passe !",
"proxyError": "Mauvaise passerelle: impossible de joindre le serveur amont",
"pwdChange":"Changement de mot de passe",
"pwd":"Mot de passe",
"pwdResetAlreadyIssued":"Une demande de réinitialisation de mot de passe a déjà été faite le ",
......
......@@ -144,6 +144,7 @@
"newPassword":"New password",
"newPwdSentTo":"A confirmation has been sent to your mail address.",
"noHistory":"This is your first connection, welcome!",
"notFound": "Not found: you try to access to an unavailable page",
"oidcConsent":"The application %s would like to know:",
"openidAp":"Do you agree to provide the following parameters?",
"openIdExample":"for example:http://myopenid.org/toto",
......@@ -155,6 +156,7 @@
"otherSessions":"Other active sessions",
"password": "Password",
"ppGrace": "authentications remaining, change your password!",
"proxyError": "Bad gateway: unable to join remote server",
"pwdChange":"Password change",
"pwd":"Password",
"pwdResetAlreadyIssued":"A password reset request was already issued on ",
......
......@@ -144,6 +144,7 @@
"newPassword":"New password",
"newPwdSentTo":"A confirmation has been sent to your mail address.",
"noHistory":"This is your first connection, welcome!",
"notFound": "Not found: you try to access to an unavailable page",
"oidcConsent":"The application %s would like to know:",
"openidAp":"Do you agree to provide the following parameters?",
"openIdExample":"for example:http://myopenid.org/toto",
......@@ -155,6 +156,7 @@
"otherSessions":"Other active sessions",
"password": "Password",
"ppGrace": "authentications remaining, change your password!",
"proxyError": "Bad gateway: unable to join remote server",
"pwdChange":"Password change",
"pwd":"Password",
"pwdResetAlreadyIssued":"A password reset request was already issued on ",
......
......@@ -144,6 +144,7 @@
"newPassword":"New password",
"newPwdSentTo":"A confirmation has been sent to your mail address.",
"noHistory":"This is your first connection, welcome!",
"notFound": "Not found: you try to access to an unavailable page",
"oidcConsent":"The application %s would like to know:",
"openidAp":"Do you agree to provide the following parameters?",
"openIdExample":"for example:http://myopenid.org/toto",
......@@ -155,6 +156,7 @@
"otherSessions":"Other active sessions",
"password": "Password",
"ppGrace": "authentications remaining, change your password!",
"proxyError": "Bad gateway: unable to join remote server",
"pwdChange":"Password change",
"pwd":"Password",
"pwdResetAlreadyIssued":"A password reset request was already issued on ",
......
......@@ -144,6 +144,7 @@
"newPassword":"New password",
"newPwdSentTo":"A confirmation has been sent to your mail address.",
"noHistory":"This is your first connection, welcome!",
"notFound": "Not found: you try to access to an unavailable page",
"oidcConsent":"The application %s would like to know:",
"openidAp":"Do you agree to provide the following parameters?",
"openIdExample":"for example:http://myopenid.org/toto",
......@@ -155,6 +156,7 @@
"otherSessions":"Other active sessions",
"password": "Password",
"ppGrace": "authentications remaining, change your password!",
"proxyError": "Bad gateway: unable to join remote server",
"pwdChange":"Password change",
"pwd":"Password",
"pwdResetAlreadyIssued":"A password reset request was already issued on ",
......
......@@ -9,12 +9,24 @@
</div>
</TMPL_IF>
<TMPL_IF ERROR404>
<div class="message message-negative alert">
<span trspan="notFound">File not found</span>
</div>
</TMPL_IF>
<TMPL_IF ERROR500>
<div class="message message-negative alert">
<span trspan="serverError">Error occurs on the server</span>
</div>
</TMPL_IF>
<TMPL_IF ERROR502>
<div class="message message-negative alert">
<span trspan="proxyError">Proxy error</span>
</div>
</TMPL_IF>
<TMPL_IF ERROR503>
<div class="message message-warning alert">
<span trspan="maintenanceMode">This application is in maintenance, please try to connect later</span>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment