Module Name: src
Committed By: christos
Date: Wed Feb 7 13:16:25 UTC 2018
Modified Files:
src/crypto/external/bsd/openssl.old/dist/crypto/dh: dh.h
Log Message:
add set0_key needed by racoon
To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 \
src/crypto/external/bsd/openssl.old/dist/crypto/dh/dh.h
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/crypto/external/bsd/openssl.old/dist/crypto/dh/dh.h
diff -u src/crypto/external/bsd/openssl.old/dist/crypto/dh/dh.h:1.7 src/crypto/external/bsd/openssl.old/dist/crypto/dh/dh.h:1.8
--- src/crypto/external/bsd/openssl.old/dist/crypto/dh/dh.h:1.7 Tue Feb 6 14:58:30 2018
+++ src/crypto/external/bsd/openssl.old/dist/crypto/dh/dh.h Wed Feb 7 08:16:25 2018
@@ -397,6 +397,20 @@ DH_get0_key(const DH *dh, const BIGNUM *
*priv_key = dh->priv_key;
}
+static inline int
+DH_set0_key(DH *dh, BIGNUM *pub_key, BIGNUM *priv_key)
+{
+ if (pub_key) {
+ BN_free(dh->pub_key);
+ dh->pub_key = pub_key;
+ }
+ if (priv_key) {
+ BN_free(dh->priv_key);
+ dh->priv_key = priv_key;
+ }
+ return 1;
+}
+
static inline void
DH_get0_pqg(const DH *dh, const BIGNUM **p, const BIGNUM **q,
const BIGNUM **g)