- Timestamp:
- Oct 10, 2010, 9:22:38 PM (15 years ago)
- Location:
- trunk/src/network/ssl
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/network/ssl/qsslsocket_openssl.cpp
r769 r788 188 188 else if (protoString == QLatin1String("TLSv1")) 189 189 ciph.d->protocol = QSsl::TlsV1; 190 190 191 191 if (descriptionList.at(2).startsWith(QLatin1String("Kx="))) 192 192 ciph.d->keyExchangeMethod = descriptionList.at(2).mid(3); … … 341 341 if (configuration.peerVerifyDepth != 0) 342 342 q_SSL_CTX_set_verify_depth(ctx, configuration.peerVerifyDepth); 343 343 344 344 // Create and initialize SSL session 345 345 if (!(ssl = q_SSL_new(ctx))) { … … 425 425 do { 426 426 if (attempts < 500) { 427 #if def Q_OS_UNIX427 #if 428 428 struct timespec ts = {0, 33333333}; 429 429 nanosleep(&ts, 0); … … 534 534 do { 535 535 transmitting = false; 536 536 537 537 // If the connection is secure, we can transfer data from the write 538 538 // buffer (in plain text) to the write BIO through SSL_write. -
trunk/src/network/ssl/qsslsocket_openssl_symbols.cpp
r769 r788 262 262 if (!(_q_##func = _q_PTR_##func(lib->resolve(#ordinal)))) \ 263 263 qWarning("QSslSocket: cannot resolve "#func); 264 265 266 267 268 264 269 #else 265 270 #define RESOLVEFUNC(func) \ … … 462 467 libssl = libcrypto = 0; 463 468 return pair; 464 469 # elif defined(Q_OS_OS2) 470 // note: the k* versions of libraries were in use once; support them for 471 // backward compatibility 472 static const char *ssl_dll[] = { "ssl10", "kssl10" }; 473 static const char *crypto_dll[] = { "crypto10", "kcrypt10" }; 474 475 QLibrary *libssl; 476 for (size_t i = 0; i < sizeof(ssl_dll)/sizeof(ssl_dll[0]); ++i) { 477 libssl = new QLibrary(QLatin1String(ssl_dll[i])); 478 if (libssl->load()) 479 break; 480 delete libssl; 481 libssl = 0; 482 } 483 if (!libssl) { 484 return pair; 485 } 486 487 QLibrary *libcrypto; 488 for (size_t i = 0; i < sizeof(crypto_dll)/sizeof(crypto_dll[0]); ++i) { 489 libcrypto = new QLibrary(QLatin1String(crypto_dll[i])); 490 if (libcrypto->load()) 491 break; 492 delete libcrypto; 493 libcrypto = 0; 494 } 495 if (!libcrypto) { 496 delete libssl; 497 return pair; 498 } 499 500 pair.first = libssl; 501 pair.second = libcrypto; 502 return pair; 465 503 # else 466 504 // not implemented for this platform yet … … 535 573 RESOLVEFUNC(sk_free, 2571, libs.second ) 536 574 RESOLVEFUNC(sk_num, 2576, libs.second ) 537 RESOLVEFUNC(sk_pop_free, 2578, libs.second ) 575 RESOLVEFUNC(sk_pop_free, 2578, libs.second ) 538 576 RESOLVEFUNC(sk_value, 2585, libs.second ) 539 577 RESOLVEFUNC(SSL_CIPHER_description, 11, libs.first ) -
trunk/src/network/ssl/ssl.pri
r561 r788 37 37 # Add optional SSL libs 38 38 LIBS_PRIVATE += $$OPENSSL_LIBS 39 40 41 42 43 39 44 }
Note:
See TracChangeset
for help on using the changeset viewer.