Blockstream / green_android

Blockstream Green Wallet for Android
GNU General Public License v3.0
201 stars 83 forks source link

Bug: Some seed words that are prefixes of other seed words are pre-emptively accepted as complete words #234

Open jivanpal opened 4 days ago

jivanpal commented 4 days ago

Description

When entering a BIP-39 seed phrase when restoring a wallet, some words that are prefixes of other words, when entered, cause the cursor to automatically jump to the next word field, even though the user may have wanted to enter one of the longer words. The user must thus tap backspace or tap the previous word field to continue entering the desired word.

For example:

When attempting to enter "sadness", the cursor jumps to the next word field immediately "sad" is entered. Likewise for any of the other example long words when the corresponding short word is entered.

This does not happen with all such prefix words, e.g. when trying to enter "vanish", the cursor does not jump to the next word field once "van" is entered, even though "van" is in the wordlist.

Version

4.0.38 via F-Droid

Steps to reproduce

  1. Set up a new wallet > On this device > Restore wallet
  2. Try to enter any of the example long words in any of the word fields.

Expected behaviour

The cursor should not jump to the next word field unless (a) there is only one valid word that begins with the characters entered so far; or (b) the user taps one of the suggested complete words beneath the keyboard.

Actual behaviour

Observe that the cursor instead jumps to the next word field once a valid prefix word has been entered.

Device or machine

angelix commented 4 days ago

Thanks for reporting. Issue fixed and should be available in the next release.