summaryrefslogtreecommitdiffstats
path: root/lasso/xml
diff options
context:
space:
mode:
Diffstat (limited to 'lasso/xml')
-rw-r--r--lasso/xml/lib_assertion.c3
-rw-r--r--lasso/xml/lib_authentication_statement.c9
-rw-r--r--lasso/xml/lib_authn_context.c12
-rw-r--r--lasso/xml/lib_authn_request.c57
-rw-r--r--lasso/xml/lib_authn_request_envelope.c26
-rw-r--r--lasso/xml/lib_authn_response.c11
-rw-r--r--lasso/xml/lib_authn_response_envelope.c12
-rw-r--r--lasso/xml/lib_federation_termination_notification.c11
-rw-r--r--lasso/xml/lib_idp_entries.c3
-rw-r--r--lasso/xml/lib_idp_entry.c9
-rw-r--r--lasso/xml/lib_idp_list.c6
-rw-r--r--lasso/xml/lib_logout_request.c26
-rw-r--r--lasso/xml/lib_name_identifier_mapping_request.c14
-rw-r--r--lasso/xml/lib_name_identifier_mapping_response.c11
-rw-r--r--lasso/xml/lib_register_name_identifier_request.c20
-rw-r--r--lasso/xml/lib_request_authn_context.c18
-rw-r--r--lasso/xml/lib_scoping.c6
-rw-r--r--lasso/xml/lib_status_response.c11
-rw-r--r--lasso/xml/lib_subject.c3
-rw-r--r--lasso/xml/saml_advice.c6
-rw-r--r--lasso/xml/saml_assertion.c33
-rw-r--r--lasso/xml/saml_audience_restriction_condition.c3
-rw-r--r--lasso/xml/saml_authentication_statement.c12
-rw-r--r--lasso/xml/saml_authority_binding.c9
-rw-r--r--lasso/xml/saml_conditions.c12
-rw-r--r--lasso/xml/saml_name_identifier.c6
-rw-r--r--lasso/xml/saml_subject.c6
-rw-r--r--lasso/xml/saml_subject_confirmation.c6
-rw-r--r--lasso/xml/saml_subject_locality.c6
-rw-r--r--lasso/xml/saml_subject_statement_abstract.c3
-rw-r--r--lasso/xml/samlp_request.c3
-rw-r--r--lasso/xml/samlp_request_abstract.c27
-rw-r--r--lasso/xml/samlp_response.c6
-rw-r--r--lasso/xml/samlp_response_abstract.c21
-rw-r--r--lasso/xml/samlp_status.c9
-rw-r--r--lasso/xml/samlp_status_code.c7
-rw-r--r--lasso/xml/soap-env_body.c3
-rw-r--r--lasso/xml/soap-env_envelope.c3
-rw-r--r--lasso/xml/tools.c12
-rw-r--r--lasso/xml/xml.c94
40 files changed, 363 insertions, 192 deletions
diff --git a/lasso/xml/lib_assertion.c b/lasso/xml/lib_assertion.c
index 2972c202..bf9e3859 100644
--- a/lasso/xml/lib_assertion.c
+++ b/lasso/xml/lib_assertion.c
@@ -59,10 +59,11 @@ void
lasso_lib_assertion_set_inResponseTo(LassoLibAssertion *node,
const xmlChar *inResponseTo)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_ASSERTION(node));
g_assert(inResponseTo != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "InResponseTo", inResponseTo);
}
diff --git a/lasso/xml/lib_authentication_statement.c b/lasso/xml/lib_authentication_statement.c
index 9524d304..f92852c0 100644
--- a/lasso/xml/lib_authentication_statement.c
+++ b/lasso/xml/lib_authentication_statement.c
@@ -50,10 +50,11 @@ void
lasso_lib_authentication_statement_set_authnContext(LassoLibAuthenticationStatement *node,
LassoLibAuthnContext *authnContext)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHENTICATION_STATEMENT(node));
g_assert(LASSO_IS_LIB_AUTHN_CONTEXT(authnContext));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE(authnContext), FALSE);
}
@@ -61,10 +62,11 @@ void
lasso_lib_authentication_statement_set_reauthenticateOnOrAfter(LassoLibAuthenticationStatement *node,
const xmlChar *reauthenticateOnOrAfter)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHENTICATION_STATEMENT(node));
g_assert(reauthenticateOnOrAfter != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "ReauthenticateOnOrAfter", reauthenticateOnOrAfter);
}
@@ -72,10 +74,11 @@ void
lasso_lib_authentication_statement_set_sessionIndex(LassoLibAuthenticationStatement *node,
const xmlChar *sessionIndex)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHENTICATION_STATEMENT(node));
g_assert(sessionIndex != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "SessionIndex", sessionIndex);
}
diff --git a/lasso/xml/lib_authn_context.c b/lasso/xml/lib_authn_context.c
index ecf6d346..a386e9ee 100644
--- a/lasso/xml/lib_authn_context.c
+++ b/lasso/xml/lib_authn_context.c
@@ -58,22 +58,26 @@ From schema liberty-authentication-context-v1.2.xsd:
void
lasso_lib_authn_context_set_authnContextClassRef(LassoLibAuthnContext *node,
- const xmlChar *authnContextClassRef) {
+ const xmlChar *authnContextClassRef)
+{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_CONTEXT(node));
g_assert(authnContextClassRef != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "AuthnContextClassRef",
authnContextClassRef, FALSE);
}
void
lasso_lib_authn_context_set_authnContextStatementRef(LassoLibAuthnContext *node,
- const xmlChar *authnContextStatementRef) {
+ const xmlChar *authnContextStatementRef)
+{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_CONTEXT(node));
g_assert(authnContextStatementRef != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "AuthnContextStatementRef",
authnContextStatementRef, FALSE);
}
diff --git a/lasso/xml/lib_authn_request.c b/lasso/xml/lib_authn_request.c
index d3ac8b09..b88bea12 100644
--- a/lasso/xml/lib_authn_request.c
+++ b/lasso/xml/lib_authn_request.c
@@ -85,22 +85,26 @@ From liberty-metadata-v1.0.xsd:
void
lasso_lib_authn_request_set_affiliationID(LassoLibAuthnRequest *node,
- const xmlChar *affiliationID) {
+ const xmlChar *affiliationID)
+{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_REQUEST(node));
g_assert(affiliationID != NULL);
- /* FIXME : affiliationID lenght SHOULD be <= 1024 */
+ /* FIXME : affiliationID length SHOULD be <= 1024 */
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "AffiliationID", affiliationID, FALSE);
}
void
lasso_lib_authn_request_set_assertionConsumerServiceID(LassoLibAuthnRequest *node,
- const xmlChar *assertionConsumerServiceID) {
+ const xmlChar *assertionConsumerServiceID)
+{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_REQUEST(node));
g_assert(assertionConsumerServiceID != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "AssertionConsumerServiceID",
assertionConsumerServiceID, FALSE);
}
@@ -109,20 +113,23 @@ void
lasso_lib_authn_request_set_consent(LassoLibAuthnRequest *node,
const xmlChar *consent)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_REQUEST(node));
g_assert(consent != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "consent", consent);
}
void
lasso_lib_authn_request_set_forceAuthn(LassoLibAuthnRequest *node,
- gboolean forceAuthn) {
+ gboolean forceAuthn)
+{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_REQUEST(node));
g_assert(forceAuthn == FALSE || forceAuthn == TRUE);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
if (forceAuthn == FALSE) {
class->new_child(LASSO_NODE (node), "ForceAuthn", "false", FALSE);
@@ -134,11 +141,13 @@ lasso_lib_authn_request_set_forceAuthn(LassoLibAuthnRequest *node,
void
lasso_lib_authn_request_set_isPassive(LassoLibAuthnRequest *node,
- gboolean isPassive) {
+ gboolean isPassive)
+{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_REQUEST(node));
g_assert(isPassive == FALSE || isPassive == TRUE);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
if (isPassive == FALSE) {
class->new_child(LASSO_NODE (node), "IsPassive", "false", FALSE);
}
@@ -159,10 +168,11 @@ void
lasso_lib_authn_request_set_nameIDPolicy(LassoLibAuthnRequest *node,
const xmlChar *nameIDPolicy)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_REQUEST(node));
g_assert(nameIDPolicy != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "NameIDPolicy", nameIDPolicy, FALSE);
}
@@ -170,10 +180,11 @@ void
lasso_lib_authn_request_set_protocolProfile(LassoLibAuthnRequest *node,
const xmlChar *protocolProfile)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_REQUEST(node));
g_assert(protocolProfile != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "ProtocolProfile", protocolProfile, FALSE);
}
@@ -181,32 +192,37 @@ void
lasso_lib_authn_request_set_providerID(LassoLibAuthnRequest *node,
const xmlChar *providerID)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_REQUEST(node));
g_assert(providerID != NULL);
- /* FIXME : providerID lenght SHOULD be <= 1024 */
+ /* FIXME : providerID length SHOULD be <= 1024 */
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "ProviderID", providerID, FALSE);
}
void
lasso_lib_authn_request_set_relayState(LassoLibAuthnRequest *node,
- const xmlChar *relayState) {
+ const xmlChar *relayState)
+{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_REQUEST(node));
g_assert(relayState != NULL);
- /* FIXME : RelayState lenght SHOULD be <= 80 */
+ /* FIXME : RelayState length SHOULD be <= 80 */
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "RelayState", relayState, FALSE);
}
void
lasso_lib_authn_request_set_requestAuthnContext(LassoLibAuthnRequest *node,
- LassoLibRequestAuthnContext *requestAuthnContext) {
+ LassoLibRequestAuthnContext *requestAuthnContext)
+{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_REQUEST(node));
g_assert(LASSO_IS_LIB_REQUEST_AUTHN_CONTEXT(requestAuthnContext));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node),
LASSO_NODE (requestAuthnContext),
FALSE);
@@ -223,10 +239,11 @@ void
lasso_lib_authn_request_set_scoping(LassoLibAuthnRequest *node,
LassoLibScoping *scoping)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_REQUEST(node));
g_assert(LASSO_IS_LIB_SCOPING(scoping));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node),
LASSO_NODE (scoping),
FALSE);
diff --git a/lasso/xml/lib_authn_request_envelope.c b/lasso/xml/lib_authn_request_envelope.c
index a2235496..6d7aa075 100644
--- a/lasso/xml/lib_authn_request_envelope.c
+++ b/lasso/xml/lib_authn_request_envelope.c
@@ -66,20 +66,22 @@ void
lasso_lib_authn_request_envelope_set_extension(LassoLibAuthnRequestEnvelope *node,
LassoNode *extension)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_REQUEST_ENVELOPE(node));
g_assert(LASSO_IS_NODE(extension));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE(node), extension, FALSE);
}
void lasso_lib_authn_request_envelope_set_authnRequest(LassoLibAuthnRequestEnvelope *node,
LassoLibAuthnRequest *request)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_REQUEST_ENVELOPE(node));
g_assert(LASSO_IS_LIB_AUTHN_REQUEST(request));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE(node), LASSO_NODE(request), FALSE);
}
@@ -87,10 +89,11 @@ void
lasso_lib_authn_request_envelope_set_assertionConsumerServiceURL(LassoLibAuthnRequestEnvelope *node,
const xmlChar *assertionConsumerServiceURL)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_REQUEST_ENVELOPE(node));
g_assert(assertionConsumerServiceURL != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE(node), "AssertionConsumerServiceURL", assertionConsumerServiceURL, FALSE);
}
@@ -98,41 +101,46 @@ void
lasso_lib_authn_request_envelope_set_providerID(LassoLibAuthnRequestEnvelope *node,
const xmlChar *providerID)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_REQUEST_ENVELOPE(node));
g_assert(providerID != NULL);
- /* FIXME : providerID lenght SHOULD be <= 1024 */
+ /* FIXME : providerID length SHOULD be <= 1024 */
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE(node), "ProviderID", providerID, FALSE);
}
void lasso_lib_authn_request_envelope_set_providerName(LassoLibAuthnRequestEnvelope *node,
const xmlChar *providerName)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_REQUEST_ENVELOPE(node));
g_assert(providerName != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE(node), "ProviderName", providerName, FALSE);
}
void lasso_lib_authn_request_envelope_set_idpList(LassoLibAuthnRequestEnvelope *node,
LassoLibIDPList *idpList)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_REQUEST_ENVELOPE(node));
g_assert(LASSO_IS_LIB_IDP_LIST(idpList));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE(node), LASSO_NODE(idpList), FALSE);
}
void
lasso_lib_authn_request_envelope_set_isPassive(LassoLibAuthnRequestEnvelope *node,
- gboolean isPassive) {
+ gboolean isPassive)
+{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_REQUEST_ENVELOPE(node));
g_assert(isPassive == FALSE || isPassive == TRUE);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
if (isPassive == FALSE) {
class->new_child(LASSO_NODE (node), "IsPassive", "false", FALSE);
}
diff --git a/lasso/xml/lib_authn_response.c b/lasso/xml/lib_authn_response.c
index 695c8a82..a5b62c0d 100644
--- a/lasso/xml/lib_authn_response.c
+++ b/lasso/xml/lib_authn_response.c
@@ -61,10 +61,11 @@ void
lasso_lib_authn_response_set_consent(LassoLibAuthnResponse *node,
const xmlChar *consent)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_RESPONSE(node));
g_assert(consent != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "consent", consent);
}
@@ -72,11 +73,12 @@ void
lasso_lib_authn_response_set_providerID(LassoLibAuthnResponse *node,
const xmlChar *providerID)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_RESPONSE(node));
g_assert(providerID != NULL);
- /* FIXME : providerID lenght SHOULD be <= 1024 */
+ /* FIXME : providerID length SHOULD be <= 1024 */
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "ProviderID", providerID, FALSE);
}
@@ -84,10 +86,11 @@ void
lasso_lib_authn_response_set_relayState(LassoLibAuthnResponse *node,
const xmlChar *relayState)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_RESPONSE(node));
g_assert(relayState != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "RelayState", relayState, FALSE);
}
diff --git a/lasso/xml/lib_authn_response_envelope.c b/lasso/xml/lib_authn_response_envelope.c
index 2b23e4e6..b53e85ad 100644
--- a/lasso/xml/lib_authn_response_envelope.c
+++ b/lasso/xml/lib_authn_response_envelope.c
@@ -35,10 +35,11 @@ void
lasso_lib_authn_response_envelope_set_extension(LassoLibAuthnResponseEnvelope *node,
LassoNode *extension)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_RESPONSE_ENVELOPE(node));
g_assert(LASSO_NODE(extension));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE(extension), extension, FALSE);
}
@@ -46,20 +47,23 @@ void
lasso_lib_authn_response_envelope_set_authnResponse(LassoLibAuthnResponseEnvelope *node,
LassoLibAuthnResponse *authnResponse_node)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_RESPONSE_ENVELOPE(node));
g_assert(LASSO_IS_LIB_AUTHN_RESPONSE(authnResponse_node));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE(node), LASSO_NODE(authnResponse_node), FALSE);
}
void
lasso_lib_authn_response_envelope_set_assertionConsumerServiceURL(LassoLibAuthnResponseEnvelope *node,
- const xmlChar *url) {
+ const xmlChar *url)
+{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_AUTHN_RESPONSE_ENVELOPE(node));
g_assert(url != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "AssertionConsumerServiceURL",
url, FALSE);
}
diff --git a/lasso/xml/lib_federation_termination_notification.c b/lasso/xml/lib_federation_termination_notification.c
index d7d2d6b1..80071d0a 100644
--- a/lasso/xml/lib_federation_termination_notification.c
+++ b/lasso/xml/lib_federation_termination_notification.c
@@ -61,10 +61,11 @@ void
lasso_lib_federation_termination_notification_set_consent(LassoLibFederationTerminationNotification *node,
const xmlChar *consent)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_FEDERATION_TERMINATION_NOTIFICATION(node));
g_assert(consent != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "consent", consent);
}
@@ -72,11 +73,12 @@ void
lasso_lib_federation_termination_notification_set_providerID(LassoLibFederationTerminationNotification *node,
const xmlChar *providerID)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_FEDERATION_TERMINATION_NOTIFICATION(node));
g_assert(providerID != NULL);
- /* FIXME : providerId lenght SHOULD be <= 1024 */
+ /* FIXME : providerId length SHOULD be <= 1024 */
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "ProviderID", providerID, FALSE);
}
@@ -84,10 +86,11 @@ void
lasso_lib_federation_termination_notification_set_nameIdentifier(LassoLibFederationTerminationNotification *node,
LassoSamlNameIdentifier *nameIdentifier)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_FEDERATION_TERMINATION_NOTIFICATION(node));
g_assert(LASSO_IS_SAML_NAME_IDENTIFIER(nameIdentifier));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE (nameIdentifier), FALSE);
}
diff --git a/lasso/xml/lib_idp_entries.c b/lasso/xml/lib_idp_entries.c
index b9c14558..450d1317 100644
--- a/lasso/xml/lib_idp_entries.c
+++ b/lasso/xml/lib_idp_entries.c
@@ -54,10 +54,11 @@ void
lasso_lib_idp_entries_add_idpEntry(LassoLibIDPEntries *node,
LassoLibIDPEntry *idpEntry)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_IDP_ENTRIES(node));
g_assert(LASSO_IS_LIB_IDP_ENTRY(idpEntry));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE(idpEntry), TRUE);
}
diff --git a/lasso/xml/lib_idp_entry.c b/lasso/xml/lib_idp_entry.c
index 995e1c99..a301db6d 100644
--- a/lasso/xml/lib_idp_entry.c
+++ b/lasso/xml/lib_idp_entry.c
@@ -56,10 +56,11 @@ void
lasso_lib_idp_entry_set_providerID(LassoLibIDPEntry *node,
const xmlChar *providerID)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_IDP_ENTRY(node));
g_assert(providerID != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "ProviderID", providerID, FALSE);
}
@@ -76,10 +77,11 @@ void
lasso_lib_idp_entry_set_providerName(LassoLibIDPEntry *node,
const xmlChar *providerName)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_IDP_ENTRY(node));
g_assert(providerName != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "ProviderName", providerName, FALSE);
}
@@ -99,10 +101,11 @@ void
lasso_lib_idp_entry_set_loc(LassoLibIDPEntry *node,
const xmlChar *loc)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_IDP_ENTRY(node));
g_assert(loc != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "Loc", loc, FALSE);
}
diff --git a/lasso/xml/lib_idp_list.c b/lasso/xml/lib_idp_list.c
index 9facba51..5c230bbc 100644
--- a/lasso/xml/lib_idp_list.c
+++ b/lasso/xml/lib_idp_list.c
@@ -57,10 +57,11 @@ void
lasso_lib_idp_list_set_getComplete(LassoLibIDPList *node,
const xmlChar *getComplete)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_IDP_LIST(node));
g_assert(getComplete != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "GetComplete", getComplete, FALSE);
}
@@ -77,10 +78,11 @@ void
lasso_lib_idp_list_set_idpEntries(LassoLibIDPList *node,
LassoLibIDPEntries *idpEntries)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_IDP_LIST(node));
g_assert(LASSO_IS_LIB_IDP_ENTRIES(idpEntries));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE(idpEntries), FALSE);
}
diff --git a/lasso/xml/lib_logout_request.c b/lasso/xml/lib_logout_request.c
index 8cac4a97..615cddfa 100644
--- a/lasso/xml/lib_logout_request.c
+++ b/lasso/xml/lib_logout_request.c
@@ -63,20 +63,23 @@ void
lasso_lib_logout_request_set_consent(LassoLibLogoutRequest *node,
const xmlChar *consent)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_LOGOUT_REQUEST(node));
g_assert(consent != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "consent", consent);
}
void
lasso_lib_logout_request_set_nameIdentifier(LassoLibLogoutRequest *node,
- LassoSamlNameIdentifier *nameIdentifier) {
+ LassoSamlNameIdentifier *nameIdentifier)
+{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_LOGOUT_REQUEST(node));
g_assert(LASSO_IS_SAML_NAME_IDENTIFIER(nameIdentifier));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE (nameIdentifier), FALSE);
}
@@ -84,31 +87,36 @@ void
lasso_lib_logout_request_set_providerID(LassoLibLogoutRequest *node,
const xmlChar *providerID)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_LOGOUT_REQUEST(node));
g_assert(providerID != NULL);
- /* FIXME : providerID lenght SHOULD be <= 1024 */
+ /* FIXME : providerID length SHOULD be <= 1024 */
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "ProviderID", providerID, FALSE);
}
void
lasso_lib_logout_request_set_relayState(LassoLibLogoutRequest *node,
- const xmlChar *relayState) {
+ const xmlChar *relayState)
+{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_LOGOUT_REQUEST(node));
g_assert(relayState != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "RelayState", relayState, FALSE);
}
void
lasso_lib_logout_request_set_sessionIndex(LassoLibLogoutRequest *node,
- const xmlChar *sessionIndex) {
+ const xmlChar *sessionIndex)
+{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_LOGOUT_REQUEST(node));
g_assert(sessionIndex != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "SessionIndex", sessionIndex, FALSE);
}
diff --git a/lasso/xml/lib_name_identifier_mapping_request.c b/lasso/xml/lib_name_identifier_mapping_request.c
index e2e08ab8..b43e69e9 100644
--- a/lasso/xml/lib_name_identifier_mapping_request.c
+++ b/lasso/xml/lib_name_identifier_mapping_request.c
@@ -61,10 +61,11 @@ void
lasso_lib_name_identifier_mapping_request_set_consent(LassoLibNameIdentifierMappingRequest *node,
const xmlChar *consent)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_NAME_IDENTIFIER_MAPPING_REQUEST(node));
g_assert(consent != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "consent", consent);
}
@@ -72,21 +73,24 @@ void
lasso_lib_name_identifier_mapping_request_set_providerID(LassoLibNameIdentifierMappingRequest *node,
const xmlChar *providerID)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_NAME_IDENTIFIER_MAPPING_REQUEST(node));
g_assert(providerID != NULL);
- /* FIXME : providerId lenght SHOULD be <= 1024 */
+ /* FIXME : providerId length SHOULD be <= 1024 */
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "ProviderID", providerID, FALSE);
}
void
lasso_lib_name_identifier_mapping_request_set_nameIdentifier(LassoLibNameIdentifierMappingRequest *node,
- LassoSamlNameIdentifier *nameIdentifier) {
+ LassoSamlNameIdentifier *nameIdentifier)
+{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_NAME_IDENTIFIER_MAPPING_REQUEST(node));
g_assert(LASSO_IS_SAML_NAME_IDENTIFIER(nameIdentifier));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE (nameIdentifier), FALSE);
}
diff --git a/lasso/xml/lib_name_identifier_mapping_response.c b/lasso/xml/lib_name_identifier_mapping_response.c
index 059477a1..e72b773d 100644
--- a/lasso/xml/lib_name_identifier_mapping_response.c
+++ b/lasso/xml/lib_name_identifier_mapping_response.c
@@ -51,10 +51,11 @@ The Schema fragment (liberty-idff-protocols-schema-v1.2.xsd):
void lasso_lib_name_identifier_mapping_response_set_nameIdentifier(LassoLibNameIdentifierMappingResponse *node,
LassoSamlNameIdentifier *nameIdentifier)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_NAME_IDENTIFIER_MAPPING_RESPONSE(node));
g_assert(LASSO_IS_SAML_NAME_IDENTIFIER(nameIdentifier));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node),
LASSO_NODE (nameIdentifier),
FALSE);
@@ -64,21 +65,23 @@ void
lasso_lib_name_identifier_mapping_response_set_providerID(LassoLibNameIdentifierMappingResponse *node,
const xmlChar *providerID)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_NAME_IDENTIFIER_MAPPING_RESPONSE(node));
g_assert(providerID != NULL);
- /* FIXME : providerID lenght SHOULD be <= 1024 */
+ /* FIXME : providerID length SHOULD be <= 1024 */
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "ProviderID", providerID, FALSE);
}
void lasso_lib_name_identifier_mapping_response_set_status(LassoLibNameIdentifierMappingResponse *node,
LassoSamlpStatus *status)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_NAME_IDENTIFIER_MAPPING_RESPONSE(node));
g_assert(LASSO_IS_SAMLP_STATUS(status));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE(status), FALSE);
}
diff --git a/lasso/xml/lib_register_name_identifier_request.c b/lasso/xml/lib_register_name_identifier_request.c
index c0ac87ab..a62bd855 100644
--- a/lasso/xml/lib_register_name_identifier_request.c
+++ b/lasso/xml/lib_register_name_identifier_request.c
@@ -67,10 +67,11 @@ void
lasso_lib_register_name_identifier_request_set_idpProvidedNameIdentifier(LassoLibRegisterNameIdentifierRequest *node,
LassoLibIDPProvidedNameIdentifier *idpProvidedNameIdentifier)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_REGISTER_NAME_IDENTIFIER_REQUEST(node));
g_assert(LASSO_IS_LIB_IDP_PROVIDED_NAME_IDENTIFIER(idpProvidedNameIdentifier));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node),
LASSO_NODE (idpProvidedNameIdentifier),
FALSE);
@@ -80,10 +81,11 @@ void
lasso_lib_register_name_identifier_request_set_oldProvidedNameIdentifier(LassoLibRegisterNameIdentifierRequest *node,
LassoLibOLDProvidedNameIdentifier *oldProvidedNameIdentifier)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_REGISTER_NAME_IDENTIFIER_REQUEST(node));
g_assert(LASSO_IS_LIB_OLD_PROVIDED_NAME_IDENTIFIER(oldProvidedNameIdentifier));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node),
LASSO_NODE (oldProvidedNameIdentifier),
FALSE);
@@ -93,21 +95,24 @@ void
lasso_lib_register_name_identifier_request_set_providerID(LassoLibRegisterNameIdentifierRequest *node,
const xmlChar *providerID)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_REGISTER_NAME_IDENTIFIER_REQUEST(node));
g_assert(providerID != NULL);
- /* FIXME : providerID lenght SHOULD be <= 1024 */
+ /* FIXME : providerID length SHOULD be <= 1024 */
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "ProviderID", providerID, FALSE);
}
void
lasso_lib_register_name_identifier_request_set_relayState(LassoLibRegisterNameIdentifierRequest *node,
- const xmlChar *relayState) {
+ const xmlChar *relayState)
+{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_REGISTER_NAME_IDENTIFIER_REQUEST(node));
g_assert(relayState != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "RelayState", relayState, FALSE);
}
@@ -115,10 +120,11 @@ void
lasso_lib_register_name_identifier_request_set_spProvidedNameIdentifier(LassoLibRegisterNameIdentifierRequest *node,
LassoLibSPProvidedNameIdentifier *spProvidedNameIdentifier)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_REGISTER_NAME_IDENTIFIER_REQUEST(node));
g_assert(LASSO_IS_LIB_SP_PROVIDED_NAME_IDENTIFIER(spProvidedNameIdentifier));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node),
LASSO_NODE (spProvidedNameIdentifier),
FALSE);
diff --git a/lasso/xml/lib_request_authn_context.c b/lasso/xml/lib_request_authn_context.c
index 3a558a2f..52604086 100644
--- a/lasso/xml/lib_request_authn_context.c
+++ b/lasso/xml/lib_request_authn_context.c
@@ -50,33 +50,39 @@ Schema fragment (liberty-idff-protocols-schema-v1.2.xsd):
void
lasso_lib_request_authn_context_add_authnContextClassRef(LassoLibRequestAuthnContext *node,
- const xmlChar *authnContextClassRef) {
+ const xmlChar *authnContextClassRef)
+{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_REQUEST_AUTHN_CONTEXT(node));
g_assert(authnContextClassRef != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "AuthnContextClassRef",
authnContextClassRef, TRUE);
}
void
lasso_lib_request_authn_context_add_authnContextStatementRef(LassoLibRequestAuthnContext *node,
- const xmlChar *authnContextStatementRef) {
+ const xmlChar *authnContextStatementRef)
+{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_REQUEST_AUTHN_CONTEXT(node));
g_assert(authnContextStatementRef != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "AuthnContextStatementRef",
authnContextStatementRef, TRUE);
}
void
lasso_lib_request_authn_context_set_authnContextComparison(LassoLibRequestAuthnContext *node,
- const xmlChar *authnContextComparison) {
+ const xmlChar *authnContextComparison)
+{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_REQUEST_AUTHN_CONTEXT(node));
g_assert(authnContextComparison != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "AuthnContextComparison",
authnContextComparison, FALSE);
}
diff --git a/lasso/xml/lib_scoping.c b/lasso/xml/lib_scoping.c
index acc637c8..d156a067 100644
--- a/lasso/xml/lib_scoping.c
+++ b/lasso/xml/lib_scoping.c
@@ -60,12 +60,13 @@ lasso_lib_scoping_set_proxyCount(LassoLibScoping *node,
gint proxyCount)
{
gchar str[6];
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_SCOPING(node));
g_assert(proxyCount >= 0);
g_sprintf(str, "%d", proxyCount);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "ProxyCount", str, FALSE);
}
@@ -84,10 +85,11 @@ void
lasso_lib_scoping_set_idpList(LassoLibScoping *node,
LassoLibIDPList *idpList)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_SCOPING(node));
g_assert(LASSO_IS_LIB_IDP_LIST(idpList));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE(idpList), FALSE);
}
diff --git a/lasso/xml/lib_status_response.c b/lasso/xml/lib_status_response.c
index 885acf72..6ccc8470 100644
--- a/lasso/xml/lib_status_response.c
+++ b/lasso/xml/lib_status_response.c
@@ -61,11 +61,12 @@ void
lasso_lib_status_response_set_providerID(LassoLibStatusResponse *node,
const xmlChar *providerID)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_STATUS_RESPONSE(node));
g_assert(providerID != NULL);
- /* FIXME : providerID lenght SHOULD be <= 1024 */
+ /* FIXME : providerID length SHOULD be <= 1024 */
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "ProviderID", providerID, FALSE);
}
@@ -73,10 +74,11 @@ void
lasso_lib_status_response_set_relayState(LassoLibStatusResponse *node,
const xmlChar *relayState)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_STATUS_RESPONSE(node));
g_assert(relayState != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "RelayState", relayState, FALSE);
}
@@ -84,10 +86,11 @@ void
lasso_lib_status_response_set_status(LassoLibStatusResponse *node,
LassoSamlpStatus *status)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_STATUS_RESPONSE(node));
g_assert(LASSO_IS_SAMLP_STATUS(status));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE (status), FALSE);
}
diff --git a/lasso/xml/lib_subject.c b/lasso/xml/lib_subject.c
index cf3012b4..4573f175 100644
--- a/lasso/xml/lib_subject.c
+++ b/lasso/xml/lib_subject.c
@@ -49,10 +49,11 @@ void
lasso_lib_subject_set_idpProvidedNameIdentifier(LassoLibSubject *node,
LassoLibIDPProvidedNameIdentifier *idpProvidedNameIdentifier)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_LIB_SUBJECT(node));
g_assert(LASSO_IS_LIB_IDP_PROVIDED_NAME_IDENTIFIER(idpProvidedNameIdentifier));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE(idpProvidedNameIdentifier), FALSE);
}
diff --git a/lasso/xml/saml_advice.c b/lasso/xml/saml_advice.c
index a0eed5b7..1e1b9a17 100644
--- a/lasso/xml/saml_advice.c
+++ b/lasso/xml/saml_advice.c
@@ -51,10 +51,11 @@ void
lasso_saml_advice_add_assertionIDReference(LassoSamlAdvice *node,
const xmlChar *assertionIDReference)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_ADVICE(node));
g_assert(assertionIDReference != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node),
"AssertionIDReference",
assertionIDReference,
@@ -65,10 +66,11 @@ void
lasso_saml_advice_add_assertion(LassoSamlAdvice *node,
gpointer *assertion)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_ADVICE(node));
/* g_assert(LASSO_IS_SAML_ASSERTION(assertion)); */
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE (assertion), TRUE);
}
diff --git a/lasso/xml/saml_assertion.c b/lasso/xml/saml_assertion.c
index c2e5692e..43708e33 100644
--- a/lasso/xml/saml_assertion.c
+++ b/lasso/xml/saml_assertion.c
@@ -65,10 +65,11 @@ void
lasso_saml_assertion_add_authenticationStatement(LassoSamlAssertion *node,
LassoSamlAuthenticationStatement *authenticationStatement)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_ASSERTION(node));
g_assert(LASSO_IS_SAML_AUTHENTICATION_STATEMENT(authenticationStatement));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE(authenticationStatement), TRUE);
}
@@ -76,10 +77,11 @@ void
lasso_saml_assertion_add_statement(LassoSamlAssertion *node,
LassoSamlStatementAbstract *statement)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_ASSERTION(node));
g_assert(LASSO_IS_SAML_STATEMENT_ABSTRACT(statement));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE(statement), TRUE);
}
@@ -87,10 +89,11 @@ void
lasso_saml_assertion_add_subjectStatement(LassoSamlAssertion *node,
LassoSamlSubjectStatementAbstract *subjectStatement)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_ASSERTION(node));
g_assert(LASSO_IS_SAML_SUBJECT_STATEMENT_ABSTRACT(subjectStatement));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE(subjectStatement), TRUE);
}
@@ -109,10 +112,11 @@ void
lasso_saml_assertion_set_advice(LassoSamlAssertion *node,
LassoSamlAdvice *advice)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_ASSERTION(node));
g_assert(LASSO_IS_SAML_ADVICE(advice));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE(advice), FALSE);
}
@@ -130,10 +134,11 @@ void
lasso_saml_assertion_set_assertionID(LassoSamlAssertion *node,
const xmlChar *assertionID)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_ASSERTION(node));
g_assert(assertionID != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "AssertionID", assertionID);
}
@@ -151,10 +156,11 @@ void
lasso_saml_assertion_set_conditions(LassoSamlAssertion *node,
LassoSamlConditions *conditions)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_ASSERTION(node));
g_assert(LASSO_IS_SAML_CONDITIONS(conditions));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE(conditions), FALSE);
}
@@ -172,10 +178,11 @@ void
lasso_saml_assertion_set_issueInstant(LassoSamlAssertion *node,
const xmlChar *issueInstant)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_ASSERTION(node));
g_assert(issueInstant != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "IssueInstant", issueInstant);
}
@@ -195,10 +202,11 @@ void
lasso_saml_assertion_set_issuer(LassoSamlAssertion *node,
const xmlChar *issuer)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_ASSERTION(node));
g_assert(issuer != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "Issuer", issuer);
}
@@ -217,10 +225,11 @@ void
lasso_saml_assertion_set_majorVersion(LassoSamlAssertion *node,
const xmlChar *majorVersion)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_ASSERTION(node));
g_assert(majorVersion != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "MajorVersion", majorVersion);
}
@@ -239,10 +248,11 @@ void
lasso_saml_assertion_set_minorVersion(LassoSamlAssertion *node,
const xmlChar *minorVersion)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_ASSERTION(node));
g_assert(minorVersion != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "MinorVersion", minorVersion);
}
@@ -255,6 +265,7 @@ lasso_saml_assertion_set_signature(LassoSamlAssertion *node,
{
gint ret;
GError *tmp_err = NULL;
+ LassoNodeClass *class;
if (err != NULL && *err != NULL) {
g_set_error(err, g_quark_from_string("Lasso"),
@@ -271,7 +282,7 @@ lasso_saml_assertion_set_signature(LassoSamlAssertion *node,
LASSO_PARAM_ERROR_BADTYPE_OR_NULL_OBJ);
}
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
ret = class->add_signature(LASSO_NODE (node), sign_method,
private_key_file, certificate_file, &tmp_err);
diff --git a/lasso/xml/saml_audience_restriction_condition.c b/lasso/xml/saml_audience_restriction_condition.c
index 055fe2d6..22f38952 100644
--- a/lasso/xml/saml_audience_restriction_condition.c
+++ b/lasso/xml/saml_audience_restriction_condition.c
@@ -61,10 +61,11 @@ void
lasso_saml_audience_restriction_condition_add_audience(LassoSamlAudienceRestrictionCondition *node,
const xmlChar *audience)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_AUDIENCE_RESTRICTION_CONDITION(node));
g_assert(audience != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "Audience", audience, TRUE);
}
diff --git a/lasso/xml/saml_authentication_statement.c b/lasso/xml/saml_authentication_statement.c
index 426d5fc0..b9842267 100644
--- a/lasso/xml/saml_authentication_statement.c
+++ b/lasso/xml/saml_authentication_statement.c
@@ -51,10 +51,11 @@ void
lasso_saml_authentication_statement_add_authorityBinding(LassoSamlAuthenticationStatement *node,
LassoSamlAuthorityBinding *authorityBinding)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_AUTHENTICATION_STATEMENT(node));
g_assert(LASSO_IS_SAML_AUTHORITY_BINDING(authorityBinding));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE(authorityBinding), TRUE);
}
@@ -62,10 +63,11 @@ void
lasso_saml_authentication_statement_set_authenticationInstant(LassoSamlAuthenticationStatement *node,
const xmlChar *authenticationInstant)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_AUTHENTICATION_STATEMENT(node));
g_assert(authenticationInstant != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "AuthenticationInstant", authenticationInstant);
}
@@ -73,10 +75,11 @@ void
lasso_saml_authentication_statement_set_authenticationMethod(LassoSamlAuthenticationStatement *node,
const xmlChar *authenticationMethod)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_AUTHENTICATION_STATEMENT(node));
g_assert(authenticationMethod != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "AuthenticationMethod", authenticationMethod);
}
@@ -84,10 +87,11 @@ void
lasso_saml_authentication_statement_set_subjectLocality(LassoSamlAuthenticationStatement *node,
LassoSamlSubjectLocality *subjectLocality)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_AUTHENTICATION_STATEMENT(node));
g_assert(LASSO_IS_SAML_SUBJECT_LOCALITY(subjectLocality));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE(subjectLocality), FALSE);
}
diff --git a/lasso/xml/saml_authority_binding.c b/lasso/xml/saml_authority_binding.c
index cf5eef01..f1368054 100644
--- a/lasso/xml/saml_authority_binding.c
+++ b/lasso/xml/saml_authority_binding.c
@@ -45,10 +45,11 @@ void
lasso_saml_authority_binding_set_authorityKind(LassoSamlAuthorityBinding *node,
const xmlChar *authorityKind)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_AUTHORITY_BINDING(node));
g_assert(authorityKind != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "AuthorityKind", authorityKind);
}
@@ -56,10 +57,11 @@ void
lasso_saml_authority_binding_set_binding(LassoSamlAuthorityBinding *node,
const xmlChar *binding)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_AUTHORITY_BINDING(node));
g_assert(binding != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "Binding", binding);
}
@@ -67,10 +69,11 @@ void
lasso_saml_authority_binding_set_location(LassoSamlAuthorityBinding *node,
const xmlChar *location)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_AUTHORITY_BINDING(node));
g_assert(location != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "Location", location);
}
diff --git a/lasso/xml/saml_conditions.c b/lasso/xml/saml_conditions.c
index f61a8856..ff51dcec 100644
--- a/lasso/xml/saml_conditions.c
+++ b/lasso/xml/saml_conditions.c
@@ -54,10 +54,11 @@ void
lasso_saml_conditions_add_condition(LassoSamlConditions *node,
LassoSamlConditionAbstract *condition)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_CONDITIONS(node));
g_assert(LASSO_IS_SAML_CONDITION_ABSTRACT(condition));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE(condition), TRUE);
}
@@ -72,10 +73,11 @@ void
lasso_saml_conditions_add_audienceRestrictionCondition(LassoSamlConditions *node,
LassoSamlAudienceRestrictionCondition *audienceRestrictionCondition)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_CONDITIONS(node));
g_assert(LASSO_IS_SAML_AUDIENCE_RESTRICTION_CONDITION(audienceRestrictionCondition));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE(audienceRestrictionCondition), TRUE);
}
@@ -94,10 +96,11 @@ void
lasso_saml_conditions_set_notBefore(LassoSamlConditions *node,
const xmlChar *notBefore)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_CONDITIONS(node));
g_assert(notBefore != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "NotBefore", notBefore);
}
@@ -116,10 +119,11 @@ void
lasso_saml_conditions_set_notOnOrAfter(LassoSamlConditions *node,
const xmlChar *notOnOrAfter)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_CONDITIONS(node));
g_assert(notOnOrAfter != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "NotOnOrAfter", notOnOrAfter);
}
diff --git a/lasso/xml/saml_name_identifier.c b/lasso/xml/saml_name_identifier.c
index 2b30c231..73c8da58 100644
--- a/lasso/xml/saml_name_identifier.c
+++ b/lasso/xml/saml_name_identifier.c
@@ -47,10 +47,11 @@ void
lasso_saml_name_identifier_set_format(LassoSamlNameIdentifier *node,
const xmlChar *format)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_NAME_IDENTIFIER(node));
g_assert(format != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "Format", format);
}
@@ -58,10 +59,11 @@ void
lasso_saml_name_identifier_set_nameQualifier(LassoSamlNameIdentifier *node,
const xmlChar *nameQualifier)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_NAME_IDENTIFIER(node));
g_assert(nameQualifier != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "NameQualifier", nameQualifier);
}
diff --git a/lasso/xml/saml_subject.c b/lasso/xml/saml_subject.c
index b3841b34..782df280 100644
--- a/lasso/xml/saml_subject.c
+++ b/lasso/xml/saml_subject.c
@@ -48,10 +48,11 @@ void
lasso_saml_subject_set_nameIdentifier(LassoSamlSubject *node,
LassoSamlNameIdentifier *nameIdentifier)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_SUBJECT(node));
g_assert(LASSO_IS_SAML_NAME_IDENTIFIER(nameIdentifier));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE(nameIdentifier), FALSE);
}
@@ -59,10 +60,11 @@ void
lasso_saml_subject_set_subjectConfirmation(LassoSamlSubject *node,
LassoSamlSubjectConfirmation *subjectConfirmation)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_SUBJECT(node));
g_assert(LASSO_IS_SAML_SUBJECT_CONFIRMATION(subjectConfirmation));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE (subjectConfirmation), FALSE);
}
diff --git a/lasso/xml/saml_subject_confirmation.c b/lasso/xml/saml_subject_confirmation.c
index 19673da9..b882de46 100644
--- a/lasso/xml/saml_subject_confirmation.c
+++ b/lasso/xml/saml_subject_confirmation.c
@@ -49,10 +49,11 @@ void
lasso_saml_subject_confirmation_add_confirmationMethod(LassoSamlSubjectConfirmation *node,
const xmlChar *confirmationMethod)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_SUBJECT_CONFIRMATION(node));
g_assert(confirmationMethod != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node),
"ConfirmationMethod", confirmationMethod, TRUE);
}
@@ -61,10 +62,11 @@ void
lasso_saml_subject_confirmation_set_subjectConfirmationMethod(LassoSamlSubjectConfirmation *node,
const xmlChar *subjectConfirmationMethod)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_SUBJECT_CONFIRMATION(node));
g_assert(subjectConfirmationMethod != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node),
"SubjectConfirmationMethod", subjectConfirmationMethod,
FALSE);
diff --git a/lasso/xml/saml_subject_locality.c b/lasso/xml/saml_subject_locality.c
index 4bad6b2a..1ab1e8ad 100644
--- a/lasso/xml/saml_subject_locality.c
+++ b/lasso/xml/saml_subject_locality.c
@@ -43,10 +43,11 @@ void
lasso_saml_subject_locality_set_dnsAddress(LassoSamlSubjectLocality *node,
const xmlChar *dnsAddress)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_SUBJECT_LOCALITY(node));
g_assert(dnsAddress != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "DNSAddress", dnsAddress);
}
@@ -54,10 +55,11 @@ void
lasso_saml_subject_locality_set_ipAddress(LassoSamlSubjectLocality *node,
const xmlChar *ipAddress)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_SUBJECT_LOCALITY(node));
g_assert(ipAddress != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "IPAddress", ipAddress);
}
diff --git a/lasso/xml/saml_subject_statement_abstract.c b/lasso/xml/saml_subject_statement_abstract.c
index 27751dfd..f7879012 100644
--- a/lasso/xml/saml_subject_statement_abstract.c
+++ b/lasso/xml/saml_subject_statement_abstract.c
@@ -48,10 +48,11 @@ void
lasso_saml_subject_statement_abstract_set_subject(LassoSamlSubjectStatementAbstract *node,
LassoSamlSubject *subject)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAML_SUBJECT_STATEMENT_ABSTRACT(node));
g_assert(LASSO_IS_SAML_SUBJECT(subject));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE(subject), FALSE);
}
diff --git a/lasso/xml/samlp_request.c b/lasso/xml/samlp_request.c
index 43d02275..a9d3d158 100644
--- a/lasso/xml/samlp_request.c
+++ b/lasso/xml/samlp_request.c
@@ -55,10 +55,11 @@ void
lasso_samlp_request_set_assertionArtifact(LassoSamlpRequest *node,
const xmlChar *assertionArtifact)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAMLP_REQUEST(node));
g_assert(assertionArtifact != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "AssertionArtifact", assertionArtifact, FALSE);
}
diff --git a/lasso/xml/samlp_request_abstract.c b/lasso/xml/samlp_request_abstract.c
index dbe238ce..8040d137 100644
--- a/lasso/xml/samlp_request_abstract.c
+++ b/lasso/xml/samlp_request_abstract.c
@@ -58,40 +58,47 @@ void
lasso_samlp_request_abstract_add_respondWith(LassoSamlpRequestAbstract *node,
const xmlChar *respondWith)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAMLP_REQUEST_ABSTRACT(node));
g_assert(respondWith != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "RespondWith", respondWith, TRUE);
}
void
lasso_samlp_request_abstract_set_issueInstant(LassoSamlpRequestAbstract *node,
- const xmlChar *issueInstant) {
+ const xmlChar *issueInstant)
+{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAMLP_REQUEST_ABSTRACT(node));
g_assert(issueInstant != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "IssueInstant", issueInstant);
}
void
lasso_samlp_request_abstract_set_majorVersion(LassoSamlpRequestAbstract *node,
- const xmlChar *majorVersion) {
+ const xmlChar *majorVersion)
+{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAMLP_REQUEST_ABSTRACT(node));
g_assert(majorVersion != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "MajorVersion", majorVersion);
}
void
lasso_samlp_request_abstract_set_minorVersion(LassoSamlpRequestAbstract *node,
- const xmlChar *minorVersion) {
+ const xmlChar *minorVersion)
+{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAMLP_REQUEST_ABSTRACT(node));
g_assert(minorVersion != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "MinorVersion", minorVersion);
}
@@ -106,10 +113,11 @@ void
lasso_samlp_request_abstract_set_requestID(LassoSamlpRequestAbstract *node,
const xmlChar *requestID)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAMLP_REQUEST_ABSTRACT(node));
g_assert(requestID != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "RequestID", requestID);
}
@@ -122,6 +130,7 @@ lasso_samlp_request_abstract_set_signature(LassoSamlpRequestAbstract *node,
{
gint ret;
GError *tmp_err = NULL;
+ LassoNodeClass *class;
if (err != NULL && *err != NULL) {
g_set_error(err, g_quark_from_string("Lasso"),
@@ -138,7 +147,7 @@ lasso_samlp_request_abstract_set_signature(LassoSamlpRequestAbstract *node,
LASSO_PARAM_ERROR_BADTYPE_OR_NULL_OBJ);
}
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
ret = class->add_signature(LASSO_NODE (node), sign_method,
private_key_file, certificate_file, &tmp_err);
diff --git a/lasso/xml/samlp_response.c b/lasso/xml/samlp_response.c
index b408cf18..31056bf7 100644
--- a/lasso/xml/samlp_response.c
+++ b/lasso/xml/samlp_response.c
@@ -50,10 +50,11 @@ void
lasso_samlp_response_add_assertion(LassoSamlpResponse *node,
gpointer assertion)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAMLP_RESPONSE(node));
/* g_assert(LASSO_IS_SAML_ASSERTION(assertion)); */
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE(assertion), TRUE);
}
@@ -61,10 +62,11 @@ void
lasso_samlp_response_set_status(LassoSamlpResponse *node,
LassoSamlpStatus *status)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAMLP_RESPONSE(node));
g_assert(LASSO_IS_SAMLP_STATUS(status));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE(status), FALSE);
}
diff --git a/lasso/xml/samlp_response_abstract.c b/lasso/xml/samlp_response_abstract.c
index cbbb517c..04c3cbba 100644
--- a/lasso/xml/samlp_response_abstract.c
+++ b/lasso/xml/samlp_response_abstract.c
@@ -59,10 +59,11 @@ void
lasso_samlp_response_abstract_set_inResponseTo(LassoSamlpResponseAbstract *node,
const xmlChar *inResponseTo)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAMLP_RESPONSE_ABSTRACT(node));
g_assert(inResponseTo != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "InResponseTo", inResponseTo);
}
@@ -70,10 +71,11 @@ void
lasso_samlp_response_abstract_set_issueInstant(LassoSamlpResponseAbstract *node,
const xmlChar *issueInstant)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAMLP_RESPONSE_ABSTRACT(node));
g_assert(issueInstant != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "IssueInstant", issueInstant);
}
@@ -81,10 +83,11 @@ void
lasso_samlp_response_abstract_set_majorVersion(LassoSamlpResponseAbstract *node,
const xmlChar *majorVersion)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAMLP_RESPONSE_ABSTRACT(node));
g_assert(majorVersion != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "MajorVersion", majorVersion);
}
@@ -92,10 +95,11 @@ void
lasso_samlp_response_abstract_set_minorVersion(LassoSamlpResponseAbstract *node,
const xmlChar *minorVersion)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAMLP_RESPONSE_ABSTRACT(node));
g_assert(minorVersion != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "MinorVersion", minorVersion);
}
@@ -103,10 +107,11 @@ void
lasso_samlp_response_abstract_set_recipient(LassoSamlpResponseAbstract *node,
const xmlChar *recipient)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAMLP_RESPONSE_ABSTRACT(node));
g_assert(recipient != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "Recipient", recipient);
}
@@ -121,10 +126,11 @@ void
lasso_samlp_response_abstract_set_responseID(LassoSamlpResponseAbstract *node,
const xmlChar *responseID)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAMLP_RESPONSE_ABSTRACT(node));
g_assert(responseID != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "ResponseID", responseID);
}
@@ -137,6 +143,7 @@ lasso_samlp_response_abstract_set_signature(LassoSamlpResponseAbstract *node,
{
gint ret;
GError *tmp_err = NULL;
+ LassoNodeClass *class;
if (err != NULL && *err != NULL) {
g_set_error(err, g_quark_from_string("Lasso"),
@@ -153,7 +160,7 @@ lasso_samlp_response_abstract_set_signature(LassoSamlpResponseAbstract *node,
LASSO_PARAM_ERROR_BADTYPE_OR_NULL_OBJ);
}
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
ret = class->add_signature(LASSO_NODE (node), sign_method,
private_key_file, certificate_file, &tmp_err);
diff --git a/lasso/xml/samlp_status.c b/lasso/xml/samlp_status.c
index 1f503311..67db6f9e 100644
--- a/lasso/xml/samlp_status.c
+++ b/lasso/xml/samlp_status.c
@@ -46,11 +46,13 @@ Schema fragment (oasis-sstc-saml-schema-protocol-1.0.xsd):
void
lasso_samlp_status_set_statusCode(LassoSamlpStatus *node,
- LassoSamlpStatusCode *statusCode) {
+ LassoSamlpStatusCode *statusCode)
+{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAMLP_STATUS(node));
g_assert(LASSO_IS_SAMLP_STATUS_CODE(statusCode));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(LASSO_NODE (node), LASSO_NODE (statusCode), FALSE);
}
@@ -66,10 +68,11 @@ void
lasso_samlp_status_set_statusMessage(LassoSamlpStatus *node,
const xmlChar *statusMessage)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAMLP_STATUS(node));
g_assert(statusMessage != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(LASSO_NODE (node), "StatusMessage", statusMessage, FALSE);
}
diff --git a/lasso/xml/samlp_status_code.c b/lasso/xml/samlp_status_code.c
index 5b9130a9..f8626603 100644
--- a/lasso/xml/samlp_status_code.c
+++ b/lasso/xml/samlp_status_code.c
@@ -43,12 +43,13 @@ Schema fragment (oasis-sstc-saml-schema-protocol-1.0.xsd):
void
lasso_samlp_status_code_set_value(LassoSamlpStatusCode *node,
- const xmlChar *value) {
-
+ const xmlChar *value)
+{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SAMLP_STATUS_CODE(node));
g_assert(value != NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(LASSO_NODE (node), "Value", value);
}
diff --git a/lasso/xml/soap-env_body.c b/lasso/xml/soap-env_body.c
index b07a4559..d5cac897 100644
--- a/lasso/xml/soap-env_body.c
+++ b/lasso/xml/soap-env_body.c
@@ -32,10 +32,11 @@
void
lasso_soap_env_body_add_child(LassoSoapEnvBody *body, LassoNode *node)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SOAP_ENV_BODY(body));
g_assert(LASSO_IS_NODE(node));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(body);
+ class = LASSO_NODE_GET_CLASS(body);
class->add_child(LASSO_NODE(body),
LASSO_NODE(node),
FALSE);
diff --git a/lasso/xml/soap-env_envelope.c b/lasso/xml/soap-env_envelope.c
index 4da7e7bd..cb9c0975 100644
--- a/lasso/xml/soap-env_envelope.c
+++ b/lasso/xml/soap-env_envelope.c
@@ -33,10 +33,11 @@ void
lasso_soap_env_envelope_set_body(LassoSoapEnvEnvelope *envelope,
LassoSoapEnvBody *body)
{
+ LassoNodeClass *class;
g_assert(LASSO_IS_SOAP_ENV_ENVELOPE(envelope));
g_assert(LASSO_IS_SOAP_ENV_BODY(body));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(envelope);
+ class = LASSO_NODE_GET_CLASS(envelope);
class->add_child(LASSO_NODE(envelope),
LASSO_NODE(body),
FALSE);
diff --git a/lasso/xml/tools.c b/lasso/xml/tools.c
index 96e417a8..10adf845 100644
--- a/lasso/xml/tools.c
+++ b/lasso/xml/tools.c
@@ -40,11 +40,11 @@
xmlChar *
lasso_build_random_sequence(guint8 size)
{
- g_return_val_if_fail(size > 0, NULL);
-
int i, val;
xmlChar *seq;
+ g_return_val_if_fail(size > 0, NULL);
+
seq = xmlMalloc(size+1);
for (i=0; i<size; i++) {
@@ -61,7 +61,7 @@ lasso_build_random_sequence(guint8 size)
/**
* lasso_build_unique_id:
- * @size: the ID's lenght (between 32 and 40)
+ * @size: the ID's length (between 32 and 40)
*
* Builds an ID which has an unicity probability of 2^(-size*4).
* The result is Base64 encoded.
@@ -78,11 +78,11 @@ lasso_build_unique_id(guint8 size)
we could build a 128-bit binary number but hexa system is shorter
32 <= hexa number size <= 40
*/
- g_return_val_if_fail((size >= 32 && size <= 40) || size == 0, NULL);
-
int i, val;
xmlChar *id; /* , *enc_id; */
+ g_return_val_if_fail((size >= 32 && size <= 40) || size == 0, NULL);
+
if (size == 0) size = 32;
id = g_malloc(size+1);
@@ -408,7 +408,7 @@ lasso_str_hash(xmlChar *str,
xmlSecNodeDigestValue,
xmlSecDSigNs));
i = xmlSecBase64Decode(b64_digest, digest, 21);
- /* printf("Decoded string %s lenght is %d\n", digest, i); */
+ /* printf("Decoded string %s length is %d\n", digest, i); */
xmlFree(b64_digest);
xmlFreeDoc(doc);
/* value returned must be xmlFree() */
diff --git a/lasso/xml/xml.c b/lasso/xml/xml.c
index b2285e5b..9aad1eac 100644
--- a/lasso/xml/xml.c
+++ b/lasso/xml/xml.c
@@ -61,9 +61,11 @@ static void lasso_node_impl_set_xmlNode(LassoNode *node, xmlNodePtr libxml_node
LassoNode *
lasso_node_copy(LassoNode *node)
{
+ LassoNodeClass *class;
+
g_return_val_if_fail (LASSO_IS_NODE(node), NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
return (class->copy(node));
}
@@ -82,9 +84,10 @@ lasso_node_dump(LassoNode *node,
const xmlChar *encoding,
int format)
{
+ LassoNodeClass *class;
g_return_val_if_fail (LASSO_IS_NODE(node), NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
return (class->dump(node, encoding, format));
}
@@ -114,9 +117,10 @@ lasso_node_destroy(LassoNode *node)
gchar *
lasso_node_export(LassoNode *node)
{
+ LassoNodeClass *class;
g_return_val_if_fail (LASSO_IS_NODE(node), NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
return (class->export(node));
}
@@ -131,9 +135,10 @@ lasso_node_export(LassoNode *node)
gchar *
lasso_node_export_to_base64(LassoNode *node)
{
+ LassoNodeClass *class;
g_return_val_if_fail (LASSO_IS_NODE(node), NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
return (class->export_to_base64(node));
}
@@ -153,9 +158,10 @@ lasso_node_export_to_query(LassoNode *node,
lassoSignatureMethod sign_method,
const gchar *private_key_file)
{
+ LassoNodeClass *class;
g_return_val_if_fail (LASSO_IS_NODE(node), NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
return (class->export_to_query(node, sign_method, private_key_file));
}
@@ -170,9 +176,10 @@ lasso_node_export_to_query(LassoNode *node,
gchar *
lasso_node_export_to_soap(LassoNode *node)
{
+ LassoNodeClass *class;
g_return_val_if_fail (LASSO_IS_NODE(node), NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
return (class->export_to_soap(node));
}
@@ -191,6 +198,7 @@ lasso_node_get_attr(LassoNode *node,
const xmlChar *name,
GError **err)
{
+ LassoNodeClass *class;
if (err != NULL && *err != NULL) {
g_set_error(err, g_quark_from_string("Lasso"),
LASSO_PARAM_ERROR_ERR_CHECK_FAILED,
@@ -205,7 +213,7 @@ lasso_node_get_attr(LassoNode *node,
}
/* don't check @name here, it's checked in impl method */
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
return (class->get_attr(node, name, err));
}
@@ -225,6 +233,7 @@ lasso_node_get_attr_value(LassoNode *node,
const xmlChar *name,
GError **err)
{
+ LassoNodeClass *class;
if (err != NULL && *err != NULL) {
g_set_error(err, g_quark_from_string("Lasso"),
LASSO_PARAM_ERROR_ERR_CHECK_FAILED,
@@ -239,7 +248,7 @@ lasso_node_get_attr_value(LassoNode *node,
}
/* don't check @name here, it's checked in impl method */
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
return (class->get_attr_value(node, name, err));
}
@@ -254,9 +263,10 @@ lasso_node_get_attr_value(LassoNode *node,
GPtrArray *
lasso_node_get_attrs(LassoNode *node)
{
+ LassoNodeClass *class;
g_return_val_if_fail (LASSO_IS_NODE(node), NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
return (class->get_attrs(node));
}
@@ -277,6 +287,7 @@ lasso_node_get_child(LassoNode *node,
const xmlChar *href,
GError **err)
{
+ LassoNodeClass *class;
if (err != NULL && *err != NULL) {
g_set_error(err, g_quark_from_string("Lasso"),
LASSO_PARAM_ERROR_ERR_CHECK_FAILED,
@@ -291,7 +302,7 @@ lasso_node_get_child(LassoNode *node,
}
/* don't check @name here, it's checked in impl method */
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
return (class->get_child(node, name, href, err));
}
@@ -313,6 +324,7 @@ lasso_node_get_child_content(LassoNode *node,
const xmlChar *href,
GError **err)
{
+ LassoNodeClass *class;
if (err != NULL && *err != NULL) {
g_set_error(err, g_quark_from_string("Lasso"),
LASSO_PARAM_ERROR_ERR_CHECK_FAILED,
@@ -327,7 +339,7 @@ lasso_node_get_child_content(LassoNode *node,
}
/* don't check @name here, it's checked in impl method */
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
return (class->get_child_content(node, name, href, err));
}
@@ -342,9 +354,10 @@ lasso_node_get_child_content(LassoNode *node,
GPtrArray *
lasso_node_get_children(LassoNode *node)
{
+ LassoNodeClass *class;
g_return_val_if_fail (LASSO_IS_NODE(node), NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
return (class->get_children(node));
}
@@ -365,6 +378,7 @@ xmlChar *
lasso_node_get_content(LassoNode *node,
GError **err)
{
+ LassoNodeClass *class;
if (err != NULL && *err != NULL) {
g_set_error(err, g_quark_from_string("Lasso"),
LASSO_PARAM_ERROR_ERR_CHECK_FAILED,
@@ -378,7 +392,7 @@ lasso_node_get_content(LassoNode *node,
g_return_val_if_fail(LASSO_IS_NODE(node), NULL);
}
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
return (class->get_content(node, err));
}
@@ -393,9 +407,10 @@ lasso_node_get_content(LassoNode *node,
xmlChar *
lasso_node_get_name(LassoNode *node)
{
+ LassoNodeClass *class;
g_return_val_if_fail (LASSO_IS_NODE(node), NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
return (class->get_name(node));
}
@@ -410,9 +425,10 @@ void
lasso_node_import(LassoNode *node,
const gchar *buffer)
{
+ LassoNodeClass *class;
g_return_if_fail(LASSO_IS_NODE(node));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->import(node, buffer);
}
@@ -427,9 +443,10 @@ void
lasso_node_import_from_node(LassoNode *node,
LassoNode *imported_node)
{
+ LassoNodeClass *class;
g_return_if_fail(LASSO_IS_NODE(node));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->import_from_node(node, imported_node);
}
@@ -446,9 +463,10 @@ lasso_node_rename_prop(LassoNode *node,
const xmlChar *old_name,
const xmlChar *new_name)
{
+ LassoNodeClass *class;
g_return_if_fail(LASSO_IS_NODE(node));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->rename_prop(node, old_name, new_name);
}
@@ -467,6 +485,7 @@ lasso_node_verify_signature(LassoNode *node,
const gchar *certificate_file,
GError **err)
{
+ LassoNodeClass *class;
if (err != NULL && *err != NULL) {
g_set_error(err, g_quark_from_string("Lasso"),
LASSO_PARAM_ERROR_ERR_CHECK_FAILED,
@@ -483,7 +502,7 @@ lasso_node_verify_signature(LassoNode *node,
}
/* don't check @certificate_file here, it's checked in impl method */
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
return (class->verify_signature(node, certificate_file, err));
}
@@ -496,9 +515,10 @@ lasso_node_add_child(LassoNode *node,
LassoNode *child,
gboolean unbounded)
{
+ LassoNodeClass *class;
g_return_if_fail(LASSO_IS_NODE(node));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->add_child(node, child, unbounded);
}
@@ -509,6 +529,7 @@ lasso_node_add_signature(LassoNode *node,
const xmlChar *certificate_file,
GError **err)
{
+ LassoNodeClass *class;
if (err != NULL && *err != NULL) {
g_set_error(err, g_quark_from_string("Lasso"),
LASSO_PARAM_ERROR_ERR_CHECK_FAILED,
@@ -526,7 +547,7 @@ lasso_node_add_signature(LassoNode *node,
/* don't check @private_key_file and @certificate_file here,
it's checked in impl method */
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
return (class->add_signature(node, sign_method, private_key_file,
certificate_file, err));
}
@@ -534,18 +555,20 @@ lasso_node_add_signature(LassoNode *node,
static gchar *
lasso_node_build_query(LassoNode *node)
{
+ LassoNodeClass *class;
g_return_val_if_fail (LASSO_IS_NODE(node), NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
return (class->build_query(node));
}
static xmlNodePtr
lasso_node_get_xmlNode(LassoNode *node)
{
+ LassoNodeClass *class;
g_return_val_if_fail (LASSO_IS_NODE(node), NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
return (class->get_xmlNode(node));
}
@@ -567,9 +590,10 @@ lasso_node_new_child(LassoNode *node,
const xmlChar *content,
gboolean unbounded)
{
+ LassoNodeClass *class;
g_return_if_fail(LASSO_IS_NODE(node));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->new_child(node, name, content, unbounded);
}
@@ -577,9 +601,10 @@ static GData *
lasso_node_serialize(LassoNode *node,
GData *gd)
{
+ LassoNodeClass *class;
g_return_val_if_fail (LASSO_IS_NODE(node), NULL);
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
return (class->serialize(node, gd));
}
@@ -587,9 +612,10 @@ static void
lasso_node_set_name(LassoNode *node,
const xmlChar *name)
{
+ LassoNodeClass *class;
g_return_if_fail(LASSO_IS_NODE(node));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_name(node, name);
}
@@ -598,9 +624,10 @@ lasso_node_set_ns(LassoNode *node,
const xmlChar *href,
const xmlChar *prefix)
{
+ LassoNodeClass *class;
g_return_if_fail(LASSO_IS_NODE(node));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_ns(node, href, prefix);
}
@@ -609,9 +636,10 @@ lasso_node_set_prop(LassoNode *node,
const xmlChar *name,
const xmlChar *value)
{
+ LassoNodeClass *class;
g_return_if_fail(LASSO_IS_NODE(node));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_prop(node, name, value);
}
@@ -619,9 +647,10 @@ static void
lasso_node_set_xmlNode(LassoNode *node,
xmlNodePtr libxml_node)
{
+ LassoNodeClass *class;
g_return_if_fail(LASSO_IS_NODE(node));
- LassoNodeClass *class = LASSO_NODE_GET_CLASS(node);
+ class = LASSO_NODE_GET_CLASS(node);
class->set_xmlNode(node, libxml_node);
}
@@ -829,6 +858,7 @@ lasso_node_impl_get_attr_value(LassoNode *node,
const xmlChar *name,
GError **err)
{
+ xmlChar *value;
if (name == NULL) {
g_set_error(err, g_quark_from_string("Lasso"),
LASSO_PARAM_ERROR_INVALID_VALUE,
@@ -836,7 +866,7 @@ lasso_node_impl_get_attr_value(LassoNode *node,
g_return_val_if_fail(name != NULL, NULL);
}
- xmlChar *value = xmlGetProp(node->private->node, name);
+ value = xmlGetProp(node->private->node, name);
if (value == NULL) {
g_set_error(err, g_quark_from_string("Lasso"),
@@ -874,6 +904,8 @@ lasso_node_impl_get_child(LassoNode *node,
const xmlChar *href,
GError **err)
{
+ xmlNodePtr child;
+
if (name == NULL) {
g_set_error(err, g_quark_from_string("Lasso"),
LASSO_PARAM_ERROR_INVALID_VALUE,
@@ -915,8 +947,6 @@ lasso_node_impl_get_child(LassoNode *node,
/* } */
/* return (NULL); */
- xmlNodePtr child;
-
if (href != NULL) {
child = xmlSecFindNode(node->private->node, name, href);
}
@@ -1087,7 +1117,7 @@ lasso_node_impl_verify_signature(LassoNode *node,
g_set_error(err, g_quark_from_string("Lasso"),
LASSO_PARAM_ERROR_INVALID_VALUE,
lasso_strerror(LASSO_PARAM_ERROR_INVALID_VALUE));
- g_return_val_if_fail(certificate_file != NULL, NULL);
+ g_return_val_if_fail(certificate_file != NULL, -2);
}
doc = xmlNewDoc("1.0");