Go to file
David Benjamin 62fd16283a Implement SSL_clear with ssl_new and ssl_free.
State on s3 gets freed in both ssl3_clear and ssl3_free. Considate to just
ssl3_free. This replaces the (SSL,ssl,ssl3)_clear calls in (SSL,ssl,ssl3)_new
with the state that was initialized. This results in a little code duplication
between SSL_new and SSL_clear because state is on the wrong object. I've just
left TODOs for now; some of it will need disentangling.

We're far from it, but going forward, separate state between s and s->s3 as:

- s contains configuration state, DTLS or TLS. It is initialized from SSL_CTX,
  configurable directly afterwards, and preserved across SSL_clear calls.
  (Including when it's implicitly set as part of a handshake callback.)

- Connection state hangs off s->s3 (TLS) and s->d1 (DTLS). It is reset across
  SSL_clear. This should happen naturally out of a ssl_free/ssl_new pair.

The goal is to avoid needing separate initialize and reset code for anything;
the point any particular state is reset is the point its owning context is
destroyed and recreated.

Change-Id: I5d779010778109f8c339c07433a0777feaf94d1f
Reviewed-on: https://boringssl-review.googlesource.com/2822
Reviewed-by: Adam Langley <agl@google.com>
2015-01-12 22:35:58 +00:00
crypto Fix DER checks for DSA_check_signature and add tests. 2015-01-12 22:29:10 +00:00
doc Inital import. 2014-06-20 13:17:32 -07:00
include/openssl Fix DER checks for DSA_check_signature and add tests. 2015-01-12 22:29:10 +00:00
ssl Implement SSL_clear with ssl_new and ssl_free. 2015-01-12 22:35:58 +00:00
tool Add the ability to run a server from the command line tool. 2014-12-11 10:47:21 -08:00
util Implement HKDF. 2014-12-18 20:13:06 +00:00
.clang-format Inital import. 2014-06-20 13:17:32 -07:00
.gitignore Inital import. 2014-06-20 13:17:32 -07:00
BUILDING Build with yasm on Win64 as well. 2014-10-31 22:02:45 +00:00
CMakeLists.txt Remove variable shadowing. 2014-12-09 21:32:49 +00:00
codereview.settings Add a codereview.settings file. 2014-11-18 22:21:33 +00:00