diff options
Diffstat (limited to 'src/lib/libcrypto/rsa')
| -rw-r--r-- | src/lib/libcrypto/rsa/rsa_saos.c | 6 | ||||
| -rw-r--r-- | src/lib/libcrypto/rsa/rsa_sign.c | 6 |
2 files changed, 6 insertions, 6 deletions
diff --git a/src/lib/libcrypto/rsa/rsa_saos.c b/src/lib/libcrypto/rsa/rsa_saos.c index adf459ee6d..3a07a7af4a 100644 --- a/src/lib/libcrypto/rsa/rsa_saos.c +++ b/src/lib/libcrypto/rsa/rsa_saos.c | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: rsa_saos.c,v 1.16 2014/07/12 16:03:37 miod Exp $ */ | 1 | /* $OpenBSD: rsa_saos.c,v 1.17 2015/07/19 18:29:31 miod Exp $ */ |
| 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
| 3 | * All rights reserved. | 3 | * All rights reserved. |
| 4 | * | 4 | * |
| @@ -84,7 +84,7 @@ RSA_sign_ASN1_OCTET_STRING(int type, const unsigned char *m, unsigned int m_len, | |||
| 84 | RSA_R_DIGEST_TOO_BIG_FOR_RSA_KEY); | 84 | RSA_R_DIGEST_TOO_BIG_FOR_RSA_KEY); |
| 85 | return 0; | 85 | return 0; |
| 86 | } | 86 | } |
| 87 | s = malloc((unsigned int)j + 1); | 87 | s = malloc(j + 1); |
| 88 | if (s == NULL) { | 88 | if (s == NULL) { |
| 89 | RSAerr(RSA_F_RSA_SIGN_ASN1_OCTET_STRING, ERR_R_MALLOC_FAILURE); | 89 | RSAerr(RSA_F_RSA_SIGN_ASN1_OCTET_STRING, ERR_R_MALLOC_FAILURE); |
| 90 | return 0; | 90 | return 0; |
| @@ -117,7 +117,7 @@ RSA_verify_ASN1_OCTET_STRING(int dtype, const unsigned char *m, | |||
| 117 | return 0; | 117 | return 0; |
| 118 | } | 118 | } |
| 119 | 119 | ||
| 120 | s = malloc((unsigned int)siglen); | 120 | s = malloc(siglen); |
| 121 | if (s == NULL) { | 121 | if (s == NULL) { |
| 122 | RSAerr(RSA_F_RSA_VERIFY_ASN1_OCTET_STRING, | 122 | RSAerr(RSA_F_RSA_VERIFY_ASN1_OCTET_STRING, |
| 123 | ERR_R_MALLOC_FAILURE); | 123 | ERR_R_MALLOC_FAILURE); |
diff --git a/src/lib/libcrypto/rsa/rsa_sign.c b/src/lib/libcrypto/rsa/rsa_sign.c index 09d8ef329d..db63c5f038 100644 --- a/src/lib/libcrypto/rsa/rsa_sign.c +++ b/src/lib/libcrypto/rsa/rsa_sign.c | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: rsa_sign.c,v 1.23 2015/06/20 01:07:25 doug Exp $ */ | 1 | /* $OpenBSD: rsa_sign.c,v 1.24 2015/07/19 18:29:31 miod Exp $ */ |
| 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
| 3 | * All rights reserved. | 3 | * All rights reserved. |
| 4 | * | 4 | * |
| @@ -121,7 +121,7 @@ RSA_sign(int type, const unsigned char *m, unsigned int m_len, | |||
| 121 | return 0; | 121 | return 0; |
| 122 | } | 122 | } |
| 123 | if (type != NID_md5_sha1) { | 123 | if (type != NID_md5_sha1) { |
| 124 | tmps = malloc((unsigned int)j + 1); | 124 | tmps = malloc(j + 1); |
| 125 | if (tmps == NULL) { | 125 | if (tmps == NULL) { |
| 126 | RSAerr(RSA_F_RSA_SIGN, ERR_R_MALLOC_FAILURE); | 126 | RSAerr(RSA_F_RSA_SIGN, ERR_R_MALLOC_FAILURE); |
| 127 | return 0; | 127 | return 0; |
| @@ -166,7 +166,7 @@ int_rsa_verify(int dtype, const unsigned char *m, unsigned int m_len, | |||
| 166 | return 1; | 166 | return 1; |
| 167 | } | 167 | } |
| 168 | 168 | ||
| 169 | s = malloc((unsigned int)siglen); | 169 | s = malloc(siglen); |
| 170 | if (s == NULL) { | 170 | if (s == NULL) { |
| 171 | RSAerr(RSA_F_INT_RSA_VERIFY, ERR_R_MALLOC_FAILURE); | 171 | RSAerr(RSA_F_INT_RSA_VERIFY, ERR_R_MALLOC_FAILURE); |
| 172 | goto err; | 172 | goto err; |
