diff options
author | Matt Caswell <matt@openssl.org> | 2015-03-31 01:18:31 +0200 |
---|---|---|
committer | Matt Caswell <matt@openssl.org> | 2015-05-16 10:20:31 +0200 |
commit | 13c9bb3ecec5f847b4c5295249e039d386e2d10e (patch) | |
tree | 8a3c816a718d72049d44dc24b6c2239fe954eab0 /demos | |
parent | Server side version negotiation rewrite (diff) | |
download | openssl-13c9bb3ecec5f847b4c5295249e039d386e2d10e.tar.xz openssl-13c9bb3ecec5f847b4c5295249e039d386e2d10e.zip |
Client side version negotiation rewrite
Continuing from the previous commit this changes the way we do client side
version negotiation. Similarly all of the s23* "up front" state machine code
has been avoided and again things now work much the same way as they already
did for DTLS, i.e. we just do most of the work in the
ssl3_get_server_hello() function.
Reviewed-by: Kurt Roeckx <kurt@openssl.org>
Diffstat (limited to 'demos')
-rw-r--r-- | demos/bio/client-arg.c | 2 | ||||
-rw-r--r-- | demos/bio/client-conf.c | 2 | ||||
-rw-r--r-- | demos/bio/sconnect.c | 2 | ||||
-rw-r--r-- | demos/easy_tls/easy-tls.c | 2 | ||||
-rw-r--r-- | demos/ssl/cli.cpp | 2 |
5 files changed, 5 insertions, 5 deletions
diff --git a/demos/bio/client-arg.c b/demos/bio/client-arg.c index 8507e04f49..99ebff1f2a 100644 --- a/demos/bio/client-arg.c +++ b/demos/bio/client-arg.c @@ -17,7 +17,7 @@ int main(int argc, char **argv) ERR_load_SSL_strings(); SSL_library_init(); - ctx = SSL_CTX_new(SSLv23_client_method()); + ctx = SSL_CTX_new(TLS_client_method()); cctx = SSL_CONF_CTX_new(); SSL_CONF_CTX_set_flags(cctx, SSL_CONF_FLAG_CLIENT); SSL_CONF_CTX_set_ssl_ctx(cctx, ctx); diff --git a/demos/bio/client-conf.c b/demos/bio/client-conf.c index b75088a758..2a78315165 100644 --- a/demos/bio/client-conf.c +++ b/demos/bio/client-conf.c @@ -37,7 +37,7 @@ int main(int argc, char **argv) goto end; } - ctx = SSL_CTX_new(SSLv23_client_method()); + ctx = SSL_CTX_new(TLS_client_method()); cctx = SSL_CONF_CTX_new(); SSL_CONF_CTX_set_flags(cctx, SSL_CONF_FLAG_CLIENT); SSL_CONF_CTX_set_flags(cctx, SSL_CONF_FLAG_FILE); diff --git a/demos/bio/sconnect.c b/demos/bio/sconnect.c index 6e4ca6596b..865d503956 100644 --- a/demos/bio/sconnect.c +++ b/demos/bio/sconnect.c @@ -43,7 +43,7 @@ char *argv[]; /* Setup all the global SSL stuff */ OpenSSL_add_ssl_algorithms(); - ssl_ctx = SSL_CTX_new(SSLv23_client_method()); + ssl_ctx = SSL_CTX_new(TLS_client_method()); /* Lets make a SSL structure */ ssl = SSL_new(ssl_ctx); diff --git a/demos/easy_tls/easy-tls.c b/demos/easy_tls/easy-tls.c index 2befb657a0..b9512909d1 100644 --- a/demos/easy_tls/easy-tls.c +++ b/demos/easy_tls/easy-tls.c @@ -667,7 +667,7 @@ SSL_CTX *tls_create_ctx(struct tls_create_ctx_args a, void *apparg) return NULL; ret = - SSL_CTX_new((a.client_p ? SSLv23_client_method : + SSL_CTX_new((a.client_p ? TLS_client_method : TLS_server_method) ()); if (ret == NULL) diff --git a/demos/ssl/cli.cpp b/demos/ssl/cli.cpp index cb5d329ea4..3459f0f93a 100644 --- a/demos/ssl/cli.cpp +++ b/demos/ssl/cli.cpp @@ -38,7 +38,7 @@ void main () SSL_METHOD *meth; SSLeay_add_ssl_algorithms(); - meth = SSLv23_client_method(); + meth = TLS_client_method(); SSL_load_error_strings(); ctx = SSL_CTX_new (meth); CHK_NULL(ctx); |