version 1.3, 2006/08/09 21:12:42
|
version 1.4, 2006/09/29 17:38:12
|
|
|
// | // |
//============================================================================== | //============================================================================== |
// | // |
// Author: Nag Boranna, Hewlett-Packard Company (nagaraja.boranna@hp.com) |
|
// |
|
// Modified By: |
|
// |
|
//%///////////////////////////////////////////////////////////////////////////// | //%///////////////////////////////////////////////////////////////////////////// |
| |
#ifndef Pegasus_SSLContextManager_h | #ifndef Pegasus_SSLContextManager_h |
|
|
class PEGASUS_COMMON_LINKAGE SSLContextManager | class PEGASUS_COMMON_LINKAGE SSLContextManager |
{ | { |
public: | public: |
enum SSLContextType |
|
{ |
|
SERVER_CONTEXT = 1, EXPORT_CONTEXT = 2 |
|
}; |
|
|
|
/** Constructor. */ | /** Constructor. */ |
| |
SSLContextManager(); | SSLContextManager(); |
|
|
~SSLContextManager(); | ~SSLContextManager(); |
| |
void createSSLContext( | void createSSLContext( |
Uint32 contextType, |
|
const String& trustStore, | const String& trustStore, |
const String& certPath, | const String& certPath, |
const String& keyPath, | const String& keyPath, |
|
|
/** | /** |
Reload the trust store used by either the CIM Server or | Reload the trust store used by either the CIM Server or |
Indication Server based on the context type. | Indication Server based on the context type. |
|
|
@param contextType specifies the SSLContext type for which |
|
the trust store is to be reloaded |
|
*/ | */ |
void reloadTrustStore(Uint32 contextType); |
void reloadTrustStore(); |
| |
/** | /** |
Reload the CRL store. | Reload the CRL store. |
|
|
/** | /** |
Get a pointer to the sslContext object. | Get a pointer to the sslContext object. |
*/ | */ |
SSLContext* getSSLContext(Uint32 contextType) const; |
SSLContext* getSSLContext() const; |
| |
/** | /** |
Get a pointer to the sslContextObjectLock. | Get a pointer to the sslContextObjectLock. |
|
|
X509_STORE* _getNewX509Store(const String& store); | X509_STORE* _getNewX509Store(const String& store); |
| |
/** | /** |
A lock to control access to the _sslContext and _exportSSLContext |
A lock to control access to the _sslContext object. |
objects. Before read accessing the _sslContext and _exportSSLContext |
Before read accessing the _sslContext object, one must first |
objects, one must first lock this for read access. Before write |
lock this for read access. Before write accessing the _sslContext |
accessing the _sslContext and _exportSSLContext objects, one must |
object, one must first lock this for write access. |
first lock this for write access. |
|
*/ | */ |
ReadWriteSem _sslContextObjectLock; | ReadWriteSem _sslContextObjectLock; |
SSLContext* _sslContext; | SSLContext* _sslContext; |
SSLContext* _exportSSLContext; |
|
}; | }; |
| |
PEGASUS_NAMESPACE_END | PEGASUS_NAMESPACE_END |