diff options
| author | beck <> | 2017-01-29 17:49:23 +0000 |
|---|---|---|
| committer | beck <> | 2017-01-29 17:49:23 +0000 |
| commit | d1f47bd292f36094480caa49ada36b99a69c59b0 (patch) | |
| tree | 1a54abba678898ee5270ae4f3404a50ee9a92eea /src/lib/libcrypto/ec/ecp_nist.c | |
| parent | f8c627888330b75c2eea8a3c27d0efe947a4f9da (diff) | |
| download | openbsd-d1f47bd292f36094480caa49ada36b99a69c59b0.tar.gz openbsd-d1f47bd292f36094480caa49ada36b99a69c59b0.tar.bz2 openbsd-d1f47bd292f36094480caa49ada36b99a69c59b0.zip | |
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 'src/lib/libcrypto/ec/ecp_nist.c')
| -rw-r--r-- | src/lib/libcrypto/ec/ecp_nist.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/lib/libcrypto/ec/ecp_nist.c b/src/lib/libcrypto/ec/ecp_nist.c index a33f9d9e39..24cba64d2e 100644 --- a/src/lib/libcrypto/ec/ecp_nist.c +++ b/src/lib/libcrypto/ec/ecp_nist.c | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: ecp_nist.c,v 1.9 2014/07/12 16:03:37 miod Exp $ */ | 1 | /* $OpenBSD: ecp_nist.c,v 1.10 2017/01/29 17:49:23 beck Exp $ */ |
| 2 | /* | 2 | /* |
| 3 | * Written by Nils Larsch for the OpenSSL project. | 3 | * Written by Nils Larsch for the OpenSSL project. |
| 4 | */ | 4 | */ |
| @@ -145,7 +145,7 @@ ec_GFp_nist_group_set_curve(EC_GROUP *group, const BIGNUM *p, | |||
| 145 | else if (BN_ucmp(BN_get0_nist_prime_521(), p) == 0) | 145 | else if (BN_ucmp(BN_get0_nist_prime_521(), p) == 0) |
| 146 | group->field_mod_func = BN_nist_mod_521; | 146 | group->field_mod_func = BN_nist_mod_521; |
| 147 | else { | 147 | else { |
| 148 | ECerr(EC_F_EC_GFP_NIST_GROUP_SET_CURVE, EC_R_NOT_A_NIST_PRIME); | 148 | ECerror(EC_R_NOT_A_NIST_PRIME); |
| 149 | goto err; | 149 | goto err; |
| 150 | } | 150 | } |
| 151 | 151 | ||
| @@ -166,7 +166,7 @@ ec_GFp_nist_field_mul(const EC_GROUP *group, BIGNUM *r, const BIGNUM *a, | |||
| 166 | BN_CTX *ctx_new = NULL; | 166 | BN_CTX *ctx_new = NULL; |
| 167 | 167 | ||
| 168 | if (!group || !r || !a || !b) { | 168 | if (!group || !r || !a || !b) { |
| 169 | ECerr(EC_F_EC_GFP_NIST_FIELD_MUL, ERR_R_PASSED_NULL_PARAMETER); | 169 | ECerror(ERR_R_PASSED_NULL_PARAMETER); |
| 170 | goto err; | 170 | goto err; |
| 171 | } | 171 | } |
| 172 | if (!ctx) | 172 | if (!ctx) |
| @@ -193,7 +193,7 @@ ec_GFp_nist_field_sqr(const EC_GROUP * group, BIGNUM * r, const BIGNUM * a, | |||
| 193 | BN_CTX *ctx_new = NULL; | 193 | BN_CTX *ctx_new = NULL; |
| 194 | 194 | ||
| 195 | if (!group || !r || !a) { | 195 | if (!group || !r || !a) { |
| 196 | ECerr(EC_F_EC_GFP_NIST_FIELD_SQR, EC_R_PASSED_NULL_PARAMETER); | 196 | ECerror(EC_R_PASSED_NULL_PARAMETER); |
| 197 | goto err; | 197 | goto err; |
| 198 | } | 198 | } |
| 199 | if (!ctx) | 199 | if (!ctx) |
