Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NFC: fixes & improvements #897

Merged
merged 6 commits into from
Dec 15, 2021
Merged

Conversation

yobabyte
Copy link
Contributor

What's new

  • Fixed reading for Mifare Ultralight tags - checks reading boundary and discards excess.
  • Fixed FAST_READ command emulation for Mifare Ultralight - handles requested page range correctly.
  • Improved Mifare Ultralight emulation stability - increased log level for some messages, because frequent calls to furi_hal_console_put() somehow directly affects emulation stability (delays due to locks or something, dunno).
  • Implemented non-strict PWD_AUTH command emulation for NTAG21x - performs authentication if PACK is not set to default value, otherwise accepts any passwords.
  • Plastic figures and cards with NTAG215 from a well-known Japanese company are now correctly read and emulated 😏

Verification

  • Build and download.
  • Read some NTAG21n tag:
    • Save, check number of pages in saved file (e.g. NTAG215 should contain pages from 0 to 134 inclusive)
    • Emulate that tag and try FAST_READ command (e.g. 3A 00 00 should return first 4 bytes of UID)
    • Replace PWD and PACK with actual values in saved file, emulate and try PWD_AUTH command:
    # NTAG215 primer
    Page 133: 00 E6 AC 0C
    Page 134: DE AD 00 00
    
    # Command: 1B 00 E6 AC 0C
    # Response: DE AD (PACK)
    
    # Command: 1B F1 F2 F3 F4
    # Response: 00 (NAK)
    

Checklist (do not modify)

  • PR has description of feature/bug or link to Confluence/Jira task
  • Description contains actions to verify feature/bugfix
  • I've built this code, uploaded it to the device and verified feature/bugfix

applications/nfc/nfc_worker.c Outdated Show resolved Hide resolved
applications/nfc/nfc_worker.c Outdated Show resolved Hide resolved
@skotopes skotopes dismissed DrZlo13’s stale review December 15, 2021 18:22

Solution accepted by code owner and me

@skotopes skotopes merged commit de006aa into flipperdevices:dev Dec 15, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants