summaryrefslogtreecommitdiff
path: root/cpp/src/IceSSL/Instance.cpp
diff options
context:
space:
mode:
authorMark Spruiell <mes@zeroc.com>2012-12-08 20:34:17 -0800
committerMark Spruiell <mes@zeroc.com>2012-12-08 20:34:17 -0800
commit490de4837d68a7fef6b4a271090d31f98c8ccde3 (patch)
tree91e428e420cbbce6ba61fb91ee8f6326e19e81dd /cpp/src/IceSSL/Instance.cpp
parentICE-5108 - cleanDbDir should ignore __Freeze (diff)
downloadice-490de4837d68a7fef6b4a271090d31f98c8ccde3.tar.bz2
ice-490de4837d68a7fef6b4a271090d31f98c8ccde3.tar.xz
ice-490de4837d68a7fef6b4a271090d31f98c8ccde3.zip
ICE-5103 - SSL failure in C#/C++ cross test
Diffstat (limited to 'cpp/src/IceSSL/Instance.cpp')
-rw-r--r--cpp/src/IceSSL/Instance.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/cpp/src/IceSSL/Instance.cpp b/cpp/src/IceSSL/Instance.cpp
index 81624789e12..7b272b8810d 100644
--- a/cpp/src/IceSSL/Instance.cpp
+++ b/cpp/src/IceSSL/Instance.cpp
@@ -687,6 +687,14 @@ IceSSL::Instance::initialize()
SSL_CTX_set_session_cache_mode(_ctx, SSL_SESS_CACHE_OFF);
//
+ // Although we disable session caching, we still need to set a session ID
+ // context (ICE-5103). The value can be anything; here we just use the
+ // pointer to this Instance object.
+ //
+ SSL_CTX_set_session_id_context(_ctx, reinterpret_cast<unsigned char*>(this),
+ static_cast<unsigned int>(sizeof(this)));
+
+ //
// Select protocols.
//
if(protocols != 0)