From 49deb1ffcb59eb41c3ac53759722472daabb8f50 Mon Sep 17 00:00:00 2001 From: Benjamin Dauvergne Date: Sat, 12 Jun 2010 00:43:20 +0000 Subject: SAMLv2: rename lasso_saml2_name_id_build_persistent to lasso_saml2_name_id_new_with_persistent_format * keep the old one for compatibility * new one will be picked by bindings as a constructor --- docs/reference/lasso/lasso-sections.txt | 1 + lasso/saml-2.0/saml2_helper.c | 19 +++++++++++++++++++ lasso/saml-2.0/saml2_helper.h | 3 +++ 3 files changed, 23 insertions(+) diff --git a/docs/reference/lasso/lasso-sections.txt b/docs/reference/lasso/lasso-sections.txt index 8028946b..147caeef 100644 --- a/docs/reference/lasso/lasso-sections.txt +++ b/docs/reference/lasso/lasso-sections.txt @@ -2727,6 +2727,7 @@ lasso_saml2_name_id_new lasso_saml2_name_id_new_with_string lasso_saml2_name_id_build_persistent lasso_saml2_name_id_equals +lasso_saml2_name_id_new_with_persistent_format LASSO_SAML2_NAME_ID LASSO_IS_SAML2_NAME_ID diff --git a/lasso/saml-2.0/saml2_helper.c b/lasso/saml-2.0/saml2_helper.c index ab946a5a..f922b1f2 100644 --- a/lasso/saml-2.0/saml2_helper.c +++ b/lasso/saml-2.0/saml2_helper.c @@ -94,6 +94,24 @@ lasso_saml2_assertion_is_audience_restricted(LassoSaml2Assertion *saml2_assertio return FALSE; } +/** + * lasso_saml2_name_id_new_with_persistent_format: + * @id: the identifier for the princiapl + * @idpID: the entity ID of the IdP + * @providerID: the entity ID of the provider + * + * Create a new #LassoSaml2NameID object, which the #LASSO_SAML2_NAME_IDENTIFIER_FORMAT_PERSISTENT + * format, @id as content, @idpID as NameQualifier and @providerID as SPNameQualifier. + * + * Since: 2.3 + * Return value: a newly created #LassoSaml2NameID + */ +LassoSaml2NameID* +lasso_saml2_name_id_new_with_persistent_format(const char *id, const char *idpID, const char *providerID) +{ + return lasso_saml2_name_id_build_persistent(id, idpID, providerID); +} + /** * lasso_saml2_name_id_build_persistent: * @id: the identifier for the princiapl @@ -104,6 +122,7 @@ lasso_saml2_assertion_is_audience_restricted(LassoSaml2Assertion *saml2_assertio * format, @id as content, @idpID as NameQualifier and @providerID as SPNameQualifier. * * Return value: a newly created #LassoSaml2NameID + * Deprecated: 2.3: use lasso_saml2_name_id_new_with_persistent_format() instead. */ LassoSaml2NameID* lasso_saml2_name_id_build_persistent(const char *id, const char *idpID, const char *providerID) diff --git a/lasso/saml-2.0/saml2_helper.h b/lasso/saml-2.0/saml2_helper.h index 9a86d0b0..30687220 100644 --- a/lasso/saml-2.0/saml2_helper.h +++ b/lasso/saml-2.0/saml2_helper.h @@ -145,6 +145,9 @@ LASSO_EXPORT LassoSaml2AssertionValidationState lasso_saml2_assertion_allows_pro LASSO_EXPORT void lasso_saml2_assertion_set_one_time_use(LassoSaml2Assertion *saml2_assertion, gboolean one_time_use); +LASSO_EXPORT LassoSaml2NameID* lasso_saml2_name_id_new_with_persistent_format(const char *id, + const char *idpID, const char *providerID); + #ifdef __cplusplus } #endif /* __cplusplus */ -- cgit