PSSLContext Class Reference

#include <pssl.h>

List of all members.

Public Member Functions

 PSSLContext (const void *sessionId=NULL, PINDEX idSize=0)
 ~PSSLContext ()
 operator ssl_ctx_st * () const
PBoolean SetCAPath (const PDirectory &caPath)
PBoolean SetCAFile (const PFilePath &caFile)
PBoolean UseCertificate (const PSSLCertificate &certificate)
PBoolean UsePrivateKey (const PSSLPrivateKey &key)
PBoolean UseDiffieHellman (const PSSLDiffieHellman &dh)
PBoolean SetCipherList (const PString &ciphers)

Protected Attributes

ssl_ctx_st * context


Detailed Description

Context for SSL channels. This class embodies a common environment for all connections made via SSL using the PSSLChannel class. It includes such things as the version of SSL and certificates, CA's etc.


Constructor & Destructor Documentation

PSSLContext::PSSLContext ( const void *  sessionId = NULL,
PINDEX  idSize = 0 
)

Create a new context for SSL channels. An optional session ID may be provided in the context. This is used to identify sessions across multiple channels in this context. The session ID is a completely arbitrary block of data. If sessionId is non NULL and idSize is zero, then sessionId is assumed to be a pointer to a C string.

Parameters:
sessionId  Pointer to session ID
idSize  Size of session ID

PSSLContext::~PSSLContext (  ) 

Clean up the SSL context.


Member Function Documentation

PSSLContext::operator ssl_ctx_st * (  )  const [inline]

Get the internal SSL context structure.

PBoolean PSSLContext::SetCAPath ( const PDirectory caPath  ) 

Set the path to locate CA certificates.

Parameters:
caPath  Directory for CA certificates

PBoolean PSSLContext::SetCAFile ( const PFilePath caFile  ) 

Set the CA certificate file.

Parameters:
caFile  CA certificate file

PBoolean PSSLContext::UseCertificate ( const PSSLCertificate certificate  ) 

Use the certificate specified.

PBoolean PSSLContext::UsePrivateKey ( const PSSLPrivateKey key  ) 

Use the private key specified.

PBoolean PSSLContext::UseDiffieHellman ( const PSSLDiffieHellman dh  ) 

Use the Diffie-Hellman parameters specified.

PBoolean PSSLContext::SetCipherList ( const PString ciphers  ) 

Set the available ciphers to those listed.

Parameters:
ciphers  List of cipher names.


Member Data Documentation

ssl_ctx_st* PSSLContext::context [protected]


The documentation for this class was generated from the following file:
Generated on Mon Dec 10 11:19:00 2007 for PTLib by  doxygen 1.5.1