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

Side by Side Diff: net/http/transport_security_reporter.h

Issue 1212613004: Build and send HPKP violation reports (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: combine GetHPKPReportUri() and BuildHPKPReport() into GetHPKPReport() Created 5 years, 5 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
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef NET_HTTP_TRANSPORT_SECURITY_REPORTER_H_
6 #define NET_HTTP_TRANSPORT_SECURITY_REPORTER_H_
7
8 #include <string>
9
10 #include "net/http/certificate_report_sender_impl.h"
11 #include "net/http/transport_security_state.h"
12
13 class GURL;
14
15 namespace net {
16
17 class SSLInfo;
18 class URLRequestContext;
19
20 // Builds, serializes, and sends violation reports detected by
21 // TransportSecurityState.
22 class NET_EXPORT TransportSecurityReporter
23 : public TransportSecurityState::Reporter {
24 public:
25 TransportSecurityReporter(TransportSecurityState* state,
26 scoped_ptr<CertificateReportSender> report_sender);
27 ~TransportSecurityReporter() override;
28
29 // TransportSecurityState::Reporter overrides
30 bool GetHPKPReport(const std::string& hostname,
31 const TransportSecurityState::PKPState& pkp_state,
32 bool is_static_pin,
33 uint16_t port,
34 const X509Certificate* served_certificate_chain,
35 const X509Certificate* validated_certificate_chain,
36 GURL* report_uri,
37 std::string* serialized_report) override;
38 void SendHPKPReport(const GURL& report_uri,
39 const std::string& report) override;
40
41 private:
42 TransportSecurityState* transport_security_state_;
43 scoped_ptr<CertificateReportSender> report_sender_;
44 };
45
46 } // namespace net
47
48 #endif // NET_HTTP_TRANSPORT_SECURITY_REPORTER_H_
OLDNEW
« no previous file with comments | « no previous file | net/http/transport_security_reporter.cc » ('j') | net/http/transport_security_reporter.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698