Functions | Variables
wps_er.c File Reference
#include "includes.h"
#include "common.h"
#include "base64.h"
#include "uuid.h"
#include "eloop.h"
#include "httpread.h"
#include "http_client.h"
#include "http_server.h"
#include "upnp_xml.h"
#include "wps_i.h"
#include "wps_upnp.h"
#include "wps_upnp_i.h"
#include "wps_er.h"
Include dependency graph for wps_er.c:

Go to the source code of this file.

Functions

static void http_put_date (struct wpabuf *buf)
static struct wps_er_stawps_er_add_sta_data (struct wps_er_ap *ap, const u8 *addr, struct wps_parse_attr *attr, int probe_req)
void wps_er_ap_add (struct wps_er *er, const u8 *uuid, struct in_addr *addr, const char *location, int max_age)
static void wps_er_ap_event (struct wps_context *wps, struct wps_er_ap *ap, enum wps_event event)
static void wps_er_ap_free (struct wps_er_ap *ap)
static struct wps_er_apwps_er_ap_get (struct wps_er *er, struct in_addr *addr, const u8 *uuid)
static struct wps_er_apwps_er_ap_get_id (struct wps_er *er, unsigned int id)
static void wps_er_ap_get_m1 (struct wps_er_ap *ap, struct wpabuf *m1)
static void wps_er_ap_learn (struct wps_er_ap *ap, const char *dev_info)
static void wps_er_ap_learn_m1 (struct wps_er_ap *ap, struct wpabuf *m1)
static void wps_er_ap_process (struct wps_er_ap *ap, struct wpabuf *msg)
static void wps_er_ap_put_message (struct wps_er_ap *ap, const struct wpabuf *msg)
void wps_er_ap_remove (struct wps_er *er, struct in_addr *addr)
static void wps_er_ap_remove_all (struct wps_er *er)
static void wps_er_ap_remove_entry (struct wps_er *er, struct wps_er_ap *ap)
static void wps_er_ap_settings_cb (void *ctx, const struct wps_credential *cred)
static void wps_er_ap_timeout (void *eloop_data, void *user_ctx)
static void wps_er_ap_unsubscribe (struct wps_er *er, struct wps_er_ap *ap)
static void wps_er_ap_unsubscribed (struct wps_er *er, struct wps_er_ap *ap)
static int wps_er_build_dev_password_id (struct wpabuf *msg, u16 dev_passwd_id)
static int wps_er_build_sel_reg_config_methods (struct wpabuf *msg, u16 sel_reg_config_methods)
static int wps_er_build_selected_registrar (struct wpabuf *msg, int sel_reg)
void wps_er_deinit (struct wps_er *er, void(*cb)(void *ctx), void *ctx)
static void wps_er_deinit_finish (void *eloop_data, void *user_ctx)
static void wps_er_get_device_info (struct wps_er_ap *ap)
static int wps_er_get_sid (struct wps_er_ap *ap, char *sid)
static void wps_er_http_dev_desc_cb (void *ctx, struct http_client *c, enum http_client_event event)
static void wps_er_http_event (struct wps_er *er, struct http_request *req, unsigned int ap_id)
static void wps_er_http_get_dev_info_cb (void *ctx, struct http_client *c, enum http_client_event event)
static void wps_er_http_notify (struct wps_er *er, struct http_request *req)
static void wps_er_http_put_message_cb (void *ctx, struct http_client *c, enum http_client_event event)
static void wps_er_http_put_wlan_response_cb (void *ctx, struct http_client *c, enum http_client_event event)
static void wps_er_http_req (void *ctx, struct http_request *req)
static void wps_er_http_resp_not_found (struct http_request *req)
static void wps_er_http_resp_ok (struct http_request *req)
static void wps_er_http_set_sel_reg_cb (void *ctx, struct http_client *c, enum http_client_event event)
static void wps_er_http_subscribe_cb (void *ctx, struct http_client *c, enum http_client_event event)
static void wps_er_http_unsubscribe_cb (void *ctx, struct http_client *c, enum http_client_event event)
struct wps_erwps_er_init (struct wps_context *wps, const char *ifname)
int wps_er_learn (struct wps_er *er, const u8 *uuid, const u8 *pin, size_t pin_len)
static void wps_er_parse_device_description (struct wps_er_ap *ap, struct wpabuf *reply)
int wps_er_pbc (struct wps_er *er, const u8 *uuid)
static void wps_er_process_wlanevent (struct wps_er_ap *ap, struct wpabuf *event)
static void wps_er_process_wlanevent_eap (struct wps_er_ap *ap, const u8 *addr, struct wpabuf *msg)
static void wps_er_process_wlanevent_probe_req (struct wps_er_ap *ap, const u8 *addr, struct wpabuf *msg)
void wps_er_refresh (struct wps_er *er)
static int wps_er_send_get_device_info (struct wps_er_ap *ap, void(*m1_handler)(struct wps_er_ap *ap, struct wpabuf *m1))
static void wps_er_send_set_sel_reg (struct wps_er_ap *ap, struct wpabuf *msg)
void wps_er_set_sel_reg (struct wps_er *er, int sel_reg, u16 dev_passwd_id, u16 sel_reg_config_methods)
static void wps_er_soap_end (struct wpabuf *buf, const char *name, char *len_ptr, char *body_ptr)
static struct wpabufwps_er_soap_hdr (const struct wpabuf *msg, const char *name, const char *arg_name, const char *path, const struct sockaddr_in *dst, char **len_ptr, char **body_ptr)
static void wps_er_sta_event (struct wps_context *wps, struct wps_er_sta *sta, enum wps_event event)
static void wps_er_sta_free (struct wps_er_sta *sta)
static struct wps_er_stawps_er_sta_get (struct wps_er_ap *ap, const u8 *addr)
static void wps_er_sta_process (struct wps_er_sta *sta, struct wpabuf *msg, enum wsc_op_code op_code)
static void wps_er_sta_remove_all (struct wps_er_ap *ap)
static void wps_er_sta_send_msg (struct wps_er_sta *sta, struct wpabuf *msg)
static void wps_er_sta_start (struct wps_er_sta *sta, struct wpabuf *msg)
static void wps_er_sta_timeout (void *eloop_data, void *user_ctx)
static void wps_er_subscribe (struct wps_er_ap *ap)

