LassoIdWsf2Discovery

LassoIdWsf2Discovery

Functions

Types and Values

Description

Functions

lasso_idwsf2_discovery_new ()

LassoIdWsf2Discovery *
lasso_idwsf2_discovery_new (LassoServer *server);

Create a new LassoIdWsf2Discovery.

Parameters

server:(allow-none)

a LassoServer object, for resolving ProviderID names

 

Returns

a newly created LassoIdWsf2Discovery object; or NULL if an error occured.


lasso_idwsf2_discovery_init_metadata_register ()

lasso_error_t
lasso_idwsf2_discovery_init_metadata_register
                               (LassoIdWsf2Discovery *discovery);

Initialise a ID-WSF service metadata registration request to a Discovery service.

Parameters

discovery

a LassoIdWsf2Discovery object

 

Returns

0 on success; an error code otherwise.


lasso_idwsf2_discovery_init_metadata_association_add ()

lasso_error_t
lasso_idwsf2_discovery_init_metadata_association_add
                               (LassoIdWsf2Discovery *discovery);

Initialise a request to associate a user account to a service metadata, allowing a WSC to request this service for data related to this user account.

Parameters

discovery

a LassoIdWsf2Discovery

 

svcMDID

identifier of the service metadata the user wants to associate with

 

Returns

0 on success; or a negative value otherwise.


lasso_idwsf2_discovery_init_query ()

lasso_error_t
lasso_idwsf2_discovery_init_query (LassoIdWsf2Discovery *discovery);

Initialise a request for ID-WSF discovery Query to a discovery service.

Parameters

discovery

a LassoIdWsf2Discovery

 

Returns

0 on success; or a negative value otherwise.


lasso_idwsf2_discovery_init_metadata_query ()

lasso_error_t
lasso_idwsf2_discovery_init_metadata_query
                               (LassoIdWsf2Discovery *discovery);

Initialise a ID-WSF service metadata query request to a Discovery service

Parameters

discovery

a LassoIdWsf2Discovery object

 

Returns

0 on success; an error code otherwise.


lasso_idwsf2_discovery_init_metadata_replace ()

lasso_error_t
lasso_idwsf2_discovery_init_metadata_replace
                               (LassoIdWsf2Discovery *discovery);

Initialise a ID-WSF service metadata replace request to a Discovery service.

Parameters

discovery

a LassoIdWsf2Discovery object

 

Returns

0 on success; an error code otherwise.


lasso_idwsf2_discovery_init_metadata_delete ()

lasso_error_t
lasso_idwsf2_discovery_init_metadata_delete
                               (LassoIdWsf2Discovery *discovery);

Initialise a ID-WSF service metadata query request to a Discovery service

Parameters

discovery

a LassoIdWsf2Discovery object

 

Returns

0 on success; an error code otherwise.


lasso_idwsf2_discovery_init_metadata_association_delete ()

lasso_error_t
lasso_idwsf2_discovery_init_metadata_association_delete
                               (LassoIdWsf2Discovery *discovery);

lasso_idwsf2_discovery_init_metadata_association_query ()

lasso_error_t
lasso_idwsf2_discovery_init_metadata_association_query
                               (LassoIdWsf2Discovery *discovery);

lasso_idwsf2_discovery_add_service_metadata ()

lasso_error_t
lasso_idwsf2_discovery_add_service_metadata
                               (LassoIdWsf2Discovery *idwsf2_discovery,
                                LassoIdWsf2DiscoSvcMetadata *service_metadata);

Add a new metadata object to a request.

Parameters

idwsf2_discovery

a LassoIdWsf2Discovery object

 

service_metadata

a LassoIdWsf2DiscoSvcMetadata object to add to the register request.

 

Returns

0 if successful, an error code otherwise.


lasso_idwsf2_discovery_add_simple_service_metadata ()

lasso_error_t
lasso_idwsf2_discovery_add_simple_service_metadata
                               (LassoIdWsf2Discovery *idwsf2_discovery,
                                const char *abstract,
                                const char *provider_id,
                                GList *service_types,
                                GList *options,
                                const char *address,
                                GList *security_mechanisms);

Add new metadata to the current Metadata Register request.

Parameters

idwsf2_discovery

a LassoIdWsf2Discovery object

 

abstract:(allow-none)

a human description of the service

 

provider_id:(allow-none)

the provider id of the service to register, if none is given, providerId of the current LassoServer object is used

 

service_types

an array of service type URIs.

[element-type utf8][allow-none]

options

an array of option string.

[element-type LassoIdWsf2DiscoOptions][allow-none]

address:(allow-none)

the URI of the service endpoint for the default EndpointContext

 

security_mechanisms

the security mechanisms supported by the service.

[allow-none][element-type utf8]

Returns

0 if successful, an error code otherwise.


lasso_idwsf2_discovery_get_metadatas ()

GList *
lasso_idwsf2_discovery_get_metadatas (LassoIdWsf2Discovery *discovery);

Return the current list of metadatas in the discovery object. They can be metadatas just received through a LASSO_IDWSF2_DISCOVERY_REQUEST_TYPE_MD_REGISTER request or added through lasso_idwsf2_discovery_add_service_metadata() or lasso_idwsf2_discovery_add_simple_service_metadata().

Parameters

discovery

a LassoIdWsf2Discovery object

 

Returns

the list of metadatas.

[transfer none][element-type LassoIdWsf2DiscoSvcMetadata]


lasso_idwsf2_discovery_add_requested_service ()

