[saml2] add proper error code for partial logout status code

This commit is contained in:
Benjamin Dauvergne 2011-05-08 00:04:40 +02:00
parent cbeecfe280
commit 2a3a56f8e1
3 changed files with 12 additions and 0 deletions

View File

@ -173,6 +173,8 @@ lasso_strerror(int error_code)
return "An unsigned authn request was received but the metadata specify that they must be signed.";
case LASSO_LOGOUT_ERROR_FEDERATION_NOT_FOUND:
return "Federation not found on logout";
case LASSO_LOGOUT_ERROR_PARTIAL_LOGOUT:
return "Logout could not be propagated to every service provider in the current session.";
case LASSO_LOGOUT_ERROR_REQUEST_DENIED:
return "Request denied by identity provider";
case LASSO_LOGOUT_ERROR_UNKNOWN_PRINCIPAL:

View File

@ -298,6 +298,12 @@ LASSO_EXPORT const char* lasso_strerror(int error_code);
* Unknown principal on logout
*/
#define LASSO_LOGOUT_ERROR_UNKNOWN_PRINCIPAL 304
/**
* LASSO_LOGOUT_ERROR_PARTIAL_LOGOUT:
*
* Logout could not be propagated to every service provider in the current session.
*/
#define LASSO_LOGOUT_ERROR_PARTIAL_LOGOUT 305
/* Profile */
/**

View File

@ -396,6 +396,10 @@ cleanup:
value = sub_status_code->Value;
if (lasso_strisequal(value,LASSO_SAML2_STATUS_CODE_PARTIAL_LOGOUT)) {
rc = LASSO_LOGOUT_ERROR_PARTIAL_LOGOUT;
break;
}
if (lasso_strisequal(value,LASSO_SAML2_STATUS_CODE_REQUEST_DENIED)) {
rc = LASSO_LOGOUT_ERROR_REQUEST_DENIED;
break;