dbus_new_handlers.h 9.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281
  1. /*
  2. * WPA Supplicant / dbus-based control interface
  3. * Copyright (c) 2006, Dan Williams <dcbw@redhat.com> and Red Hat, Inc.
  4. * Copyright (c) 2009-2010, Witold Sowa <witold.sowa@gmail.com>
  5. *
  6. * This program is free software; you can redistribute it and/or modify
  7. * it under the terms of the GNU General Public License version 2 as
  8. * published by the Free Software Foundation.
  9. *
  10. * Alternatively, this software may be distributed under the terms of BSD
  11. * license.
  12. *
  13. * See README and COPYING for more details.
  14. */
  15. #ifndef CTRL_IFACE_DBUS_NEW_HANDLERS_H
  16. #define CTRL_IFACE_DBUS_NEW_HANDLERS_H
  17. struct network_handler_args {
  18. struct wpa_supplicant *wpa_s;
  19. struct wpa_ssid *ssid;
  20. };
  21. struct bss_handler_args {
  22. struct wpa_supplicant *wpa_s;
  23. unsigned int id;
  24. };
  25. dbus_bool_t wpas_dbus_simple_property_getter(DBusMessageIter *iter,
  26. const int type,
  27. const void *val,
  28. DBusError *error);
  29. dbus_bool_t wpas_dbus_simple_property_setter(DBusMessageIter *iter,
  30. DBusError *error,
  31. const int type, void *val);
  32. dbus_bool_t wpas_dbus_simple_array_property_getter(DBusMessageIter *iter,
  33. const int type,
  34. const void *array,
  35. size_t array_len,
  36. DBusError *error);
  37. dbus_bool_t wpas_dbus_simple_array_array_property_getter(DBusMessageIter *iter,
  38. const int type,
  39. struct wpabuf **array,
  40. size_t array_len,
  41. DBusError *error);
  42. DBusMessage * wpas_dbus_handler_create_interface(DBusMessage *message,
  43. struct wpa_global *global);
  44. DBusMessage * wpas_dbus_handler_remove_interface(DBusMessage *message,
  45. struct wpa_global *global);
  46. DBusMessage * wpas_dbus_handler_get_interface(DBusMessage *message,
  47. struct wpa_global *global);
  48. dbus_bool_t wpas_dbus_getter_debug_level(DBusMessageIter *iter,
  49. DBusError *error,
  50. void *user_data);
  51. dbus_bool_t wpas_dbus_getter_debug_timestamp(DBusMessageIter *iter,
  52. DBusError *error,
  53. void *user_data);
  54. dbus_bool_t wpas_dbus_getter_debug_show_keys(DBusMessageIter *iter,
  55. DBusError *error,
  56. void *user_data);
  57. dbus_bool_t wpas_dbus_setter_debug_level(DBusMessageIter *iter,
  58. DBusError *error, void *user_data);
  59. dbus_bool_t wpas_dbus_setter_debug_timestamp(DBusMessageIter *iter,
  60. DBusError *error,
  61. void *user_data);
  62. dbus_bool_t wpas_dbus_setter_debug_show_keys(DBusMessageIter *iter,
  63. DBusError *error,
  64. void *user_data);
  65. dbus_bool_t wpas_dbus_getter_interfaces(DBusMessageIter *iter,
  66. DBusError *error,
  67. void *user_data);
  68. dbus_bool_t wpas_dbus_getter_eap_methods(DBusMessageIter *iter,
  69. DBusError *error, void *user_data);
  70. DBusMessage * wpas_dbus_handler_scan(DBusMessage *message,
  71. struct wpa_supplicant *wpa_s);
  72. DBusMessage * wpas_dbus_handler_disconnect(DBusMessage *message,
  73. struct wpa_supplicant *wpa_s);
  74. dbus_bool_t set_network_properties(struct wpa_supplicant *wpa_s,
  75. struct wpa_ssid *ssid,
  76. DBusMessageIter *iter,
  77. DBusError *error);
  78. DBusMessage * wpas_dbus_handler_add_network(DBusMessage *message,
  79. struct wpa_supplicant *wpa_s);
  80. DBusMessage * wpas_dbus_handler_remove_network(DBusMessage *message,
  81. struct wpa_supplicant *wpa_s);
  82. DBusMessage * wpas_dbus_handler_remove_all_networks(
  83. DBusMessage *message, struct wpa_supplicant *wpa_s);
  84. DBusMessage * wpas_dbus_handler_select_network(DBusMessage *message,
  85. struct wpa_supplicant *wpa_s);
  86. DBusMessage * wpas_dbus_handler_network_reply(DBusMessage *message,
  87. struct wpa_supplicant *wpa_s);
  88. DBusMessage * wpas_dbus_handler_add_blob(DBusMessage *message,
  89. struct wpa_supplicant *wpa_s);
  90. DBusMessage * wpas_dbus_handler_get_blob(DBusMessage *message,
  91. struct wpa_supplicant *wpa_s);
  92. DBusMessage * wpas_dbus_handler_remove_blob(DBusMessage *message,
  93. struct wpa_supplicant *wpa_s);
  94. DBusMessage * wpas_dbus_handler_flush_bss(DBusMessage *message,
  95. struct wpa_supplicant *wpa_s);
  96. DBusMessage * wpas_dbus_handler_autoscan(DBusMessage *message,
  97. struct wpa_supplicant *wpa_s);
  98. dbus_bool_t wpas_dbus_getter_capabilities(DBusMessageIter *iter,
  99. DBusError *error, void *user_data);
  100. dbus_bool_t wpas_dbus_getter_state(DBusMessageIter *iter, DBusError *error,
  101. void *user_data);
  102. dbus_bool_t wpas_dbus_getter_scanning(DBusMessageIter *iter, DBusError *error,
  103. void *user_data);
  104. dbus_bool_t wpas_dbus_getter_ap_scan(DBusMessageIter *iter, DBusError *error,
  105. void *user_data);
  106. dbus_bool_t wpas_dbus_setter_ap_scan(DBusMessageIter *iter, DBusError *error,
  107. void *user_data);
  108. dbus_bool_t wpas_dbus_getter_fast_reauth(DBusMessageIter *iter,
  109. DBusError *error,
  110. void *user_data);
  111. dbus_bool_t wpas_dbus_setter_fast_reauth(DBusMessageIter *iter,
  112. DBusError *error,
  113. void *user_data);
  114. dbus_bool_t wpas_dbus_getter_disconnect_reason(DBusMessageIter *iter,
  115. DBusError *error,
  116. void *user_data);
  117. dbus_bool_t wpas_dbus_getter_bss_expire_age(DBusMessageIter *iter,
  118. DBusError *error, void *user_data);
  119. dbus_bool_t wpas_dbus_setter_bss_expire_age(DBusMessageIter *iter,
  120. DBusError *error,
  121. void *user_data);
  122. dbus_bool_t wpas_dbus_getter_bss_expire_count(DBusMessageIter *iter,
  123. DBusError *error,
  124. void *user_data);
  125. dbus_bool_t wpas_dbus_setter_bss_expire_count(DBusMessageIter *iter,
  126. DBusError *error,
  127. void *user_data);
  128. dbus_bool_t wpas_dbus_getter_country(DBusMessageIter *iter, DBusError *error,
  129. void *user_data);
  130. dbus_bool_t wpas_dbus_setter_country(DBusMessageIter *iter, DBusError *error,
  131. void *user_data);
  132. dbus_bool_t wpas_dbus_getter_scan_interval(DBusMessageIter *iter,
  133. DBusError *error,
  134. void *user_data);
  135. dbus_bool_t wpas_dbus_setter_scan_interval(DBusMessageIter *iter,
  136. DBusError *error,
  137. void *user_data);
  138. dbus_bool_t wpas_dbus_getter_ifname(DBusMessageIter *iter, DBusError *error,
  139. void *user_data);
  140. dbus_bool_t wpas_dbus_getter_driver(DBusMessageIter *iter, DBusError *error,
  141. void *user_data);
  142. dbus_bool_t wpas_dbus_getter_bridge_ifname(DBusMessageIter *iter,
  143. DBusError *error,
  144. void *user_data);
  145. dbus_bool_t wpas_dbus_getter_current_bss(DBusMessageIter *iter,
  146. DBusError *error,
  147. void *user_data);
  148. dbus_bool_t wpas_dbus_getter_current_network(DBusMessageIter *iter,
  149. DBusError *error,
  150. void *user_data);
  151. dbus_bool_t wpas_dbus_getter_current_auth_mode(DBusMessageIter *iter,
  152. DBusError *error,
  153. void *user_data);
  154. dbus_bool_t wpas_dbus_getter_bsss(DBusMessageIter *iter, DBusError *error,
  155. void *user_data);
  156. dbus_bool_t wpas_dbus_getter_networks(DBusMessageIter *iter, DBusError *error,
  157. void *user_data);
  158. dbus_bool_t wpas_dbus_getter_blobs(DBusMessageIter *iter, DBusError *error,
  159. void *user_data);
  160. dbus_bool_t wpas_dbus_getter_bss_bssid(DBusMessageIter *iter, DBusError *error,
  161. void *user_data);
  162. dbus_bool_t wpas_dbus_getter_bss_ssid(DBusMessageIter *iter, DBusError *error,
  163. void *user_data);
  164. dbus_bool_t wpas_dbus_getter_bss_privacy(DBusMessageIter *iter,
  165. DBusError *error, void *user_data);
  166. dbus_bool_t wpas_dbus_getter_bss_mode(DBusMessageIter *iter, DBusError *error,
  167. void *user_data);
  168. dbus_bool_t wpas_dbus_getter_bss_signal(DBusMessageIter *iter,
  169. DBusError *error, void *user_data);
  170. dbus_bool_t wpas_dbus_getter_bss_frequency(DBusMessageIter *iter,
  171. DBusError *error, void *user_data);
  172. dbus_bool_t wpas_dbus_getter_bss_rates(DBusMessageIter *iter,
  173. DBusError *error, void *user_data);
  174. dbus_bool_t wpas_dbus_getter_bss_wpa(DBusMessageIter *iter, DBusError *error,
  175. void *user_data);
  176. dbus_bool_t wpas_dbus_getter_bss_rsn(DBusMessageIter *iter, DBusError *error,
  177. void *user_data);
  178. dbus_bool_t wpas_dbus_getter_bss_ies(DBusMessageIter *iter, DBusError *error,
  179. void *user_data);
  180. dbus_bool_t wpas_dbus_getter_enabled(DBusMessageIter *iter, DBusError *error,
  181. void *user_data);
  182. dbus_bool_t wpas_dbus_setter_enabled(DBusMessageIter *iter, DBusError *error,
  183. void *user_data);
  184. dbus_bool_t wpas_dbus_getter_network_properties(DBusMessageIter *iter,
  185. DBusError *error,
  186. void *user_data);
  187. dbus_bool_t wpas_dbus_setter_network_properties(DBusMessageIter *iter,
  188. DBusError *error,
  189. void *user_data);
  190. DBusMessage * wpas_dbus_handler_wps_start(DBusMessage *message,
  191. struct wpa_supplicant *wpa_s);
  192. dbus_bool_t wpas_dbus_getter_process_credentials(DBusMessageIter *iter,
  193. DBusError *error, void *user_data);
  194. dbus_bool_t wpas_dbus_setter_process_credentials(DBusMessageIter *iter,
  195. DBusError *error,
  196. void *user_data);
  197. DBusMessage * wpas_dbus_error_invalid_args(DBusMessage *message,
  198. const char *arg);
  199. DBusMessage * wpas_dbus_error_unknown_error(DBusMessage *message,
  200. const char *arg);
  201. DBusMessage * wpas_dbus_handler_subscribe_preq(
  202. DBusMessage *message, struct wpa_supplicant *wpa_s);
  203. DBusMessage * wpas_dbus_handler_unsubscribe_preq(
  204. DBusMessage *message, struct wpa_supplicant *wpa_s);
  205. #endif /* CTRL_IFACE_DBUS_HANDLERS_NEW_H */