Variables

static const char * soap_postfix = "</s:Body>\n</s:Envelope>\n"
static const char * soap_prefix = "<s:Body>\n"
static const char * urn_wfawlanconfig = "urn:schemas-wifialliance-org:service:WFAWLANConfig:1"

Function Documentation

static void http_put_date ( struct wpabuf buf) [static]

Definition at line 590 of file wps_er.c.

static struct wps_er_sta* wps_er_add_sta_data ( struct wps_er_ap ap,
const u8 *  addr,
struct wps_parse_attr attr,
int  probe_req 
) [static, read]

Definition at line 646 of file wps_er.c.

void wps_er_ap_add ( struct wps_er er,
const u8 *  uuid,
struct in_addr *  addr,
const char *  location,
int  max_age 
)

Definition at line 531 of file wps_er.c.

static void wps_er_ap_event ( struct wps_context wps,
struct wps_er_ap ap,
enum wps_event  event 
) [static]

Definition at line 125 of file wps_er.c.

static void wps_er_ap_free ( struct wps_er_ap ap) [static]

Definition at line 152 of file wps_er.c.

static struct wps_er_ap* wps_er_ap_get ( struct wps_er er,
struct in_addr *  addr,
const u8 *  uuid 
) [static, read]

Definition at line 100 of file wps_er.c.

static struct wps_er_ap* wps_er_ap_get_id ( struct wps_er er,
unsigned int  id 
) [static, read]

Definition at line 114 of file wps_er.c.

static void wps_er_ap_get_m1 ( struct wps_er_ap ap,
struct wpabuf m1 
) [static]

Definition at line 416 of file wps_er.c.

static void wps_er_ap_learn ( struct wps_er_ap ap,
const char *  dev_info 
) [static]

Definition at line 1522 of file wps_er.c.

static void wps_er_ap_learn_m1 ( struct wps_er_ap ap,
struct wpabuf m1 
) [static]

Definition at line 1499 of file wps_er.c.

static void wps_er_ap_process ( struct wps_er_ap ap,
struct wpabuf msg 
) [static]

Definition at line 1473 of file wps_er.c.

static void wps_er_ap_put_message ( struct wps_er_ap ap,
const struct wpabuf msg 
) [static]

Definition at line 1433 of file wps_er.c.

void wps_er_ap_remove ( struct wps_er er,
struct in_addr *  addr 
)

Definition at line 570 of file wps_er.c.

static void wps_er_ap_remove_all ( struct wps_er er) [static]

Definition at line 582 of file wps_er.c.

static void wps_er_ap_remove_entry ( struct wps_er er,
struct wps_er_ap ap 
) [static]

Definition at line 277 of file wps_er.c.

static void wps_er_ap_settings_cb ( void *  ctx,
const struct wps_credential cred 
) [static]

Definition at line 1371 of file wps_er.c.

static void wps_er_ap_timeout ( void *  eloop_data,
void *  user_ctx 
) [static]

Definition at line 300 of file wps_er.c.

static void wps_er_ap_unsubscribe ( struct wps_er er,
struct wps_er_ap ap 
) [static]

Definition at line 221 of file wps_er.c.

static void wps_er_ap_unsubscribed ( struct wps_er er,
struct wps_er_ap ap 
) [static]

Definition at line 179 of file wps_er.c.

static int wps_er_build_dev_password_id ( struct wpabuf msg,
u16  dev_passwd_id 
) [static]

Definition at line 1309 of file wps_er.c.

static int wps_er_build_sel_reg_config_methods ( struct wpabuf msg,
u16  sel_reg_config_methods 
) [static]

Definition at line 1318 of file wps_er.c.

static int wps_er_build_selected_registrar ( struct wpabuf msg,
int  sel_reg 
) [static]

Definition at line 1300 of file wps_er.c.

void wps_er_deinit ( struct wps_er er,
void(*)(void *ctx)  cb,
void *  ctx 
)

Definition at line 1225 of file wps_er.c.

static void wps_er_deinit_finish ( void *  eloop_data,
void *  user_ctx 
) [static]

Definition at line 1207 of file wps_er.c.

static void wps_er_get_device_info ( struct wps_er_ap ap) [static]

Definition at line 435 of file wps_er.c.

static int wps_er_get_sid ( struct wps_er_ap ap,
char *  sid 
) [static]

Definition at line 309 of file wps_er.c.

static void wps_er_http_dev_desc_cb ( void *  ctx,
struct http_client c,
enum http_client_event  event 
) [static]

Definition at line 503 of file wps_er.c.

static void wps_er_http_event ( struct wps_er er,
struct http_request req,
unsigned int  ap_id 
) [static]

Definition at line 1044 of file wps_er.c.

static void wps_er_http_get_dev_info_cb ( void *  ctx,
struct http_client c,
enum http_client_event  event 
) [static]

Definition at line 1541 of file wps_er.c.

static void wps_er_http_notify ( struct wps_er er,
struct http_request req 
) [static]

Definition at line 1080 of file wps_er.c.

static void wps_er_http_put_message_cb ( void *  ctx,
struct http_client c,
enum http_client_event  event 
) [static]

Definition at line 1386 of file wps_er.c.

static void wps_er_http_put_wlan_response_cb ( void *  ctx,
struct http_client c,
enum http_client_event  event 
) [static]

Definition at line 768 of file wps_er.c.

static void wps_er_http_req ( void *  ctx,
struct http_request req 
) [static]

Definition at line 1106 of file wps_er.c.

static void wps_er_http_resp_not_found ( struct http_request req) [static]

Definition at line 598 of file wps_er.c.

static void wps_er_http_resp_ok ( struct http_request req) [static]

Definition at line 617 of file wps_er.c.

static void wps_er_http_set_sel_reg_cb ( void *  ctx,
struct http_client c,
enum http_client_event  event 
) [static]

Definition at line 1241 of file wps_er.c.

static void wps_er_http_subscribe_cb ( void *  ctx,
struct http_client c,
enum http_client_event  event 
) [static]

Definition at line 344 of file wps_er.c.

static void wps_er_http_unsubscribe_cb ( void *  ctx,
struct http_client c,
enum http_client_event  event 
) [static]

Definition at line 193 of file wps_er.c.

