1gnutls_privkey_import_ext3(3)       gnutls       gnutls_privkey_import_ext3(3)
2
3
4

NAME

6       gnutls_privkey_import_ext3 - API function
7

SYNOPSIS

9       #include <gnutls/abstract.h>
10
11       int  gnutls_privkey_import_ext3(gnutls_privkey_t pkey, void * userdata,
12       gnutls_privkey_sign_func   sign_fn,   gnutls_privkey_decrypt_func   de‐
13       crypt_fn,             gnutls_privkey_deinit_func             deinit_fn,
14       gnutls_privkey_info_func info_fn, unsigned int flags);
15

ARGUMENTS

17       gnutls_privkey_t pkey
18                   The private key
19
20       void * userdata
21                   private data to be provided to the callbacks
22
23       gnutls_privkey_sign_func sign_fn
24                   callback for signature operations
25
26       gnutls_privkey_decrypt_func decrypt_fn
27                   callback for decryption operations
28
29       gnutls_privkey_deinit_func deinit_fn
30                   a deinitialization function
31
32       gnutls_privkey_info_func info_fn
33                   returns info about the public key algorithm (should not  be
34                   NULL)
35
36       unsigned int flags
37                   Flags for the import
38

DESCRIPTION

40       This   function   will   associate   the   given   callbacks  with  the
41       gnutls_privkey_t type. At least  one  of  the  two  callbacks  must  be
42       non-null.  If a deinitialization function is provided then flags is as‐
43       sumed to contain GNUTLS_PRIVKEY_IMPORT_AUTO_RELEASE.
44
45       Note that the signing function is supposed to "raw"  sign  data,  i.e.,
46       without  any  hashing  or  preprocessing. In case of RSA the DigestInfo
47       will be provided, and the signing function is expected to do the PKCS 1
48       1.5 padding and the exponentiation.
49
50       The   info_fn  must  provide information on the algorithms supported by
51       this    private    key,    and     should     support     the     flags
52       GNUTLS_PRIVKEY_INFO_PK_ALGO  and GNUTLS_PRIVKEY_INFO_SIGN_ALGO. It must
53       return -1 on unknown flags.
54

RETURNS

56       On success, GNUTLS_E_SUCCESS (0) is returned, otherwise a negative  er‐
57       ror value.
58

SINCE

60       3.4.0
61

REPORTING BUGS

63       Report bugs to <bugs@gnutls.org>.
64       Home page: https://www.gnutls.org
65
66
68       Copyright © 2001- Free Software Foundation, Inc., and others.
69       Copying  and  distribution  of this file, with or without modification,
70       are permitted in any medium without royalty provided the copyright  no‐
71       tice and this notice are preserved.
72

SEE ALSO

74       The  full  documentation  for gnutls is maintained as a Texinfo manual.
75       If the /usr/share/doc/gnutls/ directory does not contain the HTML  form
76       visit
77
78       https://www.gnutls.org/manual/
79
80gnutls                               3.7.6       gnutls_privkey_import_ext3(3)
Impressum