vomsdata(3)
β¨ vomsdata π β the Library Functions Manual page, bestie edition (part 1)
okay so. this is vomsdata, straight outta the Library Functions Manual, and it's the whole C++ API for talking to VOMS β getting attribute certs, parsing them, ordering stuff, the works. it's long, it's a lot, but we're gonna get through it together and honestly? it's iconic. π¦β¨
πΈ NAME πΈ
vomsdata
π SYNOPSIS π
#include <voms_api.h>
π Public Member Functions
vomsdata (std::string voms_dir='', std::string cert_dir='')
bool LoadSystemContacts (std::string dir='')
bool LoadUserContacts (std::string dir='')
std::vector< contactdata > FindByAlias (std::string alias)
std::vector< contactdata > FindByVO (std::string vo)
void Order (std::string att)
void ResetOrder (void)
void AddTarget (std::string target)
std::vector< std::string > ListTargets (void)
void ResetTargets (void)
std::string ServerErrors (void)
bool Retrieve (X509 *cert, STACK_OF(X509) *chain, recurse_type
how=RECURSE_CHAIN)
bool Contact (std::string hostname, int port, std::string servsubject,
std::string command)
bool Contact (std::string hostname, int port, std::string servsubject,
std::string command, int timeout)
bool ContactRaw (std::string hostname, int port, std::string
servsubject, std::string command, std::string &raw, int &version)
bool ContactRaw (std::string hostname, int port, std::string
servsubject, std::string command, std::string &raw, int &version,
int timeout)
void SetVerificationType (verify_type how)
void SetLifetime (int lifetime)
bool Import (std::string buffer)
bool Export (std::string &data)
bool DefaultData (voms &)
std::string ErrorMessage (void)
bool RetrieveFromCtx (gss_ctx_id_t context, recurse_type how)
bool RetrieveFromCred (gss_cred_id_t credential, recurse_type how)
bool Retrieve (X509_EXTENSION *ext)
bool RetrieveFromProxy (recurse_type how)
bool Retrieve (FILE *file, recurse_type how)
bool Retrieve (AC *ac)
~vomsdata ()
vomsdata (const vomsdata &)
void SetRetryCount (int retryCount)
void SetVerificationTime (time_t)
bool LoadCredentials (X509 *, EVP_PKEY *, STACK_OF(X509) *)
bool ContactRESTRaw (const std::string &, int, const std::string &,
std::string &, int, int)
π Static Public Member Functions
static void SkipSslInitialization ()
π¦ Data Fields
verror_type error
std::vector< voms > data
std::string workvo
std::string extra_data
π¦ Detailed Description π¦
Definition at line 193 of file voms_api.h.
π Constructor & Destructor Documentation π
vomsdata::vomsdata (std::string voms_dir = '', std::string cert_dir = '')
Parameters
voms_dirβ the directory that holds the certificate of the VOMS server ποΈcert_dirβ the directory that holds the certificate of the CA ποΈ
If voms_dir is empty, the value of the environment variable X509_VOMS_DIR gets used instead. no cap.
If cert_dir is empty, the value of the environment variable X509_CERT_DIR gets used instead.
vomsdata::~vomsdata ()
the destructor. it just does its thing. π
vomsdata::vomsdata (const vomsdata & )
copy constructor, purr. π±
π₯ Member Function Documentation π₯
void vomsdata::AddTarget (std::string target)
Adds a target to the AC.
targetβ the target to be added. it should be a FQDN.
bool vomsdata::Contact (std::string hostname, int port, std::string servsubject, std::string command)
Contacts a VOMS server to get a certificate.
It's the equivalent of the voms_proxy_init command, but without the --include functionality. so close to the full thing, but not quite. π
hostnameβ FQDN of the VOMS serverportβ the port on which the VOMS server is listeningservsubjectβ the subject of the server's certificatecommandβ the command sent to the server
Returns failure (F) or success (T)
bool vomsdata::Contact (std::string hostname, int port, std::string servsubject, std::string command, int timeout)
Contacts a VOMS server to get a certificate.
It's the equivalent of the voms_proxy_init command, but without the --include functionality.
hostnameβ FQDN of the VOMS serverportβ the port on which the VOMS server is listeningservsubjectβ the subject of the server's certificatecommandβ the command sent to the servertimeoutβ Timeout for server connections in seconds
Returns failure (F) or success (T)
bool vomsdata::ContactRaw (std::string hostname, int port, std::string servsubject, std::string command, std::string & raw, int & version)
Same as Contact, except it does not kick off the verification process, and the message received from the server is not parsed. so you get the raw vibes, unedited. π
Parameters
hostnameβ FQDN of the VOMS serverportβ the port on which the VOMS server is listeningservsubjectβ the subject of the server's certificatecommandβ the command sent to the serverrawβ OUTPUT PARAMETER, the answer from the serverversionβ OUTPUT PARAMETER, the version of the answer
Returns failure (F) or success (T)
bool vomsdata::ContactRaw (std::string hostname, int port, std::string servsubject, std::string command, std::string & raw, int & version, int timeout)
Same as Contact, except it does not start the verification process, and the message received from the server is not parsed.
Parameters
hostnameβ FQDN of the VOMS serverportβ the port on which the VOMS server is listeningservsubjectβ the subject of the server's certificatecommandβ the command sent to the serverrawβ OUTPUT PARAMETER, the answer from the serverversionβ OUTPUT PARAMETER, the version of the answertimeoutβ Timeout for server connections in seconds
Returns failure (F) or success (T)
bool vomsdata::ContactRESTRaw (const std::string & , int , const std::string & , std::string & , int , int )
that's it, that's the whole entry. no description given, bestie. π
bool vomsdata::DefaultData (voms & )
Get the default data extension from those present in the pseudo certificate. π―
std::string vomsdata::ErrorMessage (void )
Gets a textual description of the error.
Returns A string containing the error message.
bool vomsdata::Export (std::string & data)
Exports data from vomsdata::data to the format used for inclusion into a certificate.
β οΈ heads up: the function doesn't verify the data. so like, it's not checking your work for you, it's just packing it up. π
Parameters
dataβ The certificate extension
Returns Failure (F) or Success (T)
std::vector< contactdata > vomsdata::FindByAlias (std::string alias)
Finds servers which share a common alias.
Parameters
aliasβ The alias to look for.
Returns The servers found. The order in which they are returned is unspecified. so don't come for me about ordering, it's giving chaos. πͺοΈ
std::vector< contactdata > vomsdata::FindByVO (std::string vo)
Finds servers which serve a common VO.
Parameters
voβ The VO name to look for.
Returns The servers found. The order in which they are returned is unspecified.
bool vomsdata::Import (std::string buffer)
Converts data from the format used for inclusion into a certificate to the internal format.
The function does verify the data. (yes, opposite energy from Export, we love a plot twist β¨)
Parameters
bufferβ contains the data to be converted
Returns Failure (F) or Success (T)
std::vector< std::string > vomsdata::ListTargets (void )
Returns the list of targets.
bool vomsdata::LoadCredentials (X509 * , EVP_PKEY * , STACK_OF(X509) * )
no description on this one, it's just sitting there looking mysterious. π«Ά
bool vomsdata::LoadSystemContacts (std::string dir = '')
Loads the system wide configuration files.
Parameters
dirβ The directory in which the files are stored.
If dir is empty, it defaults to /opt/edg/etc/vomses.
Returns True if all went OK, false otherwise.
bool vomsdata::LoadUserContacts (std::string dir = '')
Loads the user-specific configuration files.
Parameters
dirβ The directory in which the files are stored.
If dir is empty, it defaults to $VOMS_USERCONF. If that is empty too, it defaults to $HOME/.edg/vomses, or to ~/.edg/vomses as a last resort. it's giving backup plan energy. π
Returns True if all went OK, false otherwise.
void vomsdata::Order (std::string att)
Sets up the ordering of the results.
Defines the ordering of the data returned by Contact(). Results come back in the same order as the calls to this function.
attβ The attribute to be ordered.
void vomsdata::ResetOrder (void )
Resets the ordering. undo, undo. β©οΈ
void vomsdata::ResetTargets (void )
Resets the target list. also undo. β©οΈ
bool vomsdata::Retrieve (AC * ac)
Gets VOMS information from the AC.
Parameters
acβ The extension to parse.
Returns failure (F) or success (T)
bool vomsdata::Retrieve (FILE * file, recurse_type how)
Gets VOMS information from a proxy saved as a file.
Parameters
fileβ the file namehowβ Recursion type
Returns failure (F) or success (T)
β οΈ Note: it does NOT verify that the proxy is valid. such verification must be obtained through other means. so like, do your own vibe check on this one, fr fr.
bool vomsdata::Retrieve (X509 * cert, STACK_OF(X509) * chain, recurse_type how = RECURSE_CHAIN)
Extracts the VOMS extension from an X.509 certificate. The function doesn't check the validity of the certificates, but it does check the content of the user data.
Parameters
certβ The certificate with the VOMS extensionschainβ The chain of the validation certificates (only the intermediate ones)howβ Recursion type
Returns failure (F) or success (T)
bool vomsdata::Retrieve (X509_EXTENSION * ext)
Gets VOMS information from the given extension.
Parameters
extβ The extension to parse.
Returns failure (F) or success (T)
bool vomsdata::RetrieveFromCred (gss_cred_id_t credential, recurse_type how)
Gets VOMS information from the given globus credential.
Parameters
credentialβ The credential from which to retrieve the certificate.howβ Recursion type
Returns failure (F) or success (T)
bool vomsdata::RetrieveFromCtx (gss_ctx_id_t context, recurse_type how)
Gets VOMS information from the given globus context.
Parameters
contextβ The context from which to retrieve the certificate.howβ Recursion type
Returns failure (F) or success (T)
bool vomsdata::RetrieveFromProxy (recurse_type how)
Gets VOMS information from an existing globus proxy.
Parameters
howβ Recursion type
Returns failure (F) or success (T)
std::string vomsdata::ServerErrors (void )
Gets the error message returned by the server. so when the server is being dramatic, this is where you find out why. π
void vomsdata::SetLifetime (int lifetime)
Set requested lifetime for the Contact() call.
Parameters
lifetimeβ Requested lifetime, in seconds
void vomsdata::SetRetryCount (int retryCount)
no description provided, it's just out here setting a retry count. keep it moving. π
void vomsdata::SetVerificationTime (time_t )
also no description. mysterious. π΅οΈ
void vomsdata::SetVerificationType (verify_type how)
Sets the type of verification done on the data.
Parameters
howβ The type of verification.
void vomsdata::SkipSslInitialization () [static]
static, no description. it's the quiet one in the group chat. π€«
β¨ Field Documentation β¨
okay bestie, this is where we meet the actual fields β the lil data slots inside vomsdata. every single one is here, no skips, no cap. π
π std::vector<voms> vomsdata::data π
This is literally the user's info, exactly like it appears in the certificate extension. It may contain data gathered from more than one VOMS server, so yeah, it can be a whole group chat of servers, not just one. π«Ά
Definition at line 371 of file voms_api.h.
πΈ verror_type vomsdata::error πΈ
Error code. That's it, that's the vibe. If something goes wrong, this is where the tea is. π
Definition at line 212 of file voms_api.h.
π¦ std::string vomsdata::extra_data π¦
The data specified by the user with the --include switch.
Heads up bestie: this field does not contain the result of a request to the VOMS server. It's instead data specified by the user. So don't get it twisted. π
The reason for the introduction of this extension is to let a user include important data into his proxy certificate, like, for example, a kerberos ticket. iconic behavior, honestly. β¨
Definition at line 375 of file voms_api.h.
π std::string vomsdata::workvo π
The value of the -vo option of the voms-proxy-init command. periodt. π
Definition at line 374 of file voms_api.h.
π Author π
Generated automatically by Doxygen for VOMS CC API from the source code. slay, Doxygen, you ate. π
And that's the whole page, bestie! According to the footer, this comes from VOMS CC API, Version 1.5.0, and it's vomsdata(3). no date on this one, but the version is right there. stay iconic, and remember: always read the field docs. π¦β¨
π¦ where this page comes from
- fedora 43: voms-devel 2.1.4-1.fc43 Β· Apache-2.0
- fedora 43: voms-devel 2.1.4-1.fc43 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms