Home | History | Annotate | Download | only in common
      1 /*
      2  * WPA Supplicant - privilege separation commands
      3  * Copyright (c) 2007-2009, Jouni Malinen <j (at) w1.fi>
      4  *
      5  * This software may be distributed under the terms of the BSD license.
      6  * See README for more details.
      7  */
      8 
      9 #ifndef PRIVSEP_COMMANDS_H
     10 #define PRIVSEP_COMMANDS_H
     11 
     12 #include "common/ieee802_11_defs.h"
     13 
     14 enum privsep_cmd {
     15 	PRIVSEP_CMD_REGISTER,
     16 	PRIVSEP_CMD_UNREGISTER,
     17 	PRIVSEP_CMD_SCAN,
     18 	PRIVSEP_CMD_GET_SCAN_RESULTS,
     19 	PRIVSEP_CMD_ASSOCIATE,
     20 	PRIVSEP_CMD_GET_BSSID,
     21 	PRIVSEP_CMD_GET_SSID,
     22 	PRIVSEP_CMD_SET_KEY,
     23 	PRIVSEP_CMD_GET_CAPA,
     24 	PRIVSEP_CMD_L2_REGISTER,
     25 	PRIVSEP_CMD_L2_UNREGISTER,
     26 	PRIVSEP_CMD_L2_NOTIFY_AUTH_START,
     27 	PRIVSEP_CMD_L2_SEND,
     28 	PRIVSEP_CMD_SET_COUNTRY,
     29 };
     30 
     31 struct privsep_cmd_associate
     32 {
     33 	u8 bssid[ETH_ALEN];
     34 	u8 ssid[SSID_MAX_LEN];
     35 	size_t ssid_len;
     36 	int hwmode;
     37 	int freq;
     38 	int channel;
     39 	int pairwise_suite;
     40 	int group_suite;
     41 	int key_mgmt_suite;
     42 	int auth_alg;
     43 	int mode;
     44 	size_t wpa_ie_len;
     45 	/* followed by wpa_ie_len bytes of wpa_ie */
     46 };
     47 
     48 struct privsep_cmd_set_key
     49 {
     50 	int alg;
     51 	u8 addr[ETH_ALEN];
     52 	int key_idx;
     53 	int set_tx;
     54 	u8 seq[8];
     55 	size_t seq_len;
     56 	u8 key[32];
     57 	size_t key_len;
     58 };
     59 
     60 enum privsep_event {
     61 	PRIVSEP_EVENT_SCAN_RESULTS,
     62 	PRIVSEP_EVENT_ASSOC,
     63 	PRIVSEP_EVENT_DISASSOC,
     64 	PRIVSEP_EVENT_ASSOCINFO,
     65 	PRIVSEP_EVENT_MICHAEL_MIC_FAILURE,
     66 	PRIVSEP_EVENT_INTERFACE_STATUS,
     67 	PRIVSEP_EVENT_PMKID_CANDIDATE,
     68 	PRIVSEP_EVENT_STKSTART,
     69 	PRIVSEP_EVENT_FT_RESPONSE,
     70 	PRIVSEP_EVENT_RX_EAPOL,
     71 };
     72 
     73 #endif /* PRIVSEP_COMMANDS_H */
     74