boringssl/ssl
David Benjamin b095f0f0ca Remove the push argument to ssl_init_wbio_buffer.
Having bbio be tri-state (not allocated, allocated but not active, and
allocated and active) is confusing.

The extra state is only used in the client handshake, where ClientHello is
special-cased to not go through the buffer while everything else is. This dates
to OpenSSL's initial commit and doesn't seem to do much. I do not believe it
can affect renego as the buffer only affects writes; although OpenSSL accepted
interleave on read (though this logic predates it slightly), it never sent
application data while it believed a handshake was active. The handshake would
always be driven to completion first.

My guess is this was to save a copy since the ClientHello is a one-message
flight so it wouldn't need to be buffered? This is probably not worth the extra
variation in the state. (Especially with the DTLS state machine going through
ClientHello twice and pushing the BIO in between the two. Though I suspect that
was a mistake in itself. If the optimization guess is correct, there was no
need to do that.)

Change-Id: I6726f866e16ee7213cab0c3e6abb133981444d47
Reviewed-on: https://boringssl-review.googlesource.com/7873
Reviewed-by: Adam Langley <agl@google.com>
2016-05-06 17:39:48 +00:00
..
pqueue Don't cast |OPENSSL_malloc|/|OPENSSL_realloc| result. 2016-02-11 22:07:56 +00:00
test Always buffer DTLS retransmits. 2016-05-06 17:37:11 +00:00
CMakeLists.txt
custom_extensions.c
d1_both.c Remove the push argument to ssl_init_wbio_buffer. 2016-05-06 17:39:48 +00:00
d1_clnt.c Remove the push argument to ssl_init_wbio_buffer. 2016-05-06 17:39:48 +00:00
d1_lib.c Set rwstate consistently. 2016-04-18 20:30:32 +00:00
d1_meth.c
d1_pkt.c Set rwstate consistently. 2016-04-18 20:30:32 +00:00
d1_srtp.c Remove some easy obj.h dependencies. 2016-03-31 20:50:33 +00:00
d1_srvr.c Remove the push argument to ssl_init_wbio_buffer. 2016-05-06 17:39:48 +00:00
dtls_record.c Move aead_{read,write}_ctx and next_proto_negotiated into ssl->s3. 2016-01-15 21:40:25 +00:00
internal.h Remove the push argument to ssl_init_wbio_buffer. 2016-05-06 17:39:48 +00:00
s3_both.c Set rwstate consistently. 2016-04-18 20:30:32 +00:00
s3_clnt.c Remove the push argument to ssl_init_wbio_buffer. 2016-05-06 17:39:48 +00:00
s3_enc.c Remove some easy obj.h dependencies. 2016-03-31 20:50:33 +00:00
s3_lib.c Remove some easy obj.h dependencies. 2016-03-31 20:50:33 +00:00
s3_meth.c
s3_pkt.c Set rwstate consistently. 2016-04-18 20:30:32 +00:00
s3_srvr.c Remove the push argument to ssl_init_wbio_buffer. 2016-05-06 17:39:48 +00:00
ssl_aead_ctx.c Disable all TLS crypto in fuzzer mode. 2016-03-02 23:39:36 +00:00
ssl_asn1.c
ssl_buffer.c Set rwstate consistently. 2016-04-18 20:30:32 +00:00
ssl_cert.c Ensure we check i2d_X509 return val 2016-04-26 17:12:01 +00:00
ssl_cipher.c Remove a number of unnecessary stdio.h includes. 2016-03-17 18:22:28 +00:00
ssl_ecdh.c Remove some easy obj.h dependencies. 2016-03-31 20:50:33 +00:00
ssl_file.c Banish SSL_add_dir_cert_subjects_to_stack and OPENSSL_DIR_CTX to decrepit. 2016-04-27 18:40:25 +00:00
ssl_lib.c Remove the push argument to ssl_init_wbio_buffer. 2016-05-06 17:39:48 +00:00
ssl_rsa.c Add |SSL_CTX_set_private_key_method| to parallel |SSL_set_private_key_method| 2016-03-07 18:16:58 +00:00
ssl_session.c Add SSL_SESSION_get_master_key. 2016-04-21 21:14:36 +00:00
ssl_stat.c
ssl_test.cc BIO_new_mem_buf should take const void * 2016-02-24 19:14:19 +00:00
t1_enc.c Remove some easy obj.h dependencies. 2016-03-31 20:50:33 +00:00
t1_lib.c Simplify server_name extension parsing. 2016-04-18 20:33:35 +00:00
tls_record.c Disable all TLS crypto in fuzzer mode. 2016-03-02 23:39:36 +00:00