Data Structures | |
struct | GNUNET_RECLAIM_Ticket |
The authorization ticket. More... | |
Macros | |
#define | GNUNET_RECLAIM_VERSION 0x00000002 |
Version number of the re:claimID API. More... | |
#define | GNUNET_RECLAIM_TICKET_RP_URI_MAX_LEN 256 |
#define | GNUNET_RECLAIM_TICKET_RP_URI_URN_PREFIX "urn:gns:" |
Typedefs | |
typedef void(* | GNUNET_RECLAIM_TicketCallback) (void *cls, const struct GNUNET_RECLAIM_Ticket *ticket, const char *rp_uri) |
Method called when a token has been issued. More... | |
typedef void(* | GNUNET_RECLAIM_IssueTicketCallback) (void *cls, const struct GNUNET_RECLAIM_Ticket *ticket, const struct GNUNET_RECLAIM_PresentationList *presentations) |
Method called when a token has been issued. More... | |
typedef void(* | GNUNET_RECLAIM_ContinuationWithStatus) (void *cls, int32_t success, const char *emsg) |
Continuation called to notify client about result of the operation. More... | |
typedef void(* | GNUNET_RECLAIM_AttributeResult) (void *cls, const struct GNUNET_CRYPTO_PublicKey *identity, const struct GNUNET_RECLAIM_Attribute *attr) |
Callback used to notify the client of attribute results. More... | |
typedef void(* | GNUNET_RECLAIM_AttributeTicketResult) (void *cls, const struct GNUNET_CRYPTO_PublicKey *identity, const struct GNUNET_RECLAIM_Attribute *attr, const struct GNUNET_RECLAIM_Presentation *presentation) |
Callback used to notify the client of attribute results. More... | |
typedef void(* | GNUNET_RECLAIM_CredentialResult) (void *cls, const struct GNUNET_CRYPTO_PublicKey *identity, const struct GNUNET_RECLAIM_Credential *credential) |
Callback used to notify the client of credential results. More... | |
#define GNUNET_RECLAIM_VERSION 0x00000002 |
Version number of the re:claimID API.
Definition at line 52 of file gnunet_reclaim_service.h.
#define GNUNET_RECLAIM_TICKET_RP_URI_MAX_LEN 256 |
Definition at line 65 of file gnunet_reclaim_service.h.
#define GNUNET_RECLAIM_TICKET_RP_URI_URN_PREFIX "urn:gns:" |
Definition at line 67 of file gnunet_reclaim_service.h.
typedef void(* GNUNET_RECLAIM_TicketCallback) (void *cls, const struct GNUNET_RECLAIM_Ticket *ticket, const char *rp_uri) |
Method called when a token has been issued.
On success returns a ticket that can be given to a relying party in order for it retrieve identity attributes
cls | closure |
ticket | the ticket |
rp_uri | the RP URI of the ticket |
Definition at line 114 of file gnunet_reclaim_service.h.
typedef void(* GNUNET_RECLAIM_IssueTicketCallback) (void *cls, const struct GNUNET_RECLAIM_Ticket *ticket, const struct GNUNET_RECLAIM_PresentationList *presentations) |
Method called when a token has been issued.
On success returns a ticket that can be given to a relying party in order for it retrieve identity attributes
cls | closure |
ticket | the ticket |
Definition at line 127 of file gnunet_reclaim_service.h.
typedef void(* GNUNET_RECLAIM_ContinuationWithStatus) (void *cls, int32_t success, const char *emsg) |
Continuation called to notify client about result of the operation.
cls | The callback closure |
success | GNUNET_SYSERR on failure |
emsg | NULL on success, otherwise an error message |
Definition at line 141 of file gnunet_reclaim_service.h.
typedef void(* GNUNET_RECLAIM_AttributeResult) (void *cls, const struct GNUNET_CRYPTO_PublicKey *identity, const struct GNUNET_RECLAIM_Attribute *attr) |
Callback used to notify the client of attribute results.
cls | The callback closure |
identity | The identity authoritative over the attributes |
attr | The attribute |
Definition at line 152 of file gnunet_reclaim_service.h.
typedef void(* GNUNET_RECLAIM_AttributeTicketResult) (void *cls, const struct GNUNET_CRYPTO_PublicKey *identity, const struct GNUNET_RECLAIM_Attribute *attr, const struct GNUNET_RECLAIM_Presentation *presentation) |
Callback used to notify the client of attribute results.
cls | The callback closure |
identity | The identity authoritative over the attributes |
attr | The attribute |
presentation | The presentation for the credential (may be NULL) |
Definition at line 164 of file gnunet_reclaim_service.h.
typedef void(* GNUNET_RECLAIM_CredentialResult) (void *cls, const struct GNUNET_CRYPTO_PublicKey *identity, const struct GNUNET_RECLAIM_Credential *credential) |
Callback used to notify the client of credential results.
cls | The callback closure |
identity | The identity authoritative over the attributes |
credential | The credential |
attributes | the parsed attributes |
Definition at line 178 of file gnunet_reclaim_service.h.
struct GNUNET_RECLAIM_Handle * GNUNET_RECLAIM_connect | ( | const struct GNUNET_CONFIGURATION_Handle * | cfg | ) |
Connect to the re:claimID service.
cfg | Configuration to contact the re:claimID service. |
Connect to the re:claimID service.
cfg | the configuration to use |
Definition at line 1118 of file reclaim_api.c.
References cfg, GNUNET_ARM_Handle::cfg, GNUNET_free, GNUNET_new, h, GNUNET_ARM_Handle::mq, and reconnect().
Referenced by REST_openid_init(), REST_reclaim_init(), and run().
struct GNUNET_RECLAIM_Operation * GNUNET_RECLAIM_attribute_store | ( | struct GNUNET_RECLAIM_Handle * | h, |
const struct GNUNET_CRYPTO_PrivateKey * | pkey, | ||
const struct GNUNET_RECLAIM_Attribute * | attr, | ||
const struct GNUNET_TIME_Relative * | exp_interval, | ||
GNUNET_RECLAIM_ContinuationWithStatus | cont, | ||
void * | cont_cls | ||
) |
Store an attribute.
If the attribute is already present, it is replaced with the new attribute.
h | handle to the reclaim service |
pkey | Private key of the identity to add an attribute to |
attr | The attribute |
exp_interval | The relative expiration interval for the attribute |
cont | Continuation to call when done |
cont_cls | Closure for cont |
Definition at line 1169 of file reclaim_api.c.
References AttributeStoreMessage::attr_len, AttributeStoreMessage::exp, exp_interval, GNUNET_assert, GNUNET_CONTAINER_DLL_insert_tail, GNUNET_CRYPTO_private_key_get_length(), GNUNET_CRYPTO_write_private_key_to_buffer(), GNUNET_htonll(), GNUNET_MESSAGE_TYPE_RECLAIM_ATTRIBUTE_STORE, GNUNET_MQ_msg_extra, GNUNET_MQ_send_copy(), GNUNET_new, GNUNET_RECLAIM_attribute_serialize(), GNUNET_RECLAIM_attribute_serialize_get_size(), h, GNUNET_ARM_Operation::h, AttributeStoreMessage::id, AttributeStoreMessage::key_len, GNUNET_ARM_Handle::mq, op, pkey, and GNUNET_TIME_Relative::rel_value_us.
Referenced by add_attribute_cont(), and iter_finished().
struct GNUNET_RECLAIM_Operation * GNUNET_RECLAIM_credential_store | ( | struct GNUNET_RECLAIM_Handle * | h, |
const struct GNUNET_CRYPTO_PrivateKey * | pkey, | ||
const struct GNUNET_RECLAIM_Credential * | credential, | ||
const struct GNUNET_TIME_Relative * | exp_interval, | ||
GNUNET_RECLAIM_ContinuationWithStatus | cont, | ||
void * | cont_cls | ||
) |
Store a credential.
If the credential is already present, it is replaced with the new credential.
h | handle to the re:claimID service |
pkey | private key of the identity |
credential | the credential value |
exp_interval | the relative expiration interval for the credential |
cont | continuation to call when done |
cont_cls | closure for cont |
Definition at line 1254 of file reclaim_api.c.
References AttributeStoreMessage::attr_len, credential, AttributeStoreMessage::exp, exp_interval, GNUNET_assert, GNUNET_CONTAINER_DLL_insert_tail, GNUNET_CRYPTO_private_key_get_length(), GNUNET_CRYPTO_write_private_key_to_buffer(), GNUNET_htonll(), GNUNET_MESSAGE_TYPE_RECLAIM_CREDENTIAL_STORE, GNUNET_MQ_msg_extra, GNUNET_MQ_send_copy(), GNUNET_new, GNUNET_RECLAIM_credential_serialize(), GNUNET_RECLAIM_credential_serialize_get_size(), h, GNUNET_ARM_Operation::h, AttributeStoreMessage::id, AttributeStoreMessage::key_len, GNUNET_ARM_Handle::mq, op, pkey, and GNUNET_TIME_Relative::rel_value_us.
Referenced by add_credential_cont(), and cred_iter_finished().
struct GNUNET_RECLAIM_Operation * GNUNET_RECLAIM_attribute_delete | ( | struct GNUNET_RECLAIM_Handle * | h, |
const struct GNUNET_CRYPTO_PrivateKey * | pkey, | ||
const struct GNUNET_RECLAIM_Attribute * | attr, | ||
GNUNET_RECLAIM_ContinuationWithStatus | cont, | ||
void * | cont_cls | ||
) |
Delete an attribute.
Tickets used to share this attribute are updated accordingly.
h | handle to the re:claimID service |
pkey | Private key of the identity to add an attribute to |
attr | The attribute |
cont | Continuation to call when done |
cont_cls | Closure for cont |
Definition at line 1213 of file reclaim_api.c.
References AttributeDeleteMessage::attr_len, GNUNET_assert, GNUNET_CONTAINER_DLL_insert_tail, GNUNET_CRYPTO_private_key_get_length(), GNUNET_CRYPTO_write_private_key_to_buffer(), GNUNET_MESSAGE_TYPE_RECLAIM_ATTRIBUTE_DELETE, GNUNET_MQ_msg_extra, GNUNET_MQ_send_copy(), GNUNET_new, GNUNET_RECLAIM_attribute_serialize(), GNUNET_RECLAIM_attribute_serialize_get_size(), h, GNUNET_ARM_Operation::h, AttributeDeleteMessage::id, AttributeDeleteMessage::key_len, GNUNET_ARM_Handle::mq, op, and pkey.
Referenced by delete_attribute_cont(), and iter_finished().
struct GNUNET_RECLAIM_Operation * GNUNET_RECLAIM_credential_delete | ( | struct GNUNET_RECLAIM_Handle * | h, |
const struct GNUNET_CRYPTO_PrivateKey * | pkey, | ||
const struct GNUNET_RECLAIM_Credential * | cred, | ||
GNUNET_RECLAIM_ContinuationWithStatus | cont, | ||
void * | cont_cls | ||
) |
Delete a credential.
Tickets used to share a presentation of this credential are updated accordingly.
h | handle to the re:claimID service |
pkey | Private key of the identity to add an attribute to |
cred | The credential |
cont | Continuation to call when done |
cont_cls | Closure for cont |
Definition at line 1298 of file reclaim_api.c.
References AttributeDeleteMessage::attr_len, GNUNET_assert, GNUNET_CONTAINER_DLL_insert_tail, GNUNET_CRYPTO_private_key_get_length(), GNUNET_CRYPTO_write_private_key_to_buffer(), GNUNET_MESSAGE_TYPE_RECLAIM_CREDENTIAL_DELETE, GNUNET_MQ_msg_extra, GNUNET_MQ_send_copy(), GNUNET_new, GNUNET_RECLAIM_credential_serialize(), GNUNET_RECLAIM_credential_serialize_get_size(), h, GNUNET_ARM_Operation::h, AttributeDeleteMessage::id, AttributeDeleteMessage::key_len, GNUNET_ARM_Handle::mq, op, and pkey.
Referenced by delete_credential_cont().
struct GNUNET_RECLAIM_AttributeIterator * GNUNET_RECLAIM_get_attributes_start | ( | struct GNUNET_RECLAIM_Handle * | h, |
const struct GNUNET_CRYPTO_PrivateKey * | identity, | ||
GNUNET_SCHEDULER_TaskCallback | error_cb, | ||
void * | error_cb_cls, | ||
GNUNET_RECLAIM_AttributeResult | proc, | ||
void * | proc_cls, | ||
GNUNET_SCHEDULER_TaskCallback | finish_cb, | ||
void * | finish_cb_cls | ||
) |
List all attributes for a local identity.
This MUST lock the struct GNUNET_RECLAIM_Handle
for any other calls than GNUNET_RECLAIM_get_attributes_next() and GNUNET_RECLAIM_get_attributes_stop. proc will be called once immediately, and then again after GNUNET_RECLAIM_get_attributes_next() is invoked.
On error (disconnect), error_cb will be invoked. On normal completion, finish_cb proc will be invoked.
h | Handle to the re:claimID service |
identity | Identity to iterate over |
error_cb | Function to call on error (i.e. disconnect), the handle is afterwards invalid |
error_cb_cls | Closure for error_cb |
proc | Function to call on each attribute |
proc_cls | Closure for proc |
finish_cb | Function to call on completion the handle is afterwards invalid |
finish_cb_cls | Closure for finish_cb |
Definition at line 1339 of file reclaim_api.c.
References env, GNUNET_RECLAIM_AttributeIterator::env, error_cb(), GNUNET_RECLAIM_AttributeIterator::error_cb, GNUNET_RECLAIM_AttributeIterator::error_cb_cls, GNUNET_RECLAIM_AttributeIterator::finish_cb, GNUNET_RECLAIM_AttributeIterator::finish_cb_cls, GNUNET_CONTAINER_DLL_insert_tail, GNUNET_CRYPTO_private_key_get_length(), GNUNET_CRYPTO_write_private_key_to_buffer(), GNUNET_MESSAGE_TYPE_RECLAIM_ATTRIBUTE_ITERATION_START, GNUNET_MQ_msg_extra, GNUNET_MQ_send(), GNUNET_new, h, GNUNET_RECLAIM_AttributeIterator::h, identity, GNUNET_RECLAIM_AttributeIterator::identity, AttributeIterationStartMessage::key_len, GNUNET_ARM_Handle::mq, msg, GNUNET_RECLAIM_AttributeIterator::proc, GNUNET_RECLAIM_AttributeIterator::proc_cls, and GNUNET_RECLAIM_AttributeIterator::r_id.
Referenced by code_redirect(), cred_iter_finished(), and list_attribute_cont().
void GNUNET_RECLAIM_get_attributes_next | ( | struct GNUNET_RECLAIM_AttributeIterator * | it | ) |
Calls the record processor specified in GNUNET_RECLAIM_get_attributes_start for the next record.
it | The iterator |
Definition at line 1384 of file reclaim_api.c.
References env, GNUNET_MESSAGE_TYPE_RECLAIM_ATTRIBUTE_ITERATION_NEXT, GNUNET_MQ_msg, GNUNET_MQ_send(), h, GNUNET_RECLAIM_AttributeIterator::h, GNUNET_ARM_Handle::mq, msg, and GNUNET_RECLAIM_AttributeIterator::r_id.
Referenced by attr_collect(), iter_cb(), and oidc_attr_collect().
void GNUNET_RECLAIM_get_attributes_stop | ( | struct GNUNET_RECLAIM_AttributeIterator * | it | ) |
Stops iteration and releases the handle for further calls.
Must be called on any iteration that has not yet completed prior to calling GNUNET_RECLAIM_disconnect.
it | the iterator |
Definition at line 1398 of file reclaim_api.c.
References env, free_it(), GNUNET_MESSAGE_TYPE_RECLAIM_ATTRIBUTE_ITERATION_STOP, GNUNET_MQ_msg, GNUNET_MQ_send(), h, GNUNET_RECLAIM_AttributeIterator::h, GNUNET_ARM_Handle::mq, msg, and GNUNET_RECLAIM_AttributeIterator::r_id.
Referenced by cleanup_handle(), and do_cleanup().
struct GNUNET_RECLAIM_CredentialIterator * GNUNET_RECLAIM_get_credentials_start | ( | struct GNUNET_RECLAIM_Handle * | h, |
const struct GNUNET_CRYPTO_PrivateKey * | identity, | ||
GNUNET_SCHEDULER_TaskCallback | error_cb, | ||
void * | error_cb_cls, | ||
GNUNET_RECLAIM_CredentialResult | proc, | ||
void * | proc_cls, | ||
GNUNET_SCHEDULER_TaskCallback | finish_cb, | ||
void * | finish_cb_cls | ||
) |
List all credentials for a local identity.
This MUST lock the struct GNUNET_RECLAIM_Handle
for any other calls than GNUNET_RECLAIM_get_credentials_next() and GNUNET_RECLAIM_get_credentials_stop. proc will be called once immediately, and then again after GNUNET_RECLAIM_get_credentials_next() is invoked.
On error (disconnect), error_cb will be invoked. On normal completion, finish_cb proc will be invoked.
h | Handle to the re:claimID service |
identity | Identity to iterate over |
error_cb | Function to call on error (i.e. disconnect), the handle is afterwards invalid |
error_cb_cls | Closure for error_cb |
proc | Function to call on each credential |
proc_cls | Closure for proc |
finish_cb | Function to call on completion the handle is afterwards invalid |
finish_cb_cls | Closure for finish_cb |
Definition at line 1416 of file reclaim_api.c.
References env, GNUNET_RECLAIM_CredentialIterator::env, error_cb(), GNUNET_RECLAIM_CredentialIterator::error_cb, GNUNET_RECLAIM_CredentialIterator::error_cb_cls, GNUNET_RECLAIM_CredentialIterator::finish_cb, GNUNET_RECLAIM_CredentialIterator::finish_cb_cls, GNUNET_CONTAINER_DLL_insert_tail, GNUNET_CRYPTO_private_key_get_length(), GNUNET_CRYPTO_write_private_key_to_buffer(), GNUNET_MESSAGE_TYPE_RECLAIM_CREDENTIAL_ITERATION_START, GNUNET_MQ_msg_extra, GNUNET_MQ_send(), GNUNET_new, h, GNUNET_RECLAIM_CredentialIterator::h, identity, GNUNET_RECLAIM_CredentialIterator::identity, CredentialIterationStartMessage::key_len, GNUNET_ARM_Handle::mq, msg, GNUNET_RECLAIM_CredentialIterator::proc, GNUNET_RECLAIM_CredentialIterator::proc_cls, and GNUNET_RECLAIM_CredentialIterator::r_id.
Referenced by list_credential_cont(), oidc_attr_collect_finished_cb(), and start_process().
void GNUNET_RECLAIM_get_credentials_next | ( | struct GNUNET_RECLAIM_CredentialIterator * | ait | ) |
Calls the record processor specified in GNUNET_RECLAIM_get_credentials_start for the next record.
ait | the iterator |
Definition at line 1462 of file reclaim_api.c.
References env, GNUNET_MESSAGE_TYPE_RECLAIM_CREDENTIAL_ITERATION_NEXT, GNUNET_MQ_msg, GNUNET_MQ_send(), h, GNUNET_RECLAIM_CredentialIterator::h, GNUNET_ARM_Handle::mq, msg, and GNUNET_RECLAIM_CredentialIterator::r_id.
Referenced by cred_collect(), cred_iter_cb(), and oidc_cred_collect().
void GNUNET_RECLAIM_get_credentials_stop | ( | struct GNUNET_RECLAIM_CredentialIterator * | ait | ) |
Stops iteration and releases the handle for further calls.
Must be called on any iteration that has not yet completed prior to calling GNUNET_RECLAIM_disconnect.
ait | the iterator |
Definition at line 1477 of file reclaim_api.c.
References env, free_ait(), GNUNET_MESSAGE_TYPE_RECLAIM_CREDENTIAL_ITERATION_STOP, GNUNET_MQ_msg, GNUNET_MQ_send(), h, GNUNET_RECLAIM_CredentialIterator::h, GNUNET_ARM_Handle::mq, msg, and GNUNET_RECLAIM_CredentialIterator::r_id.
Referenced by cleanup_handle(), and do_cleanup().
struct GNUNET_RECLAIM_Operation * GNUNET_RECLAIM_ticket_issue | ( | struct GNUNET_RECLAIM_Handle * | h, |
const struct GNUNET_CRYPTO_PrivateKey * | iss, | ||
const char * | rp_uri, | ||
const struct GNUNET_RECLAIM_AttributeList * | attrs, | ||
GNUNET_RECLAIM_IssueTicketCallback | cb, | ||
void * | cb_cls | ||
) |
Issues a ticket to a relying party.
The identity may use GNUNET_RECLAIM_ticket_consume to consume the ticket and retrieve the attributes specified in the attribute list.
h | the identity provider to use |
iss | the issuing identity (= the user) |
rp_uri | the subject of the ticket (= the relying party) see GNUNET_RECLAIM_Ticket |
attrs | the attributes that the relying party is given access to |
cb | the callback |
cb_cls | the callback closure |
Definition at line 1497 of file reclaim_api.c.
References IssueTicketMessage::attr_len, GNUNET_assert, GNUNET_CONTAINER_DLL_insert_tail, GNUNET_CRYPTO_private_key_get_length(), GNUNET_CRYPTO_write_private_key_to_buffer(), GNUNET_MESSAGE_TYPE_RECLAIM_ISSUE_TICKET, GNUNET_MQ_msg_extra, GNUNET_MQ_send_copy(), GNUNET_new, GNUNET_RECLAIM_attribute_list_serialize(), GNUNET_RECLAIM_attribute_list_serialize_get_size(), h, GNUNET_ARM_Operation::h, IssueTicketMessage::id, IssueTicketMessage::key_len, GNUNET_ARM_Handle::mq, op, rp, and IssueTicketMessage::rp_uri_len.
Referenced by iter_finished(), and oidc_cred_collect_finished_cb().
struct GNUNET_RECLAIM_Operation * GNUNET_RECLAIM_ticket_revoke | ( | struct GNUNET_RECLAIM_Handle * | h, |
const struct GNUNET_CRYPTO_PrivateKey * | identity, | ||
const struct GNUNET_RECLAIM_Ticket * | ticket, | ||
GNUNET_RECLAIM_ContinuationWithStatus | cb, | ||
void * | cb_cls | ||
) |
Revoked an issued ticket.
The relying party will be unable to retrieve attributes. Other issued tickets remain unaffected. This includes tickets issued to other relying parties as well as to other tickets issued to the audience specified in this ticket.
h | the identity provider to use |
identity | the issuing identity |
ticket | the ticket to revoke |
cb | the callback |
cb_cls | the callback closure |
Definition at line 1690 of file reclaim_api.c.
References GNUNET_RECLAIM_Ticket::gns_name, GNUNET_assert, GNUNET_CONTAINER_DLL_insert_tail, GNUNET_CRYPTO_private_key_get_length(), GNUNET_CRYPTO_write_private_key_to_buffer(), GNUNET_MESSAGE_TYPE_RECLAIM_REVOKE_TICKET, GNUNET_MQ_msg_extra, GNUNET_MQ_send(), GNUNET_new, h, GNUNET_ARM_Operation::h, identity, RevokeTicketMessage::key_len, GNUNET_ARM_Handle::mq, msg, op, ticket, and RevokeTicketMessage::tkt_len.
Referenced by iter_finished(), and revoke_ticket_cont().
struct GNUNET_RECLAIM_Operation * GNUNET_RECLAIM_ticket_consume | ( | struct GNUNET_RECLAIM_Handle * | h, |
const struct GNUNET_RECLAIM_Ticket * | ticket, | ||
const char * | rp_uri, | ||
GNUNET_RECLAIM_AttributeTicketResult | cb, | ||
void * | cb_cls | ||
) |
Consumes an issued ticket.
The ticket is used to retrieve identity information from the issuer
h | the identity provider to use |
ticket | the issued ticket to consume |
rp_uri | the RP URI |
cb | the callback to call |
cb_cls | the callback closure |
Definition at line 1546 of file reclaim_api.c.
References GNUNET_RECLAIM_Ticket::gns_name, GNUNET_CONTAINER_DLL_insert_tail, GNUNET_MESSAGE_TYPE_RECLAIM_CONSUME_TICKET, GNUNET_MQ_msg_extra, GNUNET_MQ_send_copy(), GNUNET_new, h, GNUNET_ARM_Operation::h, ConsumeTicketMessage::id, GNUNET_ARM_Handle::mq, op, reconnect(), ConsumeTicketMessage::rp_uri_len, ticket, and ConsumeTicketMessage::tkt_len.
Referenced by consume_ticket_cont(), iter_finished(), and userinfo_endpoint().
struct GNUNET_RECLAIM_TicketIterator * GNUNET_RECLAIM_ticket_iteration_start | ( | struct GNUNET_RECLAIM_Handle * | h, |
const struct GNUNET_CRYPTO_PrivateKey * | identity, | ||
GNUNET_SCHEDULER_TaskCallback | error_cb, | ||
void * | error_cb_cls, | ||
GNUNET_RECLAIM_TicketCallback | proc, | ||
void * | proc_cls, | ||
GNUNET_SCHEDULER_TaskCallback | finish_cb, | ||
void * | finish_cb_cls | ||
) |
Lists all tickets that have been issued to remote identities (relying parties)
h | the identity provider to use |
identity | the issuing identity |
error_cb | function to call on error (i.e. disconnect), the handle is afterwards invalid |
error_cb_cls | closure for error_cb |
proc | function to call on each ticket; it will be called repeatedly with a value (if available) |
proc_cls | closure for proc |
finish_cb | function to call on completion the handle is afterwards invalid |
finish_cb_cls | closure for finish_cb |
Definition at line 1586 of file reclaim_api.c.
References GNUNET_RECLAIM_TicketIterator::cls, env, GNUNET_RECLAIM_TicketIterator::env, error_cb(), GNUNET_RECLAIM_TicketIterator::error_cb, GNUNET_RECLAIM_TicketIterator::error_cb_cls, GNUNET_RECLAIM_TicketIterator::finish_cb, GNUNET_RECLAIM_TicketIterator::finish_cb_cls, GNUNET_CONTAINER_DLL_insert_tail, GNUNET_CRYPTO_private_key_get_length(), GNUNET_CRYPTO_write_private_key_to_buffer(), GNUNET_MESSAGE_TYPE_RECLAIM_TICKET_ITERATION_START, GNUNET_MQ_msg_extra, GNUNET_MQ_send(), GNUNET_new, h, GNUNET_RECLAIM_TicketIterator::h, identity, TicketIterationStartMessage::key_len, GNUNET_ARM_Handle::mq, msg, GNUNET_RECLAIM_TicketIterator::r_id, and GNUNET_RECLAIM_TicketIterator::tr_cb.
Referenced by list_tickets_cont(), and start_process().
void GNUNET_RECLAIM_ticket_iteration_next | ( | struct GNUNET_RECLAIM_TicketIterator * | it | ) |
Calls the ticket processor specified in GNUNET_RECLAIM_ticket_iteration_start for the next record.
it | the iterator |
Definition at line 1639 of file reclaim_api.c.
References env, GNUNET_MESSAGE_TYPE_RECLAIM_TICKET_ITERATION_NEXT, GNUNET_MQ_msg, GNUNET_MQ_send(), h, GNUNET_RECLAIM_TicketIterator::h, GNUNET_ARM_Handle::mq, msg, and GNUNET_RECLAIM_TicketIterator::r_id.
Referenced by ticket_collect(), and ticket_iter().
void GNUNET_RECLAIM_ticket_iteration_stop | ( | struct GNUNET_RECLAIM_TicketIterator * | it | ) |
Stops iteration and releases the handle for further calls.
Must be called on any iteration that has not yet completed prior to calling GNUNET_RECLAIM_disconnect.
it | the iterator |
Definition at line 1659 of file reclaim_api.c.
References env, GNUNET_free, GNUNET_MESSAGE_TYPE_RECLAIM_TICKET_ITERATION_STOP, GNUNET_MQ_msg, GNUNET_MQ_send(), h, GNUNET_RECLAIM_TicketIterator::h, GNUNET_ARM_Handle::mq, msg, and GNUNET_RECLAIM_TicketIterator::r_id.
Referenced by cleanup_handle(), and do_cleanup().
void GNUNET_RECLAIM_disconnect | ( | struct GNUNET_RECLAIM_Handle * | h | ) |
Disconnect from identity provider service.
h | identity provider service to disconnect |
Disconnect from identity provider service.
h | handle to destroy |
Definition at line 1150 of file reclaim_api.c.
References GNUNET_assert, GNUNET_free, GNUNET_MQ_destroy(), GNUNET_SCHEDULER_cancel(), h, GNUNET_ARM_Handle::mq, and GNUNET_ARM_Handle::reconnect_task.
Referenced by do_cleanup(), REST_openid_done(), and REST_reclaim_done().
void GNUNET_RECLAIM_cancel | ( | struct GNUNET_RECLAIM_Operation * | op | ) |
Cancel an identity provider operation.
Note that the operation MAY still be executed; this merely cancels the continuation; if the request was already transmitted, the service may still choose to complete the operation.
op | operation to cancel |
Definition at line 1135 of file reclaim_api.c.
References free_op(), GNUNET_CONTAINER_DLL_remove, h, GNUNET_ARM_Operation::h, and op.
Referenced by cleanup_handle(), consume_fail(), and do_cleanup().