wpa_supplicant / hostapd  2.5
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
dh_groups.h
Go to the documentation of this file.
1 
5 #ifndef DH_GROUPS_H
6 #define DH_GROUPS_H
7 
8 struct dh_group {
9  int id;
10  const u8 *generator;
11  size_t generator_len;
12  const u8 *prime;
13  size_t prime_len;
14  const u8 *order;
15  size_t order_len;
16  unsigned int safe_prime:1;
17 };
18 
19 const struct dh_group * dh_groups_get(int id);
20 struct wpabuf * dh_init(const struct dh_group *dh, struct wpabuf **priv);
21 struct wpabuf * dh_derive_shared(const struct wpabuf *peer_public,
22  const struct wpabuf *own_private,
23  const struct dh_group *dh);
24 
25 #endif /* DH_GROUPS_H */
Definition: wpabuf.h:16
Definition: dh_groups.h:8
struct wpabuf * dh_init(const struct dh_group *dh, struct wpabuf **priv)
Initialize Diffie-Hellman handshake.
Definition: dh_groups.c:1189
struct wpabuf * dh_derive_shared(const struct wpabuf *peer_public, const struct wpabuf *own_private, const struct dh_group *dh)
Derive shared Diffie-Hellman key.
Definition: dh_groups.c:1241