globus_gsi_cred_handle(3)
β¨ NAME β¨
globus_gsi_cred_handle β Credential Handle Management.
okay so like, this is the globus_gsi_cred_handle(3) page from the Library Functions Manual, and it's literally all about credential handle management. it's giving main character energy for GSI credentials, periodt. π
π SYNOPSIS π
π§ Typedefs π§
typedef struct globus_l_gsi_cred_handle_s * globus_gsi_cred_handle_t
π₯ Functions π₯
globus_result_t globus_gsi_cred_handle_init (globus_gsi_cred_handle_t *handle, globus_gsi_cred_handle_attrs_t handle_attrs)β Initialize a Handle. like, spin up a fresh handle, bestie.globus_result_t globus_gsi_cred_handle_destroy (globus_gsi_cred_handle_t handle)β Destroy the credential handle. bye bye, handle! πglobus_result_t globus_gsi_cred_handle_copy (globus_gsi_cred_handle_t source, globus_gsi_cred_handle_t *dest)β Copy a handle. dupe it, no cap.globus_result_t globus_gsi_cred_get_handle_attrs (globus_gsi_cred_handle_t handle, globus_gsi_cred_handle_attrs_t *attrs)β Get the handle attributes. gimme those attrs.globus_result_t globus_gsi_cred_get_goodtill (globus_gsi_cred_handle_t cred_handle, time_t *goodtill)β Get credential expiration. when does it expire? let's find out.globus_result_t globus_gsi_cred_get_lifetime (globus_gsi_cred_handle_t cred_handle, time_t *lifetime)β Get credential lifetime. how long does it live?globus_result_t globus_gsi_cred_get_key_bits (globus_gsi_cred_handle_t cred_handle, int *key_bits)β Get credential strength. how many bits? so strong. πͺglobus_result_t globus_gsi_cred_set_cert (globus_gsi_cred_handle_t handle, X509 *cert)β Set the credential's certificate. slap a cert on it.globus_result_t globus_gsi_cred_get_cert (globus_gsi_cred_handle_t handle, X509 **cert)β Get the credential's certificate. grab that cert.globus_result_t globus_gsi_cred_set_key (globus_gsi_cred_handle_t handle, EVP_PKEY *key)β Set the credential's private key. private key time, shh. π€«globus_result_t globus_gsi_cred_get_key (globus_gsi_cred_handle_t handle, EVP_PKEY **key)β Get the credential's private key. get that key.globus_result_t globus_gsi_cred_set_cert_chain (globus_gsi_cred_handle_t handle, STACK_OF(X509) *cert_chain)β Set the certificate chain. chain it up.globus_result_t globus_gsi_cred_get_cert_chain (globus_gsi_cred_handle_t handle, STACK_OF(X509) **cert_chain)β Get the certificate chain. get the whole chain.globus_result_t globus_gsi_cred_get_X509_subject_name (globus_gsi_cred_handle_t handle, X509_NAME **subject_name)β Get credential subject name. who dis?globus_result_t globus_gsi_cred_get_X509_identity_name (globus_gsi_cred_handle_t handle, X509_NAME **identity_name)β Get X.509 identity. identity check.globus_result_t globus_gsi_cred_get_subject_name (globus_gsi_cred_handle_t handle, char **subject_name)β Get credential subject name. name, please.globus_result_t globus_gsi_cred_get_policies (globus_gsi_cred_handle_t handle, STACK_OF(OPENSSL_STRING) **policies)β Get certificate chain policies. policies, periodt.globus_result_t globus_gsi_cred_get_policy_languages (globus_gsi_cred_handle_t handle, STACK_OF(ASN1_OBJECT) **policy_languages)β Get certificate chain policy languages. languages of policies, iykyk.globus_result_t globus_gsi_cred_get_X509_issuer_name (globus_gsi_cred_handle_t handle, X509_NAME **issuer_name)β Get credential issuer name object. issuer, who?globus_result_t globus_gsi_cred_get_issuer_name (globus_gsi_cred_handle_t handle, char **issuer_name)β Get issuer name. issuer name, got it.globus_result_t globus_gsi_cred_get_identity_name (globus_gsi_cred_handle_t handle, char **identity_name)β Get identity name. identity, pls.globus_result_t globus_gsi_cred_verify_cert_chain (globus_gsi_cred_handle_t cred_handle, globus_gsi_callback_data_t callback_data)β Verify credential. verify it, bestie.globus_result_t globus_gsi_cred_verify_cert_chain_when (globus_gsi_cred_handle_t cred_handle, globus_gsi_callback_data_t callback_data_in, time_t check_time)β Verify credential at a specific time. time travel verification? π₯globus_result_t globus_gsi_cred_verify (globus_gsi_cred_handle_t handle)β Verify a credential. just verify it.
π Detailed Description π
Credential Handle Management.
Create/Destroy/Modify a GSI Credential Handle.
Within the Globus GSI Credential Library, all credential operations require a handle parameter. Currently only one operation may be in progress at once per credential handle.
This section defines operations to create, modify and destroy GSI Credential handles.
π¦ Typedef Documentation π¦
typedef struct globus_l_gsi_cred_handle_s* globus_gsi_cred_handle_t
GSI Credential Handle.
A GSI Credential handle keeps track of state relating to a credential. Handles can have immutable attributes associated with them. All credential operations take a credential handle pointer as a parameter.
See also: globus_gsi_cred_handle_init(), globus_gsi_cred_handle_destroy(), globus_gsi_cred_handle_attrs_t
π Function Documentation π
π globus_gsi_cred_get_cert π
globus_result_t globus_gsi_cred_get_cert (globus_gsi_cred_handle_t handle, X509 ** cert)
Get the credential's certificate. Get the certificate of a credential.
Parameters:
handleβ the credential handle we're pulling the certificate from.certβ the resulting X509 certificate, which is a duplicate of the certificate in the credential handle. you gotta free this when you're done usingX509_free, bestie.
Returns: GLOBUS_SUCCESS if no error, otherwise an error object id is returned.
π globus_gsi_cred_get_cert_chain π
globus_result_t globus_gsi_cred_get_cert_chain (globus_gsi_cred_handle_t handle, STACK_OF(X509) ** cert_chain)
Get the certificate chain. Get the certificate chain of the credential handle.
Parameters:
handleβ the credential handle containing the certificate chain to get.cert_chainβ the certificate chain to set as a duplicate of the cert chain in the credential handle. this variable (or the variable it points to) needs to be freed when the user is finished with it usingsk_X509_free.
Returns: GLOBUS_SUCCESS if no error, otherwise an error object id is returned.
β° globus_gsi_cred_get_goodtill β°
globus_result_t globus_gsi_cred_get_goodtill (globus_gsi_cred_handle_t cred_handle, time_t * goodtill)
Get credential expiration. This function retrieves the expiration time of the credential contained in the handle.
Parameters:
cred_handleβ the credential handle to retrieve the expiration time from.goodtillβ contains the expiration time on return.
Returns: GLOBUS_SUCCESS or an error captured in a globus_result_t.
π globus_gsi_cred_get_handle_attrs π
globus_result_t globus_gsi_cred_get_handle_attrs (globus_gsi_cred_handle_t handle, globus_gsi_cred_handle_attrs_t * attrs)
Get the handle attributes. This function retrieves a copy of the credential handle attributes.
Parameters:
handleβ the credential handle to retrieve the attributes from.attrsβ contains the credential attributes on return.
Returns: GLOBUS_SUCCESS or an error captured in a globus_result_t.
πͺͺ globus_gsi_cred_get_identity_name πͺͺ
globus_result_t globus_gsi_cred_get_identity_name (globus_gsi_cred_handle_t handle, char ** identity_name)
Get identity name. Get the identity's subject name from the credential handle.
Parameters:
handleβ the credential handle containing the certificate to get the identity of.identity_nameβ the identity certificate's subject name.
Returns: GLOBUS_SUCCESS if no error, otherwise an error object identifier is returned.
π·οΈ globus_gsi_cred_get_issuer_name π·οΈ
globus_result_t globus_gsi_cred_get_issuer_name (globus_gsi_cred_handle_t handle, char ** issuer_name)
Get issuer name. Get the issuer's subject name from the credential handle.
Parameters:
handleβ the credential handle containing the certificate to get the issuer of.issuer_nameβ the issuer certificate's subject name.
Returns: GLOBUS_SUCCESS if no error, otherwise an error object identifier is returned.
π globus_gsi_cred_get_key π
globus_result_t globus_gsi_cred_get_key (globus_gsi_cred_handle_t handle, EVP_PKEY ** key)
Get the credential's private key. Get the credential handle's private key.
Parameters:
handleβ the credential handle containing the private key to get.keyβ the private key which after this function returns is set to a duplicate of the private key of the credential handle. this variable needs to be freed by the user when it is no longer used via the functionEVP_PKEY_free.
Returns: GLOBUS_SUCCESS or an error object identifier.
πͺ globus_gsi_cred_get_key_bits πͺ
globus_result_t globus_gsi_cred_get_key_bits (globus_gsi_cred_handle_t cred_handle, int * key_bits)
Get credential strength. This function retrieves the key strength of the credential contained in a handle.
Parameters:
cred_handleβ the credential handle to retrieve the strength from.key_bitsβ contains the number of bits in the key on return.
Returns: GLOBUS_SUCCESS or an error captured in a globus_result_t.
β³ globus_gsi_cred_get_lifetime β³
globus_result_t globus_gsi_cred_get_lifetime (globus_gsi_cred_handle_t cred_handle, time_t * lifetime)
Get credential lifetime. This function retrieves the lifetime of the credential contained in a handle.
Parameters:
cred_handleβ the credential handle to retrieve the lifetime from.lifetimeβ contains the lifetime on return.
Returns: GLOBUS_SUCCESS or an error captured in a globus_result_t.
π globus_gsi_cred_get_policies π
globus_result_t globus_gsi_cred_get_policies (globus_gsi_cred_handle_t handle, STACK_OF(OPENSSL_STRING) ** policies)
Get certificate chain policies. Get the Policies from the Cert Chain in the handle. The policies will be null-terminated as they are added to the handle. If a policy for a cert in the chain doesn't exist, the string in the stack will be set to the static string GLOBUS_NULL_POLICIES.
Parameters:
handleβ the handle to get the cert chain containing the policies.policiesβ the stack of policies retrieved from the handle's cert chain.
Returns: GLOBUS_SUCCESS or an error object if an error occurred.
π globus_gsi_cred_get_policy_languages π
globus_result_t globus_gsi_cred_get_policy_languages (globus_gsi_cred_handle_t handle, STACK_OF(ASN1_OBJECT) ** policy_languages)
Get certificate chain policy languages. Get the policy languages from the cert chain in the handle.
Parameters:
handleβ the handle to get the cert chain containing the policies.policy_languagesβ the stack of policies retrieved from the handle's cert chain.
Returns: GLOBUS_SUCCESS or an error object if an error occurred.
π globus_gsi_cred_get_subject_name π
globus_result_t globus_gsi_cred_get_subject_name (globus_gsi_cred_handle_t handle, char ** subject_name)
Get credential subject name. Get the credential handle's certificate subject name.
Parameters:
handleβ the credential handle containing the certificate to get the subject name of.subject_nameβ the subject name as a string. this should be freed usingOPENSSL_free()when the user is finished with it.
Returns: GLOBUS_SUCCESS if no error, a error object id otherwise.
globus_gsi_cred_get_X509_identity_name π¦
globus_result_t globus_gsi_cred_get_X509_identity_name (globus_gsi_cred_handle_t handle, X509_NAME ** identity_name)
Okay bestie, this one gets the X.509 identity. It pulls the identity's X.509 subject name straight out of the credential handle. iconic.
Parameters
handleβ the credential handle containing the certificate to get the identity fromidentity_nameβ the identity certificate's X509 subject name
Returns
GLOBUS_SUCCESSif no error, otherwise an error object identifier is returned
globus_gsi_cred_get_X509_issuer_name π
globus_result_t globus_gsi_cred_get_X509_issuer_name (globus_gsi_cred_handle_t handle, X509_NAME ** issuer_name)
Get credential issuer name object. This grabs the credential handle's certificate issuer name. vibe check passed.
Parameters
handleβ the credential handle containing the certificate to get the issuer name ofissuer_nameβ the issuer name as anX509_NAMEobject. This should be freed usingX509_NAME_freewhen the user is finished with it
Returns
GLOBUS_SUCCESSif no error, a error object id otherwise
globus_gsi_cred_get_X509_subject_name π
globus_result_t globus_gsi_cred_get_X509_subject_name (globus_gsi_cred_handle_t handle, X509_NAME ** subject_name)
Get credential subject name. This gets the credential handle's certificate subject name. slay.
Parameters
handleβ the credential handle containing the certificate to get the subject name ofsubject_nameβ the subject name as anX509_NAMEobject. This should be freed usingX509_NAME_freewhen the user is finished with it
Returns
GLOBUS_SUCCESSif no error, a error object id otherwise
globus_gsi_cred_handle_copy π«Ά
globus_result_t globus_gsi_cred_handle_copy (globus_gsi_cred_handle_t source, globus_gsi_cred_handle_t * dest)
Copy a handle. Copies a credential handle. main character energy.
Parameters
sourceβ the handle to be copieddestβ the destination of the copy
Returns
GLOBUS_SUCCESSor an error captured in aglobus_result_t
globus_gsi_cred_handle_destroy π
globus_result_t globus_gsi_cred_handle_destroy (globus_gsi_cred_handle_t handle)
Destroy the credential handle. Destroys the credential handle. bye bye.
Parameters
handleβ the credential handle to be destroyed
Returns
GLOBUS_SUCCESS
globus_gsi_cred_handle_init β¨
globus_result_t globus_gsi_cred_handle_init (globus_gsi_cred_handle_t * handle, globus_gsi_cred_handle_attrs_t handle_attrs)
Initialize a Handle. Initializes a credential handle to be used credential handling functions. Takes a set of handle attributes that are immutable to the handle. The handle attributes are only pointed to by the handle, so the lifetime of the attributes needs to be as long as that of the handle. periodt.
Parameters
handleβ the handle to be initializedhandle_attrsβ the immutable attributes of the handle
Returns
GLOBUS_SUCCESSor an error captured in aglobus_result_t
globus_gsi_cred_set_cert π
globus_result_t globus_gsi_cred_set_cert (globus_gsi_cred_handle_t handle, X509 * cert)
Set the credential's certificate. Set the Credential's Certificate. The X509 cert that is passed in should be a valid X509 certificate object. no cap.
Parameters
handleβ the credential handle to set the certificate oncertβ theX509cert to set in the cred handle. The cert passed in can beNULLwhich will set the cert in the handle toNULL, freeing the current cert in the handle.
Returns
GLOBUS_SUCCESSor an error object id if an error
globus_gsi_cred_set_cert_chain π
globus_result_t globus_gsi_cred_set_cert_chain (globus_gsi_cred_handle_t handle, STACK_OF(X509) * cert_chain)
Set the certificate chain. Set the certificate chain of the credential handle. iykyk.
Parameters
handleβ the handle containing the certificate chain field to setcert_chainβ the certificate chain to set the handle's certificate chain to
Returns
GLOBUS_SUCCESSif no error, otherwise an error object id is returned
globus_gsi_cred_set_key π
globus_result_t globus_gsi_cred_set_key (globus_gsi_cred_handle_t handle, EVP_PKEY * key)
Set the credential's private key. Set the private key of the credential handle. lowkey important.
Parameters
handleβ the handle on which to set the key.keyβ the private key to set the handle's key to. This value can beNULL, in which case the current handle's key is freed.
globus_gsi_cred_verify π₯
globus_result_t globus_gsi_cred_verify (globus_gsi_cred_handle_t handle)
Verify a credential. This function checks that the certificate is signed by the public key of the issuer cert (the first cert in the chain).
Note that this function DOES NOT check the private key or the public of the certificate, as stated in a previous version of the documentation.
Parameters
handleβ the credential handle containing the certificate and key to be validated
Returns
GLOBUS_SUCCESSif no error, otherwise an error object identifier is returned
globus_gsi_cred_verify_cert_chain π¦
globus_result_t globus_gsi_cred_verify_cert_chain (globus_gsi_cred_handle_t cred_handle, globus_gsi_callback_data_t callback_data)
Verify credential. This function performs path validation on the certificate chain contained in the credential handle. vibe check.
Parameters
cred_handleβ the credential handle containing the certificate chain to be validatedcallback_dataβ A initialized callback data structure
Returns
GLOBUS_SUCCESSif no error, otherwise an error object identifier is returned
globus_gsi_cred_verify_cert_chain_when β°
globus_result_t globus_gsi_cred_verify_cert_chain_when (globus_gsi_cred_handle_t cred_handle, globus_gsi_callback_data_t callback_data_in, time_t check_time)
Verify credential at a specific time. This function performs path validation on the certificate chain contained in the credential handle. Expiration checks are done at the time given. time travel but make it certs.
Parameters
cred_handleβ the credential handle containing the certificate chain to be validatedcallback_data_inβ A callback data structure. IfNULL, one will be initialized with only the default cert dir set.check_timeβ Check if the cert chain was valid at this time. Set to0to use a time that the cert is valid, essentially bypassing the expiration check.
Returns
GLOBUS_SUCCESSif no error, otherwise an error object identifier is returned
Author π
Generated automatically by Doxygen for globus_gsi_credential from the source code.
that's the whole page, bestie. source:globus_gsi_credential, version:8.5, page:globus_gsi_cred_handle(3), date: the Doxygen stamp in the footer. now go be iconic with your credentials π
π¦ where this page comes from
- epel 10: globus-gsi-credential-doc 8.5-1.el10_2 Β· Apache-2.0
- fedora 43: globus-gsi-credential-doc 8.5-1.fc43 Β· Apache-2.0
- fedora 44: globus-gsi-credential-doc 8.5-2.fc44 Β· Apache-2.0
- ubuntu resolute: libglobus-gsi-credential-doc 8.5-1 Β· Apache-2.0
- ubuntu stonking: libglobus-gsi-credential-doc 8.5-2build1 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms