OLD | NEW |
---|---|
(Empty) | |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | |
eroman
2016/03/08 23:40:47
nit: 2016
estark
2016/03/08 23:46:32
Done.
| |
2 // Use of this source code is governed by a BSD-style license that can be | |
3 // found in the LICENSE file. | |
4 | |
5 #ifndef CHROME_BROWSER_SSL_CHROME_EXPECT_CT_REPORTER_H_ | |
6 #define CHROME_BROWSER_SSL_CHROME_EXPECT_CT_REPORTER_H_ | |
7 | |
8 #include "base/macros.h" | |
9 #include "base/memory/scoped_ptr.h" | |
10 #include "net/http/transport_security_state.h" | |
11 | |
12 namespace net { | |
13 class CertificateReportSender; | |
14 class URLRequestContext; | |
15 } // namespace net | |
16 | |
17 // This class monitors for violations of CT policy and sends reports | |
18 // about failures for sites that have opted in. Must be deleted before | |
19 // the URLRequestContext that is passed to the constructor, so that it | |
20 // can cancel its requests. | |
21 class ChromeExpectCTReporter | |
22 : public net::TransportSecurityState::ExpectCTReporter { | |
23 public: | |
24 explicit ChromeExpectCTReporter(net::URLRequestContext* request_context); | |
25 ~ChromeExpectCTReporter() override; | |
26 | |
27 // net::ExpectCTReporter: | |
28 void OnExpectCTFailed(const net::HostPortPair& host_port_pair, | |
29 const GURL& report_uri, | |
30 const net::SSLInfo& ssl_info) override; | |
31 | |
32 private: | |
33 scoped_ptr<net::CertificateReportSender> report_sender_; | |
34 | |
35 DISALLOW_COPY_AND_ASSIGN(ChromeExpectCTReporter); | |
36 }; | |
37 | |
38 #endif // CHROME_BROWSER_SSL_CHROME_EXPECT_CT_REPORTER_H_ | |
OLD | NEW |