Index: net/cert/test_root_certs.h |
diff --git a/net/cert/test_root_certs.h b/net/cert/test_root_certs.h |
index 03cedcc93385d280eca3971d83faad883e32fd94..b44d28f7d7ee3fa0866d9ded91696a34d520f071 100644 |
--- a/net/cert/test_root_certs.h |
+++ b/net/cert/test_root_certs.h |
@@ -9,6 +9,7 @@ |
#include "base/memory/ref_counted.h" |
#include "build/build_config.h" |
#include "net/base/net_export.h" |
+#include "net/cert/x509_certificate.h" |
#if defined(USE_NSS) || defined(OS_IOS) |
#include <list> |
@@ -23,18 +24,18 @@ |
#include "base/mac/scoped_cftyperef.h" |
#endif |
+typedef struct CERTCertificateStr CERTCertificate; |
+ |
namespace base { |
class FilePath; |
} |
namespace net { |
-class X509Certificate; |
- |
// TestRootCerts is a helper class for unit tests that is used to |
// artificially mark a certificate as trusted, independent of the local |
// machine configuration. |
-class NET_EXPORT_PRIVATE TestRootCerts { |
+class NET_EXPORT TestRootCerts { |
public: |
// Obtains the Singleton instance to the trusted certificates. |
static TestRootCerts* GetInstance(); |
@@ -58,7 +59,9 @@ class NET_EXPORT_PRIVATE TestRootCerts { |
// Returns true if there are no certificates that have been marked trusted. |
bool IsEmpty() const; |
-#if defined(OS_MACOSX) && !defined(OS_IOS) |
+#if defined(USE_NSS) || defined(OS_IOS) |
+ bool Contains(CERTCertificate* cert) const; |
+#elif defined(OS_MACOSX) && !defined(OS_IOS) |
CFArrayRef temporary_roots() const { return temporary_roots_; } |
// Modifies the root certificates of |trust_ref| to include the |
@@ -73,6 +76,7 @@ class NET_EXPORT_PRIVATE TestRootCerts { |
#elif defined(USE_OPENSSL) && !defined(OS_ANDROID) |
const std::vector<scoped_refptr<X509Certificate> >& |
temporary_roots() const { return temporary_roots_; } |
+ bool Contains(X509* cert) const; |
Ryan Sleevi
2014/02/07 01:38:28
|X509| is not defined here. You need to forward de
mattm
2014/02/07 03:38:04
Oops, done.
|
#elif defined(OS_WIN) |
HCERTSTORE temporary_roots() const { return temporary_roots_; } |