Skip to content

Wallet: Reject invalid BIP39 unlock - #1301

Open
Tabakkui wants to merge 1 commit into
RavenProject:developfrom
Tabakkui:fix/issue-1252-send-assertion
Open

Tabakkui wants to merge 1 commit into
RavenProject:developfrom
Tabakkui:fix/issue-1252-send-assertion

Conversation

@Tabakkui

Copy link
Copy Markdown

Problem

Raven-Qt can abort with a MinGW runtime assertion in wallet/crypter.cpp:201 when an old encrypted wallet contains BIP39 data that cannot be decrypted. Issue #1252 reports this while attempting to send RVN from a legacy wallet.

Approach

  • Treat BIP39 decryption failure during unlock as a normal unlock failure.
  • Preserve the existing log message and let the caller report an invalid passphrase/corrupt wallet instead of terminating the GUI.
  • Add a wallet crypto regression test using malformed encrypted BIP39 data.

Test plan

  • git diff --check
  • Static regression assertions for the guarded return path and test case
  • Full C++ unit/build test not run on the ARM64 Pi; requires the authorized PC build environment.

Fixes #1252

Return a normal unlock failure when encrypted BIP39 data cannot be decrypted instead of aborting through an assertion. Add a regression test for malformed encrypted BIP39 data.\n\nFixes RavenProject#1252
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.

1 participant