version 1.31, 2004/09/09 13:09:42
|
version 1.32, 2004/09/14 09:29:03
|
|
|
return 0; | return 0; |
} | } |
| |
void CIMClientRep::_connect(AutoPtr<SSLContext>& connectSSLContext) |
void CIMClientRep::_connect() |
{ | { |
// | // |
// Test for Display optons of the form | // Test for Display optons of the form |
|
|
{ | { |
_disconnect(); | _disconnect(); |
_authenticator.setRequestMessage(0); | _authenticator.setRequestMessage(0); |
_connect(_connectSSLContext); |
_connect(); |
} | } |
| |
void CIMClientRep::connect( | void CIMClientRep::connect( |
|
|
_connectHost = hostName; | _connectHost = hostName; |
_connectPortNumber = portNumber; | _connectPortNumber = portNumber; |
| |
_connect(_connectSSLContext); |
_connect(); |
} | } |
| |
| |
|
|
_connectHost = hostName; | _connectHost = hostName; |
_connectPortNumber = portNumber; | _connectPortNumber = portNumber; |
| |
AutoPtr<SSLContext> connectSSLContext(new SSLContext(sslContext)); |
_connectSSLContext.reset(new SSLContext(sslContext)); |
_connect(connectSSLContext); |
_connect(); |
_connectSSLContext.reset(connectSSLContext.release()); |
|
} | } |
| |
| |
|
|
_connectSSLContext.reset(); | _connectSSLContext.reset(); |
_connectHost = String::EMPTY; | _connectHost = String::EMPTY; |
_connectPortNumber = 0; | _connectPortNumber = 0; |
_connect(_connectSSLContext); |
_connect(); |
#else | #else |
| |
try | try |
|
|
| |
_connectSSLContext.reset(); | _connectSSLContext.reset(); |
| |
_connect(_connectSSLContext); |
_connect(); |
} | } |
catch(CannotConnectException &e) | catch(CannotConnectException &e) |
{ | { |
|
|
pegasusHome, PEGASUS_SSLCLIENT_RANDOMFILE); | pegasusHome, PEGASUS_SSLCLIENT_RANDOMFILE); |
#endif | #endif |
| |
AutoPtr<SSLContext> connectSSLContext; |
|
try | try |
{ | { |
connectSSLContext.reset( |
_connectSSLContext.reset( |
new SSLContext(String::EMPTY, NULL, randFile)); | new SSLContext(String::EMPTY, NULL, randFile)); |
} | } |
catch (SSLException &se) | catch (SSLException &se) |
|
|
throw se; | throw se; |
} | } |
| |
_connect(connectSSLContext); |
_connect(); |
_connectSSLContext.reset(connectSSLContext.release()); |
|
} | } |
#endif | #endif |
} | } |
|
|
// Sending a new request, so clear out the response Content-Languages | // Sending a new request, so clear out the response Content-Languages |
responseContentLanguages = ContentLanguages::EMPTY; | responseContentLanguages = ContentLanguages::EMPTY; |
| |
_requestEncoder->enqueue(request.release()); |
_requestEncoder->enqueue(request.get()); |
|
request.release(); |
| |
Uint64 startMilliseconds = TimeValue::getCurrentTime().toMilliseconds(); | Uint64 startMilliseconds = TimeValue::getCurrentTime().toMilliseconds(); |
Uint64 nowMilliseconds = startMilliseconds; | Uint64 nowMilliseconds = startMilliseconds; |