gnutls_dh_get_pubkey3
Api function
Arguments
- gnutls_session_t session
-
is a gnutls session
- gnutls_datum_t * raw_key
-
will hold the public key.
Overview
This function will return the peer's public key used in the last Diffie-Hellman key exchange. This function should be used for both anonymous and ephemeral Diffie-Hellman. The output parameters must be freed with gnutls_free().
Note, that public key is exported as non-negative integer and may include a leading zero byte.
Returns
On success, GNUTLS_E_SUCCESS (0) is returned, otherwise an error code is returned.
History
- Arch Linux 2026-11-01: the text shown here
- Debian 13 (Trixie)
- Debian 12 (Bookworm)
- Debian 11 (Bullseye)
- Debian 10 (Buster)
- Debian 9 (Stretch)
- Debian 8 (Jessie)
- Debian 6.0 (Squeeze)
- Debian 5.0 (Lenny)
- Debian 4.0 (Etch)