Pin Chrome's shortcut to the Win10 Start menu on install and OS upgrade.
[chromium-blink-merge.git] / chrome / browser / ssl / chrome_fraudulent_certificate_reporter.h
blob3c4d0861632206402b26f2bdff513f46933aaf27
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.
5 #ifndef CHROME_BROWSER_SSL_CHROME_FRAUDULENT_CERTIFICATE_REPORTER_H_
6 #define CHROME_BROWSER_SSL_CHROME_FRAUDULENT_CERTIFICATE_REPORTER_H_
8 #include <set>
9 #include <string>
11 #include "base/memory/scoped_ptr.h"
12 #include "net/url_request/fraudulent_certificate_reporter.h"
14 namespace chrome_browser_net {
15 class CertificateErrorReporter;
16 } // namespace chrome_browser_net
18 namespace net {
19 class URLRequestContext;
20 } // namespace net
22 class ChromeFraudulentCertificateReporter
23 : public net::FraudulentCertificateReporter {
24 public:
25 explicit ChromeFraudulentCertificateReporter(
26 net::URLRequestContext* request_context);
28 // Useful for tests to use a mock reporter.
29 explicit ChromeFraudulentCertificateReporter(scoped_ptr<
30 chrome_browser_net::CertificateErrorReporter> certificate_reporter);
32 ~ChromeFraudulentCertificateReporter() override;
34 // net::FraudulentCertificateReporter
35 void SendReport(const std::string& hostname,
36 const net::SSLInfo& ssl_info) override;
38 private:
39 scoped_ptr<chrome_browser_net::CertificateErrorReporter>
40 certificate_reporter_;
42 DISALLOW_COPY_AND_ASSIGN(ChromeFraudulentCertificateReporter);
45 #endif // CHROME_BROWSER_SSL_CHROME_FRAUDULENT_CERTIFICATE_REPORTER_H_