| Index: net/socket/ssl_session_cache_openssl.cc
|
| diff --git a/net/socket/ssl_session_cache_openssl.cc b/net/socket/ssl_session_cache_openssl.cc
|
| index d16bb8d6325ec6b105da7219d4e9ea9e5f6f4828..ae3c5a4a2cdbdd43c5064d107685a661ba44085b 100644
|
| --- a/net/socket/ssl_session_cache_openssl.cc
|
| +++ b/net/socket/ssl_session_cache_openssl.cc
|
| @@ -236,6 +236,14 @@ class SSLSessionCacheOpenSSLImpl {
|
| return SSL_set_session(ssl, session) == 1;
|
| }
|
|
|
| + bool SSLSessionIsInCache(const std::string& cache_key) const {
|
| + base::AutoLock locked(lock_);
|
| + KeyIndex::const_iterator it = key_index_.find(cache_key);
|
| + if (it == key_index_.end())
|
| + return false;
|
| + return true;
|
| + }
|
| +
|
| void MarkSSLSessionAsGood(SSL* ssl) {
|
| SSL_SESSION* session = SSL_get_session(ssl);
|
| if (!session)
|
| @@ -469,7 +477,7 @@ class SSLSessionCacheOpenSSLImpl {
|
|
|
| // method to get the index which can later be used with SSL_CTX_get_ex_data()
|
| // or SSL_CTX_set_ex_data().
|
| - base::Lock lock_; // Protects access to containers below.
|
| + mutable base::Lock lock_; // Protects access to containers below.
|
|
|
| MRUSessionList ordering_;
|
| KeyIndex key_index_;
|
| @@ -499,6 +507,11 @@ bool SSLSessionCacheOpenSSL::SetSSLSessionWithKey(
|
| return impl_->SetSSLSessionWithKey(ssl, cache_key);
|
| }
|
|
|
| +bool SSLSessionCacheOpenSSL::SSLSessionIsInCache(
|
| + const std::string& cache_key) const {
|
| + return impl_->SSLSessionIsInCache(cache_key);
|
| +}
|
| +
|
| void SSLSessionCacheOpenSSL::MarkSSLSessionAsGood(SSL* ssl) {
|
| return impl_->MarkSSLSessionAsGood(ssl);
|
| }
|
|
|