Lines Matching refs:dh
38 #include <openssl/dh.h>
46 #include "dh.h"
117 kex->dh = PRIVSEP(choose_dh(min, nbits, max));
118 if (kex->dh == NULL) {
125 (r = sshpkt_put_bignum2(ssh, kex->dh->p)) != 0 ||
126 (r = sshpkt_put_bignum2(ssh, kex->dh->g)) != 0 ||
131 if ((r = dh_gen_key(kex->dh, kex->we_need * 8)) != 0)
189 DHparams_print_fp(stderr, kex->dh);
191 BN_print_fp(stderr, kex->dh->pub_key);
194 if (!dh_pub_is_valid(kex->dh, dh_client_pub)) {
200 klen = DH_size(kex->dh);
206 if ((kout = DH_compute_key(kbuf, dh_client_pub, kex->dh)) < 0 ||
227 kex->dh->p, kex->dh->g,
229 kex->dh->pub_key,
255 (r = sshpkt_put_bignum2(ssh, kex->dh->pub_key)) != 0 || /* f */
263 DH_free(kex->dh);
264 kex->dh = NULL;