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

Unified Diff: net/cert/nss_profile_filter_chromeos.h

Issue 112533002: Add ClientCertStoreChromeOS which only returns the certs for a given user. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: explicits Created 7 years 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « crypto/nss_util.cc ('k') | net/cert/nss_profile_filter_chromeos.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/cert/nss_profile_filter_chromeos.h
diff --git a/net/cert/nss_profile_filter_chromeos.h b/net/cert/nss_profile_filter_chromeos.h
new file mode 100644
index 0000000000000000000000000000000000000000..71abafa572e09206e45b1f157d50b7ecc4827349
--- /dev/null
+++ b/net/cert/nss_profile_filter_chromeos.h
@@ -0,0 +1,60 @@
+// Copyright (c) 2013 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef NET_CERT_NSS_PROFILE_FILTER_CHROMEOS
+#define NET_CERT_NSS_PROFILE_FILTER_CHROMEOS
+
+#include "base/callback_forward.h"
+#include "crypto/scoped_nss_types.h"
+#include "net/base/crypto_module.h"
+#include "net/cert/x509_certificate.h"
+
+namespace content {
+class ResourceContext;
+} // namespace content
+
+namespace net {
+
+class NET_EXPORT NSSProfileFilterChromeOS {
+ public:
+ NSSProfileFilterChromeOS();
+ ~NSSProfileFilterChromeOS();
+
+ // Initialize with slot handles.
+ void Init(crypto::ScopedPK11Slot public_slot,
+ crypto::ScopedPK11Slot private_slot);
+
+ bool IsModuleAllowed(PK11SlotInfo* slot) const;
+ bool IsCertAllowed(const scoped_refptr<X509Certificate>& cert) const;
+
+ class CertNotAllowedForProfilePredicate {
+ public:
+ explicit CertNotAllowedForProfilePredicate(
+ const NSSProfileFilterChromeOS& filter);
+ bool operator()(const scoped_refptr<X509Certificate>& cert) const;
+
+ private:
+ const NSSProfileFilterChromeOS& filter_;
+ };
+
+ class ModuleNotAllowedForProfilePredicate {
+ public:
+ explicit ModuleNotAllowedForProfilePredicate(
+ const NSSProfileFilterChromeOS& filter);
+ bool operator()(const scoped_refptr<CryptoModule>& module) const;
+
+ private:
+ const NSSProfileFilterChromeOS& filter_;
+ };
+
+ private:
+ crypto::ScopedPK11Slot public_slot_;
+ crypto::ScopedPK11Slot private_slot_;
+
+ DISALLOW_COPY_AND_ASSIGN(NSSProfileFilterChromeOS);
+};
+
+} // namespace net
+
+#endif // NET_CERT_NSS_PROFILE_FILTER_CHROMEOS
« no previous file with comments | « crypto/nss_util.cc ('k') | net/cert/nss_profile_filter_chromeos.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698