ssltest.c (325337) | ssltest.c (326663) |
---|---|
1/* ssl/ssltest.c */ 2/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) 3 * All rights reserved. 4 * 5 * This package is an SSL implementation written 6 * by Eric Young (eay@cryptsoft.com). 7 * The implementation was written so as to conform with Netscapes SSL. 8 * --- 409 unchanged lines hidden (view full) --- 418 return NULL; 419 420 for (i = 0; i <= len; ++i) { 421 if (i == len || in[i] == ',') { 422 if (i - start > 255) { 423 OPENSSL_free(out); 424 return NULL; 425 } | 1/* ssl/ssltest.c */ 2/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) 3 * All rights reserved. 4 * 5 * This package is an SSL implementation written 6 * by Eric Young (eay@cryptsoft.com). 7 * The implementation was written so as to conform with Netscapes SSL. 8 * --- 409 unchanged lines hidden (view full) --- 418 return NULL; 419 420 for (i = 0; i <= len; ++i) { 421 if (i == len || in[i] == ',') { 422 if (i - start > 255) { 423 OPENSSL_free(out); 424 return NULL; 425 } |
426 out[start] = i - start; | 426 out[start] = (unsigned char)(i - start); |
427 start = i + 1; 428 } else 429 out[i + 1] = in[i]; 430 } 431 | 427 start = i + 1; 428 } else 429 out[i + 1] = in[i]; 430 } 431 |
432 *outlen = len + 1; | 432 *outlen = (unsigned char)(len + 1); |
433 return out; 434} 435 436static int cb_server_alpn(SSL *s, const unsigned char **out, 437 unsigned char *outlen, const unsigned char *in, 438 unsigned int inlen, void *arg) 439{ 440 unsigned char *protos; --- 108 unchanged lines hidden (view full) --- 549 } 550 return 0; 551} 552 553static int cb_ticket2(SSL* s, unsigned char* key_name, unsigned char *iv, EVP_CIPHER_CTX *ctx, HMAC_CTX *hctx, int enc) 554{ 555 fprintf(stderr, "ticket callback for SNI context should never be called\n"); 556 EXIT(1); | 433 return out; 434} 435 436static int cb_server_alpn(SSL *s, const unsigned char **out, 437 unsigned char *outlen, const unsigned char *in, 438 unsigned int inlen, void *arg) 439{ 440 unsigned char *protos; --- 108 unchanged lines hidden (view full) --- 549 } 550 return 0; 551} 552 553static int cb_ticket2(SSL* s, unsigned char* key_name, unsigned char *iv, EVP_CIPHER_CTX *ctx, HMAC_CTX *hctx, int enc) 554{ 555 fprintf(stderr, "ticket callback for SNI context should never be called\n"); 556 EXIT(1); |
557 return 0; |
|
557} 558#endif 559 560#define SCT_EXT_TYPE 18 561 562/* 563 * WARNING : below extension types are *NOT* IETF assigned, and could 564 * conflict if these types are reassigned and handled specially by OpenSSL --- 2805 unchanged lines hidden --- | 558} 559#endif 560 561#define SCT_EXT_TYPE 18 562 563/* 564 * WARNING : below extension types are *NOT* IETF assigned, and could 565 * conflict if these types are reassigned and handled specially by OpenSSL --- 2805 unchanged lines hidden --- |