blob: 19b5e9e6f6705a5936795d56f4720a767934939a (
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
42
43
|
/*
* context.h
*
* Copyright (C) AB Strakt
* See LICENSE for details.
*
* Export SSL Context object data structures and functions.
* See the file RATIONALE for a short explanation of why this module was written.
*
* Reviewed 2001-07-23
*
*/
#ifndef PyOpenSSL_SSL_CONTEXT_H_
#define PyOpenSSL_SSL_CONTEXT_H_
#include <Python.h>
#include <openssl/ssl.h>
extern int init_ssl_context (PyObject *);
extern PyTypeObject ssl_Context_Type;
#define ssl_Context_Check(v) ((v)->ob_type == &ssl_Context_Type)
typedef struct {
PyObject_HEAD
SSL_CTX *ctx;
PyObject *passphrase_callback,
*passphrase_userdata,
*verify_callback,
*info_callback,
*tlsext_servername_callback,
*app_data;
PyThreadState *tstate;
} ssl_ContextObj;
#define ssl_SSLv2_METHOD (1)
#define ssl_SSLv3_METHOD (2)
#define ssl_SSLv23_METHOD (3)
#define ssl_TLSv1_METHOD (4)
#endif
|