diff options
author | Vincent Breitmoser <valodim@mugenguild.com> | 2014-09-26 00:38:43 +0200 |
---|---|---|
committer | Vincent Breitmoser <valodim@mugenguild.com> | 2014-09-26 00:39:48 +0200 |
commit | 4ccb26d2e584a94ab55835f7c54e119e764fb633 (patch) | |
tree | d4a9b0f4f279cd3a4ae0215904bdd14cd0e90de2 /OpenKeychain/src | |
parent | f48db5a005bbcf52b408c8bcace5a7cdfc648620 (diff) | |
download | open-keychain-4ccb26d2e584a94ab55835f7c54e119e764fb633.tar.gz open-keychain-4ccb26d2e584a94ab55835f7c54e119e764fb633.tar.bz2 open-keychain-4ccb26d2e584a94ab55835f7c54e119e764fb633.zip |
nfc: use proper hex encoding for pin length
Fixes #886
Diffstat (limited to 'OpenKeychain/src')
-rw-r--r-- | OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/NfcActivity.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/NfcActivity.java b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/NfcActivity.java index fb2209d3e..7aa09e801 100644 --- a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/NfcActivity.java +++ b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/NfcActivity.java @@ -208,7 +208,7 @@ public class NfcActivity extends ActionBarActivity { + "20" // INS + "00" // P1 + "82" // P2 (PW1) - + String.format("%02d", mPin.length()) // Lc + + String.format("%02x", mPin.length()) // Lc + Hex.toHexString(mPin.getBytes()); if ( ! card(login).equals(accepted)) { // login toast("Wrong PIN!"); |