pezkuwichain 9a11dc2c3d Fix crash reading MetaAccountSecrets for accounts predating Tron/Bitcoin/Solana
Found on a real device: opening the backup/export screen for an
existing wallet crashed with
java.lang.IndexOutOfBoundsException: Cannot read 412 of 412
  at .../scale/dataType/optional.read
  at .../scale/Schema.read (x3)
  at SecretStoreV2$getMetaAccountSecrets$2.invokeSuspend

Root cause: MetaAccountSecrets is a positional (SCALE) binary schema.
optional<T>.read() unconditionally reads a presence-flag byte with no
EOF handling - reading a blob that predates a trailing field (written
before that field existed) throws instead of yielding null. This is
also why Solana's own address was never getting backfilled: the
migration's own read of the account's stored secrets was throwing on
every attempted run, silently caught by its own per-account try/catch.

Confirmed via substrate-sdk-android's actual source (Dsl.kt/Delegate.kt)
that Tron/Bitcoin's identical schema-growth pattern carried the exact
same latent risk - it likely only avoided crashing so far by chance
byte-alignment in previously-stored blobs, not because the format
tolerates it.

Fix: read Tron/Bitcoin/Solana's keypair/derivationPath fields (every
field added after the original Substrate+Ethereum schema) through a
SafeOptional DataType that catches a failed read and returns null,
via the library's own custom() field-declaration escape hatch. Write
behavior is byte-for-byte unchanged - only reading a shorter/older
blob now correctly yields null for fields it doesn't have, instead of
crashing every caller of getMetaAccountSecrets (balance sync, signing,
backup/export, this Solana backfill migration itself).
2026-07-17 02:19:10 -07:00
2026-02-12 05:19:41 +03:00
2026-02-12 05:19:41 +03:00
2026-02-12 05:19:41 +03:00

Pezkuwi Wallet Android

Next generation mobile wallet for Pezkuwichain and the Polkadot ecosystem.

About

Pezkuwi Wallet is a next-generation mobile application for the Pezkuwichain and Polkadot ecosystem. It provides a transparent, community-oriented wallet experience with convenient UX/UI, fast performance, and strong security.

Key Features:

  • Full Pezkuwichain support (HEZ & PEZ tokens)
  • Full Polkadot ecosystem compatibility
  • Staking, Governance, DeFi
  • NFT support
  • Cross-chain transfers (XCM)
  • Hardware wallet support (Ledger, Polkadot Vault)
  • WalletConnect v2
  • Push notifications

Native Tokens

Token Network Description
HEZ Relay Chain Native token for fees and staking
PEZ Asset Hub Governance token

Build Instructions

Clone Repository

git clone git@github.com:pezkuwichain/pezkuwi-wallet-android.git

Install NDK

Install NDK version 26.1.10909125 from SDK Manager: Tools -> SDK Manager -> SDK Tools -> NDK (Side by Side)

Install Rust

Install Rust by following official instructions.

Add Android build targets:

rustup target add armv7-linux-androideabi
rustup target add i686-linux-android
rustup target add x86_64-linux-android
rustup target add aarch64-linux-android

Update local.properties

Add the following lines to your local.properties:

ACALA_PROD_AUTH_TOKEN=mock
ACALA_TEST_AUTH_TOKEN=mock
CI_KEYSTORE_KEY_ALIAS=mock
CI_KEYSTORE_KEY_PASS=mock
CI_KEYSTORE_PASS=mock
DEBUG_GOOGLE_OAUTH_ID=mock
RELEASE_GOOGLE_OAUTH_ID=mock
DWELLIR_API_KEY=mock
EHTERSCAN_API_KEY_ETHEREUM=mock
EHTERSCAN_API_KEY_MOONBEAM=mock
EHTERSCAN_API_KEY_MOONRIVER=mock
INFURA_API_KEY=mock
MERCURYO_PRODUCTION_SECRET=mock
MERCURYO_TEST_SECRET=mock
MOONBEAM_PROD_AUTH_TOKEN=mock
MOONBEAM_TEST_AUTH_TOKEN=mock
MOONPAY_PRODUCTION_SECRET=mock
MOONPAY_TEST_SECRET=mock
WALLET_CONNECT_PROJECT_ID=mock

Note: Firebase and Google-related features (Notifications, Cloud Backups) require proper configuration.

Build Types

  • debug: Uses fixed keystore for Google services
  • debugLocal: Uses your local debug keystore
  • release: Production build

Supported Languages

  • English
  • Turkish (Türkçe)
  • Kurdish Kurmanji (Kurmancî)
  • Spanish (Español)
  • French (Français)
  • German (Deutsch)
  • Russian (Русский)
  • Japanese (日本語)
  • Chinese (中文)
  • Korean (한국어)
  • Portuguese (Português)
  • Vietnamese (Tiếng Việt)
  • And more...

Resources

License

Pezkuwi Wallet Android is available under the Apache 2.0 license. See the LICENSE file for more info.

Based on Nova Wallet (https://novawallet.io) - © Novasama Technologies GmbH

© Dijital Kurdistan Tech Institute 2026

S
Description
No description provided
Readme 202 MiB
Languages
Kotlin 99.6%
Rust 0.2%
Java 0.1%