diff options
Diffstat (limited to 'src/lib/libssl/ssl.h')
| -rw-r--r-- | src/lib/libssl/ssl.h | 330 |
1 files changed, 271 insertions, 59 deletions
diff --git a/src/lib/libssl/ssl.h b/src/lib/libssl/ssl.h index 99e188086b..6df921f3c1 100644 --- a/src/lib/libssl/ssl.h +++ b/src/lib/libssl/ssl.h | |||
| @@ -109,7 +109,7 @@ | |||
| 109 | * | 109 | * |
| 110 | */ | 110 | */ |
| 111 | /* ==================================================================== | 111 | /* ==================================================================== |
| 112 | * Copyright (c) 1998-2002 The OpenSSL Project. All rights reserved. | 112 | * Copyright (c) 1998-2006 The OpenSSL Project. All rights reserved. |
| 113 | * | 113 | * |
| 114 | * Redistribution and use in source and binary forms, with or without | 114 | * Redistribution and use in source and binary forms, with or without |
| 115 | * modification, are permitted provided that the following conditions | 115 | * modification, are permitted provided that the following conditions |
| @@ -161,6 +161,11 @@ | |||
| 161 | * Hudson (tjh@cryptsoft.com). | 161 | * Hudson (tjh@cryptsoft.com). |
| 162 | * | 162 | * |
| 163 | */ | 163 | */ |
| 164 | /* ==================================================================== | ||
| 165 | * Copyright 2002 Sun Microsystems, Inc. ALL RIGHTS RESERVED. | ||
| 166 | * ECC cipher suite support in OpenSSL originally developed by | ||
| 167 | * SUN MICROSYSTEMS, INC., and contributed to the OpenSSL project. | ||
| 168 | */ | ||
| 164 | 169 | ||
| 165 | #ifndef HEADER_SSL_H | 170 | #ifndef HEADER_SSL_H |
| 166 | #define HEADER_SSL_H | 171 | #define HEADER_SSL_H |
| @@ -173,9 +178,17 @@ | |||
| 173 | #ifndef OPENSSL_NO_BIO | 178 | #ifndef OPENSSL_NO_BIO |
| 174 | #include <openssl/bio.h> | 179 | #include <openssl/bio.h> |
| 175 | #endif | 180 | #endif |
| 181 | #ifndef OPENSSL_NO_DEPRECATED | ||
| 176 | #ifndef OPENSSL_NO_X509 | 182 | #ifndef OPENSSL_NO_X509 |
| 177 | #include <openssl/x509.h> | 183 | #include <openssl/x509.h> |
| 178 | #endif | 184 | #endif |
| 185 | #include <openssl/crypto.h> | ||
| 186 | #include <openssl/lhash.h> | ||
| 187 | #include <openssl/buffer.h> | ||
| 188 | #endif | ||
| 189 | #include <openssl/pem.h> | ||
| 190 | #include <openssl/hmac.h> | ||
| 191 | |||
| 179 | #include <openssl/kssl.h> | 192 | #include <openssl/kssl.h> |
| 180 | #include <openssl/safestack.h> | 193 | #include <openssl/safestack.h> |
| 181 | #include <openssl/symhacks.h> | 194 | #include <openssl/symhacks.h> |
| @@ -239,7 +252,6 @@ extern "C" { | |||
| 239 | #define SSL_TXT_LOW "LOW" | 252 | #define SSL_TXT_LOW "LOW" |
| 240 | #define SSL_TXT_MEDIUM "MEDIUM" | 253 | #define SSL_TXT_MEDIUM "MEDIUM" |
| 241 | #define SSL_TXT_HIGH "HIGH" | 254 | #define SSL_TXT_HIGH "HIGH" |
| 242 | #define SSL_TXT_FIPS "FIPS" | ||
| 243 | #define SSL_TXT_kFZA "kFZA" | 255 | #define SSL_TXT_kFZA "kFZA" |
| 244 | #define SSL_TXT_aFZA "aFZA" | 256 | #define SSL_TXT_aFZA "aFZA" |
| 245 | #define SSL_TXT_eFZA "eFZA" | 257 | #define SSL_TXT_eFZA "eFZA" |
| @@ -270,7 +282,9 @@ extern "C" { | |||
| 270 | #define SSL_TXT_RC4 "RC4" | 282 | #define SSL_TXT_RC4 "RC4" |
| 271 | #define SSL_TXT_RC2 "RC2" | 283 | #define SSL_TXT_RC2 "RC2" |
| 272 | #define SSL_TXT_IDEA "IDEA" | 284 | #define SSL_TXT_IDEA "IDEA" |
| 285 | #define SSL_TXT_SEED "SEED" | ||
| 273 | #define SSL_TXT_AES "AES" | 286 | #define SSL_TXT_AES "AES" |
| 287 | #define SSL_TXT_CAMELLIA "CAMELLIA" | ||
| 274 | #define SSL_TXT_MD5 "MD5" | 288 | #define SSL_TXT_MD5 "MD5" |
| 275 | #define SSL_TXT_SHA1 "SHA1" | 289 | #define SSL_TXT_SHA1 "SHA1" |
| 276 | #define SSL_TXT_SHA "SHA" | 290 | #define SSL_TXT_SHA "SHA" |
| @@ -282,6 +296,7 @@ extern "C" { | |||
| 282 | #define SSL_TXT_SSLV3 "SSLv3" | 296 | #define SSL_TXT_SSLV3 "SSLv3" |
| 283 | #define SSL_TXT_TLSV1 "TLSv1" | 297 | #define SSL_TXT_TLSV1 "TLSv1" |
| 284 | #define SSL_TXT_ALL "ALL" | 298 | #define SSL_TXT_ALL "ALL" |
| 299 | #define SSL_TXT_ECC "ECCdraft" /* ECC ciphersuites are not yet official */ | ||
| 285 | 300 | ||
| 286 | /* | 301 | /* |
| 287 | * COMPLEMENTOF* definitions. These identifiers are used to (de-select) | 302 | * COMPLEMENTOF* definitions. These identifiers are used to (de-select) |
| @@ -303,7 +318,7 @@ extern "C" { | |||
| 303 | /* The following cipher list is used by default. | 318 | /* The following cipher list is used by default. |
| 304 | * It also is substituted when an application-defined cipher list string | 319 | * It also is substituted when an application-defined cipher list string |
| 305 | * starts with 'DEFAULT'. */ | 320 | * starts with 'DEFAULT'. */ |
| 306 | #define SSL_DEFAULT_CIPHER_LIST "ALL:!ADH:+RC4:@STRENGTH" /* low priority for RC4 */ | 321 | #define SSL_DEFAULT_CIPHER_LIST "AES:ALL:!aNULL:!eNULL:+RC4:@STRENGTH" /* low priority for RC4 */ |
| 307 | 322 | ||
| 308 | /* Used in SSL_set_shutdown()/SSL_get_shutdown(); */ | 323 | /* Used in SSL_set_shutdown()/SSL_get_shutdown(); */ |
| 309 | #define SSL_SENT_SHUTDOWN 1 | 324 | #define SSL_SENT_SHUTDOWN 1 |
| @@ -313,11 +328,6 @@ extern "C" { | |||
| 313 | } | 328 | } |
| 314 | #endif | 329 | #endif |
| 315 | 330 | ||
| 316 | #include <openssl/crypto.h> | ||
| 317 | #include <openssl/lhash.h> | ||
| 318 | #include <openssl/buffer.h> | ||
| 319 | #include <openssl/pem.h> | ||
| 320 | |||
| 321 | #ifdef __cplusplus | 331 | #ifdef __cplusplus |
| 322 | extern "C" { | 332 | extern "C" { |
| 323 | #endif | 333 | #endif |
| @@ -369,6 +379,12 @@ typedef struct ssl_method_st | |||
| 369 | int (*ssl_shutdown)(SSL *s); | 379 | int (*ssl_shutdown)(SSL *s); |
| 370 | int (*ssl_renegotiate)(SSL *s); | 380 | int (*ssl_renegotiate)(SSL *s); |
| 371 | int (*ssl_renegotiate_check)(SSL *s); | 381 | int (*ssl_renegotiate_check)(SSL *s); |
| 382 | long (*ssl_get_message)(SSL *s, int st1, int stn, int mt, long | ||
| 383 | max, int *ok); | ||
| 384 | int (*ssl_read_bytes)(SSL *s, int type, unsigned char *buf, int len, | ||
| 385 | int peek); | ||
| 386 | int (*ssl_write_bytes)(SSL *s, int type, const void *buf_, int len); | ||
| 387 | int (*ssl_dispatch_alert)(SSL *s); | ||
| 372 | long (*ssl_ctrl)(SSL *s,int cmd,long larg,void *parg); | 388 | long (*ssl_ctrl)(SSL *s,int cmd,long larg,void *parg); |
| 373 | long (*ssl_ctx_ctrl)(SSL_CTX *ctx,int cmd,long larg,void *parg); | 389 | long (*ssl_ctx_ctrl)(SSL_CTX *ctx,int cmd,long larg,void *parg); |
| 374 | SSL_CIPHER *(*get_cipher_by_char)(const unsigned char *ptr); | 390 | SSL_CIPHER *(*get_cipher_by_char)(const unsigned char *ptr); |
| @@ -379,9 +395,9 @@ typedef struct ssl_method_st | |||
| 379 | struct ssl_method_st *(*get_ssl_method)(int version); | 395 | struct ssl_method_st *(*get_ssl_method)(int version); |
| 380 | long (*get_timeout)(void); | 396 | long (*get_timeout)(void); |
| 381 | struct ssl3_enc_method *ssl3_enc; /* Extra SSLv3/TLS stuff */ | 397 | struct ssl3_enc_method *ssl3_enc; /* Extra SSLv3/TLS stuff */ |
| 382 | int (*ssl_version)(); | 398 | int (*ssl_version)(void); |
| 383 | long (*ssl_callback_ctrl)(SSL *s, int cb_id, void (*fp)()); | 399 | long (*ssl_callback_ctrl)(SSL *s, int cb_id, void (*fp)(void)); |
| 384 | long (*ssl_ctx_callback_ctrl)(SSL_CTX *s, int cb_id, void (*fp)()); | 400 | long (*ssl_ctx_callback_ctrl)(SSL_CTX *s, int cb_id, void (*fp)(void)); |
| 385 | } SSL_METHOD; | 401 | } SSL_METHOD; |
| 386 | 402 | ||
| 387 | /* Lets make this into an ASN.1 type structure as follows | 403 | /* Lets make this into an ASN.1 type structure as follows |
| @@ -459,6 +475,13 @@ typedef struct ssl_session_st | |||
| 459 | /* These are used to make removal of session-ids more | 475 | /* These are used to make removal of session-ids more |
| 460 | * efficient and to implement a maximum cache size. */ | 476 | * efficient and to implement a maximum cache size. */ |
| 461 | struct ssl_session_st *prev,*next; | 477 | struct ssl_session_st *prev,*next; |
| 478 | #ifndef OPENSSL_NO_TLSEXT | ||
| 479 | char *tlsext_hostname; | ||
| 480 | /* RFC4507 info */ | ||
| 481 | unsigned char *tlsext_tick; /* Session ticket */ | ||
| 482 | size_t tlsext_ticklen; /* Session ticket length */ | ||
| 483 | long tlsext_tick_lifetime_hint; /* Session lifetime hint in seconds */ | ||
| 484 | #endif | ||
| 462 | } SSL_SESSION; | 485 | } SSL_SESSION; |
| 463 | 486 | ||
| 464 | 487 | ||
| @@ -483,8 +506,17 @@ typedef struct ssl_session_st | |||
| 483 | * This used to be 0x000FFFFFL before 0.9.7. */ | 506 | * This used to be 0x000FFFFFL before 0.9.7. */ |
| 484 | #define SSL_OP_ALL 0x00000FFFL | 507 | #define SSL_OP_ALL 0x00000FFFL |
| 485 | 508 | ||
| 509 | /* DTLS options */ | ||
| 510 | #define SSL_OP_NO_QUERY_MTU 0x00001000L | ||
| 511 | /* Turn on Cookie Exchange (on relevant for servers) */ | ||
| 512 | #define SSL_OP_COOKIE_EXCHANGE 0x00002000L | ||
| 513 | /* Don't use RFC4507 ticket extension */ | ||
| 514 | #define SSL_OP_NO_TICKET 0x00004000L | ||
| 515 | |||
| 486 | /* As server, disallow session resumption on renegotiation */ | 516 | /* As server, disallow session resumption on renegotiation */ |
| 487 | #define SSL_OP_NO_SESSION_RESUMPTION_ON_RENEGOTIATION 0x00010000L | 517 | #define SSL_OP_NO_SESSION_RESUMPTION_ON_RENEGOTIATION 0x00010000L |
| 518 | /* If set, always create a new key when using tmp_ecdh parameters */ | ||
| 519 | #define SSL_OP_SINGLE_ECDH_USE 0x00080000L | ||
| 488 | /* If set, always create a new key when using tmp_dh parameters */ | 520 | /* If set, always create a new key when using tmp_dh parameters */ |
| 489 | #define SSL_OP_SINGLE_DH_USE 0x00100000L | 521 | #define SSL_OP_SINGLE_DH_USE 0x00100000L |
| 490 | /* Set to always use the tmp_rsa key when doing RSA operations, | 522 | /* Set to always use the tmp_rsa key when doing RSA operations, |
| @@ -546,6 +578,8 @@ typedef struct ssl_session_st | |||
| 546 | SSL_ctrl((ssl),SSL_CTRL_MODE,(op),NULL) | 578 | SSL_ctrl((ssl),SSL_CTRL_MODE,(op),NULL) |
| 547 | #define SSL_get_mode(ssl) \ | 579 | #define SSL_get_mode(ssl) \ |
| 548 | SSL_ctrl((ssl),SSL_CTRL_MODE,0,NULL) | 580 | SSL_ctrl((ssl),SSL_CTRL_MODE,0,NULL) |
| 581 | #define SSL_set_mtu(ssl, mtu) \ | ||
| 582 | SSL_ctrl((ssl),SSL_CTRL_SET_MTU,(mtu),NULL) | ||
| 549 | 583 | ||
| 550 | 584 | ||
| 551 | void SSL_CTX_set_msg_callback(SSL_CTX *ctx, void (*cb)(int write_p, int version, int content_type, const void *buf, size_t len, SSL *ssl, void *arg)); | 585 | void SSL_CTX_set_msg_callback(SSL_CTX *ctx, void (*cb)(int write_p, int version, int content_type, const void *buf, size_t len, SSL *ssl, void *arg)); |
| @@ -582,7 +616,7 @@ typedef int (*GEN_SESSION_CB)(const SSL *ssl, unsigned char *id, | |||
| 582 | typedef struct ssl_comp_st | 616 | typedef struct ssl_comp_st |
| 583 | { | 617 | { |
| 584 | int id; | 618 | int id; |
| 585 | char *name; | 619 | const char *name; |
| 586 | #ifndef OPENSSL_NO_COMP | 620 | #ifndef OPENSSL_NO_COMP |
| 587 | COMP_METHOD *method; | 621 | COMP_METHOD *method; |
| 588 | #else | 622 | #else |
| @@ -670,6 +704,14 @@ struct ssl_ctx_st | |||
| 670 | /* get client cert callback */ | 704 | /* get client cert callback */ |
| 671 | int (*client_cert_cb)(SSL *ssl, X509 **x509, EVP_PKEY **pkey); | 705 | int (*client_cert_cb)(SSL *ssl, X509 **x509, EVP_PKEY **pkey); |
| 672 | 706 | ||
| 707 | /* cookie generate callback */ | ||
| 708 | int (*app_gen_cookie_cb)(SSL *ssl, unsigned char *cookie, | ||
| 709 | unsigned int *cookie_len); | ||
| 710 | |||
| 711 | /* verify cookie callback */ | ||
| 712 | int (*app_verify_cookie_cb)(SSL *ssl, unsigned char *cookie, | ||
| 713 | unsigned int cookie_len); | ||
| 714 | |||
| 673 | CRYPTO_EX_DATA ex_data; | 715 | CRYPTO_EX_DATA ex_data; |
| 674 | 716 | ||
| 675 | const EVP_MD *rsa_md5;/* For SSLv2 - name is 'ssl2-md5' */ | 717 | const EVP_MD *rsa_md5;/* For SSLv2 - name is 'ssl2-md5' */ |
| @@ -702,7 +744,6 @@ struct ssl_ctx_st | |||
| 702 | void *msg_callback_arg; | 744 | void *msg_callback_arg; |
| 703 | 745 | ||
| 704 | int verify_mode; | 746 | int verify_mode; |
| 705 | int verify_depth; | ||
| 706 | unsigned int sid_ctx_length; | 747 | unsigned int sid_ctx_length; |
| 707 | unsigned char sid_ctx[SSL_MAX_SID_CTX_LENGTH]; | 748 | unsigned char sid_ctx[SSL_MAX_SID_CTX_LENGTH]; |
| 708 | int (*default_verify_callback)(int ok,X509_STORE_CTX *ctx); /* called 'verify_callback' in the SSL */ | 749 | int (*default_verify_callback)(int ok,X509_STORE_CTX *ctx); /* called 'verify_callback' in the SSL */ |
| @@ -710,10 +751,35 @@ struct ssl_ctx_st | |||
| 710 | /* Default generate session ID callback. */ | 751 | /* Default generate session ID callback. */ |
| 711 | GEN_SESSION_CB generate_session_id; | 752 | GEN_SESSION_CB generate_session_id; |
| 712 | 753 | ||
| 754 | X509_VERIFY_PARAM *param; | ||
| 755 | |||
| 756 | #if 0 | ||
| 713 | int purpose; /* Purpose setting */ | 757 | int purpose; /* Purpose setting */ |
| 714 | int trust; /* Trust setting */ | 758 | int trust; /* Trust setting */ |
| 759 | #endif | ||
| 715 | 760 | ||
| 716 | int quiet_shutdown; | 761 | int quiet_shutdown; |
| 762 | |||
| 763 | #ifndef OPENSSL_NO_TLSEXT | ||
| 764 | /* TLS extensions servername callback */ | ||
| 765 | int (*tlsext_servername_callback)(SSL*, int *, void *); | ||
| 766 | void *tlsext_servername_arg; | ||
| 767 | /* RFC 4507 session ticket keys */ | ||
| 768 | unsigned char tlsext_tick_key_name[16]; | ||
| 769 | unsigned char tlsext_tick_hmac_key[16]; | ||
| 770 | unsigned char tlsext_tick_aes_key[16]; | ||
| 771 | /* Callback to support customisation of ticket key setting */ | ||
| 772 | int (*tlsext_ticket_key_cb)(SSL *ssl, | ||
| 773 | unsigned char *name, unsigned char *iv, | ||
| 774 | EVP_CIPHER_CTX *ectx, | ||
| 775 | HMAC_CTX *hctx, int enc); | ||
| 776 | |||
| 777 | /* certificate status request info */ | ||
| 778 | /* Callback for status request */ | ||
| 779 | int (*tlsext_status_cb)(SSL *ssl, void *arg); | ||
| 780 | void *tlsext_status_arg; | ||
| 781 | #endif | ||
| 782 | |||
| 717 | }; | 783 | }; |
| 718 | 784 | ||
| 719 | #define SSL_SESS_CACHE_OFF 0x0000 | 785 | #define SSL_SESS_CACHE_OFF 0x0000 |
| @@ -753,16 +819,18 @@ struct ssl_ctx_st | |||
| 753 | #define SSL_CTX_sess_cache_full(ctx) \ | 819 | #define SSL_CTX_sess_cache_full(ctx) \ |
| 754 | SSL_CTX_ctrl(ctx,SSL_CTRL_SESS_CACHE_FULL,0,NULL) | 820 | SSL_CTX_ctrl(ctx,SSL_CTRL_SESS_CACHE_FULL,0,NULL) |
| 755 | 821 | ||
| 756 | #define SSL_CTX_sess_set_new_cb(ctx,cb) ((ctx)->new_session_cb=(cb)) | 822 | void SSL_CTX_sess_set_new_cb(SSL_CTX *ctx, int (*new_session_cb)(struct ssl_st *ssl,SSL_SESSION *sess)); |
| 757 | #define SSL_CTX_sess_get_new_cb(ctx) ((ctx)->new_session_cb) | 823 | int (*SSL_CTX_sess_get_new_cb(SSL_CTX *ctx))(struct ssl_st *ssl, SSL_SESSION *sess); |
| 758 | #define SSL_CTX_sess_set_remove_cb(ctx,cb) ((ctx)->remove_session_cb=(cb)) | 824 | void SSL_CTX_sess_set_remove_cb(SSL_CTX *ctx, void (*remove_session_cb)(struct ssl_ctx_st *ctx,SSL_SESSION *sess)); |
| 759 | #define SSL_CTX_sess_get_remove_cb(ctx) ((ctx)->remove_session_cb) | 825 | void (*SSL_CTX_sess_get_remove_cb(SSL_CTX *ctx))(struct ssl_ctx_st *ctx, SSL_SESSION *sess); |
| 760 | #define SSL_CTX_sess_set_get_cb(ctx,cb) ((ctx)->get_session_cb=(cb)) | 826 | void SSL_CTX_sess_set_get_cb(SSL_CTX *ctx, SSL_SESSION *(*get_session_cb)(struct ssl_st *ssl, unsigned char *data,int len,int *copy)); |
| 761 | #define SSL_CTX_sess_get_get_cb(ctx) ((ctx)->get_session_cb) | 827 | SSL_SESSION *(*SSL_CTX_sess_get_get_cb(SSL_CTX *ctx))(struct ssl_st *ssl, unsigned char *Data, int len, int *copy); |
| 762 | #define SSL_CTX_set_info_callback(ctx,cb) ((ctx)->info_callback=(cb)) | 828 | void SSL_CTX_set_info_callback(SSL_CTX *ctx, void (*cb)(const SSL *ssl,int type,int val)); |
| 763 | #define SSL_CTX_get_info_callback(ctx) ((ctx)->info_callback) | 829 | void (*SSL_CTX_get_info_callback(SSL_CTX *ctx))(const SSL *ssl,int type,int val); |
| 764 | #define SSL_CTX_set_client_cert_cb(ctx,cb) ((ctx)->client_cert_cb=(cb)) | 830 | void SSL_CTX_set_client_cert_cb(SSL_CTX *ctx, int (*client_cert_cb)(SSL *ssl, X509 **x509, EVP_PKEY **pkey)); |
| 765 | #define SSL_CTX_get_client_cert_cb(ctx) ((ctx)->client_cert_cb) | 831 | int (*SSL_CTX_get_client_cert_cb(SSL_CTX *ctx))(SSL *ssl, X509 **x509, EVP_PKEY **pkey); |
| 832 | void SSL_CTX_set_cookie_generate_cb(SSL_CTX *ctx, int (*app_gen_cookie_cb)(SSL *ssl, unsigned char *cookie, unsigned int *cookie_len)); | ||
| 833 | void SSL_CTX_set_cookie_verify_cb(SSL_CTX *ctx, int (*app_verify_cookie_cb)(SSL *ssl, unsigned char *cookie, unsigned int cookie_len)); | ||
| 766 | 834 | ||
| 767 | #define SSL_NOTHING 1 | 835 | #define SSL_NOTHING 1 |
| 768 | #define SSL_WRITING 2 | 836 | #define SSL_WRITING 2 |
| @@ -778,7 +846,7 @@ struct ssl_ctx_st | |||
| 778 | struct ssl_st | 846 | struct ssl_st |
| 779 | { | 847 | { |
| 780 | /* protocol version | 848 | /* protocol version |
| 781 | * (one of SSL2_VERSION, SSL3_VERSION, TLS1_VERSION) | 849 | * (one of SSL2_VERSION, SSL3_VERSION, TLS1_VERSION, DTLS1_VERSION) |
| 782 | */ | 850 | */ |
| 783 | int version; | 851 | int version; |
| 784 | int type; /* SSL_ST_CONNECT or SSL_ST_ACCEPT */ | 852 | int type; /* SSL_ST_CONNECT or SSL_ST_ACCEPT */ |
| @@ -807,7 +875,7 @@ struct ssl_st | |||
| 807 | 875 | ||
| 808 | /* true when we are actually in SSL_accept() or SSL_connect() */ | 876 | /* true when we are actually in SSL_accept() or SSL_connect() */ |
| 809 | int in_handshake; | 877 | int in_handshake; |
| 810 | int (*handshake_func)(); | 878 | int (*handshake_func)(SSL *); |
| 811 | 879 | ||
| 812 | /* Imagine that here's a boolean member "init" that is | 880 | /* Imagine that here's a boolean member "init" that is |
| 813 | * switched as soon as SSL_set_{accept/connect}_state | 881 | * switched as soon as SSL_set_{accept/connect}_state |
| @@ -842,6 +910,7 @@ struct ssl_st | |||
| 842 | 910 | ||
| 843 | struct ssl2_state_st *s2; /* SSLv2 variables */ | 911 | struct ssl2_state_st *s2; /* SSLv2 variables */ |
| 844 | struct ssl3_state_st *s3; /* SSLv3 variables */ | 912 | struct ssl3_state_st *s3; /* SSLv3 variables */ |
| 913 | struct dtls1_state_st *d1; /* DTLSv1 variables */ | ||
| 845 | 914 | ||
| 846 | int read_ahead; /* Read as many input bytes as possible | 915 | int read_ahead; /* Read as many input bytes as possible |
| 847 | * (for non-blocking reads) */ | 916 | * (for non-blocking reads) */ |
| @@ -852,8 +921,12 @@ struct ssl_st | |||
| 852 | 921 | ||
| 853 | int hit; /* reusing a previous session */ | 922 | int hit; /* reusing a previous session */ |
| 854 | 923 | ||
| 924 | X509_VERIFY_PARAM *param; | ||
| 925 | |||
| 926 | #if 0 | ||
| 855 | int purpose; /* Purpose setting */ | 927 | int purpose; /* Purpose setting */ |
| 856 | int trust; /* Trust setting */ | 928 | int trust; /* Trust setting */ |
| 929 | #endif | ||
| 857 | 930 | ||
| 858 | /* crypto */ | 931 | /* crypto */ |
| 859 | STACK_OF(SSL_CIPHER) *cipher_list; | 932 | STACK_OF(SSL_CIPHER) *cipher_list; |
| @@ -898,7 +971,6 @@ struct ssl_st | |||
| 898 | /* Used in SSL2 and SSL3 */ | 971 | /* Used in SSL2 and SSL3 */ |
| 899 | int verify_mode; /* 0 don't care about verify failure. | 972 | int verify_mode; /* 0 don't care about verify failure. |
| 900 | * 1 fail if verify fails */ | 973 | * 1 fail if verify fails */ |
| 901 | int verify_depth; | ||
| 902 | int (*verify_callback)(int ok,X509_STORE_CTX *ctx); /* fail if callback returns 0 */ | 974 | int (*verify_callback)(int ok,X509_STORE_CTX *ctx); /* fail if callback returns 0 */ |
| 903 | 975 | ||
| 904 | void (*info_callback)(const SSL *ssl,int type,int val); /* optional informational callback */ | 976 | void (*info_callback)(const SSL *ssl,int type,int val); /* optional informational callback */ |
| @@ -929,6 +1001,37 @@ struct ssl_st | |||
| 929 | int first_packet; | 1001 | int first_packet; |
| 930 | int client_version; /* what was passed, used for | 1002 | int client_version; /* what was passed, used for |
| 931 | * SSLv3/TLS rollback check */ | 1003 | * SSLv3/TLS rollback check */ |
| 1004 | #ifndef OPENSSL_NO_TLSEXT | ||
| 1005 | /* TLS extension debug callback */ | ||
| 1006 | void (*tlsext_debug_cb)(SSL *s, int client_server, int type, | ||
| 1007 | unsigned char *data, int len, | ||
| 1008 | void *arg); | ||
| 1009 | void *tlsext_debug_arg; | ||
| 1010 | char *tlsext_hostname; | ||
| 1011 | int servername_done; /* no further mod of servername | ||
| 1012 | 0 : call the servername extension callback. | ||
| 1013 | 1 : prepare 2, allow last ack just after in server callback. | ||
| 1014 | 2 : don't call servername callback, no ack in server hello | ||
| 1015 | */ | ||
| 1016 | /* certificate status request info */ | ||
| 1017 | /* Status type or -1 if no status type */ | ||
| 1018 | int tlsext_status_type; | ||
| 1019 | /* Expect OCSP CertificateStatus message */ | ||
| 1020 | int tlsext_status_expected; | ||
| 1021 | /* OCSP status request only */ | ||
| 1022 | STACK_OF(OCSP_RESPID) *tlsext_ocsp_ids; | ||
| 1023 | X509_EXTENSIONS *tlsext_ocsp_exts; | ||
| 1024 | /* OCSP response received or to be sent */ | ||
| 1025 | unsigned char *tlsext_ocsp_resp; | ||
| 1026 | int tlsext_ocsp_resplen; | ||
| 1027 | |||
| 1028 | /* RFC4507 session ticket expected to be received or sent */ | ||
| 1029 | int tlsext_ticket_expected; | ||
| 1030 | SSL_CTX * initial_ctx; /* initial ctx, used to store sessions */ | ||
| 1031 | #define session_ctx initial_ctx | ||
| 1032 | #else | ||
| 1033 | #define session_ctx ctx | ||
| 1034 | #endif | ||
| 932 | }; | 1035 | }; |
| 933 | 1036 | ||
| 934 | #ifdef __cplusplus | 1037 | #ifdef __cplusplus |
| @@ -938,6 +1041,7 @@ struct ssl_st | |||
| 938 | #include <openssl/ssl2.h> | 1041 | #include <openssl/ssl2.h> |
| 939 | #include <openssl/ssl3.h> | 1042 | #include <openssl/ssl3.h> |
| 940 | #include <openssl/tls1.h> /* This is mostly sslv3 with a few tweaks */ | 1043 | #include <openssl/tls1.h> /* This is mostly sslv3 with a few tweaks */ |
| 1044 | #include <openssl/dtls1.h> /* Datagram TLS */ | ||
| 941 | #include <openssl/ssl23.h> | 1045 | #include <openssl/ssl23.h> |
| 942 | 1046 | ||
| 943 | #ifdef __cplusplus | 1047 | #ifdef __cplusplus |
| @@ -1035,21 +1139,16 @@ size_t SSL_get_peer_finished(const SSL *s, void *buf, size_t count); | |||
| 1035 | #define SSL_set_timeout(a,b) SSL_SESSION_set_timeout((a),(b)) | 1139 | #define SSL_set_timeout(a,b) SSL_SESSION_set_timeout((a),(b)) |
| 1036 | 1140 | ||
| 1037 | #if 1 /*SSLEAY_MACROS*/ | 1141 | #if 1 /*SSLEAY_MACROS*/ |
| 1038 | #define d2i_SSL_SESSION_bio(bp,s_id) (SSL_SESSION *)ASN1_d2i_bio( \ | 1142 | #define d2i_SSL_SESSION_bio(bp,s_id) ASN1_d2i_bio_of(SSL_SESSION,SSL_SESSION_new,d2i_SSL_SESSION,bp,s_id) |
| 1039 | (char *(*)())SSL_SESSION_new,(char *(*)())d2i_SSL_SESSION, \ | 1143 | #define i2d_SSL_SESSION_bio(bp,s_id) ASN1_i2d_bio_of(SSL_SESSION,i2d_SSL_SESSION,bp,s_id) |
| 1040 | (bp),(unsigned char **)(s_id)) | ||
| 1041 | #define i2d_SSL_SESSION_bio(bp,s_id) ASN1_i2d_bio(i2d_SSL_SESSION, \ | ||
| 1042 | bp,(unsigned char *)s_id) | ||
| 1043 | #define PEM_read_SSL_SESSION(fp,x,cb,u) (SSL_SESSION *)PEM_ASN1_read( \ | 1144 | #define PEM_read_SSL_SESSION(fp,x,cb,u) (SSL_SESSION *)PEM_ASN1_read( \ |
| 1044 | (char *(*)())d2i_SSL_SESSION,PEM_STRING_SSL_SESSION,fp,(char **)x,cb,u) | 1145 | (char *(*)())d2i_SSL_SESSION,PEM_STRING_SSL_SESSION,fp,(char **)x,cb,u) |
| 1045 | #define PEM_read_bio_SSL_SESSION(bp,x,cb,u) (SSL_SESSION *)PEM_ASN1_read_bio( \ | 1146 | #define PEM_read_bio_SSL_SESSION(bp,x,cb,u) PEM_ASN1_read_bio_of(SSL_SESSION,d2i_SSL_SESSION,PEM_STRING_SSL_SESSION,bp,x,cb,u) |
| 1046 | (char *(*)())d2i_SSL_SESSION,PEM_STRING_SSL_SESSION,bp,(char **)x,cb,u) | ||
| 1047 | #define PEM_write_SSL_SESSION(fp,x) \ | 1147 | #define PEM_write_SSL_SESSION(fp,x) \ |
| 1048 | PEM_ASN1_write((int (*)())i2d_SSL_SESSION, \ | 1148 | PEM_ASN1_write((int (*)())i2d_SSL_SESSION, \ |
| 1049 | PEM_STRING_SSL_SESSION,fp, (char *)x, NULL,NULL,0,NULL,NULL) | 1149 | PEM_STRING_SSL_SESSION,fp, (char *)x, NULL,NULL,0,NULL,NULL) |
| 1050 | #define PEM_write_bio_SSL_SESSION(bp,x) \ | 1150 | #define PEM_write_bio_SSL_SESSION(bp,x) \ |
| 1051 | PEM_ASN1_write_bio((int (*)())i2d_SSL_SESSION, \ | 1151 | PEM_ASN1_write_bio_of(SSL_SESSION,i2d_SSL_SESSION,PEM_STRING_SSL_SESSION,bp,x,NULL,NULL,0,NULL,NULL) |
| 1052 | PEM_STRING_SSL_SESSION,bp, (char *)x, NULL,NULL,0,NULL,NULL) | ||
| 1053 | #endif | 1152 | #endif |
| 1054 | 1153 | ||
| 1055 | #define SSL_AD_REASON_OFFSET 1000 | 1154 | #define SSL_AD_REASON_OFFSET 1000 |
| @@ -1078,6 +1177,10 @@ size_t SSL_get_peer_finished(const SSL *s, void *buf, size_t count); | |||
| 1078 | #define SSL_AD_INTERNAL_ERROR TLS1_AD_INTERNAL_ERROR /* fatal */ | 1177 | #define SSL_AD_INTERNAL_ERROR TLS1_AD_INTERNAL_ERROR /* fatal */ |
| 1079 | #define SSL_AD_USER_CANCELLED TLS1_AD_USER_CANCELLED | 1178 | #define SSL_AD_USER_CANCELLED TLS1_AD_USER_CANCELLED |
| 1080 | #define SSL_AD_NO_RENEGOTIATION TLS1_AD_NO_RENEGOTIATION | 1179 | #define SSL_AD_NO_RENEGOTIATION TLS1_AD_NO_RENEGOTIATION |
| 1180 | #define SSL_AD_UNSUPPORTED_EXTENSION TLS1_AD_UNSUPPORTED_EXTENSION | ||
| 1181 | #define SSL_AD_CERTIFICATE_UNOBTAINABLE TLS1_AD_CERTIFICATE_UNOBTAINABLE | ||
| 1182 | #define SSL_AD_UNRECOGNIZED_NAME TLS1_AD_UNRECOGNIZED_NAME | ||
| 1183 | #define SSL_AD_BAD_CERTIFICATE_STATUS_RESPONSE TLS1_AD_BAD_CERTIFICATE_STATUS_RESPONSE | ||
| 1081 | 1184 | ||
| 1082 | #define SSL_ERROR_NONE 0 | 1185 | #define SSL_ERROR_NONE 0 |
| 1083 | #define SSL_ERROR_SSL 1 | 1186 | #define SSL_ERROR_SSL 1 |
| @@ -1092,20 +1195,24 @@ size_t SSL_get_peer_finished(const SSL *s, void *buf, size_t count); | |||
| 1092 | #define SSL_CTRL_NEED_TMP_RSA 1 | 1195 | #define SSL_CTRL_NEED_TMP_RSA 1 |
| 1093 | #define SSL_CTRL_SET_TMP_RSA 2 | 1196 | #define SSL_CTRL_SET_TMP_RSA 2 |
| 1094 | #define SSL_CTRL_SET_TMP_DH 3 | 1197 | #define SSL_CTRL_SET_TMP_DH 3 |
| 1095 | #define SSL_CTRL_SET_TMP_RSA_CB 4 | 1198 | #define SSL_CTRL_SET_TMP_ECDH 4 |
| 1096 | #define SSL_CTRL_SET_TMP_DH_CB 5 | 1199 | #define SSL_CTRL_SET_TMP_RSA_CB 5 |
| 1097 | 1200 | #define SSL_CTRL_SET_TMP_DH_CB 6 | |
| 1098 | #define SSL_CTRL_GET_SESSION_REUSED 6 | 1201 | #define SSL_CTRL_SET_TMP_ECDH_CB 7 |
| 1099 | #define SSL_CTRL_GET_CLIENT_CERT_REQUEST 7 | 1202 | |
| 1100 | #define SSL_CTRL_GET_NUM_RENEGOTIATIONS 8 | 1203 | #define SSL_CTRL_GET_SESSION_REUSED 8 |
| 1101 | #define SSL_CTRL_CLEAR_NUM_RENEGOTIATIONS 9 | 1204 | #define SSL_CTRL_GET_CLIENT_CERT_REQUEST 9 |
| 1102 | #define SSL_CTRL_GET_TOTAL_RENEGOTIATIONS 10 | 1205 | #define SSL_CTRL_GET_NUM_RENEGOTIATIONS 10 |
| 1103 | #define SSL_CTRL_GET_FLAGS 11 | 1206 | #define SSL_CTRL_CLEAR_NUM_RENEGOTIATIONS 11 |
| 1104 | #define SSL_CTRL_EXTRA_CHAIN_CERT 12 | 1207 | #define SSL_CTRL_GET_TOTAL_RENEGOTIATIONS 12 |
| 1105 | 1208 | #define SSL_CTRL_GET_FLAGS 13 | |
| 1106 | #define SSL_CTRL_SET_MSG_CALLBACK 13 | 1209 | #define SSL_CTRL_EXTRA_CHAIN_CERT 14 |
| 1107 | #define SSL_CTRL_SET_MSG_CALLBACK_ARG 14 | 1210 | |
| 1108 | 1211 | #define SSL_CTRL_SET_MSG_CALLBACK 15 | |
| 1212 | #define SSL_CTRL_SET_MSG_CALLBACK_ARG 16 | ||
| 1213 | |||
| 1214 | /* only applies to datagram connections */ | ||
| 1215 | #define SSL_CTRL_SET_MTU 17 | ||
| 1109 | /* Stats */ | 1216 | /* Stats */ |
| 1110 | #define SSL_CTRL_SESS_NUMBER 20 | 1217 | #define SSL_CTRL_SESS_NUMBER 20 |
| 1111 | #define SSL_CTRL_SESS_CONNECT 21 | 1218 | #define SSL_CTRL_SESS_CONNECT 21 |
| @@ -1132,6 +1239,29 @@ size_t SSL_get_peer_finished(const SSL *s, void *buf, size_t count); | |||
| 1132 | #define SSL_CTRL_GET_MAX_CERT_LIST 50 | 1239 | #define SSL_CTRL_GET_MAX_CERT_LIST 50 |
| 1133 | #define SSL_CTRL_SET_MAX_CERT_LIST 51 | 1240 | #define SSL_CTRL_SET_MAX_CERT_LIST 51 |
| 1134 | 1241 | ||
| 1242 | /* see tls1.h for macros based on these */ | ||
| 1243 | #ifndef OPENSSL_NO_TLSEXT | ||
| 1244 | #define SSL_CTRL_SET_TLSEXT_SERVERNAME_CB 53 | ||
| 1245 | #define SSL_CTRL_SET_TLSEXT_SERVERNAME_ARG 54 | ||
| 1246 | #define SSL_CTRL_SET_TLSEXT_HOSTNAME 55 | ||
| 1247 | #define SSL_CTRL_SET_TLSEXT_DEBUG_CB 56 | ||
| 1248 | #define SSL_CTRL_SET_TLSEXT_DEBUG_ARG 57 | ||
| 1249 | #define SSL_CTRL_GET_TLSEXT_TICKET_KEYS 58 | ||
| 1250 | #define SSL_CTRL_SET_TLSEXT_TICKET_KEYS 59 | ||
| 1251 | |||
| 1252 | #define SSL_CTRL_SET_TLSEXT_STATUS_REQ_CB 63 | ||
| 1253 | #define SSL_CTRL_SET_TLSEXT_STATUS_REQ_CB_ARG 64 | ||
| 1254 | #define SSL_CTRL_SET_TLSEXT_STATUS_REQ_TYPE 65 | ||
| 1255 | #define SSL_CTRL_GET_TLSEXT_STATUS_REQ_EXTS 66 | ||
| 1256 | #define SSL_CTRL_SET_TLSEXT_STATUS_REQ_EXTS 67 | ||
| 1257 | #define SSL_CTRL_GET_TLSEXT_STATUS_REQ_IDS 68 | ||
| 1258 | #define SSL_CTRL_SET_TLSEXT_STATUS_REQ_IDS 69 | ||
| 1259 | #define SSL_CTRL_GET_TLSEXT_STATUS_REQ_OCSP_RESP 70 | ||
| 1260 | #define SSL_CTRL_SET_TLSEXT_STATUS_REQ_OCSP_RESP 71 | ||
| 1261 | |||
| 1262 | #define SSL_CTRL_SET_TLSEXT_TICKET_KEY_CB 72 | ||
| 1263 | #endif | ||
| 1264 | |||
| 1135 | #define SSL_session_reused(ssl) \ | 1265 | #define SSL_session_reused(ssl) \ |
| 1136 | SSL_ctrl((ssl),SSL_CTRL_GET_SESSION_REUSED,0,NULL) | 1266 | SSL_ctrl((ssl),SSL_CTRL_GET_SESSION_REUSED,0,NULL) |
| 1137 | #define SSL_num_renegotiations(ssl) \ | 1267 | #define SSL_num_renegotiations(ssl) \ |
| @@ -1147,6 +1277,8 @@ size_t SSL_get_peer_finished(const SSL *s, void *buf, size_t count); | |||
| 1147 | SSL_CTX_ctrl(ctx,SSL_CTRL_SET_TMP_RSA,0,(char *)rsa) | 1277 | SSL_CTX_ctrl(ctx,SSL_CTRL_SET_TMP_RSA,0,(char *)rsa) |
| 1148 | #define SSL_CTX_set_tmp_dh(ctx,dh) \ | 1278 | #define SSL_CTX_set_tmp_dh(ctx,dh) \ |
| 1149 | SSL_CTX_ctrl(ctx,SSL_CTRL_SET_TMP_DH,0,(char *)dh) | 1279 | SSL_CTX_ctrl(ctx,SSL_CTRL_SET_TMP_DH,0,(char *)dh) |
| 1280 | #define SSL_CTX_set_tmp_ecdh(ctx,ecdh) \ | ||
| 1281 | SSL_CTX_ctrl(ctx,SSL_CTRL_SET_TMP_ECDH,0,(char *)ecdh) | ||
| 1150 | 1282 | ||
| 1151 | #define SSL_need_tmp_RSA(ssl) \ | 1283 | #define SSL_need_tmp_RSA(ssl) \ |
| 1152 | SSL_ctrl(ssl,SSL_CTRL_NEED_TMP_RSA,0,NULL) | 1284 | SSL_ctrl(ssl,SSL_CTRL_NEED_TMP_RSA,0,NULL) |
| @@ -1154,6 +1286,8 @@ size_t SSL_get_peer_finished(const SSL *s, void *buf, size_t count); | |||
| 1154 | SSL_ctrl(ssl,SSL_CTRL_SET_TMP_RSA,0,(char *)rsa) | 1286 | SSL_ctrl(ssl,SSL_CTRL_SET_TMP_RSA,0,(char *)rsa) |
| 1155 | #define SSL_set_tmp_dh(ssl,dh) \ | 1287 | #define SSL_set_tmp_dh(ssl,dh) \ |
| 1156 | SSL_ctrl(ssl,SSL_CTRL_SET_TMP_DH,0,(char *)dh) | 1288 | SSL_ctrl(ssl,SSL_CTRL_SET_TMP_DH,0,(char *)dh) |
| 1289 | #define SSL_set_tmp_ecdh(ssl,ecdh) \ | ||
| 1290 | SSL_ctrl(ssl,SSL_CTRL_SET_TMP_ECDH,0,(char *)ecdh) | ||
| 1157 | 1291 | ||
| 1158 | #define SSL_CTX_add_extra_chain_cert(ctx,x509) \ | 1292 | #define SSL_CTX_add_extra_chain_cert(ctx,x509) \ |
| 1159 | SSL_CTX_ctrl(ctx,SSL_CTRL_EXTRA_CHAIN_CERT,0,(char *)x509) | 1293 | SSL_CTX_ctrl(ctx,SSL_CTRL_EXTRA_CHAIN_CERT,0,(char *)x509) |
| @@ -1215,9 +1349,9 @@ int SSL_use_RSAPrivateKey(SSL *ssl, RSA *rsa); | |||
| 1215 | #endif | 1349 | #endif |
| 1216 | int SSL_use_RSAPrivateKey_ASN1(SSL *ssl, unsigned char *d, long len); | 1350 | int SSL_use_RSAPrivateKey_ASN1(SSL *ssl, unsigned char *d, long len); |
| 1217 | int SSL_use_PrivateKey(SSL *ssl, EVP_PKEY *pkey); | 1351 | int SSL_use_PrivateKey(SSL *ssl, EVP_PKEY *pkey); |
| 1218 | int SSL_use_PrivateKey_ASN1(int pk,SSL *ssl, unsigned char *d, long len); | 1352 | int SSL_use_PrivateKey_ASN1(int pk,SSL *ssl, const unsigned char *d, long len); |
| 1219 | int SSL_use_certificate(SSL *ssl, X509 *x); | 1353 | int SSL_use_certificate(SSL *ssl, X509 *x); |
| 1220 | int SSL_use_certificate_ASN1(SSL *ssl, unsigned char *d, int len); | 1354 | int SSL_use_certificate_ASN1(SSL *ssl, const unsigned char *d, int len); |
| 1221 | 1355 | ||
| 1222 | #ifndef OPENSSL_NO_STDIO | 1356 | #ifndef OPENSSL_NO_STDIO |
| 1223 | int SSL_use_RSAPrivateKey_file(SSL *ssl, const char *file, int type); | 1357 | int SSL_use_RSAPrivateKey_file(SSL *ssl, const char *file, int type); |
| @@ -1253,6 +1387,7 @@ void SSL_copy_session_id(SSL *to,const SSL *from); | |||
| 1253 | SSL_SESSION *SSL_SESSION_new(void); | 1387 | SSL_SESSION *SSL_SESSION_new(void); |
| 1254 | unsigned long SSL_SESSION_hash(const SSL_SESSION *a); | 1388 | unsigned long SSL_SESSION_hash(const SSL_SESSION *a); |
| 1255 | int SSL_SESSION_cmp(const SSL_SESSION *a,const SSL_SESSION *b); | 1389 | int SSL_SESSION_cmp(const SSL_SESSION *a,const SSL_SESSION *b); |
| 1390 | const unsigned char *SSL_SESSION_get_id(const SSL_SESSION *s, unsigned int *len); | ||
| 1256 | #ifndef OPENSSL_NO_FP_API | 1391 | #ifndef OPENSSL_NO_FP_API |
| 1257 | int SSL_SESSION_print_fp(FILE *fp,const SSL_SESSION *ses); | 1392 | int SSL_SESSION_print_fp(FILE *fp,const SSL_SESSION *ses); |
| 1258 | #endif | 1393 | #endif |
| @@ -1268,7 +1403,7 @@ int SSL_CTX_set_generate_session_id(SSL_CTX *, GEN_SESSION_CB); | |||
| 1268 | int SSL_set_generate_session_id(SSL *, GEN_SESSION_CB); | 1403 | int SSL_set_generate_session_id(SSL *, GEN_SESSION_CB); |
| 1269 | int SSL_has_matching_session_id(const SSL *ssl, const unsigned char *id, | 1404 | int SSL_has_matching_session_id(const SSL *ssl, const unsigned char *id, |
| 1270 | unsigned int id_len); | 1405 | unsigned int id_len); |
| 1271 | SSL_SESSION *d2i_SSL_SESSION(SSL_SESSION **a,const unsigned char * const *pp, | 1406 | SSL_SESSION *d2i_SSL_SESSION(SSL_SESSION **a,const unsigned char **pp, |
| 1272 | long length); | 1407 | long length); |
| 1273 | 1408 | ||
| 1274 | #ifdef HEADER_X509_H | 1409 | #ifdef HEADER_X509_H |
| @@ -1287,12 +1422,12 @@ void SSL_CTX_set_cert_verify_callback(SSL_CTX *ctx, int (*cb)(X509_STORE_CTX *,v | |||
| 1287 | #ifndef OPENSSL_NO_RSA | 1422 | #ifndef OPENSSL_NO_RSA |
| 1288 | int SSL_CTX_use_RSAPrivateKey(SSL_CTX *ctx, RSA *rsa); | 1423 | int SSL_CTX_use_RSAPrivateKey(SSL_CTX *ctx, RSA *rsa); |
| 1289 | #endif | 1424 | #endif |
| 1290 | int SSL_CTX_use_RSAPrivateKey_ASN1(SSL_CTX *ctx, unsigned char *d, long len); | 1425 | int SSL_CTX_use_RSAPrivateKey_ASN1(SSL_CTX *ctx, const unsigned char *d, long len); |
| 1291 | int SSL_CTX_use_PrivateKey(SSL_CTX *ctx, EVP_PKEY *pkey); | 1426 | int SSL_CTX_use_PrivateKey(SSL_CTX *ctx, EVP_PKEY *pkey); |
| 1292 | int SSL_CTX_use_PrivateKey_ASN1(int pk,SSL_CTX *ctx, | 1427 | int SSL_CTX_use_PrivateKey_ASN1(int pk,SSL_CTX *ctx, |
| 1293 | unsigned char *d, long len); | 1428 | const unsigned char *d, long len); |
| 1294 | int SSL_CTX_use_certificate(SSL_CTX *ctx, X509 *x); | 1429 | int SSL_CTX_use_certificate(SSL_CTX *ctx, X509 *x); |
| 1295 | int SSL_CTX_use_certificate_ASN1(SSL_CTX *ctx, int len, unsigned char *d); | 1430 | int SSL_CTX_use_certificate_ASN1(SSL_CTX *ctx, int len, const unsigned char *d); |
| 1296 | 1431 | ||
| 1297 | void SSL_CTX_set_default_passwd_cb(SSL_CTX *ctx, pem_password_cb *cb); | 1432 | void SSL_CTX_set_default_passwd_cb(SSL_CTX *ctx, pem_password_cb *cb); |
| 1298 | void SSL_CTX_set_default_passwd_cb_userdata(SSL_CTX *ctx, void *u); | 1433 | void SSL_CTX_set_default_passwd_cb_userdata(SSL_CTX *ctx, void *u); |
| @@ -1319,9 +1454,9 @@ int SSL_read(SSL *ssl,void *buf,int num); | |||
| 1319 | int SSL_peek(SSL *ssl,void *buf,int num); | 1454 | int SSL_peek(SSL *ssl,void *buf,int num); |
| 1320 | int SSL_write(SSL *ssl,const void *buf,int num); | 1455 | int SSL_write(SSL *ssl,const void *buf,int num); |
| 1321 | long SSL_ctrl(SSL *ssl,int cmd, long larg, void *parg); | 1456 | long SSL_ctrl(SSL *ssl,int cmd, long larg, void *parg); |
| 1322 | long SSL_callback_ctrl(SSL *, int, void (*)()); | 1457 | long SSL_callback_ctrl(SSL *, int, void (*)(void)); |
| 1323 | long SSL_CTX_ctrl(SSL_CTX *ctx,int cmd, long larg, void *parg); | 1458 | long SSL_CTX_ctrl(SSL_CTX *ctx,int cmd, long larg, void *parg); |
| 1324 | long SSL_CTX_callback_ctrl(SSL_CTX *, int, void (*)()); | 1459 | long SSL_CTX_callback_ctrl(SSL_CTX *, int, void (*)(void)); |
| 1325 | 1460 | ||
| 1326 | int SSL_get_error(const SSL *s,int ret_code); | 1461 | int SSL_get_error(const SSL *s,int ret_code); |
| 1327 | const char *SSL_get_version(const SSL *s); | 1462 | const char *SSL_get_version(const SSL *s); |
| @@ -1345,6 +1480,10 @@ SSL_METHOD *TLSv1_method(void); /* TLSv1.0 */ | |||
| 1345 | SSL_METHOD *TLSv1_server_method(void); /* TLSv1.0 */ | 1480 | SSL_METHOD *TLSv1_server_method(void); /* TLSv1.0 */ |
| 1346 | SSL_METHOD *TLSv1_client_method(void); /* TLSv1.0 */ | 1481 | SSL_METHOD *TLSv1_client_method(void); /* TLSv1.0 */ |
| 1347 | 1482 | ||
| 1483 | SSL_METHOD *DTLSv1_method(void); /* DTLSv1.0 */ | ||
| 1484 | SSL_METHOD *DTLSv1_server_method(void); /* DTLSv1.0 */ | ||
| 1485 | SSL_METHOD *DTLSv1_client_method(void); /* DTLSv1.0 */ | ||
| 1486 | |||
| 1348 | STACK_OF(SSL_CIPHER) *SSL_get_ciphers(const SSL *s); | 1487 | STACK_OF(SSL_CIPHER) *SSL_get_ciphers(const SSL *s); |
| 1349 | 1488 | ||
| 1350 | int SSL_do_handshake(SSL *s); | 1489 | int SSL_do_handshake(SSL *s); |
| @@ -1395,6 +1534,7 @@ int SSL_CTX_load_verify_locations(SSL_CTX *ctx, const char *CAfile, | |||
| 1395 | SSL_SESSION *SSL_get_session(const SSL *ssl); | 1534 | SSL_SESSION *SSL_get_session(const SSL *ssl); |
| 1396 | SSL_SESSION *SSL_get1_session(SSL *ssl); /* obtain a reference count */ | 1535 | SSL_SESSION *SSL_get1_session(SSL *ssl); /* obtain a reference count */ |
| 1397 | SSL_CTX *SSL_get_SSL_CTX(const SSL *ssl); | 1536 | SSL_CTX *SSL_get_SSL_CTX(const SSL *ssl); |
| 1537 | SSL_CTX *SSL_set_SSL_CTX(SSL *ssl, SSL_CTX* ctx); | ||
| 1398 | void SSL_set_info_callback(SSL *ssl, | 1538 | void SSL_set_info_callback(SSL *ssl, |
| 1399 | void (*cb)(const SSL *ssl,int type,int val)); | 1539 | void (*cb)(const SSL *ssl,int type,int val)); |
| 1400 | void (*SSL_get_info_callback(const SSL *ssl))(const SSL *ssl,int type,int val); | 1540 | void (*SSL_get_info_callback(const SSL *ssl))(const SSL *ssl,int type,int val); |
| @@ -1462,11 +1602,27 @@ void SSL_set_tmp_dh_callback(SSL *ssl, | |||
| 1462 | DH *(*dh)(SSL *ssl,int is_export, | 1602 | DH *(*dh)(SSL *ssl,int is_export, |
| 1463 | int keylength)); | 1603 | int keylength)); |
| 1464 | #endif | 1604 | #endif |
| 1605 | #ifndef OPENSSL_NO_ECDH | ||
| 1606 | void SSL_CTX_set_tmp_ecdh_callback(SSL_CTX *ctx, | ||
| 1607 | EC_KEY *(*ecdh)(SSL *ssl,int is_export, | ||
| 1608 | int keylength)); | ||
| 1609 | void SSL_set_tmp_ecdh_callback(SSL *ssl, | ||
| 1610 | EC_KEY *(*ecdh)(SSL *ssl,int is_export, | ||
| 1611 | int keylength)); | ||
| 1612 | #endif | ||
| 1465 | 1613 | ||
| 1466 | #ifndef OPENSSL_NO_COMP | 1614 | #ifndef OPENSSL_NO_COMP |
| 1615 | const COMP_METHOD *SSL_get_current_compression(SSL *s); | ||
| 1616 | const COMP_METHOD *SSL_get_current_expansion(SSL *s); | ||
| 1617 | const char *SSL_COMP_get_name(const COMP_METHOD *comp); | ||
| 1618 | STACK_OF(SSL_COMP) *SSL_COMP_get_compression_methods(void); | ||
| 1467 | int SSL_COMP_add_compression_method(int id,COMP_METHOD *cm); | 1619 | int SSL_COMP_add_compression_method(int id,COMP_METHOD *cm); |
| 1468 | #else | 1620 | #else |
| 1469 | int SSL_COMP_add_compression_method(int id,char *cm); | 1621 | const void *SSL_get_current_compression(SSL *s); |
| 1622 | const void *SSL_get_current_expansion(SSL *s); | ||
| 1623 | const char *SSL_COMP_get_name(const void *comp); | ||
| 1624 | void *SSL_COMP_get_compression_methods(void); | ||
| 1625 | int SSL_COMP_add_compression_method(int id,void *cm); | ||
| 1470 | #endif | 1626 | #endif |
| 1471 | 1627 | ||
| 1472 | /* BEGIN ERROR CODES */ | 1628 | /* BEGIN ERROR CODES */ |
| @@ -1479,11 +1635,36 @@ void ERR_load_SSL_strings(void); | |||
| 1479 | 1635 | ||
| 1480 | /* Function codes. */ | 1636 | /* Function codes. */ |
| 1481 | #define SSL_F_CLIENT_CERTIFICATE 100 | 1637 | #define SSL_F_CLIENT_CERTIFICATE 100 |
| 1482 | #define SSL_F_CLIENT_FINISHED 238 | 1638 | #define SSL_F_CLIENT_FINISHED 167 |
| 1483 | #define SSL_F_CLIENT_HELLO 101 | 1639 | #define SSL_F_CLIENT_HELLO 101 |
| 1484 | #define SSL_F_CLIENT_MASTER_KEY 102 | 1640 | #define SSL_F_CLIENT_MASTER_KEY 102 |
| 1485 | #define SSL_F_D2I_SSL_SESSION 103 | 1641 | #define SSL_F_D2I_SSL_SESSION 103 |
| 1642 | #define SSL_F_DO_DTLS1_WRITE 245 | ||
| 1486 | #define SSL_F_DO_SSL3_WRITE 104 | 1643 | #define SSL_F_DO_SSL3_WRITE 104 |
| 1644 | #define SSL_F_DTLS1_ACCEPT 246 | ||
| 1645 | #define SSL_F_DTLS1_BUFFER_RECORD 247 | ||
| 1646 | #define SSL_F_DTLS1_CLIENT_HELLO 248 | ||
| 1647 | #define SSL_F_DTLS1_CONNECT 249 | ||
| 1648 | #define SSL_F_DTLS1_ENC 250 | ||
| 1649 | #define SSL_F_DTLS1_GET_HELLO_VERIFY 251 | ||
| 1650 | #define SSL_F_DTLS1_GET_MESSAGE 252 | ||
| 1651 | #define SSL_F_DTLS1_GET_MESSAGE_FRAGMENT 253 | ||
| 1652 | #define SSL_F_DTLS1_GET_RECORD 254 | ||
| 1653 | #define SSL_F_DTLS1_OUTPUT_CERT_CHAIN 255 | ||
| 1654 | #define SSL_F_DTLS1_PREPROCESS_FRAGMENT 277 | ||
| 1655 | #define SSL_F_DTLS1_PROCESS_OUT_OF_SEQ_MESSAGE 256 | ||
| 1656 | #define SSL_F_DTLS1_PROCESS_RECORD 257 | ||
| 1657 | #define SSL_F_DTLS1_READ_BYTES 258 | ||
| 1658 | #define SSL_F_DTLS1_READ_FAILED 259 | ||
| 1659 | #define SSL_F_DTLS1_SEND_CERTIFICATE_REQUEST 260 | ||
| 1660 | #define SSL_F_DTLS1_SEND_CLIENT_CERTIFICATE 261 | ||
| 1661 | #define SSL_F_DTLS1_SEND_CLIENT_KEY_EXCHANGE 262 | ||
| 1662 | #define SSL_F_DTLS1_SEND_CLIENT_VERIFY 263 | ||
| 1663 | #define SSL_F_DTLS1_SEND_HELLO_VERIFY_REQUEST 264 | ||
| 1664 | #define SSL_F_DTLS1_SEND_SERVER_CERTIFICATE 265 | ||
| 1665 | #define SSL_F_DTLS1_SEND_SERVER_HELLO 266 | ||
| 1666 | #define SSL_F_DTLS1_SEND_SERVER_KEY_EXCHANGE 267 | ||
| 1667 | #define SSL_F_DTLS1_WRITE_APP_DATA_BYTES 268 | ||
| 1487 | #define SSL_F_GET_CLIENT_FINISHED 105 | 1668 | #define SSL_F_GET_CLIENT_FINISHED 105 |
| 1488 | #define SSL_F_GET_CLIENT_HELLO 106 | 1669 | #define SSL_F_GET_CLIENT_HELLO 106 |
| 1489 | #define SSL_F_GET_CLIENT_MASTER_KEY 107 | 1670 | #define SSL_F_GET_CLIENT_MASTER_KEY 107 |
| @@ -1524,6 +1705,7 @@ void ERR_load_SSL_strings(void); | |||
| 1524 | #define SSL_F_SSL3_ENC 134 | 1705 | #define SSL_F_SSL3_ENC 134 |
| 1525 | #define SSL_F_SSL3_GENERATE_KEY_BLOCK 238 | 1706 | #define SSL_F_SSL3_GENERATE_KEY_BLOCK 238 |
| 1526 | #define SSL_F_SSL3_GET_CERTIFICATE_REQUEST 135 | 1707 | #define SSL_F_SSL3_GET_CERTIFICATE_REQUEST 135 |
| 1708 | #define SSL_F_SSL3_GET_CERT_STATUS 288 | ||
| 1527 | #define SSL_F_SSL3_GET_CERT_VERIFY 136 | 1709 | #define SSL_F_SSL3_GET_CERT_VERIFY 136 |
| 1528 | #define SSL_F_SSL3_GET_CLIENT_CERTIFICATE 137 | 1710 | #define SSL_F_SSL3_GET_CLIENT_CERTIFICATE 137 |
| 1529 | #define SSL_F_SSL3_GET_CLIENT_HELLO 138 | 1711 | #define SSL_F_SSL3_GET_CLIENT_HELLO 138 |
| @@ -1531,10 +1713,12 @@ void ERR_load_SSL_strings(void); | |||
| 1531 | #define SSL_F_SSL3_GET_FINISHED 140 | 1713 | #define SSL_F_SSL3_GET_FINISHED 140 |
| 1532 | #define SSL_F_SSL3_GET_KEY_EXCHANGE 141 | 1714 | #define SSL_F_SSL3_GET_KEY_EXCHANGE 141 |
| 1533 | #define SSL_F_SSL3_GET_MESSAGE 142 | 1715 | #define SSL_F_SSL3_GET_MESSAGE 142 |
| 1716 | #define SSL_F_SSL3_GET_NEW_SESSION_TICKET 283 | ||
| 1534 | #define SSL_F_SSL3_GET_RECORD 143 | 1717 | #define SSL_F_SSL3_GET_RECORD 143 |
| 1535 | #define SSL_F_SSL3_GET_SERVER_CERTIFICATE 144 | 1718 | #define SSL_F_SSL3_GET_SERVER_CERTIFICATE 144 |
| 1536 | #define SSL_F_SSL3_GET_SERVER_DONE 145 | 1719 | #define SSL_F_SSL3_GET_SERVER_DONE 145 |
| 1537 | #define SSL_F_SSL3_GET_SERVER_HELLO 146 | 1720 | #define SSL_F_SSL3_GET_SERVER_HELLO 146 |
| 1721 | #define SSL_F_SSL3_NEW_SESSION_TICKET 284 | ||
| 1538 | #define SSL_F_SSL3_OUTPUT_CERT_CHAIN 147 | 1722 | #define SSL_F_SSL3_OUTPUT_CERT_CHAIN 147 |
| 1539 | #define SSL_F_SSL3_PEEK 235 | 1723 | #define SSL_F_SSL3_PEEK 235 |
| 1540 | #define SSL_F_SSL3_READ_BYTES 148 | 1724 | #define SSL_F_SSL3_READ_BYTES 148 |
| @@ -1550,8 +1734,10 @@ void ERR_load_SSL_strings(void); | |||
| 1550 | #define SSL_F_SSL3_SETUP_KEY_BLOCK 157 | 1734 | #define SSL_F_SSL3_SETUP_KEY_BLOCK 157 |
| 1551 | #define SSL_F_SSL3_WRITE_BYTES 158 | 1735 | #define SSL_F_SSL3_WRITE_BYTES 158 |
| 1552 | #define SSL_F_SSL3_WRITE_PENDING 159 | 1736 | #define SSL_F_SSL3_WRITE_PENDING 159 |
| 1737 | #define SSL_F_SSL_ADD_CLIENTHELLO_TLSEXT 272 | ||
| 1553 | #define SSL_F_SSL_ADD_DIR_CERT_SUBJECTS_TO_STACK 215 | 1738 | #define SSL_F_SSL_ADD_DIR_CERT_SUBJECTS_TO_STACK 215 |
| 1554 | #define SSL_F_SSL_ADD_FILE_CERT_SUBJECTS_TO_STACK 216 | 1739 | #define SSL_F_SSL_ADD_FILE_CERT_SUBJECTS_TO_STACK 216 |
| 1740 | #define SSL_F_SSL_ADD_SERVERHELLO_TLSEXT 273 | ||
| 1555 | #define SSL_F_SSL_BAD_METHOD 160 | 1741 | #define SSL_F_SSL_BAD_METHOD 160 |
| 1556 | #define SSL_F_SSL_BYTES_TO_CIPHER_LIST 161 | 1742 | #define SSL_F_SSL_BYTES_TO_CIPHER_LIST 161 |
| 1557 | #define SSL_F_SSL_CERT_DUP 221 | 1743 | #define SSL_F_SSL_CERT_DUP 221 |
| @@ -1559,6 +1745,7 @@ void ERR_load_SSL_strings(void); | |||
| 1559 | #define SSL_F_SSL_CERT_INSTANTIATE 214 | 1745 | #define SSL_F_SSL_CERT_INSTANTIATE 214 |
| 1560 | #define SSL_F_SSL_CERT_NEW 162 | 1746 | #define SSL_F_SSL_CERT_NEW 162 |
| 1561 | #define SSL_F_SSL_CHECK_PRIVATE_KEY 163 | 1747 | #define SSL_F_SSL_CHECK_PRIVATE_KEY 163 |
| 1748 | #define SSL_F_SSL_CHECK_SERVERHELLO_TLSEXT 274 | ||
| 1562 | #define SSL_F_SSL_CIPHER_PROCESS_RULESTR 230 | 1749 | #define SSL_F_SSL_CIPHER_PROCESS_RULESTR 230 |
| 1563 | #define SSL_F_SSL_CIPHER_STRENGTH_SORT 231 | 1750 | #define SSL_F_SSL_CIPHER_STRENGTH_SORT 231 |
| 1564 | #define SSL_F_SSL_CLEAR 164 | 1751 | #define SSL_F_SSL_CLEAR 164 |
| @@ -1590,6 +1777,9 @@ void ERR_load_SSL_strings(void); | |||
| 1590 | #define SSL_F_SSL_INIT_WBIO_BUFFER 184 | 1777 | #define SSL_F_SSL_INIT_WBIO_BUFFER 184 |
| 1591 | #define SSL_F_SSL_LOAD_CLIENT_CA_FILE 185 | 1778 | #define SSL_F_SSL_LOAD_CLIENT_CA_FILE 185 |
| 1592 | #define SSL_F_SSL_NEW 186 | 1779 | #define SSL_F_SSL_NEW 186 |
| 1780 | #define SSL_F_SSL_PEEK 270 | ||
| 1781 | #define SSL_F_SSL_PREPARE_CLIENTHELLO_TLSEXT 275 | ||
| 1782 | #define SSL_F_SSL_PREPARE_SERVERHELLO_TLSEXT 276 | ||
| 1593 | #define SSL_F_SSL_READ 223 | 1783 | #define SSL_F_SSL_READ 223 |
| 1594 | #define SSL_F_SSL_RSA_PRIVATE_DECRYPT 187 | 1784 | #define SSL_F_SSL_RSA_PRIVATE_DECRYPT 187 |
| 1595 | #define SSL_F_SSL_RSA_PUBLIC_ENCRYPT 188 | 1785 | #define SSL_F_SSL_RSA_PUBLIC_ENCRYPT 188 |
| @@ -1609,6 +1799,7 @@ void ERR_load_SSL_strings(void); | |||
| 1609 | #define SSL_F_SSL_SHUTDOWN 224 | 1799 | #define SSL_F_SSL_SHUTDOWN 224 |
| 1610 | #define SSL_F_SSL_UNDEFINED_CONST_FUNCTION 243 | 1800 | #define SSL_F_SSL_UNDEFINED_CONST_FUNCTION 243 |
| 1611 | #define SSL_F_SSL_UNDEFINED_FUNCTION 197 | 1801 | #define SSL_F_SSL_UNDEFINED_FUNCTION 197 |
| 1802 | #define SSL_F_SSL_UNDEFINED_VOID_FUNCTION 244 | ||
| 1612 | #define SSL_F_SSL_USE_CERTIFICATE 198 | 1803 | #define SSL_F_SSL_USE_CERTIFICATE 198 |
| 1613 | #define SSL_F_SSL_USE_CERTIFICATE_ASN1 199 | 1804 | #define SSL_F_SSL_USE_CERTIFICATE_ASN1 199 |
| 1614 | #define SSL_F_SSL_USE_CERTIFICATE_FILE 200 | 1805 | #define SSL_F_SSL_USE_CERTIFICATE_FILE 200 |
| @@ -1639,6 +1830,9 @@ void ERR_load_SSL_strings(void); | |||
| 1639 | #define SSL_R_BAD_DH_P_LENGTH 110 | 1830 | #define SSL_R_BAD_DH_P_LENGTH 110 |
| 1640 | #define SSL_R_BAD_DIGEST_LENGTH 111 | 1831 | #define SSL_R_BAD_DIGEST_LENGTH 111 |
| 1641 | #define SSL_R_BAD_DSA_SIGNATURE 112 | 1832 | #define SSL_R_BAD_DSA_SIGNATURE 112 |
| 1833 | #define SSL_R_BAD_ECC_CERT 304 | ||
| 1834 | #define SSL_R_BAD_ECDSA_SIGNATURE 305 | ||
| 1835 | #define SSL_R_BAD_ECPOINT 306 | ||
| 1642 | #define SSL_R_BAD_HELLO_REQUEST 105 | 1836 | #define SSL_R_BAD_HELLO_REQUEST 105 |
| 1643 | #define SSL_R_BAD_LENGTH 271 | 1837 | #define SSL_R_BAD_LENGTH 271 |
| 1644 | #define SSL_R_BAD_MAC_DECODE 113 | 1838 | #define SSL_R_BAD_MAC_DECODE 113 |
| @@ -1668,17 +1862,22 @@ void ERR_load_SSL_strings(void); | |||
| 1668 | #define SSL_R_CIPHER_CODE_WRONG_LENGTH 137 | 1862 | #define SSL_R_CIPHER_CODE_WRONG_LENGTH 137 |
| 1669 | #define SSL_R_CIPHER_OR_HASH_UNAVAILABLE 138 | 1863 | #define SSL_R_CIPHER_OR_HASH_UNAVAILABLE 138 |
| 1670 | #define SSL_R_CIPHER_TABLE_SRC_ERROR 139 | 1864 | #define SSL_R_CIPHER_TABLE_SRC_ERROR 139 |
| 1865 | #define SSL_R_CLIENTHELLO_TLSEXT 157 | ||
| 1671 | #define SSL_R_COMPRESSED_LENGTH_TOO_LONG 140 | 1866 | #define SSL_R_COMPRESSED_LENGTH_TOO_LONG 140 |
| 1672 | #define SSL_R_COMPRESSION_FAILURE 141 | 1867 | #define SSL_R_COMPRESSION_FAILURE 141 |
| 1868 | #define SSL_R_COMPRESSION_ID_NOT_WITHIN_PRIVATE_RANGE 307 | ||
| 1673 | #define SSL_R_COMPRESSION_LIBRARY_ERROR 142 | 1869 | #define SSL_R_COMPRESSION_LIBRARY_ERROR 142 |
| 1674 | #define SSL_R_CONNECTION_ID_IS_DIFFERENT 143 | 1870 | #define SSL_R_CONNECTION_ID_IS_DIFFERENT 143 |
| 1675 | #define SSL_R_CONNECTION_TYPE_NOT_SET 144 | 1871 | #define SSL_R_CONNECTION_TYPE_NOT_SET 144 |
| 1872 | #define SSL_R_COOKIE_MISMATCH 308 | ||
| 1676 | #define SSL_R_DATA_BETWEEN_CCS_AND_FINISHED 145 | 1873 | #define SSL_R_DATA_BETWEEN_CCS_AND_FINISHED 145 |
| 1677 | #define SSL_R_DATA_LENGTH_TOO_LONG 146 | 1874 | #define SSL_R_DATA_LENGTH_TOO_LONG 146 |
| 1678 | #define SSL_R_DECRYPTION_FAILED 147 | 1875 | #define SSL_R_DECRYPTION_FAILED 147 |
| 1679 | #define SSL_R_DECRYPTION_FAILED_OR_BAD_RECORD_MAC 281 | 1876 | #define SSL_R_DECRYPTION_FAILED_OR_BAD_RECORD_MAC 281 |
| 1680 | #define SSL_R_DH_PUBLIC_VALUE_LENGTH_IS_WRONG 148 | 1877 | #define SSL_R_DH_PUBLIC_VALUE_LENGTH_IS_WRONG 148 |
| 1681 | #define SSL_R_DIGEST_CHECK_FAILED 149 | 1878 | #define SSL_R_DIGEST_CHECK_FAILED 149 |
| 1879 | #define SSL_R_DUPLICATE_COMPRESSION_ID 309 | ||
| 1880 | #define SSL_R_ECGROUP_TOO_LARGE_FOR_CIPHER 310 | ||
| 1682 | #define SSL_R_ENCRYPTED_LENGTH_TOO_LONG 150 | 1881 | #define SSL_R_ENCRYPTED_LENGTH_TOO_LONG 150 |
| 1683 | #define SSL_R_ERROR_GENERATING_TMP_RSA_KEY 282 | 1882 | #define SSL_R_ERROR_GENERATING_TMP_RSA_KEY 282 |
| 1684 | #define SSL_R_ERROR_IN_RECEIVED_CIPHER_LIST 151 | 1883 | #define SSL_R_ERROR_IN_RECEIVED_CIPHER_LIST 151 |
| @@ -1691,6 +1890,8 @@ void ERR_load_SSL_strings(void); | |||
| 1691 | #define SSL_R_INVALID_CHALLENGE_LENGTH 158 | 1890 | #define SSL_R_INVALID_CHALLENGE_LENGTH 158 |
| 1692 | #define SSL_R_INVALID_COMMAND 280 | 1891 | #define SSL_R_INVALID_COMMAND 280 |
| 1693 | #define SSL_R_INVALID_PURPOSE 278 | 1892 | #define SSL_R_INVALID_PURPOSE 278 |
| 1893 | #define SSL_R_INVALID_STATUS_RESPONSE 316 | ||
| 1894 | #define SSL_R_INVALID_TICKET_KEYS_LENGTH 275 | ||
| 1694 | #define SSL_R_INVALID_TRUST 279 | 1895 | #define SSL_R_INVALID_TRUST 279 |
| 1695 | #define SSL_R_KEY_ARG_TOO_LONG 284 | 1896 | #define SSL_R_KEY_ARG_TOO_LONG 284 |
| 1696 | #define SSL_R_KRB5 285 | 1897 | #define SSL_R_KRB5 285 |
| @@ -1719,6 +1920,7 @@ void ERR_load_SSL_strings(void); | |||
| 1719 | #define SSL_R_MISSING_RSA_ENCRYPTING_CERT 169 | 1920 | #define SSL_R_MISSING_RSA_ENCRYPTING_CERT 169 |
| 1720 | #define SSL_R_MISSING_RSA_SIGNING_CERT 170 | 1921 | #define SSL_R_MISSING_RSA_SIGNING_CERT 170 |
| 1721 | #define SSL_R_MISSING_TMP_DH_KEY 171 | 1922 | #define SSL_R_MISSING_TMP_DH_KEY 171 |
| 1923 | #define SSL_R_MISSING_TMP_ECDH_KEY 311 | ||
| 1722 | #define SSL_R_MISSING_TMP_RSA_KEY 172 | 1924 | #define SSL_R_MISSING_TMP_RSA_KEY 172 |
| 1723 | #define SSL_R_MISSING_TMP_RSA_PKEY 173 | 1925 | #define SSL_R_MISSING_TMP_RSA_PKEY 173 |
| 1724 | #define SSL_R_MISSING_VERIFY_MESSAGE 174 | 1926 | #define SSL_R_MISSING_VERIFY_MESSAGE 174 |
| @@ -1747,6 +1949,7 @@ void ERR_load_SSL_strings(void); | |||
| 1747 | #define SSL_R_OLD_SESSION_CIPHER_NOT_RETURNED 197 | 1949 | #define SSL_R_OLD_SESSION_CIPHER_NOT_RETURNED 197 |
| 1748 | #define SSL_R_ONLY_TLS_ALLOWED_IN_FIPS_MODE 297 | 1950 | #define SSL_R_ONLY_TLS_ALLOWED_IN_FIPS_MODE 297 |
| 1749 | #define SSL_R_PACKET_LENGTH_TOO_LONG 198 | 1951 | #define SSL_R_PACKET_LENGTH_TOO_LONG 198 |
| 1952 | #define SSL_R_PARSE_TLSEXT 223 | ||
| 1750 | #define SSL_R_PATH_TOO_LONG 270 | 1953 | #define SSL_R_PATH_TOO_LONG 270 |
| 1751 | #define SSL_R_PEER_DID_NOT_RETURN_A_CERTIFICATE 199 | 1954 | #define SSL_R_PEER_DID_NOT_RETURN_A_CERTIFICATE 199 |
| 1752 | #define SSL_R_PEER_ERROR 200 | 1955 | #define SSL_R_PEER_ERROR 200 |
| @@ -1761,6 +1964,7 @@ void ERR_load_SSL_strings(void); | |||
| 1761 | #define SSL_R_PUBLIC_KEY_IS_NOT_RSA 209 | 1964 | #define SSL_R_PUBLIC_KEY_IS_NOT_RSA 209 |
| 1762 | #define SSL_R_PUBLIC_KEY_NOT_RSA 210 | 1965 | #define SSL_R_PUBLIC_KEY_NOT_RSA 210 |
| 1763 | #define SSL_R_READ_BIO_NOT_SET 211 | 1966 | #define SSL_R_READ_BIO_NOT_SET 211 |
| 1967 | #define SSL_R_READ_TIMEOUT_EXPIRED 312 | ||
| 1764 | #define SSL_R_READ_WRONG_PACKET_TYPE 212 | 1968 | #define SSL_R_READ_WRONG_PACKET_TYPE 212 |
| 1765 | #define SSL_R_RECORD_LENGTH_MISMATCH 213 | 1969 | #define SSL_R_RECORD_LENGTH_MISMATCH 213 |
| 1766 | #define SSL_R_RECORD_TOO_LARGE 214 | 1970 | #define SSL_R_RECORD_TOO_LARGE 214 |
| @@ -1769,11 +1973,14 @@ void ERR_load_SSL_strings(void); | |||
| 1769 | #define SSL_R_REUSE_CERT_LENGTH_NOT_ZERO 216 | 1973 | #define SSL_R_REUSE_CERT_LENGTH_NOT_ZERO 216 |
| 1770 | #define SSL_R_REUSE_CERT_TYPE_NOT_ZERO 217 | 1974 | #define SSL_R_REUSE_CERT_TYPE_NOT_ZERO 217 |
| 1771 | #define SSL_R_REUSE_CIPHER_LIST_NOT_ZERO 218 | 1975 | #define SSL_R_REUSE_CIPHER_LIST_NOT_ZERO 218 |
| 1976 | #define SSL_R_SERVERHELLO_TLSEXT 224 | ||
| 1772 | #define SSL_R_SESSION_ID_CONTEXT_UNINITIALIZED 277 | 1977 | #define SSL_R_SESSION_ID_CONTEXT_UNINITIALIZED 277 |
| 1773 | #define SSL_R_SHORT_READ 219 | 1978 | #define SSL_R_SHORT_READ 219 |
| 1774 | #define SSL_R_SIGNATURE_FOR_NON_SIGNING_CERTIFICATE 220 | 1979 | #define SSL_R_SIGNATURE_FOR_NON_SIGNING_CERTIFICATE 220 |
| 1775 | #define SSL_R_SSL23_DOING_SESSION_ID_REUSE 221 | 1980 | #define SSL_R_SSL23_DOING_SESSION_ID_REUSE 221 |
| 1776 | #define SSL_R_SSL2_CONNECTION_ID_TOO_LONG 299 | 1981 | #define SSL_R_SSL2_CONNECTION_ID_TOO_LONG 299 |
| 1982 | #define SSL_R_SSL3_EXT_INVALID_SERVERNAME 225 | ||
| 1983 | #define SSL_R_SSL3_EXT_INVALID_SERVERNAME_TYPE 226 | ||
| 1777 | #define SSL_R_SSL3_SESSION_ID_TOO_LONG 300 | 1984 | #define SSL_R_SSL3_SESSION_ID_TOO_LONG 300 |
| 1778 | #define SSL_R_SSL3_SESSION_ID_TOO_SHORT 222 | 1985 | #define SSL_R_SSL3_SESSION_ID_TOO_SHORT 222 |
| 1779 | #define SSL_R_SSLV3_ALERT_BAD_CERTIFICATE 1042 | 1986 | #define SSL_R_SSLV3_ALERT_BAD_CERTIFICATE 1042 |
| @@ -1808,12 +2015,15 @@ void ERR_load_SSL_strings(void); | |||
| 1808 | #define SSL_R_TLSV1_ALERT_UNKNOWN_CA 1048 | 2015 | #define SSL_R_TLSV1_ALERT_UNKNOWN_CA 1048 |
| 1809 | #define SSL_R_TLSV1_ALERT_USER_CANCELLED 1090 | 2016 | #define SSL_R_TLSV1_ALERT_USER_CANCELLED 1090 |
| 1810 | #define SSL_R_TLS_CLIENT_CERT_REQ_WITH_ANON_CIPHER 232 | 2017 | #define SSL_R_TLS_CLIENT_CERT_REQ_WITH_ANON_CIPHER 232 |
| 2018 | #define SSL_R_TLS_INVALID_ECPOINTFORMAT_LIST 227 | ||
| 1811 | #define SSL_R_TLS_PEER_DID_NOT_RESPOND_WITH_CERTIFICATE_LIST 233 | 2019 | #define SSL_R_TLS_PEER_DID_NOT_RESPOND_WITH_CERTIFICATE_LIST 233 |
| 1812 | #define SSL_R_TLS_RSA_ENCRYPTED_VALUE_LENGTH_IS_WRONG 234 | 2020 | #define SSL_R_TLS_RSA_ENCRYPTED_VALUE_LENGTH_IS_WRONG 234 |
| 1813 | #define SSL_R_TRIED_TO_USE_UNSUPPORTED_CIPHER 235 | 2021 | #define SSL_R_TRIED_TO_USE_UNSUPPORTED_CIPHER 235 |
| 1814 | #define SSL_R_UNABLE_TO_DECODE_DH_CERTS 236 | 2022 | #define SSL_R_UNABLE_TO_DECODE_DH_CERTS 236 |
| 2023 | #define SSL_R_UNABLE_TO_DECODE_ECDH_CERTS 313 | ||
| 1815 | #define SSL_R_UNABLE_TO_EXTRACT_PUBLIC_KEY 237 | 2024 | #define SSL_R_UNABLE_TO_EXTRACT_PUBLIC_KEY 237 |
| 1816 | #define SSL_R_UNABLE_TO_FIND_DH_PARAMETERS 238 | 2025 | #define SSL_R_UNABLE_TO_FIND_DH_PARAMETERS 238 |
| 2026 | #define SSL_R_UNABLE_TO_FIND_ECDH_PARAMETERS 314 | ||
| 1817 | #define SSL_R_UNABLE_TO_FIND_PUBLIC_KEY_PARAMETERS 239 | 2027 | #define SSL_R_UNABLE_TO_FIND_PUBLIC_KEY_PARAMETERS 239 |
| 1818 | #define SSL_R_UNABLE_TO_FIND_SSL_METHOD 240 | 2028 | #define SSL_R_UNABLE_TO_FIND_SSL_METHOD 240 |
| 1819 | #define SSL_R_UNABLE_TO_LOAD_SSL2_MD5_ROUTINES 241 | 2029 | #define SSL_R_UNABLE_TO_LOAD_SSL2_MD5_ROUTINES 241 |
| @@ -1834,8 +2044,10 @@ void ERR_load_SSL_strings(void); | |||
| 1834 | #define SSL_R_UNKNOWN_STATE 255 | 2044 | #define SSL_R_UNKNOWN_STATE 255 |
| 1835 | #define SSL_R_UNSUPPORTED_CIPHER 256 | 2045 | #define SSL_R_UNSUPPORTED_CIPHER 256 |
| 1836 | #define SSL_R_UNSUPPORTED_COMPRESSION_ALGORITHM 257 | 2046 | #define SSL_R_UNSUPPORTED_COMPRESSION_ALGORITHM 257 |
| 2047 | #define SSL_R_UNSUPPORTED_ELLIPTIC_CURVE 315 | ||
| 1837 | #define SSL_R_UNSUPPORTED_PROTOCOL 258 | 2048 | #define SSL_R_UNSUPPORTED_PROTOCOL 258 |
| 1838 | #define SSL_R_UNSUPPORTED_SSL_VERSION 259 | 2049 | #define SSL_R_UNSUPPORTED_SSL_VERSION 259 |
| 2050 | #define SSL_R_UNSUPPORTED_STATUS_TYPE 329 | ||
| 1839 | #define SSL_R_WRITE_BIO_NOT_SET 260 | 2051 | #define SSL_R_WRITE_BIO_NOT_SET 260 |
| 1840 | #define SSL_R_WRONG_CIPHER_RETURNED 261 | 2052 | #define SSL_R_WRONG_CIPHER_RETURNED 261 |
| 1841 | #define SSL_R_WRONG_MESSAGE_TYPE 262 | 2053 | #define SSL_R_WRONG_MESSAGE_TYPE 262 |
