With Ultralight EV1, after failing PwdAuth I'm unable to try another password:
status = phalMful_PwdAuth( palMful, passDefault, packResult); <- assume wrong password
I tried to do a few different things while tag remained in field such as reactivate (which works sometimes, sometimes not)
phpalI14443p3a_ActivateCard(
pDataParams->pPal1443p3aDataParams,
((pDataParams->sTypeATargetInfo).aTypeA_I3P3[bTypeATagIdx]).aUid,
((pDataParams->sTypeATargetInfo).aTypeA_I3P3[bTypeATagIdx]).bUidSize,
aUid,
&bUidLen,
&(((pDataParams->sTypeATargetInfo).aTypeA_I3P3[bTypeATagIdx]).aSak),
&bMoreCardsAvailable);
Also tried WUPA (which nearly always succeeds - I get back ATQA correctly)
status = phpalI14443p3a_WakeUpA(
((phacDiscLoop_Sw_DataParams_t *) pDataParams)->pPal1443p3aDataParams,
((phacDiscLoop_Sw_DataParams_t * ) pDataParams)->sTypeATargetInfo.aTypeA_I3P3[0].aAtqa);
Followed by a read of block 0 to get into Active state. (read does return UID of tag which seems to indicate activation success)
However in all cases, a subsequent try of PwdAuth always fails (even if the password is correct). I even get PACK = the right value, so that should indicate state = AUTHENTICATED.
However an immediate subsequent write to a protected or nonprotected page will always fail (when PwdAuth success is AFTER HALT->WUPA transition)
Using the exact same password on the "first try" works fine. Just never after reactivation.
Am I missing a step in getting the tag to activate? Or am I supposed to reset the reader library structures in some way?
Thanks!
--
avoiding wupa function and going straight for activation was better. looking into difference, but not yet sure
---
code had duplicate wupa causing fail to hlta in unexpected place -- consider this post a non-issue.
Dear Jeffrey Chan,
as you can see you are in HALT state due to a failed authentication the only ways to come out of this state is either sending a WUPA command or performing a POR. please let me know which reader are you using so I can replicate this.
looking forward to you answer.
Have a great day !
BR
Jonathan