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

Side by Side Diff: webrtc/base/sslstreamadapter.h

Issue 1802013002: A bunch of interfaces: Return scoped_ptr<SSLCertificate> (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: less auto Created 4 years, 8 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
« no previous file with comments | « webrtc/base/opensslstreamadapter.cc ('k') | webrtc/base/sslstreamadapter_unittest.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 /* 1 /*
2 * Copyright 2004 The WebRTC Project Authors. All rights reserved. 2 * Copyright 2004 The WebRTC Project Authors. All rights reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after
147 // obtained through some other secure channel (such as the XMPP 147 // obtained through some other secure channel (such as the XMPP
148 // channel). Unlike SetPeerCertificate(), this must specify the 148 // channel). Unlike SetPeerCertificate(), this must specify the
149 // terminal certificate, not just a CA. 149 // terminal certificate, not just a CA.
150 // SSLStream makes a copy of the digest value. 150 // SSLStream makes a copy of the digest value.
151 virtual bool SetPeerCertificateDigest(const std::string& digest_alg, 151 virtual bool SetPeerCertificateDigest(const std::string& digest_alg,
152 const unsigned char* digest_val, 152 const unsigned char* digest_val,
153 size_t digest_len) = 0; 153 size_t digest_len) = 0;
154 154
155 // Retrieves the peer's X.509 certificate, if a connection has been 155 // Retrieves the peer's X.509 certificate, if a connection has been
156 // established. It returns the transmitted over SSL, including the entire 156 // established. It returns the transmitted over SSL, including the entire
157 // chain. The returned certificate is owned by the caller. 157 // chain.
158 virtual bool GetPeerCertificate(SSLCertificate** cert) const = 0; 158 virtual rtc::scoped_ptr<SSLCertificate> GetPeerCertificate() const = 0;
159 159
160 // Retrieves the IANA registration id of the cipher suite used for the 160 // Retrieves the IANA registration id of the cipher suite used for the
161 // connection (e.g. 0x2F for "TLS_RSA_WITH_AES_128_CBC_SHA"). 161 // connection (e.g. 0x2F for "TLS_RSA_WITH_AES_128_CBC_SHA").
162 virtual bool GetSslCipherSuite(int* cipher_suite); 162 virtual bool GetSslCipherSuite(int* cipher_suite);
163 163
164 virtual int GetSslVersion() const = 0; 164 virtual int GetSslVersion() const = 0;
165 165
166 // Key Exporter interface from RFC 5705 166 // Key Exporter interface from RFC 5705
167 // Arguments are: 167 // Arguments are:
168 // label -- the exporter label. 168 // label -- the exporter label.
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
209 209
210 // If true (default), the client is required to provide a certificate during 210 // If true (default), the client is required to provide a certificate during
211 // handshake. If no certificate is given, handshake fails. This applies to 211 // handshake. If no certificate is given, handshake fails. This applies to
212 // server mode only. 212 // server mode only.
213 bool client_auth_enabled_; 213 bool client_auth_enabled_;
214 }; 214 };
215 215
216 } // namespace rtc 216 } // namespace rtc
217 217
218 #endif // WEBRTC_BASE_SSLSTREAMADAPTER_H_ 218 #endif // WEBRTC_BASE_SSLSTREAMADAPTER_H_
OLDNEW
« no previous file with comments | « webrtc/base/opensslstreamadapter.cc ('k') | webrtc/base/sslstreamadapter_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698