libwifi 0.0.3
An 802.11 Frame Parsing and Generation library in C
eapol.h
Go to the documentation of this file.
1/* Copyright 2021 The libwifi Authors
2 *
3 * Licensed under the Apache License, Version 2.0 (the "License");
4 * you may not use this file except in compliance with the License.
5 * You may obtain a copy of the License at
6 *
7 * http://www.apache.org/licenses/LICENSE-2.0
8 *
9 * Unless required by applicable law or agreed to in writing, software
10 * distributed under the License is distributed on an "AS IS" BASIS,
11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 * See the License for the specific language governing permissions and
13 * limitations under the License.
14 */
15
16#ifndef LIBWIFI_PARSE_EAPOL_H
17#define LIBWIFI_PARSE_EAPOL_H
18
19#include "../../core/frame/frame.h"
20#include "../../core/misc/security.h"
21
28};
29
37
53
60const char *libwifi_get_wpa_message_string(struct libwifi_frame *frame);
61
69
81int libwifi_get_wpa_data(struct libwifi_frame *frame, struct libwifi_wpa_auth_data *data);
82
90
91#endif /* LIBWIFI_PARSE_EAPOL_H */
const char * libwifi_get_wpa_message_string(struct libwifi_frame *frame)
Get a string describing the WPA handshake message inside a supplied libwifi_frame.
Definition: eapol.c:105
int libwifi_check_wpa_message(struct libwifi_frame *frame)
Check what message of the WPA1/2 handshake is in the given frame.
Definition: eapol.c:74
int libwifi_check_wpa_handshake(struct libwifi_frame *frame)
Check if a libwifi_frame contains a WPA1/2 handshake message.
Definition: eapol.c:34
void libwifi_free_wpa_data(struct libwifi_wpa_auth_data *data)
Free any memory allocated inside of a libwifi_wpa_auth data, such as a buffer for WPA key data alloca...
Definition: eapol.c:186
WPA_HANDSHAKE_PART
Definition: eapol.h:22
@ HANDSHAKE_M2
Definition: eapol.h:24
@ HANDSHAKE_INVALID
Definition: eapol.h:27
@ HANDSHAKE_M1
Definition: eapol.h:23
@ HANDSHAKE_M3
Definition: eapol.h:25
@ HANDSHAKE_M4
Definition: eapol.h:26
int libwifi_get_wpa_data(struct libwifi_frame *frame, struct libwifi_wpa_auth_data *data)
Get the EAPOL/WPA information from a given libwifi_frame.
Definition: eapol.c:147
int libwifi_get_wpa_key_data_length(struct libwifi_frame *frame)
Get the length of the key data, if any, present at the end of an EAPOL frame.
Definition: eapol.c:127
libwifi Representation of the encapsulating 802.1X data in an EAPOL frame ┌─────────────────┐ │ Versi...
Definition: security.h:281