Lines Matching refs:parse

916 				   struct ttls_parse_avp *parse)  in eap_ttls_parse_attr_eap()  argument
919 if (parse->eapdata == NULL) { in eap_ttls_parse_attr_eap()
920 parse->eapdata = os_memdup(dpos, dlen); in eap_ttls_parse_attr_eap()
921 if (parse->eapdata == NULL) { in eap_ttls_parse_attr_eap()
926 parse->eap_len = dlen; in eap_ttls_parse_attr_eap()
928 u8 *neweap = os_realloc(parse->eapdata, parse->eap_len + dlen); in eap_ttls_parse_attr_eap()
934 os_memcpy(neweap + parse->eap_len, dpos, dlen); in eap_ttls_parse_attr_eap()
935 parse->eapdata = neweap; in eap_ttls_parse_attr_eap()
936 parse->eap_len += dlen; in eap_ttls_parse_attr_eap()
944 struct ttls_parse_avp *parse) in eap_ttls_parse_avp() argument
991 if (eap_ttls_parse_attr_eap(dpos, dlen, parse) < 0) in eap_ttls_parse_avp()
1009 parse->mschapv2 = dpos; in eap_ttls_parse_avp()
1014 parse->mschapv2_error = 1; in eap_ttls_parse_avp()
1031 struct ttls_parse_avp *parse) in eap_ttls_parse_avps() argument
1049 os_memset(parse, 0, sizeof(*parse)); in eap_ttls_parse_avps()
1052 avp_length = eap_ttls_parse_avp(pos, left, parse); in eap_ttls_parse_avps()
1119 struct ttls_parse_avp *parse, in eap_ttls_process_phase2_eap() argument
1125 if (parse->eapdata == NULL) { in eap_ttls_process_phase2_eap()
1132 parse->eapdata, parse->eap_len); in eap_ttls_process_phase2_eap()
1133 hdr = (struct eap_hdr *) parse->eapdata; in eap_ttls_process_phase2_eap()
1135 if (parse->eap_len < sizeof(*hdr)) { in eap_ttls_process_phase2_eap()
1138 (unsigned long) parse->eap_len, in eap_ttls_process_phase2_eap()
1143 if (len > parse->eap_len) { in eap_ttls_process_phase2_eap()
1148 (unsigned long) parse->eap_len); in eap_ttls_process_phase2_eap()
1175 struct ttls_parse_avp *parse) in eap_ttls_process_phase2_mschapv2() argument
1178 if (parse->mschapv2_error) { in eap_ttls_process_phase2_mschapv2()
1187 if (parse->mschapv2 == NULL) { in eap_ttls_process_phase2_mschapv2()
1189 if (data->phase2_success && parse->eapdata) { in eap_ttls_process_phase2_mschapv2()
1201 if (parse->mschapv2[0] != data->ident) { in eap_ttls_process_phase2_mschapv2()
1204 parse->mschapv2[0], data->ident); in eap_ttls_process_phase2_mschapv2()
1209 parse->mschapv2 + 1, 42)) { in eap_ttls_process_phase2_mschapv2()
1237 struct ttls_parse_avp *parse, in eap_ttls_process_tnc_start() argument
1241 if (parse->eapdata == NULL) { in eap_ttls_process_tnc_start()
1257 if (eap_ttls_process_phase2_eap(sm, data, ret, parse, resp) < 0) in eap_ttls_process_tnc_start()
1269 struct ttls_parse_avp *parse, in eap_ttls_process_decrypted() argument
1285 if (eap_ttls_process_phase2_eap(sm, data, ret, parse, &resp) < in eap_ttls_process_decrypted()
1290 res = eap_ttls_process_phase2_mschapv2(sm, data, ret, parse); in eap_ttls_process_decrypted()
1292 if (res == 1 && parse->eapdata && data->phase2_success) { in eap_ttls_process_decrypted()
1299 if (eap_ttls_process_tnc_start(sm, data, ret, parse, in eap_ttls_process_decrypted()
1309 if (eap_ttls_process_tnc_start(sm, data, ret, parse, &resp) < in eap_ttls_process_decrypted()
1430 struct ttls_parse_avp parse; in eap_ttls_decrypt() local
1432 os_memset(&parse, 0, sizeof(parse)); in eap_ttls_decrypt()
1489 if (eap_ttls_parse_avps(in_decrypted, &parse) < 0) { in eap_ttls_decrypt()
1495 &parse, in_decrypted, out_data); in eap_ttls_decrypt()
1499 os_free(parse.eapdata); in eap_ttls_decrypt()