mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-08-21 05:43:48 -07:00
Merge pull request #2754 from Eltrick/proper-uid-print
Switch around some logic in ul_auth_select to make the client print t…
This commit is contained in:
commit
f7a8703c6d
1 changed files with 3 additions and 5 deletions
|
@ -669,6 +669,9 @@ static int try_default_aes_keys(bool override) {
|
||||||
}
|
}
|
||||||
|
|
||||||
static int ul_auth_select(iso14a_card_select_t *card, uint64_t tagtype, bool hasAuthKey, uint8_t *authkey, uint8_t *pack, uint8_t packSize) {
|
static int ul_auth_select(iso14a_card_select_t *card, uint64_t tagtype, bool hasAuthKey, uint8_t *authkey, uint8_t *pack, uint8_t packSize) {
|
||||||
|
if (ul_select(card) == false) {
|
||||||
|
return PM3_ESOFT;
|
||||||
|
}
|
||||||
|
|
||||||
if (hasAuthKey && (tagtype & MFU_TT_UL_C)) {
|
if (hasAuthKey && (tagtype & MFU_TT_UL_C)) {
|
||||||
//will select card automatically and close connection on error
|
//will select card automatically and close connection on error
|
||||||
|
@ -676,12 +679,7 @@ static int ul_auth_select(iso14a_card_select_t *card, uint64_t tagtype, bool has
|
||||||
PrintAndLogEx(WARNING, "Authentication Failed UL-C");
|
PrintAndLogEx(WARNING, "Authentication Failed UL-C");
|
||||||
return PM3_ESOFT;
|
return PM3_ESOFT;
|
||||||
}
|
}
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
if (ul_select(card) == false) {
|
|
||||||
return PM3_ESOFT;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (hasAuthKey) {
|
if (hasAuthKey) {
|
||||||
if (ulev1_requestAuthentication(authkey, pack, packSize) == PM3_EWRONGANSWER) {
|
if (ulev1_requestAuthentication(authkey, pack, packSize) == PM3_EWRONGANSWER) {
|
||||||
DropField();
|
DropField();
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue