rwlogo
SourcePro C++ 12.0

SourcePro® C++ API Reference Guide



   SourcePro C++
Documentation Home

RWSecureSocketMethod Class Reference
[Secure Sockets]

Encapsulates the various TLS/SSL protocol versions. An instance of this class is required to construct an RWSecureSocketContext object. More...

#include <rw/secsock/RWSecureSocketMethod.h>

List of all members.

Public Member Functions

 RWSecureSocketMethod (const SSL_METHOD *meth)
 operator const SSL_METHOD * () const

Detailed Description

RWSecureSocketMethod encapsulates the various TLS/SSL protocol versions. An instance of this class is required to construct an RWSecureSocketContext object.

The Secure Sockets package used to provide a static instance of this class for each available TLS/SSL protocol version. Unfortunately, this solution suffered from static initialization order problems when global instances of RWSecureSocketContext were used. We replaced the static instances with identically named static pointers to the corresponding underlying cryptography library functions, and added a constructor that converts these pointers to functions into RWSecureSocketMethod instances. This change allows code previously written to function identically with no code changes, and only a recompile.

The following table lists the provided static function pointers:

Static Constant Name TLS or SSL Version
TLSv1WithFallback TLS version 1, either side of protocol, with fallback to SSL version 3, and then SSL version 2. This is the default when creating RWSecureSocketContext objects.
TLSv1ClientWithFallback TLS version 1, client side only, with fallback to SSL version 3, and then SSL version 2.
TLSv1ServerWithFallback TLS version 1, server side only, with fallback to SSL version 3, and then SSL version 2.
TLSv1 TLS version 1 only, either side of protocol.
TLSv1Client TLS version 1 only, client side only.
TLSv1Server TLS version 1 only, server side only.
SSLv3 SSL version 3 only, either side of protocol.
SSLv3Client SSL version 3 only, client side only.
SSLv3Server SSL version 3 only, server side only.
SSLv2 SSL version 2 only, either side of protocol.
SSLv2Client SSL version 2 only, client side only.
SSLv2Server SSL version 2 only, server side only.

Constructor & Destructor Documentation

RWSecureSocketMethod::RWSecureSocketMethod ( const SSL_METHOD *  meth  ) 
Exceptions:
RWSecureSocketInvalidMethodError Thrown if meth is NULL. You will not normally use this constructor directly.

Member Function Documentation

RWSecureSocketMethod::operator const SSL_METHOD * (  )  const [inline]

Conversion operator.

 All Classes Functions Variables Typedefs Enumerations Enumerator Friends

© Copyright Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave and SourcePro are registered trademarks of Rogue Wave Software, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.
Contact Rogue Wave about documentation or support issues.