input stringlengths 16 454k | output stringlengths 13 350k | function_name stringlengths 1 100 | repo_name stringlengths 6 43 | category stringclasses 76
values | sample_id stringlengths 22 88 | decompiler stringclasses 1
value | opt_level stringclasses 1
value |
|---|---|---|---|---|---|---|---|
const char *eap_tls_state_txt(int state) {
if (state == 3)
return "FAILURE";
if (state <= 3) {
switch (state) {
case 2:
return "SUCCESS";
case 0:
return "START";
case 1:
return "CONTINUE";
}
}
return "Unknown?!";
} | static const char *eap_tls_state_txt(int state) {
switch (state) {
case START:
return "START";
case CONTINUE:
return "CONTINUE";
case SUCCESS:
return "SUCCESS";
case FAILURE:
return "FAILURE";
default:
return "Unknown?!";
}
} | eap_tls_state_txt | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eap_tls_valid_session(eap_sm *sm, eap_tls_data *data) {
wpabuf *buf;
if (sm->cfg->tls_session_lifetime) {
buf = wpabuf_alloc(1u);
if (buf) {
wpabuf_put_u8_7(buf, data->eap_type);
tls_connection_set_success_data(data->ssl.conn, buf);
}
}
} | static void eap_tls_valid_session(struct eap_sm *sm,
struct eap_tls_data *data) {
struct wpabuf *buf;
if (!sm->cfg->tls_session_lifetime)
return;
buf = wpabuf_alloc(1);
if (!buf)
return;
wpabuf_put_u8(buf, data->eap_type);
tls_connection_set_success_data(data->ssl... | eap_tls_valid_session | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
int eap_tlv_validate_cryptobinding(eap_sm *sm, eap_peap_data *data,
const u8 *crypto_tlv,
size_t crypto_tlv_len) {
const u8 *pos;
u8 mac[32];
u8 buf[72];
unsigned long v8;
v8 = __readfsqword(0x28u);
if (crypto_tlv_len == 60) {
pos = ... | static int eap_tlv_validate_cryptobinding(struct eap_sm *sm,
struct eap_peap_data *data,
const u8 *crypto_tlv,
size_t crypto_tlv_len) {
u8 buf[61], mac[SHA1_MAC_LEN];
const u8 *pos;
if (c... | eap_tlv_validate_cryptobinding | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
wpabuf *eap_tnc_build(eap_sm *sm, eap_tnc_data *data) {
u8 *v3;
size_t v4;
const void *v5;
size_t imv_len;
char *start_buf;
size_t start_len;
char *end_buf;
size_t end_len;
wpabuf *req;
u8 *rpos1;
imv_len = tncs_total_send_len(data->tncs);
start_buf = tncs_if_tnccs_start(data->tncs);
if (!sta... | static struct wpabuf *eap_tnc_build(struct eap_sm *sm,
struct eap_tnc_data *data) {
struct wpabuf *req;
u8 *rpos, *rpos1;
size_t rlen;
char *start_buf, *end_buf;
size_t start_len, end_len;
size_t imv_len;
imv_len = tncs_total_send_len(data->tncs);
start_buf = tncs_i... | eap_tnc_build | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
wpabuf *eap_tnc_buildReq(eap_sm *sm, void *priv, u8 id) {
wpabuf *result;
switch (*(_DWORD *)priv) {
case 0:
tncs_init_connection(*((tncs_data **)priv + 1));
result = eap_tnc_build_start(sm, (eap_tnc_data *)priv, id);
break;
case 1:
if (*((_QWORD *)priv + 3))
goto LABEL_7;
*((_QWORD *... | static struct wpabuf *eap_tnc_buildReq(struct eap_sm *sm, void *priv, u8 id) {
struct eap_tnc_data *data = priv;
switch (data->state) {
case START:
tncs_init_connection(data->tncs);
return eap_tnc_build_start(sm, data, id);
case CONTINUE:
if (data->out_buf == NULL) {
data->out_buf = eap_tnc_b... | eap_tnc_buildReq | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
wpabuf *eap_tnc_build_frag_ack(u8 id, u8 code) {
wpabuf *msg;
msg = eap_msg_alloc(0, eap_type_EAP_TYPE_TNC, 1u, code, id);
if (msg) {
wpabuf_put_u8_34(msg, 1u);
wpa_printf(2, "EAP-TNC: Send fragment ack");
return msg;
} else {
wpa_printf(5, "EAP-TNC: Failed to allocate memory for fragment ack")... | static struct wpabuf *eap_tnc_build_frag_ack(u8 id, u8 code) {
struct wpabuf *msg;
msg = eap_msg_alloc(EAP_VENDOR_IETF, EAP_TYPE_TNC, 1, code, id);
if (msg == NULL) {
wpa_printf(MSG_ERROR, "EAP-TNC: Failed to allocate memory "
"for fragment ack");
return NULL;
}
wpabuf_put_u... | eap_tnc_build_frag_ack | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
wpabuf *eap_tnc_build_msg(eap_tnc_data *data, u8 id) {
u32 v3;
const u8 *v4;
size_t out_used;
size_t v6;
char flags;
size_t send_len;
size_t plen;
wpabuf *req;
wpa_printf(2, "EAP-TNC: Generating Request");
flags = 1;
send_len = wpabuf_len_63(data->out_buf) - data->out_used;
if (send_len + 1 > d... | static struct wpabuf *eap_tnc_build_msg(struct eap_tnc_data *data, u8 id) {
struct wpabuf *req;
u8 flags;
size_t send_len, plen;
wpa_printf(MSG_DEBUG, "EAP-TNC: Generating Request");
flags = EAP_TNC_VERSION;
send_len = wpabuf_len(data->out_buf) - data->out_used;
if (1 + send_len > data->fragment_size) {... | eap_tnc_build_msg | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
wpabuf *eap_tnc_build_recommendation(eap_sm *sm, eap_tnc_data *data) {
eap_tnc_data_$A10779FFB9A1D7FAE379823F325E4A37 recommendation;
recommendation = data->recommendation;
if (recommendation == NO_RECOMMENDATION)
goto LABEL_5;
if ((unsigned int)recommendation > NO_RECOMMENDATION) {
wpa_printf(2, "EAP-... | static struct wpabuf *eap_tnc_build_recommendation(struct eap_sm *sm,
struct eap_tnc_data *data) {
switch (data->recommendation) {
case ALLOW:
eap_tnc_set_state(data, DONE);
break;
case ISOLATE:
eap_tnc_set_state(data, FAIL);
break;
case NO_ACC... | eap_tnc_build_recommendation | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
wpabuf *eap_tnc_build_start(eap_sm *sm, eap_tnc_data *data, u8 id) {
wpabuf *req;
req = eap_msg_alloc(0, eap_type_EAP_TYPE_TNC, 1u, 1u, id);
if (req) {
wpabuf_put_u8_34(req, 0x21u);
eap_tnc_set_state(data, eap_tnc_state_CONTINUE);
return req;
} else {
wpa_printf(5, "EAP-TNC: Failed to allocate ... | static struct wpabuf *eap_tnc_build_start(struct eap_sm *sm,
struct eap_tnc_data *data, u8 id) {
struct wpabuf *req;
req = eap_msg_alloc(EAP_VENDOR_IETF, EAP_TYPE_TNC, 1, EAP_CODE_REQUEST, id);
if (req == NULL) {
wpa_printf(MSG_ERROR, "EAP-TNC: Failed to allocate mem... | eap_tnc_build_start | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
bool eap_tnc_check(eap_sm *sm, void *priv, wpabuf *respData) {
size_t len;
eap_tnc_data *data;
const u8 *pos;
unsigned long v7;
v7 = __readfsqword(0x28u);
data = (eap_tnc_data *)priv;
pos = eap_hdr_validate(0, eap_type_EAP_TYPE_TNC, respData, &len);
if (pos) {
if (len || data->state == eap_tnc_stat... | static bool eap_tnc_check(struct eap_sm *sm, void *priv,
struct wpabuf *respData) {
struct eap_tnc_data *data = priv;
const u8 *pos;
size_t len;
pos = eap_hdr_validate(EAP_VENDOR_IETF, EAP_TYPE_TNC, respData, &len);
if (pos == NULL) {
wpa_printf(MSG_INFO, "EAP-TNC: Invalid frame... | eap_tnc_check | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void *eap_tnc_init(eap_sm *sm) {
long v2;
eap_tnc_data *data;
data = (eap_tnc_data *)os_zalloc(0x38u);
if (!data)
return 0;
eap_tnc_set_state(data, eap_tnc_state_START);
data->tncs = tncs_init();
if (data->tncs) {
if (sm->cfg->fragment_size <= 100)
v2 = 1300;
else
v2 = sm->cfg->fr... | static void *eap_tnc_init(struct eap_sm *sm) {
struct eap_tnc_data *data;
data = os_zalloc(sizeof(*data));
if (data == NULL)
return NULL;
eap_tnc_set_state(data, START);
data->tncs = tncs_init();
if (data->tncs == NULL) {
os_free(data);
return NULL;
}
data->fragment_size =
sm->cfg->f... | eap_tnc_init | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
bool eap_tnc_isDone(eap_sm *sm, void *priv) {
return *(_DWORD *)priv == 5 || *(_DWORD *)priv == 6;
} | static bool eap_tnc_isDone(struct eap_sm *sm, void *priv) {
struct eap_tnc_data *data = priv;
return data->state == DONE || data->state == FAIL;
} | eap_tnc_isDone | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
bool eap_tnc_isSuccess(eap_sm *sm, void *priv) { return *(_DWORD *)priv == 5; } | static bool eap_tnc_isSuccess(struct eap_sm *sm, void *priv) {
struct eap_tnc_data *data = priv;
return data->state == DONE;
} | eap_tnc_isSuccess | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eap_tnc_process(eap_sm *sm, void *priv, wpabuf *respData) {
char *v3;
size_t v4;
const void *v5;
char flags;
unsigned int message_length;
size_t len;
const u8 *pos;
eap_tnc_data *data;
const u8 *end;
wpabuf tmpbuf;
unsigned long v13;
v13 = __readfsqword(0x28u);
data = (eap_tnc_data *)pri... | static void eap_tnc_process(struct eap_sm *sm, void *priv,
struct wpabuf *respData) {
struct eap_tnc_data *data = priv;
const u8 *pos, *end;
size_t len;
u8 flags;
u32 message_length = 0;
struct wpabuf tmpbuf;
pos = eap_hdr_validate(EAP_VENDOR_IETF, EAP_TYPE_TNC, respData, &len... | eap_tnc_process | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
int eap_tnc_process_cont(eap_tnc_data *data, const u8 *buf, size_t len) {
size_t v4;
if (len <= wpabuf_tailroom_6(data->in_buf)) {
wpabuf_put_data_44(data->in_buf, buf, len);
v4 = wpabuf_tailroom_6(data->in_buf);
wpa_printf(2, "EAP-TNC: Received %lu bytes, waiting for %lu bytes more",
le... | static int eap_tnc_process_cont(struct eap_tnc_data *data, const u8 *buf,
size_t len) {
if (len > wpabuf_tailroom(data->in_buf)) {
wpa_printf(MSG_DEBUG, "EAP-TNC: Fragment overflow");
eap_tnc_set_state(data, FAIL);
return -1;
}
wpabuf_put_data(data->in_buf, buf, len);... | eap_tnc_process_cont | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
int eap_tnc_process_fragment(eap_tnc_data *data, u8 flags, u32 message_length,
const u8 *buf, size_t len) {
size_t v6;
if (!data->in_buf && (flags & 0x80u) == 0) {
wpa_printf(2, "EAP-TNC: No Message Length field in a fragmented packet");
return -1;
}
if (!data->in_buf) {
... | static int eap_tnc_process_fragment(struct eap_tnc_data *data, u8 flags,
u32 message_length, const u8 *buf,
size_t len) {
if (data->in_buf == NULL && !(flags & EAP_TNC_FLAGS_LENGTH_INCLUDED)) {
wpa_printf(MSG_DEBUG, "EAP-TNC: No Message Leng... | eap_tnc_process_fragment | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eap_tnc_reset(eap_sm *sm, void *priv) {
wpabuf_free(*((wpabuf **)priv + 2));
wpabuf_free(*((wpabuf **)priv + 3));
tncs_deinit(*((tncs_data **)priv + 1));
free(priv);
} | static void eap_tnc_reset(struct eap_sm *sm, void *priv) {
struct eap_tnc_data *data = priv;
wpabuf_free(data->in_buf);
wpabuf_free(data->out_buf);
tncs_deinit(data->tncs);
os_free(data);
} | eap_tnc_reset | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eap_tnc_set_state(eap_tnc_data *data, eap_tnc_state new_state) {
const char *v2;
const char *v3;
v2 = eap_tnc_state_txt(new_state);
v3 = eap_tnc_state_txt(data->state);
wpa_printf(2, "EAP-TNC: %s -> %s", v3, v2);
data->state = new_state;
} | static void eap_tnc_set_state(struct eap_tnc_data *data,
enum eap_tnc_state new_state) {
wpa_printf(MSG_DEBUG, "EAP-TNC: %s -> %s", eap_tnc_state_txt(data->state),
eap_tnc_state_txt(new_state));
data->state = new_state;
} | eap_tnc_set_state | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
const char *eap_tnc_state_txt(eap_tnc_state state) {
const char *result;
switch (state) {
case eap_tnc_state_START:
result = "START";
break;
case eap_tnc_state_CONTINUE:
result = "CONTINUE";
break;
case eap_tnc_state_RECOMMENDATION:
result = "RECOMMENDATION";
break;
case eap_tnc_sta... | static const char *eap_tnc_state_txt(enum eap_tnc_state state) {
switch (state) {
case START:
return "START";
case CONTINUE:
return "CONTINUE";
case RECOMMENDATION:
return "RECOMMENDATION";
case FRAG_ACK:
return "FRAG_ACK";
case WAIT_FRAG_ACK:
return "WAIT_FRAG_ACK";
case DONE:
ret... | eap_tnc_state_txt | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
wpabuf *eap_ttls_avp_encapsulate(wpabuf *resp, u32 avp_code, int mandatory) {
size_t v3;
size_t v5;
u8 *v6;
size_t v7;
const void *v8;
unsigned char v9;
size_t v10;
int __pad;
wpabuf *avp;
u8 *pos;
u8 *posa;
v3 = wpabuf_len_23(resp);
avp = wpabuf_alloc(v3 + 12);
if (avp) {
v5 = wpabuf_l... | static struct wpabuf *eap_ttls_avp_encapsulate(struct wpabuf *resp,
u32 avp_code, int mandatory) {
struct wpabuf *avp;
u8 *pos;
avp = wpabuf_alloc(sizeof(struct ttls_avp) + wpabuf_len(resp) + 4);
if (avp == NULL) {
wpabuf_free(resp);
return NULL;
}
po... | eap_ttls_avp_encapsulate | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
u8 *eap_ttls_avp_hdr(u8 *avphdr, u32 avp_code, u32 vendor_id, int mandatory,
size_t len) {
char v5;
int lena;
u8 flags;
size_t hdrlen;
lena = len;
if (mandatory)
v5 = 64;
else
v5 = 0;
flags = v5;
if (vendor_id) {
flags = v5 | 0x80;
hdrlen = 12;
*((_DWORD *)avp... | static u8 *eap_ttls_avp_hdr(u8 *avphdr, u32 avp_code, u32 vendor_id,
int mandatory, size_t len) {
struct ttls_avp_vendor *avp;
u8 flags;
size_t hdrlen;
avp = (struct ttls_avp_vendor *)avphdr;
flags = mandatory ? AVP_FLAGS_MANDATORY : 0;
if (vendor_id) {
flags |= AVP_FLAGS_VE... | eap_ttls_avp_hdr | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
int eap_ttls_avp_parse(wpabuf *buf, eap_ttls_avp *parse) {
__uint32_t v2;
signed char avp_flags;
int left;
__uint32_t vendor_id;
__uint32_t avp_code;
u32 avp_length;
__uint32_t *pos;
u8 *dpos;
unsigned long dlen;
size_t password_len;
u8 *neweap;
pos = (__uint32_t *)wpabuf_mhead_2(buf);
left =... | static int eap_ttls_avp_parse(struct wpabuf *buf, struct eap_ttls_avp *parse) {
struct ttls_avp *avp;
u8 *pos;
int left;
pos = wpabuf_mhead(buf);
left = wpabuf_len(buf);
os_memset(parse, 0, sizeof(*parse));
while (left > 0) {
u32 avp_code, avp_length, vendor_id = 0;
u8 avp_flags, *dpos;
size... | eap_ttls_avp_parse | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
wpabuf *eap_ttls_buildReq(eap_sm *sm, void *priv, u8 id) {
unsigned int v4;
if (*((_DWORD *)priv + 14) == 1)
return eap_server_tls_build_ack(id, 21, *((_DWORD *)priv + 27));
if (*((_DWORD *)priv + 14) != 2) {
v4 = *((_DWORD *)priv + 26);
if (v4 == 4) {
wpabuf_free(*((wpabuf **)priv + 1));
... | static struct wpabuf *eap_ttls_buildReq(struct eap_sm *sm, void *priv, u8 id) {
struct eap_ttls_data *data = priv;
if (data->ssl.state == FRAG_ACK) {
return eap_server_tls_build_ack(id, EAP_TYPE_TTLS, data->ttls_version);
}
if (data->ssl.state == WAIT_FRAG_ACK) {
return eap_server_tls_build_msg(&data-... | eap_ttls_buildReq | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
wpabuf *eap_ttls_build_phase2_eap_req(eap_sm *sm, eap_ttls_data *data, u8 id) {
wpabuf *buf;
wpabuf *bufa;
wpabuf *encr_req;
buf = data->phase2_method->buildReq(sm, data->phase2_priv, id);
if (!buf)
return 0;
wpa_hexdump_buf_key_0(2, "EAP-TTLS/EAP: Encapsulate Phase 2 data", buf);
bufa = eap_ttls_avp... | static struct wpabuf *eap_ttls_build_phase2_eap_req(struct eap_sm *sm,
struct eap_ttls_data *data,
u8 id) {
struct wpabuf *buf, *encr_req;
buf = data->phase2_method->buildReq(sm, data->phase2_priv, id);
if (bu... | eap_ttls_build_phase2_eap_req | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
wpabuf *eap_ttls_build_phase2_mschapv2(eap_sm *sm, eap_ttls_data *data) {
u8 *v3;
int ret;
char *pos;
u8 *posa;
u8 *posb;
u8 *req;
u8 *end;
wpabuf *encr_req;
wpabuf msgbuf;
unsigned long v12;
v12 = __readfsqword(0x28u);
req = (u8 *)malloc(0x64u);
if (!req)
return 0;
end = req + 100;
i... | static struct wpabuf *
eap_ttls_build_phase2_mschapv2(struct eap_sm *sm, struct eap_ttls_data *data) {
struct wpabuf *encr_req, msgbuf;
u8 *req, *pos, *end;
int ret;
pos = req = os_malloc(100);
if (req == NULL)
return NULL;
end = req + 100;
if (data->mschapv2_resp_ok) {
pos = eap_ttls_avp_hdr(po... | eap_ttls_build_phase2_mschapv2 | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
wpabuf *eap_ttls_build_start(eap_sm *sm, eap_ttls_data *data, u8 id) {
wpabuf *req;
req = eap_msg_alloc(0, eap_type_EAP_TYPE_TTLS, 1u, 1u, id);
if (req) {
wpabuf_put_u8_9(req, LOBYTE(data->ttls_version) | 0x20);
eap_ttls_state(data, 1);
return req;
} else {
wpa_printf(5, "EAP-TTLS: Failed to al... | static struct wpabuf *eap_ttls_build_start(struct eap_sm *sm,
struct eap_ttls_data *data, u8 id) {
struct wpabuf *req;
req = eap_msg_alloc(EAP_VENDOR_IETF, EAP_TYPE_TTLS, 1, EAP_CODE_REQUEST, id);
if (req == NULL) {
wpa_printf(MSG_ERROR, "EAP-TTLS: Failed to allocat... | eap_ttls_build_start | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
bool eap_ttls_check(eap_sm *sm, void *priv, wpabuf *respData) {
size_t len;
const u8 *pos;
unsigned long v6;
v6 = __readfsqword(0x28u);
pos = eap_hdr_validate(0, eap_type_EAP_TYPE_TTLS, respData, &len);
if (pos && len)
return 0;
wpa_printf(3, "EAP-TTLS: Invalid frame");
return 1;
} | static bool eap_ttls_check(struct eap_sm *sm, void *priv,
struct wpabuf *respData) {
const u8 *pos;
size_t len;
pos = eap_hdr_validate(EAP_VENDOR_IETF, EAP_TYPE_TTLS, respData, &len);
if (pos == NULL || len < 1) {
wpa_printf(MSG_INFO, "EAP-TTLS: Invalid frame");
return true;
... | eap_ttls_check | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
u8 *eap_ttls_getKey(eap_sm *sm, void *priv, size_t *len) {
const char *label;
u8 *context;
size_t context_len;
u8 *eapKeyData;
u8 eap_tls13_context[1];
unsigned long v10;
v10 = __readfsqword(0x28u);
eap_tls13_context[0] = 21;
context = 0;
context_len = 0;
if (*((_DWORD *)priv + 26) != 5)
retu... | static u8 *eap_ttls_getKey(struct eap_sm *sm, void *priv, size_t *len) {
struct eap_ttls_data *data = priv;
u8 *eapKeyData;
const char *label;
const u8 eap_tls13_context[1] = {EAP_TYPE_TTLS};
const u8 *context = NULL;
size_t context_len = 0;
if (data->state != SUCCESS)
return NULL;
if (data->ssl.t... | eap_ttls_getKey | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
u8 *eap_ttls_get_emsk(eap_sm *sm, void *priv, size_t *len) {
u8 *emsk;
const char *label;
u8 *context;
size_t context_len;
u8 *eapKeyData;
u8 eap_tls13_context[1];
unsigned long v11;
v11 = __readfsqword(0x28u);
eap_tls13_context[0] = 21;
context = 0;
context_len = 0;
if (*((_DWORD *)priv + 26) ... | static u8 *eap_ttls_get_emsk(struct eap_sm *sm, void *priv, size_t *len) {
struct eap_ttls_data *data = priv;
u8 *eapKeyData, *emsk;
const char *label;
const u8 eap_tls13_context[1] = {EAP_TYPE_TTLS};
const u8 *context = NULL;
size_t context_len = 0;
if (data->state != SUCCESS)
return NULL;
if (da... | eap_ttls_get_emsk | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
u8 *eap_ttls_get_session_id(eap_sm *sm, void *priv, size_t *len) {
if (*((_DWORD *)priv + 26) == 5)
return eap_server_tls_derive_session_id(sm, (eap_ssl_data *)priv, 0x15u,
len);
else
return 0;
} | static u8 *eap_ttls_get_session_id(struct eap_sm *sm, void *priv, size_t *len) {
struct eap_ttls_data *data = priv;
if (data->state != SUCCESS)
return NULL;
return eap_server_tls_derive_session_id(sm, &data->ssl, EAP_TYPE_TTLS, len);
} | eap_ttls_get_session_id | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
u8 *eap_ttls_implicit_challenge(eap_sm *sm, eap_ttls_data *data, size_t len) {
return eap_server_tls_derive_key(sm, &data->ssl, "ttls challenge", 0, 0, len);
} | static u8 *eap_ttls_implicit_challenge(struct eap_sm *sm,
struct eap_ttls_data *data, size_t len) {
return eap_server_tls_derive_key(sm, &data->ssl, "ttls challenge", NULL, 0,
len);
} | eap_ttls_implicit_challenge | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void *eap_ttls_init(eap_sm *sm) {
eap_ttls_data *data;
data = (eap_ttls_data *)os_zalloc(0xB0u);
if (!data)
return 0;
data->ttls_version = 0;
data->state = 0;
if (!eap_server_tls_ssl_init(sm, &data->ssl, 0, 21))
return data;
wpa_printf(3, "EAP-TTLS: Failed to initialize SSL.");
eap_ttls_reset(s... | static void *eap_ttls_init(struct eap_sm *sm) {
struct eap_ttls_data *data;
data = os_zalloc(sizeof(*data));
if (data == NULL)
return NULL;
data->ttls_version = EAP_TTLS_VERSION;
data->state = START;
if (eap_server_tls_ssl_init(sm, &data->ssl, 0, EAP_TYPE_TTLS)) {
wpa_printf(MSG_INFO, "EAP-TTLS: F... | eap_ttls_init | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
bool eap_ttls_isDone(eap_sm *sm, void *priv) {
return *((_DWORD *)priv + 26) == 5 || *((_DWORD *)priv + 26) == 6;
} | static bool eap_ttls_isDone(struct eap_sm *sm, void *priv) {
struct eap_ttls_data *data = priv;
return data->state == SUCCESS || data->state == FAILURE;
} | eap_ttls_isDone | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
bool eap_ttls_isSuccess(eap_sm *sm, void *priv) {
return *((_DWORD *)priv + 26) == 5;
} | static bool eap_ttls_isSuccess(struct eap_sm *sm, void *priv) {
struct eap_ttls_data *data = priv;
return data->state == SUCCESS;
} | eap_ttls_isSuccess | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
int eap_ttls_phase2_eap_init(eap_sm *sm, eap_ttls_data *data, int vendor,
eap_type eap_type) {
if (data->phase2_priv && data->phase2_method) {
data->phase2_method->reset(sm, data->phase2_priv);
data->phase2_method = 0;
data->phase2_priv = 0;
}
data->phase2_method = eap_ser... | static int eap_ttls_phase2_eap_init(struct eap_sm *sm,
struct eap_ttls_data *data, int vendor,
enum eap_type eap_type) {
if (data->phase2_priv && data->phase2_method) {
data->phase2_method->reset(sm, data->phase2_priv);
data->phase2_metho... | eap_ttls_phase2_eap_init | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eap_ttls_process(eap_sm *sm, void *priv, wpabuf *respData) {
u8 *v3;
size_t v4;
u8 id_len;
const wpabuf *buf;
const u8 *pos;
const u8 *posa;
if (eap_server_tls_process(
sm, (eap_ssl_data *)priv, respData, priv, 21,
(int (*)(eap_sm *, void *, int))eap_ttls_process_version,
... | static void eap_ttls_process(struct eap_sm *sm, void *priv,
struct wpabuf *respData) {
struct eap_ttls_data *data = priv;
const struct wpabuf *buf;
const u8 *pos;
u8 id_len;
if (eap_server_tls_process(sm, &data->ssl, respData, data, EAP_TYPE_TTLS,
eap... | eap_ttls_process | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eap_ttls_process_msg(eap_sm *sm, void *priv, const wpabuf *respData) {
unsigned int v3;
size_t v4;
v3 = *((_DWORD *)priv + 26);
if (v3 == 4) {
if (!*((_DWORD *)priv + 32) ||
wpabuf_len_23(*((const wpabuf **)priv + 4))) {
if (*((_DWORD *)priv + 32)) {
v4 = wpabuf_len_23(*((const w... | static void eap_ttls_process_msg(struct eap_sm *sm, void *priv,
const struct wpabuf *respData) {
struct eap_ttls_data *data = priv;
switch (data->state) {
case PHASE1:
if (eap_server_tls_phase1(sm, &data->ssl) < 0)
eap_ttls_state(data, FAILURE);
break;
case PHASE2... | eap_ttls_process_msg | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eap_ttls_process_phase2(eap_sm *sm, eap_ttls_data *data, wpabuf *in_buf) {
size_t v3;
size_t v4;
const u8 *v5;
wpabuf *in_decrypted;
char *nbuf;
eap_ttls_avp parse;
unsigned long v10;
v10 = __readfsqword(0x28u);
v3 = wpabuf_len_23(in_buf);
wpa_printf(2, "EAP-TTLS: received %lu bytes encrypted ... | static void eap_ttls_process_phase2(struct eap_sm *sm,
struct eap_ttls_data *data,
struct wpabuf *in_buf) {
struct wpabuf *in_decrypted;
struct eap_ttls_avp parse;
wpa_printf(MSG_DEBUG,
"EAP-TTLS: received %lu bytes encrypted da... | eap_ttls_process_phase2 | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eap_ttls_process_phase2_chap(eap_sm *sm, eap_ttls_data *data,
const u8 *challenge, size_t challenge_len,
const u8 *password, size_t password_len) {
u8 *chal;
u8 hash[24];
unsigned long v10;
v10 = __readfsqword(0x28u);
if (challenge && p... | static void
eap_ttls_process_phase2_chap(struct eap_sm *sm, struct eap_ttls_data *data,
const u8 *challenge, size_t challenge_len,
const u8 *password, size_t password_len) {
u8 *chal, hash[CHAP_MD5_LEN];
if (challenge == NULL || password == NULL ||
ch... | eap_ttls_process_phase2_chap | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eap_ttls_process_phase2_eap(eap_sm *sm, eap_ttls_data *data, const u8 *eap,
size_t eap_len) {
size_t len;
if (data->state == 2 &&
(wpa_printf(2, "EAP-TTLS/EAP: initializing Phase 2"),
eap_ttls_phase2_eap_init(sm, data, 0, eap_type_EAP_TYPE_IDENTITY) < 0)) {
wp... | static void eap_ttls_process_phase2_eap(struct eap_sm *sm,
struct eap_ttls_data *data,
const u8 *eap, size_t eap_len) {
struct eap_hdr *hdr;
size_t len;
if (data->state == PHASE2_START) {
wpa_printf(MSG_DEBUG, "EAP-TTLS/EAP: init... | eap_ttls_process_phase2_eap | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eap_ttls_process_phase2_eap_response(eap_sm *sm, eap_ttls_data *data,
u8 *in_data, size_t in_len) {
eap_user *user;
int user_eap_method_index;
eap_ttls_data_$A8B437AF50AE1AB095BA7E14A48865B0 state;
int next_vendor;
eap_user_$C30F7A9355C0960A698D4B58193367EA next_... | static void eap_ttls_process_phase2_eap_response(struct eap_sm *sm,
struct eap_ttls_data *data,
u8 *in_data, size_t in_len) {
int next_vendor = EAP_VENDOR_IETF;
enum eap_type next_type = EAP_TYPE_NONE;
struct eap_hdr... | eap_ttls_process_phase2_eap_response | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eap_ttls_process_phase2_mschap(eap_sm *sm, eap_ttls_data *data,
u8 *challenge, size_t challenge_len,
u8 *response, size_t response_len) {
u8 *chal;
u8 nt_response[24];
unsigned long v10;
v10 = __readfsqword(0x28u);
if (challenge && ... | static void eap_ttls_process_phase2_mschap(struct eap_sm *sm,
struct eap_ttls_data *data,
u8 *challenge, size_t challenge_len,
u8 *response, size_t response_len) {
u8 *chal, nt_response[24]... | eap_ttls_process_phase2_mschap | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eap_ttls_process_phase2_mschapv2(eap_sm *sm, eap_ttls_data *data,
u8 *challenge, size_t challenge_len,
u8 *response, size_t response_len) {
u8 *username;
unsigned long username_len;
size_t i;
u8 *chal;
u8 *peer_challenge;
u8 nt... | static void eap_ttls_process_phase2_mschapv2(struct eap_sm *sm,
struct eap_ttls_data *data,
u8 *challenge,
size_t challenge_len, u8 *response,
... | eap_ttls_process_phase2_mschapv2 | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eap_ttls_process_phase2_pap(eap_sm *sm, eap_ttls_data *data,
const u8 *user_password,
size_t user_password_len) {
if (sm->user && sm->user->password && !sm->user->password_hash &&
(sm->user->ttls_auth & 1) != 0) {
if (user_password_len =... | static void eap_ttls_process_phase2_pap(struct eap_sm *sm,
struct eap_ttls_data *data,
const u8 *user_password,
size_t user_password_len) {
if (!sm->user || !sm->user->password || sm->user->password... | eap_ttls_process_phase2_pap | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
int eap_ttls_process_version(eap_sm *sm, void *priv, int peer_version) {
if (peer_version < *((_DWORD *)priv + 27)) {
wpa_printf(2, "EAP-TTLS: peer ver=%d, own ver=%d; use version %d",
peer_version, *((_DWORD *)priv + 27), peer_version);
*((_DWORD *)priv + 27) = peer_version;
}
return 0;
} | static int eap_ttls_process_version(struct eap_sm *sm, void *priv,
int peer_version) {
struct eap_ttls_data *data = priv;
if (peer_version < data->ttls_version) {
wpa_printf(MSG_DEBUG,
"EAP-TTLS: peer ver=%d, own ver=%d; "
"use version %d",
... | eap_ttls_process_version | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eap_ttls_reset(eap_sm *sm, void *priv) {
if (priv) {
if (*((_QWORD *)priv + 15)) {
if (*((_QWORD *)priv + 14))
(*(void (**)(eap_sm *, _QWORD))(*((_QWORD *)priv + 14) + 32LL))(
sm, *((_QWORD *)priv + 15));
}
eap_server_tls_ssl_deinit(sm, (eap_ssl_data *)priv);
wpabuf_free... | static void eap_ttls_reset(struct eap_sm *sm, void *priv) {
struct eap_ttls_data *data = priv;
if (data == NULL)
return;
if (data->phase2_priv && data->phase2_method)
data->phase2_method->reset(sm, data->phase2_priv);
eap_server_tls_ssl_deinit(sm, &data->ssl);
wpabuf_free(data->pending_phase2_eap_resp... | eap_ttls_reset | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eap_ttls_start_tnc(eap_sm *sm, eap_ttls_data *data) {
if (sm->cfg->tnc && data->state == 5 && !data->tnc_started) {
wpa_printf(2, "EAP-TTLS: Initialize TNC");
if (eap_ttls_phase2_eap_init(sm, data, 0, eap_type_EAP_TYPE_TNC)) {
wpa_printf(2, "EAP-TTLS: Failed to initialize TNC");
eap_ttls_stat... | static void eap_ttls_start_tnc(struct eap_sm *sm, struct eap_ttls_data *data) {
#ifdef EAP_SERVER_TNC
if (!sm->cfg->tnc || data->state != SUCCESS || data->tnc_started)
return;
wpa_printf(MSG_DEBUG, "EAP-TTLS: Initialize TNC");
if (eap_ttls_phase2_eap_init(sm, data, EAP_VENDOR_IETF, EAP_TYPE_TNC)) {
wpa_p... | eap_ttls_start_tnc | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eap_ttls_state(eap_ttls_data *data, int state) {
const char *v2;
const char *v3;
v2 = eap_ttls_state_txt(state);
v3 = eap_ttls_state_txt(data->state);
wpa_printf(2, "EAP-TTLS: %s -> %s", v3, v2);
data->state = state;
if (state == 6)
tls_connection_remove_session(data->ssl.conn);
} | static void eap_ttls_state(struct eap_ttls_data *data, int state) {
wpa_printf(MSG_DEBUG, "EAP-TTLS: %s -> %s", eap_ttls_state_txt(data->state),
eap_ttls_state_txt(state));
data->state = state;
if (state == FAILURE)
tls_connection_remove_session(data->ssl.conn);
} | eap_ttls_state | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
const char *eap_ttls_state_txt(int state) {
const char *result;
switch (state) {
case 0:
result = "START";
break;
case 1:
result = "PHASE1";
break;
case 2:
result = "PHASE2_START";
break;
case 3:
result = "PHASE2_METHOD";
break;
case 4:
result = "PHASE2_MSCHAPV2_RESP";... | static const char *eap_ttls_state_txt(int state) {
switch (state) {
case START:
return "START";
case PHASE1:
return "PHASE1";
case PHASE2_START:
return "PHASE2_START";
case PHASE2_METHOD:
return "PHASE2_METHOD";
case PHASE2_MSCHAPV2_RESP:
return "PHASE2_MSCHAPV2_RESP";
case SUCCESS:
... | eap_ttls_state_txt | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eap_ttls_valid_session(eap_sm *sm, eap_ttls_data *data) {
u8 id_len;
wpabuf *buf;
if (sm->cfg->tls_session_lifetime) {
buf = wpabuf_alloc(sm->identity_len + 2);
if (buf) {
wpabuf_put_u8_9(buf, 0x15u);
if (sm->identity) {
if (sm->identity_len > 0xFF)
id_len = -1;
... | static void eap_ttls_valid_session(struct eap_sm *sm,
struct eap_ttls_data *data) {
struct wpabuf *buf;
if (!sm->cfg->tls_session_lifetime)
return;
buf = wpabuf_alloc(1 + 1 + sm->identity_len);
if (!buf)
return;
wpabuf_put_u8(buf, EAP_TYPE_TTLS);
if (sm->identity... | eap_ttls_valid_session | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eap_update_len(wpabuf *msg) {
__uint16_t v1;
eap_hdr *hdr;
hdr = (eap_hdr *)wpabuf_mhead_9(msg);
if (wpabuf_len_65(msg) > 3) {
v1 = wpabuf_len_65(msg);
hdr->length = _bswap_16_13(v1);
}
} | void eap_update_len(struct wpabuf *msg) {
struct eap_hdr *hdr;
hdr = wpabuf_mhead(msg);
if (wpabuf_len(msg) < sizeof(*hdr))
return;
hdr->length = host_to_be16(wpabuf_len(msg));
} | eap_update_len | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eap_user_free(eap_user *user) {
if (user) {
bin_clear_free(user->password, user->password_len);
user->password = 0;
bin_clear_free(user->salt, user->salt_len);
user->salt = 0;
free(user);
}
} | void eap_user_free(struct eap_user *user) {
if (user == NULL)
return;
bin_clear_free(user->password, user->password_len);
user->password = NULL;
bin_clear_free(user->salt, user->salt_len);
user->salt = NULL;
os_free(user);
} | eap_user_free | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
int eap_user_get(eap_sm *sm, const u8 *identity, size_t identity_len,
int phase2) {
eap_user *user;
if (!sm || !sm->eapol_cb || !sm->eapol_cb->get_eap_user)
return -1;
eap_user_free(sm->user);
sm->user = 0;
user = (eap_user *)os_zalloc(0x88u);
if (!user)
return -1;
if (sm->eapol_... | int eap_user_get(struct eap_sm *sm, const u8 *identity, size_t identity_len,
int phase2) {
struct eap_user *user;
if (sm == NULL || sm->eapol_cb == NULL || sm->eapol_cb->get_eap_user == NULL)
return -1;
eap_user_free(sm->user);
sm->user = NULL;
user = os_zalloc(sizeof(*user));
if (us... | eap_user_get | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void *eap_wfa_unauth_tls_init(eap_sm *sm) {
eap_tls_data *data;
data = (eap_tls_data *)os_zalloc(0x78u);
if (!data)
return 0;
data->state = START;
if (eap_server_tls_ssl_init(sm, &data->ssl, 0, 254)) {
wpa_printf(3, "EAP-TLS: Failed to initialize SSL.");
eap_tls_reset(sm, data);
return 0;
}... | static void *eap_wfa_unauth_tls_init(struct eap_sm *sm) {
struct eap_tls_data *data;
data = os_zalloc(sizeof(*data));
if (data == NULL)
return NULL;
data->state = START;
if (eap_server_tls_ssl_init(sm, &data->ssl, 0, EAP_WFA_UNAUTH_TLS_TYPE)) {
wpa_printf(MSG_INFO, "EAP-TLS: Failed to initialize SSL... | eap_wfa_unauth_tls_init | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
wpabuf *eap_wsc_buildReq(eap_sm *sm, void *priv, u8 id) {
unsigned int v3;
v3 = *(_DWORD *)priv;
if (*(_DWORD *)priv == 3)
return eap_wsc_build_msg((eap_wsc_data *)priv, id);
if (v3 <= 3) {
if (v3 == 2)
return eap_wsc_build_frag_ack(id, 1u);
if (v3 <= 2) {
if (!v3)
return eap_ws... | static struct wpabuf *eap_wsc_buildReq(struct eap_sm *sm, void *priv, u8 id) {
struct eap_wsc_data *data = priv;
switch (data->state) {
case START:
return eap_wsc_build_start(sm, data, id);
case MESG:
if (data->out_buf == NULL) {
data->out_buf = wps_get_msg(data->wps, &data->out_op_code);
i... | eap_wsc_buildReq | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
wpabuf *eap_wsc_build_frag_ack(u8 id, u8 code) {
wpabuf *msg;
msg = eap_msg_alloc(14122, eap_type_EAP_TYPE_IDENTITY, 2u, code, id);
if (msg) {
wpa_printf(2, "EAP-WSC: Send WSC/FRAG_ACK");
wpabuf_put_u8_19(msg, 6u);
wpabuf_put_u8_19(msg, 0);
return msg;
} else {
wpa_printf(5, "EAP-WSC: Faile... | struct wpabuf *eap_wsc_build_frag_ack(u8 id, u8 code) {
struct wpabuf *msg;
msg = eap_msg_alloc(EAP_VENDOR_WFA, EAP_VENDOR_TYPE_WSC, 2, code, id);
if (msg == NULL) {
wpa_printf(MSG_ERROR, "EAP-WSC: Failed to allocate memory for "
"FRAG_ACK");
return NULL;
}
wpa_printf(MSG_D... | eap_wsc_build_frag_ack | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
wpabuf *eap_wsc_build_msg(eap_wsc_data *data, u8 id) {
u16 v3;
const u8 *v4;
size_t out_used;
size_t v6;
u8 flags;
size_t send_len;
size_t plen;
wpabuf *req;
flags = 0;
send_len = wpabuf_len_36(data->out_buf) - data->out_used;
if (send_len + 2 > data->fragment_size) {
send_len = data->fragmen... | static struct wpabuf *eap_wsc_build_msg(struct eap_wsc_data *data, u8 id) {
struct wpabuf *req;
u8 flags;
size_t send_len, plen;
flags = 0;
send_len = wpabuf_len(data->out_buf) - data->out_used;
if (2 + send_len > data->fragment_size) {
send_len = data->fragment_size - 2;
flags |= WSC_FLAGS_MF;
... | eap_wsc_build_msg | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
wpabuf *eap_wsc_build_start(eap_sm *sm, eap_wsc_data *data, u8 id) {
wpabuf *req;
req = eap_msg_alloc(14122, eap_type_EAP_TYPE_IDENTITY, 2u, 1u, id);
if (req) {
wpa_printf(2, "EAP-WSC: Send WSC/Start");
wpabuf_put_u8_18(req, 1u);
wpabuf_put_u8_18(req, 0);
return req;
} else {
wpa_printf(5, ... | static struct wpabuf *eap_wsc_build_start(struct eap_sm *sm,
struct eap_wsc_data *data, u8 id) {
struct wpabuf *req;
req = eap_msg_alloc(EAP_VENDOR_WFA, EAP_VENDOR_TYPE_WSC, 2, EAP_CODE_REQUEST,
id);
if (req == NULL) {
wpa_printf(MSG_ERROR, "EAP... | eap_wsc_build_start | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
bool eap_wsc_check(eap_sm *sm, void *priv, wpabuf *respData) {
size_t len;
const u8 *pos;
unsigned long v6;
v6 = __readfsqword(0x28u);
pos = eap_hdr_validate(14122, eap_type_EAP_TYPE_IDENTITY, respData, &len);
if (pos && len > 1)
return 0;
wpa_printf(3, "EAP-WSC: Invalid frame");
return 1;
} | static bool eap_wsc_check(struct eap_sm *sm, void *priv,
struct wpabuf *respData) {
const u8 *pos;
size_t len;
pos = eap_hdr_validate(EAP_VENDOR_WFA, EAP_VENDOR_TYPE_WSC, respData, &len);
if (pos == NULL || len < 2) {
wpa_printf(MSG_INFO, "EAP-WSC: Invalid frame");
return true... | eap_wsc_check | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eap_wsc_ext_reg_timeout(void *eloop_ctx, void *timeout_ctx) {
if (*((_DWORD *)eloop_ctx + 129) == 1) {
wpa_printf(2, "EAP-WSC: Timeout while waiting for an External Registrar");
*((_DWORD *)timeout_ctx + 14) = 1;
eap_sm_pending_cb((eap_sm *)eloop_ctx);
}
} | static void eap_wsc_ext_reg_timeout(void *eloop_ctx, void *timeout_ctx) {
struct eap_sm *sm = eloop_ctx;
struct eap_wsc_data *data = timeout_ctx;
if (sm->method_pending != METHOD_PENDING_WAIT)
return;
wpa_printf(MSG_DEBUG, "EAP-WSC: Timeout while waiting for an External "
"Registra... | eap_wsc_ext_reg_timeout | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
int eap_wsc_getTimeout(eap_sm *sm, void *priv) {
sm->MaxRetrans = 2;
return 5;
} | static int eap_wsc_getTimeout(struct eap_sm *sm, void *priv) {
sm->MaxRetrans = 2;
return 5;
} | eap_wsc_getTimeout | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void *eap_wsc_init(eap_sm *sm) {
long fragment_size;
int registrar;
eap_wsc_data *data;
wps_config_0 cfg;
unsigned long v6;
v6 = __readfsqword(0x28u);
if (sm->identity && sm->identity_len == 30 &&
!memcmp(sm->identity, "WFA-SimpleConfig-Registrar-1-0", 0x1Eu)) {
registrar = 0;
} else {
if... | static void *eap_wsc_init(struct eap_sm *sm) {
struct eap_wsc_data *data;
int registrar;
struct wps_config cfg;
if (sm->identity && sm->identity_len == WSC_ID_REGISTRAR_LEN &&
os_memcmp(sm->identity, WSC_ID_REGISTRAR, WSC_ID_REGISTRAR_LEN) == 0)
registrar = 0;
else if (sm->identity && sm->identity_... | eap_wsc_init | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
bool eap_wsc_isDone(eap_sm *sm, void *priv) { return *(_DWORD *)priv == 5; } | static bool eap_wsc_isDone(struct eap_sm *sm, void *priv) {
struct eap_wsc_data *data = priv;
return data->state == FAIL;
} | eap_wsc_isDone | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
bool eap_wsc_isSuccess(eap_sm *sm, void *priv) { return 0; } | static bool eap_wsc_isSuccess(struct eap_sm *sm, void *priv) { return false; } | eap_wsc_isSuccess | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eap_wsc_process(eap_sm *sm, void *priv, wpabuf *respData) {
u8 *v3;
u8 *v4;
u8 op_code;
u8 flags;
u16 message_length;
wps_process_res res;
size_t len;
const u8 *pos;
eap_wsc_data *data;
const u8 *start;
const u8 *end;
wpabuf tmpbuf;
unsigned long v16;
v16 = __readfsqword(0x28u);
data... | static void eap_wsc_process(struct eap_sm *sm, void *priv,
struct wpabuf *respData) {
struct eap_wsc_data *data = priv;
const u8 *start, *pos, *end;
size_t len;
u8 op_code, flags;
u16 message_length = 0;
enum wps_process_res res;
struct wpabuf tmpbuf;
eloop_cancel_timeout(ea... | eap_wsc_process | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
int eap_wsc_process_cont(eap_wsc_data *data, const u8 *buf, size_t len,
u8 op_code) {
size_t v5;
if (op_code == data->in_op_code) {
if (len <= wpabuf_tailroom_3(data->in_buf)) {
wpabuf_put_data_24(data->in_buf, buf, len);
v5 = wpabuf_tailroom_3(data->in_buf);
wpa_prin... | static int eap_wsc_process_cont(struct eap_wsc_data *data, const u8 *buf,
size_t len, u8 op_code) {
if (op_code != data->in_op_code) {
wpa_printf(MSG_DEBUG,
"EAP-WSC: Unexpected Op-Code %d in "
"fragment (expected %d)",
op_code, data->i... | eap_wsc_process_cont | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
int eap_wsc_process_fragment(eap_wsc_data *data, u8 flags, u8 op_code,
u16 message_length, const u8 *buf, size_t len) {
size_t v7;
if (!data->in_buf && (flags & 2) == 0) {
wpa_printf(2, "EAP-WSC: No Message Length field in a fragmented packet");
return -1;
}
if (!data->in_b... | static int eap_wsc_process_fragment(struct eap_wsc_data *data, u8 flags,
u8 op_code, u16 message_length,
const u8 *buf, size_t len) {
if (data->in_buf == NULL && !(flags & WSC_FLAGS_LF)) {
wpa_printf(MSG_DEBUG, "EAP-WSC: No Message Length "
... | eap_wsc_process_fragment | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eap_wsc_reset(eap_sm *sm, void *priv) {
eloop_cancel_timeout((eloop_timeout_handler)eap_wsc_ext_reg_timeout, sm,
priv);
wpabuf_free(*((wpabuf **)priv + 1));
wpabuf_free(*((wpabuf **)priv + 2));
wps_deinit(*((wps_data **)priv + 6));
free(priv);
} | static void eap_wsc_reset(struct eap_sm *sm, void *priv) {
struct eap_wsc_data *data = priv;
eloop_cancel_timeout(eap_wsc_ext_reg_timeout, sm, data);
wpabuf_free(data->in_buf);
wpabuf_free(data->out_buf);
wps_deinit(data->wps);
os_free(data);
} | eap_wsc_reset | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eap_wsc_state(eap_wsc_data *data, int state) {
const char *v2;
const char *v3;
v2 = eap_wsc_state_txt(state);
v3 = eap_wsc_state_txt(data->state);
wpa_printf(2, "EAP-WSC: %s -> %s", v3, v2);
data->state = state;
} | static void eap_wsc_state(struct eap_wsc_data *data, int state) {
wpa_printf(MSG_DEBUG, "EAP-WSC: %s -> %s", eap_wsc_state_txt(data->state),
eap_wsc_state_txt(state));
data->state = state;
} | eap_wsc_state | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
const char *eap_wsc_state_txt(int state) {
const char *result;
switch (state) {
case 0:
result = "START";
break;
case 1:
result = "MESG";
break;
case 2:
result = "FRAG_ACK";
break;
case 3:
result = "WAIT_FRAG_ACK";
break;
case 4:
result = "DONE";
break;
case 5:
... | static const char *eap_wsc_state_txt(int state) {
switch (state) {
case START:
return "START";
case MESG:
return "MESG";
case FRAG_ACK:
return "FRAG_ACK";
case WAIT_FRAG_ACK:
return "WAIT_FRAG_ACK";
case DONE:
return "DONE";
case FAIL:
return "FAIL";
default:
return "?";
}
... | eap_wsc_state_txt | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
eapol_state_machine *
eapol_auth_alloc(eapol_authenticator *eapol, const u8 *addr, int flags,
const wpabuf *assoc_wps_ie, const wpabuf *assoc_p2p_ie,
void *sta_ctx, const char *identity, const char *radius_cui) {
size_t v9;
eapol_state_machine *sm;
eap_session_data_0 eap_sess;
... | struct eapol_state_machine *
eapol_auth_alloc(struct eapol_authenticator *eapol, const u8 *addr, int flags,
const struct wpabuf *assoc_wps_ie,
const struct wpabuf *assoc_p2p_ie, void *sta_ctx,
const char *identity, const char *radius_cui) {
struct eapol_state_machine... | eapol_auth_alloc | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
int eapol_auth_conf_clone(eapol_auth_config *dst, eapol_auth_config *src) {
dst->eap_cfg = src->eap_cfg;
dst->ctx = src->ctx;
dst->eap_reauth_period = src->eap_reauth_period;
dst->wpa = src->wpa;
free(dst->eap_req_id_text);
if (src->eap_req_id_text) {
dst->eap_req_id_text =
(char *)os_memdup(src... | static int eapol_auth_conf_clone(struct eapol_auth_config *dst,
struct eapol_auth_config *src) {
dst->eap_cfg = src->eap_cfg;
dst->ctx = src->ctx;
dst->eap_reauth_period = src->eap_reauth_period;
dst->wpa = src->wpa;
#ifdef CONFIG_WEP
dst->individual_wep_key_len = src->individ... | eapol_auth_conf_clone | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eapol_auth_conf_free(eapol_auth_config *conf) {
free(conf->eap_req_id_text);
conf->eap_req_id_text = 0;
free(conf->erp_domain);
conf->erp_domain = 0;
} | static void eapol_auth_conf_free(struct eapol_auth_config *conf) {
os_free(conf->eap_req_id_text);
conf->eap_req_id_text = NULL;
os_free(conf->erp_domain);
conf->erp_domain = NULL;
} | eapol_auth_conf_free | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eapol_auth_deinit(eapol_authenticator *eapol) {
if (eapol) {
eapol_auth_conf_free(&eapol->conf);
free(eapol);
}
} | void eapol_auth_deinit(struct eapol_authenticator *eapol) {
if (eapol == NULL)
return;
eapol_auth_conf_free(&eapol->conf);
#ifdef CONFIG_WEP
os_free(eapol->default_wep_key);
#endif
os_free(eapol);
} | eapol_auth_deinit | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
int eapol_auth_dump_state(eapol_state_machine *sm, char *buf, size_t buflen) {
const char *v4;
const char *v5;
const char *v6;
const char *v7;
const char *v8;
const char *v9;
const char *v10;
const char *v11;
Counter authAuthEapLogoffWhileAuthenticated;
const char *v13;
const char *v14;
const ch... | int eapol_auth_dump_state(struct eapol_state_machine *sm, char *buf,
size_t buflen) {
char *pos, *end;
int ret;
pos = buf;
end = pos + buflen;
ret = os_snprintf(pos, end - pos,
"aWhile=%d\nquietWhile=%d\n"
"reAuthWhen=%d\n",
... | eapol_auth_dump_state | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
int eapol_auth_eap_pending_cb(eapol_state_machine *sm, void *ctx) {
if (!sm || !ctx || ctx != sm->eap)
return -1;
eap_sm_pending_cb(sm->eap);
eapol_auth_step(sm);
return 0;
} | int eapol_auth_eap_pending_cb(struct eapol_state_machine *sm, void *ctx) {
if (sm == NULL || ctx == NULL || ctx != sm->eap)
return -1;
eap_sm_pending_cb(sm->eap);
eapol_auth_step(sm);
return 0;
} | eapol_auth_eap_pending_cb | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eapol_auth_free(eapol_state_machine *sm) {
if (sm) {
eloop_cancel_timeout((eloop_timeout_handler)eapol_port_timers_tick, 0, sm);
eloop_cancel_timeout((eloop_timeout_handler)eapol_sm_step_cb, sm, 0);
if (sm->eap)
eap_server_sm_deinit(sm->eap);
wpabuf_free(sm->radius_cui);
free(sm->identi... | void eapol_auth_free(struct eapol_state_machine *sm) {
if (sm == NULL)
return;
eloop_cancel_timeout(eapol_port_timers_tick, NULL, sm);
eloop_cancel_timeout(eapol_sm_step_cb, sm, NULL);
if (sm->eap)
eap_server_sm_deinit(sm->eap);
wpabuf_free(sm->radius_cui);
os_free(sm->identity);
os_free(sm);
} | eapol_auth_free | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
eapol_authenticator *eapol_auth_init(eapol_auth_config *conf,
eapol_auth_cb *cb) {
eapol_authenticator *eapol;
eapol = (eapol_authenticator *)os_zalloc(0xB0u);
if (!eapol)
return 0;
if (eapol_auth_conf_clone(&eapol->conf, conf) >= 0) {
eapol->cb = *cb;
return ea... | struct eapol_authenticator *eapol_auth_init(struct eapol_auth_config *conf,
struct eapol_auth_cb *cb) {
struct eapol_authenticator *eapol;
eapol = os_zalloc(sizeof(*eapol));
if (eapol == NULL)
return NULL;
if (eapol_auth_conf_clone(&eapol->conf, conf) < 0) {
... | eapol_auth_init | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eapol_auth_initialize(eapol_state_machine *sm) {
sm->initializing = 1;
sm->initialize = 1;
eapol_sm_step_run(sm);
sm->initialize = 0;
eapol_sm_step_run(sm);
sm->initializing = 0;
eloop_cancel_timeout((eloop_timeout_handler)eapol_port_timers_tick, 0, sm);
eloop_register_timeout(1u, 0, (eloop_timeout... | static void eapol_auth_initialize(struct eapol_state_machine *sm) {
sm->initializing = true;
sm->initialize = true;
eapol_sm_step_run(sm);
sm->initialize = false;
eapol_sm_step_run(sm);
sm->initializing = false;
eloop_cancel_timeout(eapol_port_timers_tick, NULL, sm);
eloop_register_timeout(1, 0, eapol... | eapol_auth_initialize | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eapol_auth_logger(eapol_authenticator *eapol, const u8 *addr,
eapol_logger_level level, const char *txt) {
if (eapol->cb.logger)
eapol->cb.logger(eapol->conf.ctx, addr, level, txt);
} | static void eapol_auth_logger(struct eapol_authenticator *eapol, const u8 *addr,
eapol_logger_level level, const char *txt) {
if (eapol->cb.logger == NULL)
return;
eapol->cb.logger(eapol->conf.ctx, addr, level, txt);
} | eapol_auth_logger | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eapol_auth_reauthenticate(eapol_state_machine *sm) {
wpa_printf(2,
"EAPOL: External reauthentication trigger for "
"%02x:%02x:%02x:%02x:%02x:%02x",
sm->addr[0], sm->addr[1], sm->addr[2], sm->addr[3], sm->addr[4],
sm->addr[5]);
sm->reAuthenticate = 1;
eapol_... | void eapol_auth_reauthenticate(struct eapol_state_machine *sm) {
wpa_printf(MSG_DEBUG, "EAPOL: External reauthentication trigger for " MACSTR,
MAC2STR(sm->addr));
sm->reAuthenticate = true;
eapol_auth_step(sm);
} | eapol_auth_reauthenticate | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
int eapol_auth_set_conf(eapol_state_machine *sm, const char *param,
const char *value) {
wpa_printf(2,
"EAPOL: External configuration operation for "
"%02x:%02x:%02x:%02x:%02x:%02x - param=%s value=%s",
sm->addr[0], sm->addr[1], sm->addr[2], sm->addr[3], ... | int eapol_auth_set_conf(struct eapol_state_machine *sm, const char *param,
const char *value) {
wpa_printf(MSG_DEBUG,
"EAPOL: External configuration operation for " MACSTR
" - param=%s value=%s",
MAC2STR(sm->addr), param, value);
if (os_strcasecmp(para... | eapol_auth_set_conf | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eapol_auth_step(eapol_state_machine *sm) {
eloop_register_timeout(0, 0, (eloop_timeout_handler)eapol_sm_step_cb, sm, 0);
} | void eapol_auth_step(struct eapol_state_machine *sm) {
eloop_register_timeout(0, 0, eapol_sm_step_cb, sm, NULL);
} | eapol_auth_step | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eapol_auth_tx_canned_eap(eapol_state_machine *sm, int success) {
u8 v2;
const char *v3;
eap_hdr eap;
unsigned long v5;
v5 = __readfsqword(0x28u);
memset(&eap, 0, sizeof(eap));
if (success)
v2 = 3;
else
v2 = 4;
eap.code = v2;
eap.identifier = ++sm->last_eap_id;
eap.length = _bswap_16_... | static void eapol_auth_tx_canned_eap(struct eapol_state_machine *sm,
int success) {
struct eap_hdr eap;
os_memset(&eap, 0, sizeof(eap));
eap.code = success ? EAP_CODE_SUCCESS : EAP_CODE_FAILURE;
eap.identifier = ++sm->last_eap_id;
eap.length = host_to_be16(sizeof(eap));
... | eapol_auth_tx_canned_eap | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eapol_auth_tx_req(eapol_state_machine *sm) {
void (*eapol_send)(void *, void *, u8, const u8 *, size_t);
size_t v2;
const u8 *v3;
if (sm->eap_if->eapReqData && wpabuf_len_10(sm->eap_if->eapReqData) > 3) {
if ((sm->flags & 2) != 0) {
wpa_printf(2,
"EAPOL: Drop EAPOL TX to %02x:%0... | static void eapol_auth_tx_req(struct eapol_state_machine *sm) {
if (sm->eap_if->eapReqData == NULL ||
wpabuf_len(sm->eap_if->eapReqData) < sizeof(struct eap_hdr)) {
eapol_auth_logger(sm->eapol, sm->addr, EAPOL_LOGGER_DEBUG,
"TxReq called, but there is no EAP request "
... | eapol_auth_tx_req | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eapol_auth_vlogger(eapol_authenticator *eapol, const u8 *addr,
eapol_logger_level level, const char *fmt, ...) {
long v4;
long v5;
int maxlen;
char *format;
va_list ap;
unsigned long v11;
long v12;
long v13;
va_start(ap, fmt);
v4 = va_arg(ap, _QWORD);
v5 = va_arg(ap, ... | PRINTF_FORMAT(4, 5)
static void eapol_auth_vlogger(struct eapol_authenticator *eapol,
const u8 *addr, eapol_logger_level level,
const char *fmt, ...) {
char *format;
int maxlen;
va_list ap;
if (eapol->cb.logger == NULL)
return;
maxlen = os_st... | eapol_auth_vlogger | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eapol_port_timers_tick(void *eloop_ctx, void *timeout_ctx) {
if (*(int *)timeout_ctx > 0 && !--*(_DWORD *)timeout_ctx)
wpa_printf(2, "IEEE 802.1X: %02x:%02x:%02x:%02x:%02x:%02x - aWhile --> 0",
*((unsigned char *)timeout_ctx + 216),
*((unsigned char *)timeout_ctx + 217),
... | static void eapol_port_timers_tick(void *eloop_ctx, void *timeout_ctx) {
struct eapol_state_machine *state = timeout_ctx;
if (state->aWhile > 0) {
state->aWhile--;
if (state->aWhile == 0) {
wpa_printf(MSG_DEBUG, "IEEE 802.1X: " MACSTR " - aWhile --> 0",
MAC2STR(state->addr));
}
... | eapol_port_timers_tick | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
int eapol_sm_erp_add_key(void *ctx, eap_server_erp_key *erp) {
return (
*(int (**)(_QWORD, eap_server_erp_key *))(*((_QWORD *)ctx + 41) + 152LL))(
*(_QWORD *)(*((_QWORD *)ctx + 41) + 56LL), erp);
} | static int eapol_sm_erp_add_key(void *ctx, struct eap_server_erp_key *erp) {
struct eapol_state_machine *sm = ctx;
return sm->eapol->cb.erp_add_key(sm->eapol->conf.ctx, erp);
} | eapol_sm_erp_add_key | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
eap_server_erp_key *eapol_sm_erp_get_key(void *ctx, const char *keyname) {
return (*(eap_server_erp_key * (**)(_QWORD, const char *))(
*((_QWORD *)ctx + 41) + 144LL))(*(_QWORD *)(*((_QWORD *)ctx + 41) + 56LL),
keyname);
} | static struct eap_server_erp_key *eapol_sm_erp_get_key(void *ctx,
const char *keyname) {
struct eapol_state_machine *sm = ctx;
return sm->eapol->cb.erp_get_key(sm->eapol->conf.ctx, keyname);
} | eapol_sm_erp_get_key | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
const char *eapol_sm_get_eap_req_id_text(void *ctx, size_t *len) {
*len = *(_QWORD *)(*((_QWORD *)ctx + 41) + 32LL);
return *(const char **)(*((_QWORD *)ctx + 41) + 24LL);
} | static const char *eapol_sm_get_eap_req_id_text(void *ctx, size_t *len) {
struct eapol_state_machine *sm = ctx;
*len = sm->eapol->conf.eap_req_id_text_len;
return sm->eapol->conf.eap_req_id_text;
} | eapol_sm_get_eap_req_id_text | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
int eapol_sm_get_eap_user(void *ctx, const u8 *identity, size_t identity_len,
int phase2, eap_user *user) {
int ret;
ret = (*(long (**)(_QWORD, const u8 *, size_t, _QWORD, eap_user *))(
*((_QWORD *)ctx + 41) + 88LL))(*(_QWORD *)(*((_QWORD *)ctx + 41) + 56LL),
... | static int eapol_sm_get_eap_user(void *ctx, const u8 *identity,
size_t identity_len, int phase2,
struct eap_user *user) {
struct eapol_state_machine *sm = ctx;
int ret;
ret = sm->eapol->cb.get_eap_user(sm->eapol->conf.ctx, identity, identity_len,
... | eapol_sm_get_eap_user | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
const char *eapol_sm_get_erp_domain(void *ctx) {
return *(const char **)(*((_QWORD *)ctx + 41) + 48LL);
} | static const char *eapol_sm_get_erp_domain(void *ctx) {
struct eapol_state_machine *sm = ctx;
return sm->eapol->conf.erp_domain;
} | eapol_sm_get_erp_domain | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
int eapol_sm_get_erp_send_reauth_start(void *ctx) {
return *(_DWORD *)(*((_QWORD *)ctx + 41) + 40LL);
} | static int eapol_sm_get_erp_send_reauth_start(void *ctx) {
struct eapol_state_machine *sm = ctx;
return sm->eapol->conf.erp_send_reauth_start;
} | eapol_sm_get_erp_send_reauth_start | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
int eapol_sm_sta_entry_alive(eapol_authenticator *eapol, const u8 *addr) {
return eapol->cb.sta_entry_alive(eapol->conf.ctx, addr);
} | static int eapol_sm_sta_entry_alive(struct eapol_authenticator *eapol,
const u8 *addr) {
return eapol->cb.sta_entry_alive(eapol->conf.ctx, addr);
} | eapol_sm_sta_entry_alive | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eapol_sm_step_cb(void *eloop_ctx, void *timeout_ctx) {
eapol_sm_step_run((eapol_state_machine *)eloop_ctx);
} | static void eapol_sm_step_cb(void *eloop_ctx, void *timeout_ctx) {
struct eapol_state_machine *sm = eloop_ctx;
eapol_sm_step_run(sm);
} | eapol_sm_step_cb | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
void eapol_sm_step_run(eapol_state_machine *sm) {
void (*aaa_send)(void *, void *, const u8 *, size_t);
size_t v2;
const u8 *v3;
int max_steps;
eapol_state_machine_$9D79E0E8BE6624DF62DCC50DB2CA689A prev_auth_pae;
eapol_state_machine_$84970FB7B763FCBAD231DC05B663F0AB prev_be_auth;
eapol_state_machine_$7E9A... | static void eapol_sm_step_run(struct eapol_state_machine *sm) {
struct eapol_authenticator *eapol = sm->eapol;
u8 addr[ETH_ALEN];
unsigned int prev_auth_pae, prev_be_auth, prev_reauth_timer, prev_auth_key_tx,
prev_key_rx, prev_ctrl_dir;
int max_steps = 100;
os_memcpy(addr, sm->addr, ETH_ALEN);
restart... | eapol_sm_step_run | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
int eloop_cancel_timeout_one(eloop_timeout_handler handler, void *eloop_data,
void *user_data, os_reltime *remaining) {
int removed;
eloop_timeout *timeout;
eloop_timeout *prev;
os_reltime now;
unsigned long v11;
v11 = __readfsqword(0x28u);
removed = 0;
os_get_reltime(&now)... | int eloop_cancel_timeout_one(eloop_timeout_handler handler, void *eloop_data,
void *user_data, struct os_reltime *remaining) {
struct eloop_timeout *timeout, *prev;
int removed = 0;
struct os_reltime now;
os_get_reltime(&now);
remaining->sec = remaining->usec = 0;
dl_list_for_... | eloop_cancel_timeout_one | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
int eloop_deplete_timeout(unsigned int req_secs, unsigned int req_usecs,
eloop_timeout_handler handler, void *eloop_data,
void *user_data) {
eloop_timeout *tmp;
os_reltime now;
os_reltime requested;
os_reltime remaining;
unsigned long v13;
v13 = __readfsq... | int eloop_deplete_timeout(unsigned int req_secs, unsigned int req_usecs,
eloop_timeout_handler handler, void *eloop_data,
void *user_data) {
struct os_reltime now, requested, remaining;
struct eloop_timeout *tmp;
dl_list_for_each(tmp, &eloop.timeout, struct elo... | eloop_deplete_timeout | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
int eloop_init() {
int *v0;
char *v1;
memset(&eloop, 0, sizeof(eloop));
dl_list_init_4(&eloop.timeout);
eloop.epollfd = epoll_create1(0);
if (eloop.epollfd >= 0) {
eloop.readers.type = EVENT_TYPE_READ;
eloop.writers.type = EVENT_TYPE_WRITE;
eloop.exceptions.type = EVENT_TYPE_EXCEPTION;
retu... | while (0)
#endif
int eloop_init(void) {
os_memset(&eloop, 0, sizeof(eloop));
dl_list_init(&eloop.timeout);
#ifdef CONFIG_ELOOP_EPOLL
eloop.epollfd = epoll_create1(0);
if (eloop.epollfd < 0) {
wpa_printf(MSG_ERROR, "%s: epoll_create1 failed. %s", __func__,
strerror(errno));
... | eloop_init | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
int eloop_register_signal(int sig, eloop_signal_handler handler,
void *user_data) {
eloop_signal *tmp;
tmp = (eloop_signal *)os_realloc_array_4(eloop.signals,
eloop.signal_count + 1, 0x20u);
if (!tmp)
return -1;
tmp[eloop.signal_count].si... | int eloop_register_signal(int sig, eloop_signal_handler handler,
void *user_data) {
struct eloop_signal *tmp;
tmp = os_realloc_array(eloop.signals, eloop.signal_count + 1,
sizeof(struct eloop_signal));
if (tmp == NULL)
return -1;
tmp[eloop.signal_count].s... | eloop_register_signal | hostapd-2.10 | net-wireless | O0/net-wireless/hostapd-2.10/hostapd | ida | O0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.