OLD | NEW |
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 CONTENT_PUBLIC_BROWSER_SECURITY_STYLE_EXPLANATION_H_ | 5 #ifndef CONTENT_PUBLIC_BROWSER_SECURITY_STYLE_EXPLANATION_H_ |
6 #define CONTENT_PUBLIC_BROWSER_SECURITY_STYLE_EXPLANATION_H_ | 6 #define CONTENT_PUBLIC_BROWSER_SECURITY_STYLE_EXPLANATION_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "content/common/content_export.h" | 10 #include "content/common/content_export.h" |
11 | 11 |
12 namespace content { | 12 namespace content { |
13 | 13 |
14 // A human-readable summary phrase and more detailed description of a | 14 // A human-readable summary phrase and more detailed description of a |
15 // security property that was used to compute the SecurityStyle of a | 15 // security property that was used to compute the SecurityStyle of a |
16 // resource. An example summary phrase would be "Expired Certificate", | 16 // resource. An example summary phrase would be "Expired Certificate", |
17 // with a description along the lines of "This site's certificate chain | 17 // with a description along the lines of "This site's certificate chain |
18 // contains errors (net::CERT_DATE_INVALID)". | 18 // contains errors (net::CERT_DATE_INVALID)". |
19 struct SecurityStyleExplanation { | 19 struct SecurityStyleExplanation { |
20 CONTENT_EXPORT SecurityStyleExplanation(){}; | 20 CONTENT_EXPORT SecurityStyleExplanation(){}; |
21 CONTENT_EXPORT SecurityStyleExplanation(const std::string& summary, | 21 CONTENT_EXPORT SecurityStyleExplanation(const std::string& summary, |
22 const std::string& description) | 22 const std::string& description) |
23 : summary(summary), description(description), cert_id(0) {} | 23 : summary(summary), description(description), has_certificate(false) {} |
24 CONTENT_EXPORT SecurityStyleExplanation(const std::string& summary, | 24 CONTENT_EXPORT SecurityStyleExplanation(const std::string& summary, |
25 const std::string& description, | 25 const std::string& description, |
26 int cert_id) | 26 bool has_certificate) |
27 : summary(summary), description(description), cert_id(cert_id) {} | 27 : summary(summary), description(description), |
| 28 has_certificate(has_certificate) {} |
28 CONTENT_EXPORT ~SecurityStyleExplanation() {} | 29 CONTENT_EXPORT ~SecurityStyleExplanation() {} |
29 | 30 |
30 std::string summary; | 31 std::string summary; |
31 std::string description; | 32 std::string description; |
32 int cert_id; | 33 bool has_certificate; |
33 }; | 34 }; |
34 | 35 |
35 } // namespace content | 36 } // namespace content |
36 | 37 |
37 #endif // CONTENT_PUBLIC_BROWSER_SECURITY_STYLE_EXPLANATION_H_ | 38 #endif // CONTENT_PUBLIC_BROWSER_SECURITY_STYLE_EXPLANATION_H_ |
OLD | NEW |