Home | History | Annotate | Download | only in eap_peer

Lines Matching defs:imsi

1274  * Rules for figuring out MNC length based on IMSI for SIM cards that do not
1277 static int mnc_len_from_imsi(const char *imsi)
1282 os_memcpy(mcc_str, imsi, 3);
1295 static int eap_sm_append_3gpp_realm(struct eap_sm *sm, char *imsi,
1302 wpa_printf(MSG_WARNING, "No room for realm in IMSI buffer");
1309 mnc_len = mnc_len_from_imsi(imsi);
1318 mnc[1] = imsi[3];
1319 mnc[2] = imsi[4];
1321 mnc[0] = imsi[3];
1322 mnc[1] = imsi[4];
1323 mnc[2] = imsi[5];
1327 pos = imsi + *imsi_len;
1328 pos += os_snprintf(pos, imsi + max_len - pos,
1330 mnc, imsi[0], imsi[1], imsi[2]);
1331 *imsi_len = pos - imsi;
1341 char imsi[100];
1346 imsi_len = sizeof(imsi);
1347 if (scard_get_imsi(sm->scard_ctx, imsi, &imsi_len)) {
1348 wpa_printf(MSG_WARNING, "Failed to get IMSI from SIM");
1352 wpa_hexdump_ascii(MSG_DEBUG, "IMSI", (u8 *) imsi, imsi_len);
1355 wpa_printf(MSG_WARNING, "Too short IMSI for SIM identity");
1359 if (eap_sm_append_3gpp_realm(sm, imsi, sizeof(imsi), &imsi_len) < 0) {
1363 wpa_hexdump_ascii(MSG_DEBUG, "IMSI + realm", (u8 *) imsi, imsi_len);
1384 "IMSI-based identity");
1399 os_memcpy(conf->identity + 1, imsi, imsi_len);
1486 "permanent identity from IMSI",