TLSv1 credentials. More...
Go to the source code of this file.
Data Structures | |
struct | tlsv1_credentials |
Functions | |
struct tlsv1_credentials * | tlsv1_cred_alloc (void) |
void | tlsv1_cred_free (struct tlsv1_credentials *cred) |
int | tlsv1_set_ca_cert (struct tlsv1_credentials *cred, const char *cert, const u8 *cert_blob, size_t cert_blob_len, const char *path) |
Set trusted CA certificate(s). | |
int | tlsv1_set_cert (struct tlsv1_credentials *cred, const char *cert, const u8 *cert_blob, size_t cert_blob_len) |
Set certificate. | |
int | tlsv1_set_private_key (struct tlsv1_credentials *cred, const char *private_key, const char *private_key_passwd, const u8 *private_key_blob, size_t private_key_blob_len) |
Set private key. | |
int | tlsv1_set_dhparams (struct tlsv1_credentials *cred, const char *dh_file, const u8 *dh_blob, size_t dh_blob_len) |
Set Diffie-Hellman parameters. |
TLSv1 credentials.
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License version 2 as published by the Free Software Foundation.
Alternatively, this software may be distributed under the terms of BSD license.
See README and COPYING for more details.
Definition in file tlsv1_cred.h.
int tlsv1_set_ca_cert | ( | struct tlsv1_credentials * | cred, | |
const char * | cert, | |||
const u8 * | cert_blob, | |||
size_t | cert_blob_len, | |||
const char * | path | |||
) |
Set trusted CA certificate(s).
cred | TLSv1 credentials from tlsv1_cred_alloc() | |
cert | File or reference name for X.509 certificate in PEM or DER format | |
cert_blob | cert as inlined data or NULL if not used | |
cert_blob_len | ca_cert_blob length | |
path | Path to CA certificates (not yet supported) |
Definition at line 185 of file tlsv1_cred.c.
int tlsv1_set_cert | ( | struct tlsv1_credentials * | cred, | |
const char * | cert, | |||
const u8 * | cert_blob, | |||
size_t | cert_blob_len | |||
) |
Set certificate.
cred | TLSv1 credentials from tlsv1_cred_alloc() | |
cert | File or reference name for X.509 certificate in PEM or DER format | |
cert_blob | cert as inlined data or NULL if not used | |
cert_blob_len | cert_blob length |
Definition at line 213 of file tlsv1_cred.c.
int tlsv1_set_dhparams | ( | struct tlsv1_credentials * | cred, | |
const char * | dh_file, | |||
const u8 * | dh_blob, | |||
size_t | dh_blob_len | |||
) |
Set Diffie-Hellman parameters.
cred | TLSv1 credentials from tlsv1_cred_alloc() | |
dh_file | File or reference name for the DH params in PEM or DER format | |
dh_blob | DH params as inlined data or NULL if not used | |
dh_blob_len | dh_blob length |
Definition at line 474 of file tlsv1_cred.c.
int tlsv1_set_private_key | ( | struct tlsv1_credentials * | cred, | |
const char * | private_key, | |||
const char * | private_key_passwd, | |||
const u8 * | private_key_blob, | |||
size_t | private_key_blob_len | |||
) |
Set private key.
cred | TLSv1 credentials from tlsv1_cred_alloc() | |
private_key | File or reference name for the key in PEM or DER format | |
private_key_passwd | Passphrase for decrypted private key, NULL if no passphrase is used. | |
private_key_blob | private_key as inlined data or NULL if not used | |
private_key_blob_len | private_key_blob length |
Definition at line 308 of file tlsv1_cred.c.