diff options
author | Bob Beck <beck@cvs.openbsd.org> | 2017-01-29 17:49:24 +0000 |
---|---|---|
committer | Bob Beck <beck@cvs.openbsd.org> | 2017-01-29 17:49:24 +0000 |
commit | c95f3b2c0c39020aafaffd84899a33ece0210769 (patch) | |
tree | 6d6e55f6c8b4047319196f43823ad30170dfe061 /lib/libcrypto/rsa/rsa_none.c | |
parent | b8dd3a8e12bfab2c15794994bc5bdc1397125536 (diff) |
Send the function codes from the error functions to the bit bucket,
as was done earlier in libssl. Thanks inoguchi@ for noticing
libssl had more reacharounds into this.
ok jsing@ inoguchi@
Diffstat (limited to 'lib/libcrypto/rsa/rsa_none.c')
-rw-r--r-- | lib/libcrypto/rsa/rsa_none.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/lib/libcrypto/rsa/rsa_none.c b/lib/libcrypto/rsa/rsa_none.c index 5222b3c1ebf..13d3449a9f4 100644 --- a/lib/libcrypto/rsa/rsa_none.c +++ b/lib/libcrypto/rsa/rsa_none.c @@ -1,4 +1,4 @@ -/* $OpenBSD: rsa_none.c,v 1.10 2014/10/18 17:20:40 jsing Exp $ */ +/* $OpenBSD: rsa_none.c,v 1.11 2017/01/29 17:49:23 beck Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -68,14 +68,12 @@ RSA_padding_add_none(unsigned char *to, int tlen, const unsigned char *from, int flen) { if (flen > tlen) { - RSAerr(RSA_F_RSA_PADDING_ADD_NONE, - RSA_R_DATA_TOO_LARGE_FOR_KEY_SIZE); + RSAerror(RSA_R_DATA_TOO_LARGE_FOR_KEY_SIZE); return 0; } if (flen < tlen) { - RSAerr(RSA_F_RSA_PADDING_ADD_NONE, - RSA_R_DATA_TOO_SMALL_FOR_KEY_SIZE); + RSAerror(RSA_R_DATA_TOO_SMALL_FOR_KEY_SIZE); return 0; } @@ -88,7 +86,7 @@ RSA_padding_check_none(unsigned char *to, int tlen, const unsigned char *from, int flen, int num) { if (flen > tlen) { - RSAerr(RSA_F_RSA_PADDING_CHECK_NONE, RSA_R_DATA_TOO_LARGE); + RSAerror(RSA_R_DATA_TOO_LARGE); return -1; } |