privsep_commands.h 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. /*
  2. * WPA Supplicant - privilege separation commands
  3. * Copyright (c) 2007-2009, Jouni Malinen <j@w1.fi>
  4. *
  5. * This program is free software; you can redistribute it and/or modify
  6. * it under the terms of the GNU General Public License version 2 as
  7. * published by the Free Software Foundation.
  8. *
  9. * Alternatively, this software may be distributed under the terms of BSD
  10. * license.
  11. *
  12. * See README and COPYING for more details.
  13. */
  14. #ifndef PRIVSEP_COMMANDS_H
  15. #define PRIVSEP_COMMANDS_H
  16. enum privsep_cmd {
  17. PRIVSEP_CMD_REGISTER,
  18. PRIVSEP_CMD_UNREGISTER,
  19. PRIVSEP_CMD_SCAN,
  20. PRIVSEP_CMD_GET_SCAN_RESULTS,
  21. PRIVSEP_CMD_ASSOCIATE,
  22. PRIVSEP_CMD_GET_BSSID,
  23. PRIVSEP_CMD_GET_SSID,
  24. PRIVSEP_CMD_SET_KEY,
  25. PRIVSEP_CMD_GET_CAPA,
  26. PRIVSEP_CMD_L2_REGISTER,
  27. PRIVSEP_CMD_L2_UNREGISTER,
  28. PRIVSEP_CMD_L2_NOTIFY_AUTH_START,
  29. PRIVSEP_CMD_L2_SEND,
  30. PRIVSEP_CMD_SET_COUNTRY,
  31. };
  32. struct privsep_cmd_associate
  33. {
  34. u8 bssid[ETH_ALEN];
  35. u8 ssid[32];
  36. size_t ssid_len;
  37. int freq;
  38. int pairwise_suite;
  39. int group_suite;
  40. int key_mgmt_suite;
  41. int auth_alg;
  42. int mode;
  43. size_t wpa_ie_len;
  44. /* followed by wpa_ie_len bytes of wpa_ie */
  45. };
  46. struct privsep_cmd_set_key
  47. {
  48. int alg;
  49. u8 addr[ETH_ALEN];
  50. int key_idx;
  51. int set_tx;
  52. u8 seq[8];
  53. size_t seq_len;
  54. u8 key[32];
  55. size_t key_len;
  56. };
  57. enum privsep_event {
  58. PRIVSEP_EVENT_SCAN_RESULTS,
  59. PRIVSEP_EVENT_ASSOC,
  60. PRIVSEP_EVENT_DISASSOC,
  61. PRIVSEP_EVENT_ASSOCINFO,
  62. PRIVSEP_EVENT_MICHAEL_MIC_FAILURE,
  63. PRIVSEP_EVENT_INTERFACE_STATUS,
  64. PRIVSEP_EVENT_PMKID_CANDIDATE,
  65. PRIVSEP_EVENT_STKSTART,
  66. PRIVSEP_EVENT_FT_RESPONSE,
  67. PRIVSEP_EVENT_RX_EAPOL,
  68. PRIVSEP_EVENT_STA_RX,
  69. };
  70. #endif /* PRIVSEP_COMMANDS_H */