vomsdata (3) - Linux Manuals
NAME
vomsdata -
SYNOPSIS
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)
Data Fields
verror_type error
std::vector< voms > data
std::string workvo
std::string extra_data
Detailed Description
Definition at line 194 of file voms_api.h.
Constructor & Destructor Documentation
vomsdata::vomsdata (std::stringvoms_dir = '', std::stringcert_dir = '')
Parameters:
-
voms_dir The directory which contains the certificate of the VOMS server
cert_dir The directory which contains the certificate of the CA
If voms_dir is empty, the value of the environment variable X509_VOMS_DIR is taken.
If cert_dir is empty, the value of the environment variable X509_CERT_DIR is taken.
vomsdata::~vomsdata ()
vomsdata::vomsdata (const vomsdata &)
Member Function Documentation
void vomsdata::AddTarget (std::stringtarget)
Adds a target to the AC.
aram target The target to be added. it should be a FQDN.
Parameters:
Returns:
Parameters:
Returns:
Returns:
The function doesn't verify the data
Parameters:
Returns:
Parameters:
Returns:
Parameters:
Returns:
The function does verify the data.
Parameters:
Returns:
Parameters:
If dir is empty, defaults to /opt/edg/etc/vomses.
Returns:
Parameters:
If dir is empty, defaults to $VOMS_USERCONF. If this is empty too, defaults to $HOME/.edg/vomses, or to ~/.edg/vomses as a last resort.
Returns:
Parameters:
Returns:
Parameters:
Returns:
Parameters:
Returns:
Note: Does NOT verify that the proxy is valid. Such verification must be obtained through other means.
Parameters:
Returns:
Parameters:
Returns:
Parameters:
Returns:
Parameters:
Returns:
Parameters:
Parameters:
Definition at line 370 of file voms_api.h.
Definition at line 213 of file voms_api.h.
Note that this field doesn't contain the result of a request to the VOMS server, but instead data specified by the user.
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
Definition at line 374 of file voms_api.h.
Definition at line 373 of file voms_api.h.
Generated automatically by Doxygen for VOMS CC API from the source code.
bool vomsdata::Contact (std::stringhostname, intport, std::stringservsubject, std::stringcommand)
Contacts a VOMS server to get a certificate
It is the equivalent of the voms_proxy_init command, but
without the --include functionality.
aram hostname FQDN of the VOMS server
aram port the port on which the VOMS server is listening
aram servsubject the subject of the server's certificate
aram command the command sent to the server
eturn failure (F) or success (T)
bool vomsdata::Contact (std::stringhostname, intport, std::stringservsubject, std::stringcommand, inttimeout)
Contacts a VOMS server to get a certificate
It is the equivalent of the voms_proxy_init command, but
without the --include functionality.
aram hostname FQDN of the VOMS server
aram port the port on which the VOMS server is listening
aram servsubject the subject of the server's certificate
aram command the command sent to the server
aram timeout Timeout for server connections in seconds
eturn failure (F) or success (T)
bool vomsdata::ContactRaw (std::stringhostname, intport, std::stringservsubject, std::stringcommand, std::string &raw, int &version)
Same as Contact, however it does not start the verification process, and the message receviedfrom the server is not parsed.
port the port on which the VOMS server is listening
servsubject the subject of the server's certificate
command the command sent to the server
raw OUTPUT PARAMETER the answer from the server
version OUTPUT PARAMETER the version of the answer
bool vomsdata::ContactRaw (std::stringhostname, intport, std::stringservsubject, std::stringcommand, std::string &raw, int &version, inttimeout)
Same as Contact, however it does not start the verification process, and the message receviedfrom the server is not parsed.
port the port on which the VOMS server is listening
servsubject the subject of the server's certificate
command the command sent to the server
raw OUTPUT PARAMETER the answer from the server
version OUTPUT PARAMETER the version of the answer
timeout Timeout for server connections in seconds
bool vomsdata::ContactRESTRaw (const std::string &, int, const std::string &, std::string &, int, int)
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.
bool vomsdata::Export (std::string &data)
Exports data from vomsdata::data to the format used for inclusion into a certificate.
std::vector<contactdata> vomsdata::FindByAlias (std::stringalias)
Finds servers which share a common alias.
std::vector<contactdata> vomsdata::FindByVO (std::stringvo)
Finds servers which serve a common VO
bool vomsdata::Import (std::stringbuffer)
Converts data from the format used for inclusion into a certificate to the internal format
std::vector<std::string> vomsdata::ListTargets (void)
Returns the list of targets.
bool vomsdata::LoadCredentials (X509 *, EVP_PKEY *, STACK_OF(X509)*)
bool vomsdata::LoadSystemContacts (std::stringdir = '')
Loads the system wide configuration files.
bool vomsdata::LoadUserContacts (std::stringdir = '')
Loads the user-specific configuration files.
void vomsdata::Order (std::stringatt)
Sets up the ordering of the results.
Defines the ordering of the data returned by Contact(). Results are
ordered in the same order as the calls to this function.
aram att The attribute to be ordered.
void vomsdata::ResetOrder (void)
Resets the ordering.
void vomsdata::ResetTargets (void)
Resets the target list.
bool vomsdata::Retrieve (X509 *cert, STACK_OF(X509)*chain, recurse_typehow = 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.
chain The chain of the validation certificates (only the intermediate ones)
how Recursion type
bool vomsdata::Retrieve (X509_EXTENSION *ext)
Gets VOMS information from the given extension
bool vomsdata::Retrieve (FILE *file, recurse_typehow)
Gets VOMS information from a proxy saved as a file.
how Recursion type
bool vomsdata::Retrieve (AC *ac)
Gets VOMS information from the AC
bool vomsdata::RetrieveFromCred (gss_cred_id_tcredential, recurse_typehow)
Gets VOMS information from the given globus credential
how Recursion type
bool vomsdata::RetrieveFromCtx (gss_ctx_id_tcontext, recurse_typehow)
Gets VOMS information from the given globus context
how Recursion type
bool vomsdata::RetrieveFromProxy (recurse_typehow)
Gets VOMS information from an existing globus proxy
std::string vomsdata::ServerErrors (void)
Gets the error message returned by the server
void vomsdata::SetLifetime (intlifetime)
Set requested lifetime for the Contact() call.
void vomsdata::SetRetryCount (intretryCount)
void vomsdata::SetVerificationTime (time_t)
void vomsdata::SetVerificationType (verify_typehow)
Sets the type of verification done on the data.
Field Documentation
std::vector<voms> vomsdata::data
User's info, as in the certificate extension. It may contain data gathered from more than one VOMS server,
verror_type vomsdata::error
Error code
std::string vomsdata::extra_data
The data specified by the user with the --include switch.
std::string vomsdata::workvo
The value of the -vo option of the voms-proxy-init command
Author