Context.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 1996-2017 The Squid Software Foundation and contributors
3  *
4  * Squid software is distributed under GPLv2+ license and includes
5  * contributions from numerous individuals and organizations.
6  * Please see the COPYING and CONTRIBUTORS files for details.
7  */
8 
9 #ifndef SQUID_SRC_SECURITY_CONTEXT_H
10 #define SQUID_SRC_SECURITY_CONTEXT_H
11 
12 #include <memory>
13 
14 #if USE_OPENSSL
15 #if HAVE_OPENSSL_SSL_H
16 #include <openssl/ssl.h>
17 #endif
18 
19 #elif USE_GNUTLS
20 #if HAVE_GNUTLS_GNUTLS_H
21 #include <gnutls/gnutls.h>
22 #endif
23 #endif
24 
25 namespace Security {
26 
27 #if USE_OPENSSL
28 typedef std::shared_ptr<SSL_CTX> ContextPointer;
29 
30 #elif USE_GNUTLS
31 typedef std::shared_ptr<struct gnutls_certificate_credentials_st> ContextPointer;
32 
33 #else
34 // use void* so we can check against nullptr
35 typedef std::shared_ptr<void> ContextPointer;
36 
37 #endif
38 
39 } // namespace Security
40 
41 #endif /* SQUID_SRC_SECURITY_CONTEXT_H */
42 
std::shared_ptr< SSL_CTX > ContextPointer
Definition: Context.h:28

 

Introduction

Documentation

Support

Miscellaneous

Web Site Translations

Mirrors