summaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
authortb <>2023-07-05 17:36:19 +0000
committertb <>2023-07-05 17:36:19 +0000
commit1b9cfd8fd3700a5020daafcea0793af1d5342c40 (patch)
tree3c0e0e0d781f92647b226aa72b6c30f81d3d43bb /src/lib
parent91007d9e4c34d3a71ca05ee0cf3db536eadd6b71 (diff)
downloadopenbsd-1b9cfd8fd3700a5020daafcea0793af1d5342c40.tar.gz
openbsd-1b9cfd8fd3700a5020daafcea0793af1d5342c40.tar.bz2
openbsd-1b9cfd8fd3700a5020daafcea0793af1d5342c40.zip
whitespace
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/libcrypto/sm2/sm2_sign.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/lib/libcrypto/sm2/sm2_sign.c b/src/lib/libcrypto/sm2/sm2_sign.c
index 5d929e57aa..a5e3a8aee5 100644
--- a/src/lib/libcrypto/sm2/sm2_sign.c
+++ b/src/lib/libcrypto/sm2/sm2_sign.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: sm2_sign.c,v 1.3 2022/11/26 16:08:54 tb Exp $ */ 1/* $OpenBSD: sm2_sign.c,v 1.4 2023/07/05 17:36:19 tb Exp $ */
2/* 2/*
3 * Copyright (c) 2017, 2019 Ribose Inc 3 * Copyright (c) 2017, 2019 Ribose Inc
4 * 4 *
@@ -95,12 +95,12 @@ sm2_sig_gen(const EC_KEY *key, const BIGNUM *e)
95 const BIGNUM *dA; 95 const BIGNUM *dA;
96 BIGNUM *order = NULL, *r = NULL, *s = NULL; 96 BIGNUM *order = NULL, *r = NULL, *s = NULL;
97 BIGNUM *k, *rk, *tmp, *x1; 97 BIGNUM *k, *rk, *tmp, *x1;
98 98
99 if ((dA = EC_KEY_get0_private_key(key)) == NULL) { 99 if ((dA = EC_KEY_get0_private_key(key)) == NULL) {
100 SM2error(SM2_R_INVALID_FIELD); 100 SM2error(SM2_R_INVALID_FIELD);
101 goto err; 101 goto err;
102 } 102 }
103 103
104 if ((group = EC_KEY_get0_group(key)) == NULL) { 104 if ((group = EC_KEY_get0_group(key)) == NULL) {
105 SM2error(SM2_R_INVALID_FIELD); 105 SM2error(SM2_R_INVALID_FIELD);
106 goto err; 106 goto err;
@@ -405,7 +405,7 @@ SM2_sign(const unsigned char *dgst, int dgstlen, unsigned char *sig,
405 if ((s = sm2_sig_gen(eckey, e)) == NULL) { 405 if ((s = sm2_sig_gen(eckey, e)) == NULL) {
406 goto err; 406 goto err;
407 } 407 }
408 408
409 if ((outlen = i2d_ECDSA_SIG(s, &sig)) < 0) { 409 if ((outlen = i2d_ECDSA_SIG(s, &sig)) < 0) {
410 SM2error(SM2_R_ASN1_ERROR); 410 SM2error(SM2_R_ASN1_ERROR);
411 goto err; 411 goto err;