summaryrefslogtreecommitdiffstats
path: root/lasso/id-ff/federation_termination.c
diff options
context:
space:
mode:
authorValery Febvre <vfebvre at easter-eggs.com>2004-08-04 00:45:32 +0000
committerValery Febvre <vfebvre at easter-eggs.com>2004-08-04 00:45:32 +0000
commit8116061d6bd0c2825f7fe072a890151786f4fce1 (patch)
tree708ed988df5b10b5d34a1b4037d37a5b7d6a865d /lasso/id-ff/federation_termination.c
parentbad710b4e0aa661ab2d9a7d7aed95e5672221fee (diff)
downloadlasso-8116061d6bd0c2825f7fe072a890151786f4fce1.tar.gz
lasso-8116061d6bd0c2825f7fe072a890151786f4fce1.tar.xz
lasso-8116061d6bd0c2825f7fe072a890151786f4fce1.zip
Changed all lasso_provider_get_* methods prototype
It was added: a 'provider_type' argument to read in the appropriate Descriptor in metadata a 'err' argument for reporting errors
Diffstat (limited to 'lasso/id-ff/federation_termination.c')
-rw-r--r--lasso/id-ff/federation_termination.c18
1 files changed, 15 insertions, 3 deletions
diff --git a/lasso/id-ff/federation_termination.c b/lasso/id-ff/federation_termination.c
index 71bdfd4a..5d1edcb8 100644
--- a/lasso/id-ff/federation_termination.c
+++ b/lasso/id-ff/federation_termination.c
@@ -35,6 +35,7 @@ lasso_federation_termination_build_notification_msg(LassoFederationTermination *
LassoProfile *profile;
LassoProvider *provider;
xmlChar *protocolProfile;
+ lassoProviderTypes provider_type; /* use to get metadata */
g_return_val_if_fail(LASSO_IS_FEDERATION_TERMINATION(defederation), -1);
@@ -46,8 +47,17 @@ lasso_federation_termination_build_notification_msg(LassoFederationTermination *
return(-2);
}
+ if (profile->provider_type == lassoProviderTypeSp) {
+ provider_type = lassoProviderTypeIdp;
+ }
+ else {
+ provider_type = lassoProviderTypeSp;
+ }
+
/* get the prototocol profile of the federation termination notification */
- protocolProfile = lasso_provider_get_federationTerminationNotificationProtocolProfile(provider);
+ protocolProfile = lasso_provider_get_federationTerminationNotificationProtocolProfile(provider,
+ provider_type,
+ NULL);
if(protocolProfile == NULL) {
message(G_LOG_LEVEL_CRITICAL, "Federation termination notification protocol profile not found\n");
return(-3);
@@ -56,7 +66,9 @@ lasso_federation_termination_build_notification_msg(LassoFederationTermination *
if(xmlStrEqual(protocolProfile, lassoLibProtocolProfileSloSpSoap) || \
xmlStrEqual(protocolProfile, lassoLibProtocolProfileSloIdpSoap)) {
profile->request_type = lassoHttpMethodSoap;
- profile->msg_url = lasso_provider_get_federationTerminationServiceURL(provider);
+ profile->msg_url = lasso_provider_get_federationTerminationServiceURL(provider,
+ lassoProviderTypeIdp,
+ NULL);
if(profile->msg_url == NULL) {
message(G_LOG_LEVEL_CRITICAL, "Federation Termination Notification url not found\n");
return(-4);
@@ -71,7 +83,7 @@ lasso_federation_termination_build_notification_msg(LassoFederationTermination *
profile->server->private_key);
profile->msg_body = NULL;
}
- else{
+ else {
message(G_LOG_LEVEL_CRITICAL, "Invalid protocol profile\n");
return(-5);
}