lasso_error_t
lasso_idwsf2_discovery_add_requested_service
                               (LassoIdWsf2Discovery *discovery,
                                GList *service_types,
                                GList *provider_ids,
                                GList *options,
                                GList *security_mechanisms,
                                GList *frameworks,
                                GList *actions,
                                LassoIdWsf2DiscoveryQueryResultType result_type,
                                const char *req_id);

Add a new request to find some specific services associated to the current principal at the discovery service.

Parameters

discovery

a LassoIdWsf2Discovery

 

service_types

the service type (or data profile) requested.

[element-type utf8][allow-none]

provider_ids

the providers ids to select.

[element-type utf8][allow-none]

options

the options to select.

[element-type utf8][allow-none]

security_mechanisms

the security mechanisms to select.

[element-type utf8][allow-none]

frameworks

the ID-WSF framework version to select.

[element-type utf8][allow-none]

actions

the actions to select.

[element-type utf8][allow-none]

result_type

how to filter the generated EPRs.

[allow-none][default LASSO_IDWSF2_DISCOVERY_QUERY_RESULT_TYPE_NONE]

req_id:(allow-none)

an eventual ID to put on the request, that can be matched with the generated EndpointReferences

 

Returns

0 on success; or a negative value otherwise.


lasso_idwsf2_discovery_build_request_msg ()

lasso_error_t
lasso_idwsf2_discovery_build_request_msg
                               (LassoIdWsf2Discovery *discovery,
                                const char *security_mechanism);

Build the request message using a security mechanism to authenticate the requester and the target identity. If none is given Bearer mechanism is used.

Parameters

discovery

a LassoIdWsf2Discovery object

 

security_mechanism:(allow-none)

the security mech id to use, if NULL a Bearer mechanism is used.

 

Returns

0 if successful, an error code otherwise.


lasso_idwsf2_discovery_process_request_msg ()

lasso_error_t
lasso_idwsf2_discovery_process_request_msg
                               (LassoIdWsf2Discovery *discovery,
                                const char *message);

Parse a Discovery service request.

Parameters

discovery

a LassoIdWsf2Discovery object

 

message

a received SOAP message

 

Returns

0 if sucessful, an error code otherwise among:

  • LASSO_PARAM_ERROR_BAD_TYPE_OR_NULL_OBJ if profile is not a LassoIdWsf2Profile object,

  • LASSO_PARAM_ERROR_INVALID_VALUE if message is NULL,

  • LASSO_PROFILE_ERROR_INVALID_MSG if we cannot parse the message,

  • LASSO_SOAP_ERROR_MISSING_BODY if the message has no body content.


lasso_idwsf2_discovery_get_request_type ()

LassoIdWsf2DiscoveryRequestType
lasso_idwsf2_discovery_get_request_type
                               (LassoIdWsf2Discovery *discovery);

Return the type of the last parsed request.

Parameters

discovery

a LassoIdWsf2Discovery object

 

Returns

the type of the last parsed request.


lasso_idwsf2_discovery_validate_request ()

lasso_error_t
lasso_idwsf2_discovery_validate_request
                               (LassoIdWsf2Discovery *discovery);

Accept the discovery request, and produce the response.

Parameters

discovery

a LassoIdWsf2Discovery object

 

Returns

0 on success; or a negative value otherwise.


lasso_idwsf2_discovery_fail_request ()

lasso_error_t
lasso_idwsf2_discovery_fail_request (LassoIdWsf2Discovery *discovery,
                                     const char *status_code,
                                     const char *status_code2);

Fail the last request with the given status code.

Parameters

discovery

a LassoIdWsf2Discovery

 

status_code

a status code string

 

status_code2:(allow-none)

a second-level status code

 

Returns

0 on success; or a negative value otherwise.


lasso_idwsf2_discovery_process_response_msg ()

lasso_error_t
lasso_idwsf2_discovery_process_response_msg
                               (LassoIdWsf2Discovery *discovery,
                                const char *msg);

Parameters

discovery

a LassoIdWsf2Discovery object

 

msg

a string containing the response messages

 

Returns

0 if successful, an error code otherwise.


lasso_idwsf2_discovery_get_endpoint_references ()

GList *
lasso_idwsf2_discovery_get_endpoint_references
                               (LassoIdWsf2Discovery *discovery);

Return the list of wsa:EndpointReference returned by the last discovery query.

Parameters

discovery

a LassoIdWsf2Discovery object

 

Returns

a GList of LassoWsAddrEndpointReference objects, or NULL if none is found.

[transfer none][element-type LassoWsAddrEndpointReference]


lasso_idwsf2_discovery_get_svcmdids ()

GList *
lasso_idwsf2_discovery_get_svcmdids (LassoIdWsf2Discovery *discovery);

Return the list of SvcMDID, or service metadata ids, returned by the last discovery query.

Parameters

discovery

a LassoIdWsf2Discovery object

 

Returns

a list of SvcMDID's.

[transfer none][element-type utf8][allow-none]


lasso_idwsf2_discovery_set_svcmdids ()

void
lasso_idwsf2_discovery_set_svcmdids (LassoIdWsf2Discovery *discovery,
                                     GList *svcmdids);

Set the list of SvcMDID, or service metadata ids.

Parameters

discovery

a LassoIdWsf2Discovery object

 

svcmdids

a list of service metadata IDs.

[element-type utf8][allow-none]

Types and Values

struct LassoIdWsf2Discovery

struct LassoIdWsf2Discovery {
	LassoIdWsf2Profile parent;
};