Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(568)

Side by Side Diff: net/ssl/openssl_client_key_store.h

Issue 474663002: Remove manual CRYPTO_add calls. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: speling Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « net/socket/ssl_client_socket_openssl.cc ('k') | net/ssl/openssl_client_key_store.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef NET_SSL_OPENSSL_CLIENT_KEY_STORE_H_ 5 #ifndef NET_SSL_OPENSSL_CLIENT_KEY_STORE_H_
6 #define NET_SSL_OPENSSL_CLIENT_KEY_STORE_H_ 6 #define NET_SSL_OPENSSL_CLIENT_KEY_STORE_H_
7 7
8 #include <openssl/evp.h> 8 #include <openssl/evp.h>
9 9
10 #include <vector> 10 #include <vector>
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
69 private: 69 private:
70 // KeyPair is an internal class used to hold a pair of private / public 70 // KeyPair is an internal class used to hold a pair of private / public
71 // EVP_PKEY objects, with appropriate ownership. 71 // EVP_PKEY objects, with appropriate ownership.
72 class KeyPair { 72 class KeyPair {
73 public: 73 public:
74 explicit KeyPair(EVP_PKEY* pub_key, EVP_PKEY* priv_key); 74 explicit KeyPair(EVP_PKEY* pub_key, EVP_PKEY* priv_key);
75 KeyPair(const KeyPair& other); 75 KeyPair(const KeyPair& other);
76 void operator=(const KeyPair& other); 76 void operator=(const KeyPair& other);
77 ~KeyPair(); 77 ~KeyPair();
78 78
79 EVP_PKEY* public_key; 79 crypto::ScopedEVP_PKEY public_key;
80 EVP_PKEY* private_key; 80 crypto::ScopedEVP_PKEY private_key;
81 81
82 private: 82 private:
83 KeyPair(); // intentionally not implemented. 83 KeyPair(); // intentionally not implemented.
84 }; 84 };
85 85
86 // Returns the index of the keypair for |public_key|. or -1 if not found. 86 // Returns the index of the keypair for |public_key|. or -1 if not found.
87 int FindKeyPairIndex(EVP_PKEY* public_key); 87 int FindKeyPairIndex(EVP_PKEY* public_key);
88 88
89 std::vector<KeyPair> pairs_; 89 std::vector<KeyPair> pairs_;
90 90
91 friend struct DefaultSingletonTraits<OpenSSLClientKeyStore>; 91 friend struct DefaultSingletonTraits<OpenSSLClientKeyStore>;
92 92
93 DISALLOW_COPY_AND_ASSIGN(OpenSSLClientKeyStore); 93 DISALLOW_COPY_AND_ASSIGN(OpenSSLClientKeyStore);
94 }; 94 };
95 95
96 } // namespace net 96 } // namespace net
97 97
98 #endif // NET_SSL_OPENSSL_CLIENT_KEY_STORE_H_ 98 #endif // NET_SSL_OPENSSL_CLIENT_KEY_STORE_H_
OLDNEW
« no previous file with comments | « net/socket/ssl_client_socket_openssl.cc ('k') | net/ssl/openssl_client_key_store.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698