struct wps_er* wps_er_init ( struct wps_context wps,
const char *  ifname 
) [read]

Definition at line 1142 of file wps_er.c.

int wps_er_learn ( struct wps_er er,
const u8 *  uuid,
const u8 *  pin,
size_t  pin_len 
)

Definition at line 1622 of file wps_er.c.

static void wps_er_parse_device_description ( struct wps_er_ap ap,
struct wpabuf reply 
) [static]

Definition at line 441 of file wps_er.c.

int wps_er_pbc ( struct wps_er er,
const u8 *  uuid 
)

Definition at line 1353 of file wps_er.c.

static void wps_er_process_wlanevent ( struct wps_er_ap ap,
struct wpabuf event 
) [static]

Definition at line 1004 of file wps_er.c.

static void wps_er_process_wlanevent_eap ( struct wps_er_ap ap,
const u8 *  addr,
struct wpabuf msg 
) [static]

Definition at line 961 of file wps_er.c.

static void wps_er_process_wlanevent_probe_req ( struct wps_er_ap ap,
const u8 *  addr,
struct wpabuf msg 
) [static]

Definition at line 747 of file wps_er.c.

void wps_er_refresh ( struct wps_er er)

Definition at line 1192 of file wps_er.c.

static int wps_er_send_get_device_info ( struct wps_er_ap ap,
void(*)(struct wps_er_ap *ap, struct wpabuf *m1)  m1_handler 
) [static]

Definition at line 1575 of file wps_er.c.

static void wps_er_send_set_sel_reg ( struct wps_er_ap ap,
struct wpabuf msg 
) [static]

Definition at line 1261 of file wps_er.c.

void wps_er_set_sel_reg ( struct wps_er er,
int  sel_reg,
u16  dev_passwd_id,
u16  sel_reg_config_methods 
)

Definition at line 1328 of file wps_er.c.

static void wps_er_soap_end ( struct wpabuf buf,
const char *  name,
char *  len_ptr,
char *  body_ptr 
) [static]

Definition at line 854 of file wps_er.c.

static struct wpabuf* wps_er_soap_hdr ( const struct wpabuf msg,
const char *  name,
const char *  arg_name,
const char *  path,
const struct sockaddr_in *  dst,
char **  len_ptr,
char **  body_ptr 
) [static, read]

Definition at line 798 of file wps_er.c.

static void wps_er_sta_event ( struct wps_context wps,
struct wps_er_sta sta,
enum wps_event  event 
) [static]

Definition at line 40 of file wps_er.c.

static void wps_er_sta_free ( struct wps_er_sta sta) [static]

Definition at line 76 of file wps_er.c.

static struct wps_er_sta* wps_er_sta_get ( struct wps_er_ap ap,
const u8 *  addr 
) [static, read]

Definition at line 65 of file wps_er.c.

static void wps_er_sta_process ( struct wps_er_sta sta,
struct wpabuf msg,
enum wsc_op_code  op_code 
) [static]

Definition at line 913 of file wps_er.c.

static void wps_er_sta_remove_all ( struct wps_er_ap ap) [static]

Definition at line 92 of file wps_er.c.

static void wps_er_sta_send_msg ( struct wps_er_sta sta,
struct wpabuf msg 
) [static]

Definition at line 866 of file wps_er.c.

static void wps_er_sta_start ( struct wps_er_sta sta,
struct wpabuf msg 
) [static]

Definition at line 939 of file wps_er.c.

static void wps_er_sta_timeout ( void *  eloop_data,
void *  user_ctx 
) [static]

Definition at line 637 of file wps_er.c.

static void wps_er_subscribe ( struct wps_er_ap ap) [static]

Definition at line 367 of file wps_er.c.


Variable Documentation

const char* soap_postfix = "</s:Body>\n</s:Envelope>\n" [static]

Definition at line 793 of file wps_er.c.

const char* soap_prefix = "<s:Body>\n" [static]

Definition at line 788 of file wps_er.c.

const char* urn_wfawlanconfig = "urn:schemas-wifialliance-org:service:WFAWLANConfig:1" [static]

Definition at line 795 of file wps_er.c.



wpa_supplicant_node
Author(s): Package maintained by Blaise Gassend
autogenerated on Thu Apr 24 2014 15:33:25