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

Side by Side Diff: ios/web/net/cert_host_pair.h

Issue 2000503002: Remove the fingerprint and ca_fingerprint from X509Certificate (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@move_cache
Patch Set: Fix Win & iOS Created 4 years, 6 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 IOS_WEB_NET_CERT_HOST_PAIR_H_ 5 #ifndef IOS_WEB_NET_CERT_HOST_PAIR_H_
6 #define IOS_WEB_NET_CERT_HOST_PAIR_H_ 6 #define IOS_WEB_NET_CERT_HOST_PAIR_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
11 #include "net/base/hash_value.h"
11 12
12 namespace net { 13 namespace net {
13 class X509Certificate; 14 class X509Certificate;
14 } 15 }
15 16
16 namespace web { 17 namespace web {
17 18
18 // Holds certificate-host pair. Implements operator less, hence can act as a key 19 // Holds certificate-host pair. Implements operator less, hence can act as a key
19 // for a container. 20 // for a container.
20 struct CertHostPair { 21 struct CertHostPair {
21 CertHostPair(const scoped_refptr<net::X509Certificate>& cert, 22 CertHostPair(const scoped_refptr<net::X509Certificate>& cert,
22 const std::string& host); 23 const std::string& host);
23 CertHostPair(const CertHostPair& other); 24 CertHostPair(const CertHostPair& other);
24 ~CertHostPair(); 25 ~CertHostPair();
25 26
26 bool operator<(const CertHostPair& other) const; 27 bool operator<(const CertHostPair& other) const;
27 28
28 scoped_refptr<net::X509Certificate> cert; 29 scoped_refptr<net::X509Certificate> cert;
29 std::string host; 30 std::string host;
31 const net::SHA256HashValue cert_hash;
Eugene But (OOO till 7-30) 2016/06/16 01:14:34 Should |cert| field be private or at least const?
Ryan Sleevi 2016/06/16 01:19:44 Actually making CertHostPair a proper class, with
Eugene But (OOO till 7-30) 2016/06/16 01:36:23 That sounds even better and totally reasonable to
30 }; 32 };
31 33
32 } // namespace web 34 } // namespace web
33 35
34 #endif // IOS_WEB_NET_CERT_HOST_PAIR_H_ 36 #endif // IOS_WEB_NET_CERT_HOST_PAIR_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698