Skip to content

FileSettings.encodeToData() is returning to few data  #5

Description

@MichaelsPlayground

Running FileSettings.encodeToData() is giving to few data, e.g.

File 01: length: 3 data: 0000e0

Using this output as input for FileSettings.decodeFromData(xx) gives an ArrayIndexOutOfBoundsException:

FATAL EXCEPTION: Thread-7
Process: de.androidcrypto.ntag424testapp, PID: 24668
java.lang.ArrayIndexOutOfBoundsException: length=3; index=3
	at net.bplearning.ntag424.command.FileSettings.decodeFromData(FileSettings.java:46)
	at de.androidcrypto.ntag424testapp.MainActivity$28.run(MainActivity.java:4787)
	at java.lang.Thread.run(Thread.java:764)

NTAG 424 DNA NT4H2421Gx.pdf page 69 ff is stating a minimum of 7 bytes + extra bytes if SDM is enabled.

Greetings
Michael (AndroidCrypto)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions