Blame doc/tpm-api.texi

Packit 549fdc
Packit 549fdc
@subheading gnutls_tpm_get_registered
Packit 549fdc
@anchor{gnutls_tpm_get_registered}
Packit 549fdc
@deftypefun {int} {gnutls_tpm_get_registered} (gnutls_tpm_key_list_t * @var{list})
Packit 549fdc
@var{list}: a list to store the keys
Packit 549fdc
Packit 549fdc
This function will get a list of stored keys in the TPM. The uuid
Packit 549fdc
of those keys
Packit 549fdc
Packit 549fdc
@strong{Returns:} On success, @code{GNUTLS_E_SUCCESS}  (0) is returned, otherwise a
Packit 549fdc
negative error value.
Packit 549fdc
Packit 549fdc
@strong{Since:} 3.1.0
Packit 549fdc
@end deftypefun
Packit 549fdc
Packit 549fdc
@subheading gnutls_tpm_key_list_deinit
Packit 549fdc
@anchor{gnutls_tpm_key_list_deinit}
Packit 549fdc
@deftypefun {void} {gnutls_tpm_key_list_deinit} (gnutls_tpm_key_list_t @var{list})
Packit 549fdc
@var{list}: a list of the keys
Packit 549fdc
Packit 549fdc
This function will deinitialize the list of stored keys in the TPM.
Packit 549fdc
Packit 549fdc
@strong{Since:} 3.1.0
Packit 549fdc
@end deftypefun
Packit 549fdc
Packit 549fdc
@subheading gnutls_tpm_key_list_get_url
Packit 549fdc
@anchor{gnutls_tpm_key_list_get_url}
Packit 549fdc
@deftypefun {int} {gnutls_tpm_key_list_get_url} (gnutls_tpm_key_list_t @var{list}, unsigned int @var{idx}, char ** @var{url}, unsigned int @var{flags})
Packit 549fdc
@var{list}: a list of the keys
Packit 549fdc
Packit 549fdc
@var{idx}: The index of the key (starting from zero)
Packit 549fdc
Packit 549fdc
@var{url}: The URL to be returned
Packit 549fdc
Packit 549fdc
@var{flags}: should be zero
Packit 549fdc
Packit 549fdc
This function will return for each given index a URL of
Packit 549fdc
the corresponding key.
Packit 549fdc
If the provided index is out of bounds then @code{GNUTLS_E_REQUESTED_DATA_NOT_AVAILABLE} 
Packit 549fdc
is returned.
Packit 549fdc
Packit 549fdc
@strong{Returns:} On success, @code{GNUTLS_E_SUCCESS}  (0) is returned, otherwise a
Packit 549fdc
negative error value.
Packit 549fdc
Packit 549fdc
@strong{Since:} 3.1.0
Packit 549fdc
@end deftypefun
Packit 549fdc
Packit 549fdc
@subheading gnutls_tpm_privkey_delete
Packit 549fdc
@anchor{gnutls_tpm_privkey_delete}
Packit 549fdc
@deftypefun {int} {gnutls_tpm_privkey_delete} (const char * @var{url}, const char * @var{srk_password})
Packit 549fdc
@var{url}: the URL describing the key
Packit 549fdc
Packit 549fdc
@var{srk_password}: a password for the SRK key
Packit 549fdc
Packit 549fdc
This function will unregister the private key from the TPM
Packit 549fdc
chip. 
Packit 549fdc
Packit 549fdc
@strong{Returns:} On success, @code{GNUTLS_E_SUCCESS}  (0) is returned, otherwise a
Packit 549fdc
negative error value.
Packit 549fdc
Packit 549fdc
@strong{Since:} 3.1.0
Packit 549fdc
@end deftypefun
Packit 549fdc
Packit 549fdc
@subheading gnutls_tpm_privkey_generate
Packit 549fdc
@anchor{gnutls_tpm_privkey_generate}
Packit 549fdc
@deftypefun {int} {gnutls_tpm_privkey_generate} (gnutls_pk_algorithm_t @var{pk}, unsigned int @var{bits}, const char * @var{srk_password}, const char * @var{key_password}, gnutls_tpmkey_fmt_t @var{format}, gnutls_x509_crt_fmt_t @var{pub_format}, gnutls_datum_t * @var{privkey}, gnutls_datum_t * @var{pubkey}, unsigned int @var{flags})
Packit 549fdc
@var{pk}: the public key algorithm
Packit 549fdc
Packit 549fdc
@var{bits}: the security bits
Packit 549fdc
Packit 549fdc
@var{srk_password}: a password to protect the exported key (optional)
Packit 549fdc
Packit 549fdc
@var{key_password}: the password for the TPM (optional)
Packit 549fdc
Packit 549fdc
@var{format}: the format of the private key
Packit 549fdc
Packit 549fdc
@var{pub_format}: the format of the public key
Packit 549fdc
Packit 549fdc
@var{privkey}: the generated key
Packit 549fdc
Packit 549fdc
@var{pubkey}: the corresponding public key (may be null)
Packit 549fdc
Packit 549fdc
@var{flags}: should be a list of GNUTLS_TPM_* flags
Packit 549fdc
Packit 549fdc
This function will generate a private key in the TPM
Packit 549fdc
chip. The private key will be generated within the chip
Packit 549fdc
and will be exported in a wrapped with TPM's master key
Packit 549fdc
form. Furthermore the wrapped key can be protected with
Packit 549fdc
the provided  @code{password} .
Packit 549fdc
Packit 549fdc
Note that bits in TPM is quantized value. If the input value
Packit 549fdc
is not one of the allowed values, then it will be quantized to
Packit 549fdc
one of 512, 1024, 2048, 4096, 8192 and 16384.
Packit 549fdc
Packit 549fdc
Allowed flags are:
Packit 549fdc
Packit 549fdc
@strong{Returns:} On success, @code{GNUTLS_E_SUCCESS}  (0) is returned, otherwise a
Packit 549fdc
negative error value.
Packit 549fdc
Packit 549fdc
@strong{Since:} 3.1.0
Packit 549fdc
@end deftypefun
Packit 549fdc