artulab
projects
/
openbsd
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d210168
)
In DH_set0_pqg() also set dh->length if q is set to match what OpenSSL do.
author
tb
<tb@openbsd.org>
Tue, 23 Nov 2021 09:53:45 +0000
(09:53 +0000)
committer
tb
<tb@openbsd.org>
Tue, 23 Nov 2021 09:53:45 +0000
(09:53 +0000)
ok inoguchi jsing
lib/libcrypto/dh/dh_lib.c
patch
|
blob
|
history
diff --git
a/lib/libcrypto/dh/dh_lib.c
b/lib/libcrypto/dh/dh_lib.c
index
446bc65
..
a66ed1f
100644
(file)
--- a/
lib/libcrypto/dh/dh_lib.c
+++ b/
lib/libcrypto/dh/dh_lib.c
@@
-1,4
+1,4
@@
-/* $OpenBSD: dh_lib.c,v 1.3
2 2018/05/02 15:48:38
tb Exp $ */
+/* $OpenBSD: dh_lib.c,v 1.3
3 2021/11/23 09:53:45
tb Exp $ */
/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
* All rights reserved.
*
@@
-273,6
+273,7
@@
DH_set0_pqg(DH *dh, BIGNUM *p, BIGNUM *q, BIGNUM *g)
if (q != NULL) {
BN_free(dh->q);
dh->q = q;
+ dh->length = BN_num_bits(dh->q);
}
if (g != NULL) {
BN_free(dh->g);