summaryrefslogtreecommitdiff
path: root/src/lib/libssl/d1_srvr.c
diff options
context:
space:
mode:
authorbeck <>2017-01-26 10:40:21 +0000
committerbeck <>2017-01-26 10:40:21 +0000
commit59161dbdf4da5b82b27402f93d7007a11b2d1cc1 (patch)
treee105a2b33d3aefb54727a955e9c746cc8edb0e50 /src/lib/libssl/d1_srvr.c
parenta2e1efdba084d65702b419bc510c30a144eb5d7f (diff)
downloadopenbsd-59161dbdf4da5b82b27402f93d7007a11b2d1cc1.tar.gz
openbsd-59161dbdf4da5b82b27402f93d7007a11b2d1cc1.tar.bz2
openbsd-59161dbdf4da5b82b27402f93d7007a11b2d1cc1.zip
Send the error function codes to rot in the depths of hell where they belong
We leave a single funciton code (0xFFF) to say "SSL_internal" so the public API will not break, and we replace all internal use of the two argument SSL_err() with the internal only SSL_error() that only takes a reason code. ok jsing@
Diffstat (limited to 'src/lib/libssl/d1_srvr.c')
-rw-r--r--src/lib/libssl/d1_srvr.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/lib/libssl/d1_srvr.c b/src/lib/libssl/d1_srvr.c
index f36d3f40cd..80d7d639c3 100644
--- a/src/lib/libssl/d1_srvr.c
+++ b/src/lib/libssl/d1_srvr.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: d1_srvr.c,v 1.81 2017/01/26 06:32:58 jsing Exp $ */ 1/* $OpenBSD: d1_srvr.c,v 1.82 2017/01/26 10:40:21 beck Exp $ */
2/* 2/*
3 * DTLS implementation written by Nagendra Modadugu 3 * DTLS implementation written by Nagendra Modadugu
4 * (nagendra@cs.stanford.edu) for the OpenSSL project 2005. 4 * (nagendra@cs.stanford.edu) for the OpenSSL project 2005.
@@ -202,7 +202,7 @@ dtls1_accept(SSL *s)
202 D1I(s)->listen = listen; 202 D1I(s)->listen = listen;
203 203
204 if (s->cert == NULL) { 204 if (s->cert == NULL) {
205 SSLerr(SSL_F_DTLS1_ACCEPT, SSL_R_NO_CERTIFICATE_SET); 205 SSLerror(SSL_R_NO_CERTIFICATE_SET);
206 ret = -1; 206 ret = -1;
207 goto end; 207 goto end;
208 } 208 }
@@ -225,7 +225,7 @@ dtls1_accept(SSL *s)
225 cb(s, SSL_CB_HANDSHAKE_START, 1); 225 cb(s, SSL_CB_HANDSHAKE_START, 1);
226 226
227 if ((s->version & 0xff00) != (DTLS1_VERSION & 0xff00)) { 227 if ((s->version & 0xff00) != (DTLS1_VERSION & 0xff00)) {
228 SSLerr(SSL_F_DTLS1_ACCEPT, ERR_R_INTERNAL_ERROR); 228 SSLerror(ERR_R_INTERNAL_ERROR);
229 ret = -1; 229 ret = -1;
230 goto end; 230 goto end;
231 } 231 }
@@ -506,7 +506,7 @@ dtls1_accept(SSL *s)
506 * at this point and digest cached records. 506 * at this point and digest cached records.
507 */ 507 */
508 if (!S3I(s)->handshake_buffer) { 508 if (!S3I(s)->handshake_buffer) {
509 SSLerr(SSL_F_SSL3_ACCEPT, 509 SSLerror(
510 ERR_R_INTERNAL_ERROR); 510 ERR_R_INTERNAL_ERROR);
511 ret = -1; 511 ret = -1;
512 goto end; 512 goto end;
@@ -659,7 +659,7 @@ dtls1_accept(SSL *s)
659 /* break; */ 659 /* break; */
660 660
661 default: 661 default:
662 SSLerr(SSL_F_DTLS1_ACCEPT, SSL_R_UNKNOWN_STATE); 662 SSLerror(SSL_R_UNKNOWN_STATE);
663 ret = -1; 663 ret = -1;
664 goto end; 664 goto end;
665 /* break; */ 665 /* break; */
@@ -706,7 +706,7 @@ dtls1_send_hello_verify_request(SSL *s)
706 if (s->ctx->internal->app_gen_cookie_cb == NULL || 706 if (s->ctx->internal->app_gen_cookie_cb == NULL ||
707 s->ctx->internal->app_gen_cookie_cb(s, 707 s->ctx->internal->app_gen_cookie_cb(s,
708 D1I(s)->cookie, &(D1I(s)->cookie_len)) == 0) { 708 D1I(s)->cookie, &(D1I(s)->cookie_len)) == 0) {
709 SSLerr(SSL_F_DTLS1_SEND_HELLO_VERIFY_REQUEST, 709 SSLerror(
710 ERR_R_INTERNAL_ERROR); 710 ERR_R_INTERNAL_ERROR);
711 return 0; 711 return 0;
712 } 712 }