#include "os.h"
#include <stdint.h>
#include "wpa_debug.h"
Go to the source code of this file.
|
#define | WPA_TYPES_DEFINED |
|
#define | __LITTLE_ENDIAN 1234 |
|
#define | __BIG_ENDIAN 4321 |
|
#define | WPA_BYTE_SWAP_DEFINED |
|
#define | WPA_GET_BE16(a) ((u16) (((a)[0] << 8) | (a)[1])) |
|
#define | WPA_PUT_BE16(a, val) |
|
#define | WPA_GET_LE16(a) ((u16) (((a)[1] << 8) | (a)[0])) |
|
#define | WPA_PUT_LE16(a, val) |
|
#define | WPA_GET_BE24(a) |
|
#define | WPA_PUT_BE24(a, val) |
|
#define | WPA_GET_BE32(a) |
|
#define | WPA_PUT_BE32(a, val) |
|
#define | WPA_GET_LE32(a) |
|
#define | WPA_PUT_LE32(a, val) |
|
#define | WPA_GET_BE64(a) |
|
#define | WPA_PUT_BE64(a, val) |
|
#define | WPA_GET_LE64(a) |
|
#define | ETH_ALEN 6 |
|
#define | IFNAMSIZ 16 |
|
#define | ETH_P_ALL 0x0003 |
|
#define | ETH_P_PAE 0x888E /* Port Access Entity (IEEE 802.1X) */ |
|
#define | ETH_P_EAPOL ETH_P_PAE |
|
#define | ETH_P_RSN_PREAUTH 0x88c7 |
|
#define | ETH_P_RRB 0x890D |
|
#define | PRINTF_FORMAT(a, b) |
|
#define | STRUCT_PACKED |
|
#define | MAC2STR(a) (a)[0], (a)[1], (a)[2], (a)[3], (a)[4], (a)[5] |
|
#define | MACSTR "%02x:%02x:%02x:%02x:%02x:%02x" |
|
#define | BIT(x) (1 << (x)) |
|
#define | __force |
|
#define | __bitwise |
|
#define | __must_check |
|
#define | wpa_unicode2ascii_inplace(s) do { } while (0) |
|
#define | wpa_strdup_tchar(s) strdup((s)) |
|
#define | aliasing_hide_typecast(a, t) (t *) __hide_aliasing_typecast((a)) |
|
|
int | hwaddr_aton (const char *txt, u8 *addr) |
|
int | hwaddr_aton2 (const char *txt, u8 *addr) |
|
int | hexstr2bin (const char *hex, u8 *buf, size_t len) |
|
void | inc_byte_array (u8 *counter, size_t len) |
|
void | wpa_get_ntp_timestamp (u8 *buf) |
|
int | wpa_snprintf_hex (char *buf, size_t buf_size, const u8 *data, size_t len) |
|
int | wpa_snprintf_hex_uppercase (char *buf, size_t buf_size, const u8 *data, size_t len) |
|
const char * | wpa_ssid_txt (const u8 *ssid, size_t ssid_len) |
|
void * | __hide_aliasing_typecast (void *foo) |
|
#define __BIG_ENDIAN 4321 |
#define __LITTLE_ENDIAN 1234 |
#define BIT |
( |
|
x | ) |
(1 << (x)) |
#define ETH_P_PAE 0x888E /* Port Access Entity (IEEE 802.1X) */ |
#define ETH_P_RSN_PREAUTH 0x88c7 |
#define MAC2STR |
( |
|
a | ) |
(a)[0], (a)[1], (a)[2], (a)[3], (a)[4], (a)[5] |
#define MACSTR "%02x:%02x:%02x:%02x:%02x:%02x" |
#define PRINTF_FORMAT |
( |
|
a, |
|
|
|
b |
|
) |
| |
#define WPA_BYTE_SWAP_DEFINED |
#define WPA_GET_BE16 |
( |
|
a | ) |
((u16) (((a)[0] << 8) | (a)[1])) |
#define WPA_GET_BE24 |
( |
|
a | ) |
|
Value:((((
u32) (a)[0]) << 16) | (((
u32) (a)[1]) << 8) | \
Definition at line 263 of file common.h.
#define WPA_GET_BE32 |
( |
|
a | ) |
|
Value:((((
u32) (a)[0]) << 24) | (((
u32) (a)[1]) << 16) | \
(((
u32) (a)[2]) << 8) | ((
u32) (a)[3]))
Definition at line 272 of file common.h.
#define WPA_GET_BE64 |
( |
|
a | ) |
|
Value:((((
u64) (a)[0]) << 56) | (((
u64) (a)[1]) << 48) | \
(((
u64) (a)[2]) << 40) | (((
u64) (a)[3]) << 32) | \
(((
u64) (a)[4]) << 24) | (((
u64) (a)[5]) << 16) | \
(((
u64) (a)[6]) << 8) | ((
u64) (a)[7]))
Definition at line 292 of file common.h.
#define WPA_GET_LE16 |
( |
|
a | ) |
((u16) (((a)[1] << 8) | (a)[0])) |
#define WPA_GET_LE32 |
( |
|
a | ) |
|
Value:((((
u32) (a)[3]) << 24) | (((
u32) (a)[2]) << 16) | \
(((
u32) (a)[1]) << 8) | ((
u32) (a)[0]))
Definition at line 282 of file common.h.
#define WPA_GET_LE64 |
( |
|
a | ) |
|
Value:((((
u64) (a)[7]) << 56) | (((
u64) (a)[6]) << 48) | \
(((
u64) (a)[5]) << 40) | (((
u64) (a)[4]) << 32) | \
(((
u64) (a)[3]) << 24) | (((
u64) (a)[2]) << 16) | \
(((
u64) (a)[1]) << 8) | ((
u64) (a)[0]))
Definition at line 308 of file common.h.
#define WPA_PUT_BE16 |
( |
|
a, |
|
|
|
val |
|
) |
| |
Value:do { \
(a)[0] = ((
u16) (val)) >> 8; \
(a)[1] = ((
u16) (val)) & 0xff; \
} while (0)
Definition at line 250 of file common.h.
#define WPA_PUT_BE24 |
( |
|
a, |
|
|
|
val |
|
) |
| |
Value:do { \
(a)[0] = (
u8) ((((
u32) (val)) >> 16) & 0xff); \
(a)[1] = (
u8) ((((
u32) (val)) >> 8) & 0xff); \
(a)[2] = (
u8) (((
u32) (val)) & 0xff); \
} while (0)
Definition at line 265 of file common.h.
#define WPA_PUT_BE32 |
( |
|
a, |
|
|
|
val |
|
) |
| |
Value:do { \
(a)[0] = (
u8) ((((
u32) (val)) >> 24) & 0xff); \
(a)[1] = (
u8) ((((
u32) (val)) >> 16) & 0xff); \
(a)[2] = (
u8) ((((
u32) (val)) >> 8) & 0xff); \
(a)[3] = (
u8) (((
u32) (val)) & 0xff); \
} while (0)
Definition at line 274 of file common.h.
#define WPA_PUT_BE64 |
( |
|
a, |
|
|
|
val |
|
) |
| |
Value:do { \
(a)[0] = (
u8) (((
u64) (val)) >> 56); \
(a)[1] = (
u8) (((
u64) (val)) >> 48); \
(a)[2] = (
u8) (((
u64) (val)) >> 40); \
(a)[3] = (
u8) (((
u64) (val)) >> 32); \
(a)[4] = (
u8) (((
u64) (val)) >> 24); \
(a)[5] = (
u8) (((
u64) (val)) >> 16); \
(a)[6] = (
u8) (((
u64) (val)) >> 8); \
(a)[7] = (
u8) (((
u64) (val)) & 0xff); \
} while (0)
Definition at line 296 of file common.h.
#define WPA_PUT_LE16 |
( |
|
a, |
|
|
|
val |
|
) |
| |
Value:do { \
(a)[1] = ((
u16) (val)) >> 8; \
(a)[0] = ((
u16) (val)) & 0xff; \
} while (0)
Definition at line 257 of file common.h.
#define WPA_PUT_LE32 |
( |
|
a, |
|
|
|
val |
|
) |
| |
Value:do { \
(a)[3] = (
u8) ((((
u32) (val)) >> 24) & 0xff); \
(a)[2] = (
u8) ((((
u32) (val)) >> 16) & 0xff); \
(a)[1] = (
u8) ((((
u32) (val)) >> 8) & 0xff); \
(a)[0] = (
u8) (((
u32) (val)) & 0xff); \
} while (0)
Definition at line 284 of file common.h.
#define wpa_strdup_tchar |
( |
|
s | ) |
strdup((s)) |
#define WPA_TYPES_DEFINED |
#define wpa_unicode2ascii_inplace |
( |
|
s | ) |
do { } while (0) |
void* __hide_aliasing_typecast |
( |
void * |
foo | ) |
|
int hexstr2bin |
( |
const char * |
hex, |
|
|
u8 * |
buf, |
|
|
size_t |
len |
|
) |
| |
int hwaddr_aton |
( |
const char * |
txt, |
|
|
u8 * |
addr |
|
) |
| |
int hwaddr_aton2 |
( |
const char * |
txt, |
|
|
u8 * |
addr |
|
) |
| |
void inc_byte_array |
( |
u8 * |
counter, |
|
|
size_t |
len |
|
) |
| |
void wpa_get_ntp_timestamp |
( |
u8 * |
buf | ) |
|
int wpa_snprintf_hex |
( |
char * |
buf, |
|
|
size_t |
buf_size, |
|
|
const u8 * |
data, |
|
|
size_t |
len |
|
) |
| |
int wpa_snprintf_hex_uppercase |
( |
char * |
buf, |
|
|
size_t |
buf_size, |
|
|
const u8 * |
data, |
|
|
size_t |
len |
|
) |
| |
const char* wpa_ssid_txt |
( |
const u8 * |
ssid, |
|
|
size_t |
ssid_len |
|
) |
| |