blob: 93d07ceb0d16edb2e869896ff5f3a1015c57dc85 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
// Copyright (c) 2011 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_OCSP_NSS_OCSP_H_
#define NET_OCSP_NSS_OCSP_H_
#pragma once
#include "net/base/net_export.h"
namespace net {
class URLRequestContext;
// Sets the MessageLoop for OCSP to the current message loop.
// This should be called before EnsureOCSPInit() if you want to
// control the message loop for OCSP.
NET_EXPORT void SetMessageLoopForOCSP();
// Disables OCSP for the current process. This is needed to run SSL
// code in the renderer process. After this method is called all
// calls to EnsureOCSPInit() and ShutdownOCSP() are ignored. When
// OCSP is disabled SetMessageLoopForOCSP() and
// SetURLRequestContextForOCSP() are useless and should not be called.
NET_EXPORT void DisableOCSP();
// Initializes OCSP handlers for NSS. This must be called before any
// certificate verification functions. This function is thread-safe, and OCSP
// handlers will only ever be initialized once. ShutdownOCSP() must be called
// on shutdown.
NET_EXPORT void EnsureOCSPInit();
// This should be called once on shutdown to stop issuing URLRequests for OCSP.
NET_EXPORT void ShutdownOCSP();
// Set URLRequestContext for OCSP handlers.
NET_EXPORT void SetURLRequestContextForOCSP(URLRequestContext* request_context);
} // namespace net
#endif // NET_OCSP_NSS_OCSP_H_
|