Lasso Reference Manual: LassoWsAddrEndpointReference

## LassoWsAddrEndpointReference LassoWsAddrEndpointReference |

## Functions

LassoWsAddrEndpointReference * | lasso_wsa_endpoint_reference_new ()
LassoNode * | lasso_wsa_endpoint_reference_get_target_identity_token ()
LassoWsAddrEndpointReference * | lasso_wsa_endpoint_reference_new_for_idwsf2_service ()
lasso_error_t | lasso_wsa_endpoint_reference_add_security_token ()
lasso_error_t | lasso_wsa_endpoint_reference_associate_service_to_type ()
LassoIdWsf2Profile * | lasso_wsa_endpoint_reference_get_service ()

## Types and Values

struct | LassoWsAddrEndpointReference

## Description

## Functions

### lasso_wsa_endpoint_reference_new ()

    LassoWsAddrEndpointReference *
    lasso_wsa_endpoint_reference_new (void);

Creates a new LassoWsAddrEndpointReference object.

#### Returns

a newly created LassoWsAddrEndpointReference object

### lasso_wsa_endpoint_reference_get_target_identity_token ()

    LassoNode *
    lasso_wsa_endpoint_reference_get_target_identity_token
                                   (const LassoWsAddrEndpointReference *epr,
                                    gboolean (*sech_mech_predicate) (const char *),
                                    const char *security_mech_id);

Return the first target identity token found in the metadata of the `epr` object which qualify with respect to the predicate or the given security mechanism identifier. It is an error to pass both of `sech_mech_predicate` and `security_mech_id` as NULL.

#### Parameters

epr | a LassoWsAddrEndpointReference object |
sech_mech_predicate:(allow-none) | a boolean function to select the security mechanism for which we want the security token |
security_mech_id:(allow-none) | an optional specific security mechanism identifier to select the security token. |

#### Returns

a LassoNode object or NULL if the query cannot be satisfied.

[transfer none]

### lasso_wsa_endpoint_reference_new_for_idwsf2_service ()

    LassoWsAddrEndpointReference *
    lasso_wsa_endpoint_reference_new_for_idwsf2_service
                                   (const char *address,
                                    const char *service_ype,
                                    const char *provider_id,
                                    const char *abstract);

Create and populate a new LassoWsAddrEndpointReference object.

#### Parameters

address | the URL of the SOAP endpoint where the service is anchored |
service_type | an URI identifying the ID-WSF 2.0 service type |
provider_id | an URI identifying the SAML 2.0 service provider hosting the service, this should help in finding key material for security mechanisms. |
abstract | a human description of the service. |

#### Returns

a newly created LassoWsAddrEndpointReference.

### lasso_wsa_endpoint_reference_add_security_token ()

    lasso_error_t
    lasso_wsa_endpoint_reference_add_security_token
                                   (LassoWsAddrEndpointReference *epr,
                                    LassoNode *security_token,
                                    GList *security_mechanisms);

Add a new security context declaration for the given security mechanisms identifiers and populate it with a security token.

#### Parameters

epr | a LassoWsAddrEndpointReference object |
security_token | a security token as a LassoNode object |
security_mechanisms | a list of security mechanism for whom the token is made. | [element-type utf8]

#### Returns

0 if successfull, an error code otherwise.

### lasso_wsa_endpoint_reference_associate_service_to_type ()

    lasso_error_t
    lasso_wsa_endpoint_reference_associate_service_to_type
                                   (const char *service_type_uri,
                                    GType g_type);

Associate a profile type to a service type.

#### Parameters

service_type_uri | a service type to associate |
g_type | the type of the profile object handling this service type |

#### Returns

0 if successful, an error code otherwise.

### lasso_wsa_endpoint_reference_get_service ()

    LassoIdWsf2Profile *
    lasso_wsa_endpoint_reference_get_service
                                   (LassoWsAddrEndpointReference *epr);

Get a profile object able to communicate with the service represented by this EPR.

Return object: a newly created LassoIdWsf2Profile instance.

#### Parameters

epr | a LassoWsAddrEndpointReference object |

## Types and Values

### struct LassoWsAddrEndpointReference

    struct LassoWsAddrEndpointReference {
    	LassoNode parent;

    	/* elements */
    	LassoWsAddrAttributedURI *Address;
    	LassoWsAddrReferenceParameters *ReferenceParameters;
    	LassoWsAddrMetadata *Metadata;
    	GList *any; /* of LassoNode */
    	/* attributes */
    	GHashTable *attributes;
    };