wpa_supplicant / hostapd  2.5
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
tlsv1_cred.h
Go to the documentation of this file.
1 
5 #ifndef TLSV1_CRED_H
6 #define TLSV1_CRED_H
7 
9  struct x509_certificate *trusted_certs;
10  struct x509_certificate *cert;
11  struct crypto_private_key *key;
12 
13  /* Diffie-Hellman parameters */
14  u8 *dh_p; /* prime */
15  size_t dh_p_len;
16  u8 *dh_g; /* generator */
17  size_t dh_g_len;
18 };
19 
20 
21 struct tlsv1_credentials * tlsv1_cred_alloc(void);
22 void tlsv1_cred_free(struct tlsv1_credentials *cred);
23 int tlsv1_set_ca_cert(struct tlsv1_credentials *cred, const char *cert,
24  const u8 *cert_blob, size_t cert_blob_len,
25  const char *path);
26 int tlsv1_set_cert(struct tlsv1_credentials *cred, const char *cert,
27  const u8 *cert_blob, size_t cert_blob_len);
29  const char *private_key,
30  const char *private_key_passwd,
31  const u8 *private_key_blob,
32  size_t private_key_blob_len);
33 int tlsv1_set_dhparams(struct tlsv1_credentials *cred, const char *dh_file,
34  const u8 *dh_blob, size_t dh_blob_len);
35 
36 #endif /* TLSV1_CRED_H */
Definition: tlsv1_cred.h:8
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)
Definition: tlsv1_cred.c:185
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.
Definition: tlsv1_cred.c:313
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.
Definition: tlsv1_cred.c:478
Definition: x509v3.h:44
int tlsv1_set_cert(struct tlsv1_credentials *cred, const char *cert, const u8 *cert_blob, size_t cert_blob_len)
Set certificate.
Definition: tlsv1_cred.c:212
Definition: crypto_libtomcrypt.c:407