17#include "../../core/frame/tag.h"
18#include "../../core/frame/tag_iterator.h"
19#include "../../core/misc/byteswap.h"
20#include "../../core/misc/epoch.h"
70 const unsigned char *chan = (
const unsigned char *) &
channel;
82 const unsigned char receiver[6],
83 const unsigned char transmitter[6],
84 const unsigned char address3[6],
117 if (probe_resp_len > buf_len) {
131 return probe_resp_len;
struct libwifi_tagged_parameters tags
uint16_t probe_resp_interval
struct libwifi_radiotap_channel channel
unsigned long long libwifi_get_epoch(void)
Get the current system time in epoch.
#define LIBWIFI_DEFAULT_AP_CAPABS
A sane default for an AP-side capabilities information field.
void libwifi_free_probe_resp(struct libwifi_probe_resp *probe_resp)
Because the tagged parameters memory is managed inside of the library, the library must be the one to...
size_t libwifi_get_probe_resp_length(struct libwifi_probe_resp *probe_resp)
The length of a probe response frame is the sum of the header length, the fixed parameters length,...
int libwifi_set_probe_resp_ssid(struct libwifi_probe_resp *probe_resp, const char *ssid)
Simple helper to set the probe response SSID tag by removing it and then adding it back with the new ...
int libwifi_set_probe_resp_channel(struct libwifi_probe_resp *probe_resp, uint8_t channel)
Simple helper to set the probe response DS tag by removing it and then adding it back with the new va...
int libwifi_create_probe_resp(struct libwifi_probe_resp *probe_resp, const unsigned char receiver[6], const unsigned char transmitter[6], const unsigned char address3[6], const char *ssid, uint8_t channel)
The generated probe response frame is made with sane defaults defined in common.h.
size_t libwifi_dump_probe_resp(struct libwifi_probe_resp *probe_resp, unsigned char *buf, size_t buf_len)
Copy a libwifi_probe_resp into a regular unsigned char buffer.
uint16_t probe_resp_interval
uint16_t capabilities_information
struct libwifi_tagged_parameters tags
struct libwifi_probe_resp_fixed_parameters fixed_parameters
struct libwifi_mgmt_unordered_frame_header frame_header
unsigned int sequence_number
unsigned char * parameters
int libwifi_quick_add_tag(struct libwifi_tagged_parameters *tags, int tag_number, const unsigned char *tag_data, size_t tag_length)
Add a tagged parameter via tag number and data to a management frame.
int libwifi_remove_tag(struct libwifi_tagged_parameters *tags, int tag_number)
Remove a tagged parameter from a list of frame tagged parameters.