gnutls_privkey_import_ext3
Api function
Arguments
- gnutls_privkey_t pkey
-
The private key
- gnutls_pk_algorithm_t pk
-
The public key algorithm
- void * userdata
-
private data to be provided to the callbacks
- gnutls_privkey_sign_func sign_func
-
callback for signature operations
- gnutls_privkey_decrypt_func decrypt_func
-
callback for decryption operations
- unsigned int flags
-
Flags for the import
Overview
This function will associate the given callbacks with the gnutls_privkey_t type. At least one of the two callbacks must be non-null.
Note that the signing function is supposed to "raw" sign data, i.e., without any hashing or preprocessing. In case of RSA the DigestInfo will be provided, and the signing function is expected to do the PKCS 1 1.5 padding and the exponentiation.
See also gnutls_privkey_import_ext3().
Returns
On success, GNUTLS_E_SUCCESS (0) is returned, otherwise a negative error value.
Since
3.0
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)