diff options
author | Nikos Mavrogiannopoulos <nmav@redhat.com> | 2017-08-07 16:23:29 +0200 |
---|---|---|
committer | Nikos Mavrogiannopoulos <nmav@redhat.com> | 2017-08-08 08:30:01 +0200 |
commit | 2c5129f360384cc74aa94290c4edd1463d3e558f (patch) | |
tree | 50aad16304755e84d2cf8b4ffd73384e1d9f74b6 /lib/privkey.c | |
parent | d9a3e84f99f90b21d79a5874a0f117a3a2c524b7 (diff) | |
download | gnutls-2c5129f360384cc74aa94290c4edd1463d3e558f.tar.gz |
gnutls_pk_params_st: separate flags/qbits and curve
Previously we were using the field flags to store the
size of q in case of GNUTLS_PK_DH, some key generation flags
in case of GNUTLS_PK_RSA, and the curve in case of elliptic
curve key. Separate this into multiple fields to reduce
confusion on the field.
Signed-off-by: Nikos Mavrogiannopoulos <nmav@redhat.com>
Diffstat (limited to 'lib/privkey.c')
-rw-r--r-- | lib/privkey.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/privkey.c b/lib/privkey.c index b67f8e18ce..8f45a9ce84 100644 --- a/lib/privkey.c +++ b/lib/privkey.c @@ -153,7 +153,9 @@ privkey_to_pubkey(gnutls_pk_algorithm_t pk, int ret; pub->algo = priv->algo; - pub->flags = priv->flags; + pub->pkflags = priv->pkflags; + pub->curve = priv->curve; + pub->qbits = priv->qbits; memcpy(&pub->spki, &priv->spki, sizeof(gnutls_x509_spki_st)); switch (pk) { |