diff options
author | Mike DePaulo <mikedep333@gmail.com> | 2015-01-10 12:26:41 -0500 |
---|---|---|
committer | Mike DePaulo <mikedep333@gmail.com> | 2015-01-10 13:07:24 -0500 |
commit | 4668cbfa14460fbead98ec3a904a58df1f41c4c3 (patch) | |
tree | 72b1fec2e5bfb8ea8ffad514d923c65e9ef38135 /openssl/apps/s_server.c | |
parent | 15915c262c1334282d0ab2a3fdb2c416e91b51cf (diff) | |
download | vcxsrv-4668cbfa14460fbead98ec3a904a58df1f41c4c3.tar.gz vcxsrv-4668cbfa14460fbead98ec3a904a58df1f41c4c3.tar.bz2 vcxsrv-4668cbfa14460fbead98ec3a904a58df1f41c4c3.zip |
Update openssl to version openssl-1.0.1k
Conflicts:
openssl/Makefile
Diffstat (limited to 'openssl/apps/s_server.c')
-rw-r--r-- | openssl/apps/s_server.c | 22 |
1 files changed, 19 insertions, 3 deletions
diff --git a/openssl/apps/s_server.c b/openssl/apps/s_server.c index fe7ad8823..f47328ab3 100644 --- a/openssl/apps/s_server.c +++ b/openssl/apps/s_server.c @@ -515,7 +515,9 @@ static void sv_usage(void) BIO_printf(bio_err," -srpuserseed string - A seed string for a default user salt.\n"); #endif BIO_printf(bio_err," -ssl2 - Just talk SSLv2\n"); +#ifndef OPENSSL_NO_SSL3_METHOD BIO_printf(bio_err," -ssl3 - Just talk SSLv3\n"); +#endif BIO_printf(bio_err," -tls1_2 - Just talk TLSv1.2\n"); BIO_printf(bio_err," -tls1_1 - Just talk TLSv1.1\n"); BIO_printf(bio_err," -tls1 - Just talk TLSv1\n"); @@ -1251,7 +1253,7 @@ int MAIN(int argc, char *argv[]) else if (strcmp(*argv,"-ssl2") == 0) { meth=SSLv2_server_method(); } #endif -#ifndef OPENSSL_NO_SSL3 +#ifndef OPENSSL_NO_SSL3_METHOD else if (strcmp(*argv,"-ssl3") == 0) { meth=SSLv3_server_method(); } #endif @@ -2049,10 +2051,24 @@ static int sv_body(char *hostname, int s, unsigned char *context) BIO_ctrl(sbio, BIO_CTRL_DGRAM_SET_SEND_TIMEOUT, 0, &timeout); } - if (socket_mtu > 28) + if (socket_mtu) { + if(socket_mtu < DTLS_get_link_min_mtu(con)) + { + BIO_printf(bio_err,"MTU too small. Must be at least %ld\n", + DTLS_get_link_min_mtu(con)); + ret = -1; + BIO_free(sbio); + goto err; + } SSL_set_options(con, SSL_OP_NO_QUERY_MTU); - SSL_set_mtu(con, socket_mtu - 28); + if(!DTLS_set_link_mtu(con, socket_mtu)) + { + BIO_printf(bio_err, "Failed to set MTU\n"); + ret = -1; + BIO_free(sbio); + goto err; + } } else /* want to do MTU discovery */ |