43 #ifndef QSSLSOCKET_OPENSSL_SYMBOLS_P_H 44 #define QSSLSOCKET_OPENSSL_SYMBOLS_P_H 63 #if !defined QT_LINKED_OPENSSL 67 # define DEFINEFUNC(ret, func, arg, a, err, funcret) \ 68 typedef ret (*_q_PTR_##func)(arg); \ 69 static _q_PTR_##func _q_##func = 0; \ 72 qWarning("QSslSocket: cannot call unresolved function "#func); \ 75 funcret _q_##func(a); \ 79 # define DEFINEFUNC2(ret, func, arg1, a, arg2, b, err, funcret) \ 80 typedef ret (*_q_PTR_##func)(arg1, arg2); \ 81 static _q_PTR_##func _q_##func = 0; \ 82 ret q_##func(arg1, arg2) { \ 84 qWarning("QSslSocket: cannot call unresolved function "#func);\ 87 funcret _q_##func(a, b); \ 91 # define DEFINEFUNC3(ret, func, arg1, a, arg2, b, arg3, c, err, funcret) \ 92 typedef ret (*_q_PTR_##func)(arg1, arg2, arg3); \ 93 static _q_PTR_##func _q_##func = 0; \ 94 ret q_##func(arg1, arg2, arg3) { \ 96 qWarning("QSslSocket: cannot call unresolved function "#func); \ 99 funcret _q_##func(a, b, c); \ 103 # define DEFINEFUNC4(ret, func, arg1, a, arg2, b, arg3, c, arg4, d, err, funcret) \ 104 typedef ret (*_q_PTR_##func)(arg1, arg2, arg3, arg4); \ 105 static _q_PTR_##func _q_##func = 0; \ 106 ret q_##func(arg1, arg2, arg3, arg4) { \ 108 qWarning("QSslSocket: cannot call unresolved function "#func); \ 111 funcret _q_##func(a, b, c, d); \ 115 # define DEFINEFUNC5(ret, func, arg1, a, arg2, b, arg3, c, arg4, d, arg5, e, err, funcret) \ 116 typedef ret (*_q_PTR_##func)(arg1, arg2, arg3, arg4, arg5); \ 117 static _q_PTR_##func _q_##func = 0; \ 118 ret q_##func(arg1, arg2, arg3, arg4, arg5) { \ 120 qWarning("QSslSocket: cannot call unresolved function "#func); \ 123 funcret _q_##func(a, b, c, d, e); \ 127 # define DEFINEFUNC6(ret, func, arg1, a, arg2, b, arg3, c, arg4, d, arg5, e, arg6, f, err, funcret) \ 128 typedef ret (*_q_PTR_##func)(arg1, arg2, arg3, arg4, arg5, arg6); \ 129 static _q_PTR_##func _q_##func = 0; \ 130 ret q_##func(arg1, arg2, arg3, arg4, arg5, arg6) { \ 132 qWarning("QSslSocket: cannot call unresolved function "#func); \ 135 funcret _q_##func(a, b, c, d, e, f); \ 139 # define DEFINEFUNC7(ret, func, arg1, a, arg2, b, arg3, c, arg4, d, arg5, e, arg6, f, arg7, g, err, funcret) \ 140 typedef ret (*_q_PTR_##func)(arg1, arg2, arg3, arg4, arg5, arg6, arg7); \ 141 static _q_PTR_##func _q_##func = 0; \ 142 ret q_##func(arg1, arg2, arg3, arg4, arg5, arg6, arg7) { \ 144 qWarning("QSslSocket: cannot call unresolved function "#func); \ 147 funcret _q_##func(a, b, c, d, e, f, g); \ 151 # define DEFINEFUNC9(ret, func, arg1, a, arg2, b, arg3, c, arg4, d, arg5, e, arg6, f, arg7, g, arg8, h, arg9, i, err, funcret) \ 152 typedef ret (*_q_PTR_##func)(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9); \ 153 static _q_PTR_##func _q_##func = 0; \ 154 ret q_##func(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) { \ 156 qWarning("QSslSocket: cannot call unresolved function "#func); \ 159 funcret _q_##func(a, b, c, d, e, f, g, h, i); \ 163 #else // !defined QT_LINKED_OPENSSL 168 # define DEFINEFUNC(ret, func, arg, a, err, funcret) \ 169 ret q_##func(arg) { funcret func(a); } 172 # define DEFINEFUNC2(ret, func, arg1, a, arg2, b, err, funcret) \ 173 ret q_##func(arg1, arg2) { funcret func(a, b); } 176 # define DEFINEFUNC3(ret, func, arg1, a, arg2, b, arg3, c, err, funcret) \ 177 ret q_##func(arg1, arg2, arg3) { funcret func(a, b, c); } 180 # define DEFINEFUNC4(ret, func, arg1, a, arg2, b, arg3, c, arg4, d, err, funcret) \ 181 ret q_##func(arg1, arg2, arg3, arg4) { funcret func(a, b, c, d); } 184 # define DEFINEFUNC5(ret, func, arg1, a, arg2, b, arg3, c, arg4, d, arg5, e, err, funcret) \ 185 ret q_##func(arg1, arg2, arg3, arg4, arg5) { funcret func(a, b, c, d, e); } 188 # define DEFINEFUNC6(ret, func, arg1, a, arg2, b, arg3, c, arg4, d, arg5, e, arg6, f, err, funcret) \ 189 ret q_##func(arg1, arg2, arg3, arg4, arg5, arg6) { funcret func(a, b, c, d, e, f); } 192 # define DEFINEFUNC7(ret, func, arg1, a, arg2, b, arg3, c, arg4, d, arg5, e, arg6, f, arg7, g, err, funcret) \ 193 ret q_##func(arg1, arg2, arg3, arg4, arg5, arg6, arg7) { funcret func(a, b, c, d, e, f, g); } 196 # define DEFINEFUNC9(ret, func, arg1, a, arg2, b, arg3, c, arg4, d, arg5, e, arg6, f, arg7, g, arg8, h, arg9, i, err, funcret) \ 197 ret q_##func(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) { funcret func(a, b, c, d, e, f, g, h, i); } 201 #endif // !defined QT_LINKED_OPENSSL 221 #if OPENSSL_VERSION_NUMBER >= 0x00908000L 243 void *q_PEM_ASN1_read_bio(d2i_of_void *
a,
const char *b, BIO *
c,
void **
d, pem_password_cb *e,
250 int e, pem_password_cb *f,
void *g);
252 int e, pem_password_cb *f,
void *g);
263 #if OPENSSL_VERSION_NUMBER >= 0x10000000L 274 #if OPENSSL_VERSION_NUMBER >= 0x00908000L 282 #if OPENSSL_VERSION_NUMBER >= 0x10000000L 297 #if OPENSSL_VERSION_NUMBER >= 0x00908000L 299 STACK_OF(SSL_CIPHER) *q_SSL_get_ciphers(
const SSL *a);
301 STACK_OF(SSL_CIPHER) *q_SSL_get_ciphers(SSL *a);
303 #if OPENSSL_VERSION_NUMBER >= 0x10000000L 311 #if OPENSSL_VERSION_NUMBER >= 0x00908000L 320 #if OPENSSL_VERSION_NUMBER >= 0x0090806fL && !defined(OPENSSL_NO_TLSEXT) 321 long q_SSL_ctrl(SSL *ssl,
int cmd,
long larg,
void *
parg);
328 #if OPENSSL_VERSION_NUMBER >= 0x10000000L 350 void *q_ASN1_dup(i2d_of_void *i2d, d2i_of_void *d2i,
char *x);
351 #define q_X509_dup(x509) (X509 *)q_ASN1_dup((i2d_of_void *)q_i2d_X509, \ 352 (d2i_of_void *)q_d2i_X509,(char *)x509) 380 STACK_OF(
X509) *q_X509_STORE_CTX_get_chain(X509_STORE_CTX *ctx);
382 #define q_BIO_get_mem_data(b, pp) (int)q_BIO_ctrl(b,BIO_CTRL_INFO,0,(char *)pp) 383 #define q_BIO_pending(b) (int)q_BIO_ctrl(b,BIO_CTRL_PENDING,0,NULL) 385 int q_i2d_DSAPrivateKey(
const DSA *a,
unsigned char **pp);
386 int q_i2d_RSAPrivateKey(
const RSA *a,
unsigned char **pp);
387 RSA *q_d2i_RSAPrivateKey(RSA **a,
unsigned char **pp,
long length);
388 DSA *q_d2i_DSAPrivateKey(DSA **a,
unsigned char **pp,
long length);
389 #define q_PEM_read_bio_RSAPrivateKey(bp, x, cb, u) \ 390 (RSA *)q_PEM_ASN1_read_bio( \ 391 (void *(*)(void**, const unsigned char**, long int))q_d2i_RSAPrivateKey, PEM_STRING_RSA, bp, (void **)x, cb, u) 392 #define q_PEM_read_bio_DSAPrivateKey(bp, x, cb, u) \ 393 (DSA *)q_PEM_ASN1_read_bio( \ 394 (void *(*)(void**, const unsigned char**, long int))q_d2i_DSAPrivateKey, PEM_STRING_DSA, bp, (void **)x, cb, u) 395 #define q_PEM_write_bio_RSAPrivateKey(bp,x,enc,kstr,klen,cb,u) \ 396 PEM_ASN1_write_bio((int (*)(void*, unsigned char**))q_i2d_RSAPrivateKey,PEM_STRING_RSA,\ 397 bp,(char *)x,enc,kstr,klen,cb,u) 398 #define q_PEM_write_bio_DSAPrivateKey(bp,x,enc,kstr,klen,cb,u) \ 399 PEM_ASN1_write_bio((int (*)(void*, unsigned char**))q_i2d_DSAPrivateKey,PEM_STRING_DSA,\ 400 bp,(char *)x,enc,kstr,klen,cb,u) 402 #define q_SSL_CTX_set_options(ctx,op) q_SSL_CTX_ctrl((ctx),SSL_CTRL_OPTIONS,(op),NULL) 403 #define q_SKM_sk_num(type, st) ((int (*)(const STACK_OF(type) *))q_sk_num)(st) 404 #define q_SKM_sk_value(type, st,i) ((type * (*)(const STACK_OF(type) *, int))q_sk_value)(st, i) 405 #define q_sk_GENERAL_NAME_num(st) q_SKM_sk_num(GENERAL_NAME, (st)) 406 #define q_sk_GENERAL_NAME_value(st, i) q_SKM_sk_value(GENERAL_NAME, (st), (i)) 407 #define q_sk_X509_num(st) q_SKM_sk_num(X509, (st)) 408 #define q_sk_X509_value(st, i) q_SKM_sk_value(X509, (st), (i)) 409 #define q_sk_SSL_CIPHER_num(st) q_SKM_sk_num(SSL_CIPHER, (st)) 410 #define q_sk_SSL_CIPHER_value(st, i) q_SKM_sk_value(SSL_CIPHER, (st), (i)) 411 #define q_SSL_CTX_add_extra_chain_cert(ctx,x509) \ 412 q_SSL_CTX_ctrl(ctx,SSL_CTRL_EXTRA_CHAIN_CERT,0,(char *)x509) 413 #define q_X509_get_notAfter(x) X509_get_notAfter(x) 414 #define q_X509_get_notBefore(x) X509_get_notBefore(x) 415 #define q_EVP_PKEY_assign_RSA(pkey,rsa) q_EVP_PKEY_assign((pkey),EVP_PKEY_RSA,\ 417 #define q_EVP_PKEY_assign_DSA(pkey,dsa) q_EVP_PKEY_assign((pkey),EVP_PKEY_DSA,\ 419 #ifdef OPENSSL_LOAD_CONF 420 #define q_OpenSSL_add_all_algorithms() q_OPENSSL_add_all_algorithms_conf() 422 #define q_OpenSSL_add_all_algorithms() q_OPENSSL_add_all_algorithms_noconf() int q_SSL_CTX_load_verify_locations(SSL_CTX *ctx, const char *CAfile, const char *CApath)
int q_BIO_read(BIO *a, void *b, int c)
int q_SSL_CTX_check_private_key(SSL_CTX *a)
long q_ASN1_INTEGER_get(ASN1_INTEGER *a)
int q_SSL_CTX_use_certificate(SSL_CTX *a, X509 *b)
const char * q_OBJ_nid2sn(int a)
int q_SSL_CTX_use_RSAPrivateKey(SSL_CTX *a, RSA *b)
EVP_PKEY * q_X509_PUBKEY_get(X509_PUBKEY *a)
X509 * q_X509_dup(X509 *a)
int q_SSL_CTX_use_PrivateKey(SSL_CTX *a, EVP_PKEY *b)
QDateTime q_getTimeFromASN1(const ASN1_TIME *aTime)
SSL_METHOD * q_SSLv3_client_method()
BIO_METHOD * q_BIO_s_mem()
SSL_METHOD * q_SSLv3_server_method()
void q_CRYPTO_set_id_callback(unsigned long(*a)())
#define QT_END_NAMESPACE
This macro expands to.
int q_X509_verify_cert(X509_STORE_CTX *ctx)
int q_X509_STORE_CTX_set_purpose(X509_STORE_CTX *ctx, int purpose)
X509_STORE * q_X509_STORE_new()
int q_SSL_CTX_set_cipher_list(SSL_CTX *a, const char *b)
void q_OPENSSL_add_all_algorithms_noconf()
void q_SSL_CTX_free(SSL_CTX *a)
int q_EVP_PKEY_assign(EVP_PKEY *a, int b, char *c)
int q_PEM_write_bio_RSAPrivateKey(BIO *a, RSA *b, const EVP_CIPHER *c, unsigned char *d, int e, pem_password_cb *f, void *g)
SSL_CIPHER * q_SSL_get_current_cipher(SSL *a)
int q_SSL_CTX_use_PrivateKey_file(SSL_CTX *a, const char *b, int c)
int q_SSL_get_error(SSL *a, int b)
long ASN1_INTEGER_get ASN1_INTEGER * a
int q_SSL_write(SSL *a, const void *b, int c)
DSA * q_PEM_read_bio_DSAPrivateKey(BIO *a, DSA **b, pem_password_cb *c, void *d)
int q_EVP_PKEY_set1_RSA(EVP_PKEY *a, RSA *b)
int q_BN_num_bits(const BIGNUM *a)
int q_X509_STORE_CTX_get_error_depth(X509_STORE_CTX *ctx)
RSA * q_PEM_read_bio_RSA_PUBKEY(BIO *a, RSA **b, pem_password_cb *c, void *d)
char * q_ERR_error_string(unsigned long a, char *b)
int q_SSL_CTX_use_certificate_file(SSL_CTX *a, const char *b, int c)
void q_SSL_set_bio(SSL *a, BIO *b, BIO *c)
EVP_PKEY * q_EVP_PKEY_new()
#define QT_BEGIN_NAMESPACE
This macro expands to.
BIO * q_BIO_new(BIO_METHOD *a)
STACK_OF(SSL_CIPHER) *q_SSL_get_ciphers(SSL *a)
int q_X509_get_ext_count(X509 *a)
void q_SSL_set_accept_state(SSL *a)
SSL_METHOD * q_SSLv2_server_method()
int q_SSL_shutdown(SSL *a)
void q_OPENSSL_add_all_algorithms_conf()
void q_CRYPTO_set_locking_callback(void(*a)(int, int, const char *, int))
SSL_METHOD * q_SSLv23_client_method()
SSL_METHOD * q_TLSv1_server_method()
unsigned char * q_ASN1_STRING_data(ASN1_STRING *a)
RSA * q_PEM_read_bio_RSAPrivateKey(BIO *a, RSA **b, pem_password_cb *c, void *d)
long q_SSL_get_verify_result(SSL *a)
void q_X509_STORE_free(X509_STORE *store)
X509_NAME * q_X509_get_issuer_name(X509 *a)
void q_sk_pop_free(STACK *a, void(*b)(void *))
void q_X509_free(X509 *a)
int q_EVP_PKEY_set1_DSA(EVP_PKEY *a, DSA *b)
int q_X509_STORE_CTX_get_error(X509_STORE_CTX *ctx)
int q_PEM_write_bio_DSA_PUBKEY(BIO *a, DSA *b)
long q_BIO_ctrl(BIO *a, int b, long c, void *d)
int q_EVP_PKEY_type(int a)
DSA * q_EVP_PKEY_get1_DSA(EVP_PKEY *a)
int q_PEM_write_bio_RSA_PUBKEY(BIO *a, RSA *b)
SSL_METHOD * q_SSLv2_client_method()
void q_SSL_CTX_set_verify_depth(SSL_CTX *a, int b)
X509 * q_X509_STORE_CTX_get_current_cert(X509_STORE_CTX *ctx)
SSL * q_SSL_new(SSL_CTX *a)
ASN1_OBJECT * q_X509_NAME_ENTRY_get_object(X509_NAME_ENTRY *a)
void * q_X509_get_ext_d2i(X509 *a, int b, int *c, int *d)
int q_OBJ_obj2nid(const ASN1_OBJECT *a)
int q_X509_STORE_CTX_init(X509_STORE_CTX *ctx, X509_STORE *store, X509 *x509, STACK_OF(X509) *chain)
int q_X509_NAME_entry_count(X509_NAME *a)
X509_EXTENSION * q_X509_get_ext(X509 *a, int b)
int q_i2d_X509(X509 *a, unsigned char **b)
The QDateTime class provides date and time functions.
int q_SSL_CTX_set_default_verify_paths(SSL_CTX *a)
char * q_sk_value(STACK *a, int b)
SSL_METHOD * q_TLSv1_client_method()
DSA * q_PEM_read_bio_DSA_PUBKEY(BIO *a, DSA **b, pem_password_cb *c, void *d)
RSA * q_EVP_PKEY_get1_RSA(EVP_PKEY *a)
void q_SSL_CTX_set_verify(SSL_CTX *a, int b, int(*c)(int, X509_STORE_CTX *))
X509_NAME * q_X509_get_subject_name(X509 *a)
void q_SSL_load_error_strings()
ASN1_OBJECT * q_X509_EXTENSION_get_object(X509_EXTENSION *a)
unsigned long q_ERR_get_error()
int q_SSL_read(SSL *a, void *b, int c)
BIO * q_BIO_new_mem_buf(void *a, int b)
void q_SSL_set_connect_state(SSL *a)
void q_RAND_seed(const void *a, int b)
int q_ASN1_STRING_to_UTF8(unsigned char **a, ASN1_STRING *b)
ASN1_STRING * q_X509_NAME_ENTRY_get_data(X509_NAME_ENTRY *a)
int q_SSL_connect(SSL *a)
void q_EVP_PKEY_free(EVP_PKEY *a)
int q_PEM_write_bio_DSAPrivateKey(BIO *a, DSA *b, const EVP_CIPHER *c, unsigned char *d, int e, pem_password_cb *f, void *g)
char * q_SSL_CIPHER_description(SSL_CIPHER *a, char *b, int c)
const EVP_CIPHER * q_EVP_des_ede3_cbc()
void q_X509_STORE_CTX_free(X509_STORE_CTX *storeCtx)
SSL_METHOD * q_SSLv23_server_method()
X509_STORE_CTX * q_X509_STORE_CTX_new()
void q_CRYPTO_free(void *a)
X509_NAME_ENTRY * q_X509_NAME_get_entry(X509_NAME *a, int b)
int q_BIO_write(BIO *a, const void *b, int c)
long q_SSL_CTX_ctrl(SSL_CTX *a, int b, long c, void *d)
int q_ASN1_STRING_length(ASN1_STRING *a)
SSL_CTX * q_SSL_CTX_new(SSL_METHOD *a)
X509 * q_d2i_X509(X509 **a, unsigned char **b, long c)
bool q_resolveOpenSslSymbols()
int q_X509_cmp(X509 *a, X509 *b)
int q_X509_STORE_add_cert(X509_STORE *ctx, X509 *x)
X509 * q_SSL_get_peer_certificate(SSL *a)