File: gnutls_pubkey_get_openpgp_key_id

package info (click to toggle)
gnutls28 3.3.8-6
  • links: PTS, VCS
  • area: main
  • in suites: jessie-kfreebsd
  • size: 51,388 kB
  • sloc: ansic: 191,357; asm: 60,370; sh: 21,457; makefile: 5,257; lisp: 1,531; yacc: 1,254; cpp: 1,155; perl: 199; sed: 16
file content (32 lines) | stat: -rw-r--r-- 1,154 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32




@deftypefun {int} {gnutls_pubkey_get_openpgp_key_id} (gnutls_pubkey_t @var{key}, unsigned int @var{flags}, unsigned char * @var{output_data}, size_t * @var{output_data_size}, unsigned int * @var{subkey})
@var{key}: Holds the public key

@var{flags}: should be 0 or @code{GNUTLS_PUBKEY_GET_OPENPGP_FINGERPRINT} 

@var{output_data}: will contain the key ID

@var{output_data_size}: holds the size of output_data (and will be
replaced by the actual size of parameters)

@var{subkey}: Will be non zero if the key ID corresponds to a subkey

This function returns the OpenPGP key ID of the corresponding key.
The key is a unique ID that depends on the public
key parameters. 

If the flag @code{GNUTLS_PUBKEY_GET_OPENPGP_FINGERPRINT}  is specified
this function returns the fingerprint of the master key.

If the buffer provided is not long enough to hold the output, then
*output_data_size is updated and @code{GNUTLS_E_SHORT_MEMORY_BUFFER}  will
be returned.  The output is @code{GNUTLS_OPENPGP_KEYID_SIZE}  bytes long.

@strong{Returns:} In case of failure a negative error code will be
returned, and 0 on success.

@strong{Since:} 3.0
@end deftypefun