#endif
STACK_OF(SSL_CIPHER) *ciphers=NULL;
- if (s->state == SSL3_ST_SR_CLNT_HELLO_C)
+ if (s->state == SSL3_ST_SR_CLNT_HELLO_C && !s->first_packet)
goto retry_cert;
/* We do this so that we will respond with our native type.
if (!record->fn1)
continue;
cb_retval = record->fn1(s, record->supp_data_type,
- &out, &outlen, &al,
- record->arg);
+ &out, &outlen, &al, record->arg);
if (cb_retval == -1)
continue; /* skip this supp data entry */
if (cb_retval == 0)
long n;
const unsigned char *p, *d;
unsigned short supp_data_entry_type = 0;
- unsigned long supp_data_entry_len = 0;
+ unsigned short supp_data_entry_len = 0;
unsigned long supp_data_len = 0;
size_t i = 0;
n=s->method->ssl_get_message(s,
- SSL3_ST_SR_SUPPLEMENTAL_DATA_A,
- SSL3_ST_SR_SUPPLEMENTAL_DATA_B,
- SSL3_MT_SUPPLEMENTAL_DATA,
- /* use default limit */
- TLSEXT_MAXLEN_supplemental_data,
- &ok);
+ SSL3_ST_SR_SUPPLEMENTAL_DATA_A,
+ SSL3_ST_SR_SUPPLEMENTAL_DATA_B,
+ SSL3_MT_SUPPLEMENTAL_DATA,
+ /* use default limit */
+ TLSEXT_MAXLEN_supplemental_data,
+ &ok);
if (!ok) return((int)n);