Pin Chrome's shortcut to the Win10 Start menu on install and OS upgrade.
[chromium-blink-merge.git] / net / cert_net / nss_ocsp.h
bloba422cb22e5ab37bccc7a3327ac3bf2ab1c90ff6f
1 // Copyright (c) 2012 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 NET_CERT_NET_NSS_OCSP_H_
6 #define NET_CERT_NET_NSS_OCSP_H_
8 #include "net/base/net_export.h"
10 namespace net {
12 class URLRequestContext;
14 // Sets the MessageLoop for NSS's HTTP client functions (i.e. OCSP, CA
15 // certificate and CRL fetches) to the current message loop. This should be
16 // called before EnsureNSSHttpIOInit() if you want to control the message loop.
17 NET_EXPORT void SetMessageLoopForNSSHttpIO();
19 // Initializes HTTP client functions for NSS. This must be called before any
20 // certificate verification functions. This function is thread-safe, and HTTP
21 // handlers will only ever be initialized once. ShutdownNSSHttpIO() must be
22 // called on shutdown.
23 NET_EXPORT void EnsureNSSHttpIOInit();
25 // This should be called once on shutdown to stop issuing URLRequests for NSS
26 // related HTTP fetches.
27 NET_EXPORT void ShutdownNSSHttpIO();
29 // Can be called after a call to |ShutdownNSSHttpIO()| to reset internal state
30 // and associate it with the current thread.
31 NET_EXPORT void ResetNSSHttpIOForTesting();
33 // Sets the URLRequestContext for HTTP requests issued by NSS.
34 NET_EXPORT void SetURLRequestContextForNSSHttpIO(
35 URLRequestContext* request_context);
37 } // namespace net
39 #endif // NET_CERT_NET_NSS_OCSP_H_