Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_SSL_HOST_STATE_DELEGATE_H_ | 5 #ifndef CONTENT_PUBLIC_BROWSER_SSL_HOST_STATE_DELEGATE_H_ |
| 6 #define CONTENT_PUBLIC_BROWSER_SSL_HOST_STATE_DELEGATE_H_ | 6 #define CONTENT_PUBLIC_BROWSER_SSL_HOST_STATE_DELEGATE_H_ |
| 7 | 7 |
| 8 #include "base/memory/ref_counted.h" | 8 #include "base/memory/ref_counted.h" |
| 9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
| 10 #include "content/common/content_export.h" | 10 #include "content/common/content_export.h" |
| (...skipping 14 matching lines...) Expand all Loading... | |
| 25 // Records that |cert| is permitted to be used for |host| in the future, for | 25 // Records that |cert| is permitted to be used for |host| in the future, for |
| 26 // a specified |error| type. | 26 // a specified |error| type. |
| 27 virtual void AllowCert(const std::string&, | 27 virtual void AllowCert(const std::string&, |
| 28 net::X509Certificate* cert, | 28 net::X509Certificate* cert, |
| 29 net::CertStatus error) = 0; | 29 net::CertStatus error) = 0; |
| 30 | 30 |
| 31 // Clear all allow/deny preferences. | 31 // Clear all allow/deny preferences. |
| 32 virtual void Clear() = 0; | 32 virtual void Clear() = 0; |
| 33 | 33 |
| 34 // Queries whether |cert| is allowed or denied for |host| and |error|. | 34 // Queries whether |cert| is allowed or denied for |host| and |error|. |
| 35 virtual net::CertPolicy::Judgment QueryPolicy(const std::string& host, | 35 virtual net::CertPolicy::Judgment QueryPolicy( |
| 36 net::X509Certificate* cert, | 36 const std::string& host, |
| 37 net::CertStatus error) = 0; | 37 net::X509Certificate* cert, |
| 38 net::CertStatus error, | |
| 39 bool* expired_previous_decision) = 0; | |
|
felt
2014/08/08 17:55:33
why a bool* in some places and a bool in others?
jww
2014/08/12 04:51:02
The pointer ones are because they are return value
felt
2014/08/12 04:54:33
Oh, no, you don't need to. I see now.
| |
| 38 | 40 |
| 39 // Revoke all allow/deny preferences for |host|. | 41 // Revoke all allow/deny preferences for |host|. |
| 40 virtual void RevokeAllowAndDenyPreferences(const std::string& host) = 0; | 42 virtual void RevokeAllowAndDenyPreferences(const std::string& host) = 0; |
| 41 | 43 |
| 42 // Returns true if any decisions has been recorded for |host|, otherwise | 44 // Returns true if any decisions has been recorded for |host|, otherwise |
| 43 // false. | 45 // false. |
| 44 virtual bool HasAllowedOrDeniedCert(const std::string& host) = 0; | 46 virtual bool HasAllowedOrDeniedCert(const std::string& host) = 0; |
| 45 | 47 |
| 46 protected: | 48 protected: |
| 47 virtual ~SSLHostStateDelegate() {} | 49 virtual ~SSLHostStateDelegate() {} |
| 48 }; | 50 }; |
| 49 | 51 |
| 50 } // namespace content | 52 } // namespace content |
| 51 | 53 |
| 52 #endif // CONTENT_PUBLIC_BROWSER_SSL_HOST_STATE_DELEGATE_H_ | 54 #endif // CONTENT_PUBLIC_BROWSER_SSL_HOST_STATE_DELEGATE_H_ |
| OLD | NEW |