diff options
| -rw-r--r-- | lasso/xml/lib_authn_response.c | 17 | ||||
| -rw-r--r-- | lasso/xml/samlp_response.c | 1 | ||||
| -rw-r--r-- | lasso/xml/samlp_response.h | 3 |
3 files changed, 8 insertions, 13 deletions
diff --git a/lasso/xml/lib_authn_response.c b/lasso/xml/lib_authn_response.c index 0f81ed65..f1da845d 100644 --- a/lasso/xml/lib_authn_response.c +++ b/lasso/xml/lib_authn_response.c @@ -151,20 +151,17 @@ lasso_lib_authn_response_get_type() LassoNode* lasso_lib_authn_response_new(char *providerID, LassoLibAuthnRequest *request) { - LassoSamlpResponseAbstract *response; + LassoLibAuthnResponse *response; response = g_object_new(LASSO_TYPE_LIB_AUTHN_RESPONSE, NULL); if (providerID) { - response->ResponseID = lasso_build_unique_id(32); - response->MajorVersion = LASSO_LIB_MAJOR_VERSION_N; - response->MinorVersion = LASSO_LIB_MINOR_VERSION_N; - response->IssueInstant = lasso_get_current_time(); - - LASSO_LIB_AUTHN_RESPONSE(response)->ProviderID = g_strdup(providerID); - - LASSO_LIB_AUTHN_RESPONSE(response)->RelayState = g_strdup( - request->RelayState); + lasso_samlp_response_abstract_fill( + LASSO_SAMLP_RESPONSE_ABSTRACT(response), + LASSO_SAMLP_REQUEST_ABSTRACT(request)->RequestID, + request->ProviderID); + response->ProviderID = g_strdup(providerID); + response->RelayState = g_strdup(request->RelayState); } return LASSO_NODE(response); diff --git a/lasso/xml/samlp_response.c b/lasso/xml/samlp_response.c index b81c3163..d8bb73d0 100644 --- a/lasso/xml/samlp_response.c +++ b/lasso/xml/samlp_response.c @@ -157,6 +157,7 @@ lasso_samlp_response_new() response->MajorVersion = LASSO_SAML_MAJOR_VERSION_N; response->MinorVersion = LASSO_SAML_MINOR_VERSION_N; response->IssueInstant = lasso_get_current_time(); + /* XXX: shouldn't ->InResponseTo be set ? */ /* Add Status */ status = LASSO_SAMLP_STATUS(lasso_samlp_status_new()); diff --git a/lasso/xml/samlp_response.h b/lasso/xml/samlp_response.h index fca7f03b..a1121659 100644 --- a/lasso/xml/samlp_response.h +++ b/lasso/xml/samlp_response.h @@ -49,11 +49,8 @@ struct _LassoSamlpResponse { /* <element ref="samlp:Status"/> */ LassoSamlpStatus *Status; - /* <element ref="saml:Assertion" minOccurs="0" maxOccurs="unbounded"/> */ LassoSamlAssertion *Assertion; /* XXX: GList */ - - /*< private >*/ }; struct _LassoSamlpResponseClass { |
