#include <stdio.h>
#include <stdlib.h>
#include <stdint.h>
#include <string.h>
#include <sys/ioctl.h>
#include <glib.h>
#include <glib-object.h>
#include <unistd.h>
#include "common.h"
#include "wpa.h"
#include "wps.h"
#include "log.h"
Go to the source code of this file.
Defines | |
#define | WPS_VERSION 0x10 |
#define | MAX_DEVICE_NAME 32 |
#define | WPS_STATE_UNCONFIGURED 0x01 |
#define | WPS_STATE_CONFIGURED 0x02 |
#define | WPS_PIN_CODE 0 |
#define | WPS_PUSH_BUTTON 4 |
#define | WPS_VERSION_TLV 0x104A |
#define | WPS_STATE_TLV 0x1044 |
#define | WPS_APSETUPLOCKED_TLV 0x1057 |
#define | WPS_SELECTEDREGISTRAR_TLV 0x1041 |
#define | WPS_DEVICEPASSWORD_ID_TLV 0x1012 |
#define | WPS_SELECTEDREGISTRARCONFIGMETHODS_TLV 0x1053 |
#define | WPS_DEVICENAME_TLV 0x1011 |
#define | WPS_UUID_E_TLV 0x1047 |
Functions | |
static int | get_tlv_value (guchar *msg, guint msg_size, guint type, guchar *value, guint value_len) |
int | handle_wps_ie (unsigned char *p, struct scan_results_t *scan_results, unsigned int length) |
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
Definition in file wps.c.
static int get_tlv_value | ( | guchar * | msg, | |
guint | msg_size, | |||
guint | type, | |||
guchar * | value, | |||
guint | value_len | |||
) | [static] |
Get selected TLV value.
msg | WPS Information Element. | |
msg_size | Message size. | |
type | Type of TLV value to search. | |
value | Pointer to result. | |
value_len | Result lenght. |
Definition at line 64 of file wps.c.
Referenced by handle_wps_ie().
int handle_wps_ie | ( | unsigned char * | p, | |
struct scan_results_t * | scan_results, | |||
unsigned int | length | |||
) |
Handle Wifi Protected Setup Information Element.
p | WPS Information Element. | |
scan_results | Scan results. | |
length | WPS Information Element length. |
Definition at line 120 of file wps.c.
References get_tlv_value().
Referenced by handle_wpa_ie_event_binary().