Lines Matching refs:parse

941 				   struct ttls_parse_avp *parse)  in eap_ttls_parse_attr_eap()  argument
944 if (parse->eapdata == NULL) { in eap_ttls_parse_attr_eap()
945 parse->eapdata = os_memdup(dpos, dlen); in eap_ttls_parse_attr_eap()
946 if (parse->eapdata == NULL) { in eap_ttls_parse_attr_eap()
951 parse->eap_len = dlen; in eap_ttls_parse_attr_eap()
953 u8 *neweap = os_realloc(parse->eapdata, parse->eap_len + dlen); in eap_ttls_parse_attr_eap()
959 os_memcpy(neweap + parse->eap_len, dpos, dlen); in eap_ttls_parse_attr_eap()
960 parse->eapdata = neweap; in eap_ttls_parse_attr_eap()
961 parse->eap_len += dlen; in eap_ttls_parse_attr_eap()
969 struct ttls_parse_avp *parse) in eap_ttls_parse_avp() argument
1016 if (eap_ttls_parse_attr_eap(dpos, dlen, parse) < 0) in eap_ttls_parse_avp()
1034 parse->mschapv2 = dpos; in eap_ttls_parse_avp()
1039 parse->mschapv2_error = 1; in eap_ttls_parse_avp()
1056 struct ttls_parse_avp *parse) in eap_ttls_parse_avps() argument
1074 os_memset(parse, 0, sizeof(*parse)); in eap_ttls_parse_avps()
1077 avp_length = eap_ttls_parse_avp(pos, left, parse); in eap_ttls_parse_avps()
1144 struct ttls_parse_avp *parse, in eap_ttls_process_phase2_eap() argument
1150 if (parse->eapdata == NULL) { in eap_ttls_process_phase2_eap()
1157 parse->eapdata, parse->eap_len); in eap_ttls_process_phase2_eap()
1158 hdr = (struct eap_hdr *) parse->eapdata; in eap_ttls_process_phase2_eap()
1160 if (parse->eap_len < sizeof(*hdr)) { in eap_ttls_process_phase2_eap()
1163 (unsigned long) parse->eap_len, in eap_ttls_process_phase2_eap()
1168 if (len > parse->eap_len) { in eap_ttls_process_phase2_eap()
1173 (unsigned long) parse->eap_len); in eap_ttls_process_phase2_eap()
1200 struct ttls_parse_avp *parse) in eap_ttls_process_phase2_mschapv2() argument
1203 if (parse->mschapv2_error) { in eap_ttls_process_phase2_mschapv2()
1212 if (parse->mschapv2 == NULL) { in eap_ttls_process_phase2_mschapv2()
1214 if (data->phase2_success && parse->eapdata) { in eap_ttls_process_phase2_mschapv2()
1226 if (parse->mschapv2[0] != data->ident) { in eap_ttls_process_phase2_mschapv2()
1229 parse->mschapv2[0], data->ident); in eap_ttls_process_phase2_mschapv2()
1234 parse->mschapv2 + 1, 42)) { in eap_ttls_process_phase2_mschapv2()
1262 struct ttls_parse_avp *parse, in eap_ttls_process_tnc_start() argument
1266 if (parse->eapdata == NULL) { in eap_ttls_process_tnc_start()
1282 if (eap_ttls_process_phase2_eap(sm, data, ret, parse, resp) < 0) in eap_ttls_process_tnc_start()
1294 struct ttls_parse_avp *parse, in eap_ttls_process_decrypted() argument
1310 if (eap_ttls_process_phase2_eap(sm, data, ret, parse, &resp) < in eap_ttls_process_decrypted()
1315 res = eap_ttls_process_phase2_mschapv2(sm, data, ret, parse); in eap_ttls_process_decrypted()
1317 if (res == 1 && parse->eapdata && data->phase2_success) { in eap_ttls_process_decrypted()
1324 if (eap_ttls_process_tnc_start(sm, data, ret, parse, in eap_ttls_process_decrypted()
1334 if (eap_ttls_process_tnc_start(sm, data, ret, parse, &resp) < in eap_ttls_process_decrypted()
1455 struct ttls_parse_avp parse; in eap_ttls_decrypt() local
1457 os_memset(&parse, 0, sizeof(parse)); in eap_ttls_decrypt()
1514 if (eap_ttls_parse_avps(in_decrypted, &parse) < 0) { in eap_ttls_decrypt()
1520 &parse, in_decrypted, out_data); in eap_ttls_decrypt()
1524 os_free(parse.eapdata); in eap_ttls_decrypt()