ARC SDK
Public Member Functions
Arc::CertEnvLocker Class Reference

Class for handling X509* variables in a multi-threaded environment. More...

#include <arc/UserConfig.h>

Public Member Functions

 CertEnvLocker (const UserConfig &cfg)
 Create a lock on X509 environment variables. Blocks if another instance exists.
 
 ~CertEnvLocker (void)
 Release lock on X509 environment variables and set back to old values if they were changed.
 

Detailed Description

Class for handling X509* variables in a multi-threaded environment.

This class is useful when using external libraries which depend on X509* environment variables in a multi-threaded environment. When an instance of this class is created it holds a lock on these variables until the instance is destroyed. Additionally, if the credentials pointed to by the those variables are owned by a different uid from the uid of the current process, a temporary copy is made owned by the uid of the current process and the X509 variable points there instead. This is to comply with some restrictions in third-party libraries which insist on the credential files being owned by the current uid.


The documentation for this class was generated from the following file: