-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Description
public String exportMnemonic(Wallet wallet, String password) {
StoredKey key = wallet.key;
try {
key.decryptMnemonic(password);
} catch (Throwable e){
}
return wallet.key.decryptMnemonic(password);
}
In android JNI wallet core ,
about decryptMnemonic() in StoredKey class
When I entered the normal password, I got the right mnemonic.
ex log)
(2019-04-18 15:06:49.265 16697-16697/com.sinest.chan.myapplication D/Unite: machine wrestle usual category shine north thing repeat lady citizen actress gossip)
But when i enter on purpose incorrect password, i got the crash
In this case, i didn't get any Exception , Throwable
ex log)
2019-04-18 15:13:46.814 18499-18499/com.sinest.chan.myapplication A/libc: Fatal signal 11 (SIGSEGV), code 1, fault addr 0x0 in tid 18499 (n.myapplication)
2019-04-18 15:13:46.815 18630-18630/? E/Zygote: v2
2019-04-18 15:13:46.815 18630-18630/? I/libpersona: KNOX_SDCARD checking this for 1000
2019-04-18 15:13:46.815 18630-18630/? I/libpersona: KNOX_SDCARD not a persona
2019-04-18 15:13:46.816 18630-18630/? E/Zygote: accessInfo : 0
2019-04-18 15:13:46.816 18630-18630/? W/SELinux: SELinux selinux_android_compute_policy_index : Policy Index[2], Con:u:r:zygote:s0 RAM:SEPF_SECMOBILE_7.0_0010, [-1 -1 -1 -1 0 1]
2019-04-18 15:13:46.816 3661-4752/? I/ActivityManager: Start proc 18630:com.lguplus.rms/1000 for broadcast com.lguplus.rms/.RmsPackageReceiver
2019-04-18 15:13:46.817 18630-18630/? I/SELinux: SELinux: seapp_context_lookup: seinfo=default, level=s0:c512,c768, pkgname=com.lguplus.rms
2019-04-18 15:13:46.831 18630-18630/? D/TimaKeyStoreProvider: TimaKeyStore is not enabled: cannot add TimaSignature Service and generateKeyPair Service
2019-04-18 15:13:46.832 18635-18635/? A/DEBUG: *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
2019-04-18 15:13:46.833 18635-18635/? A/DEBUG: Build fingerprint: 'samsung/zerofltelgt/zerofltelgt:7.0/NRD90M/G920LKLU3ERG1:user/release-keys'
2019-04-18 15:13:46.833 18635-18635/? A/DEBUG: Revision: '11'
2019-04-18 15:13:46.833 18635-18635/? A/DEBUG: ABI: 'arm64'
2019-04-18 15:13:46.833 18635-18635/? A/DEBUG: pid: 18499, tid: 18499, name: n.myapplication >>> com.sinest.chan.myapplication <<<
2019-04-18 15:13:46.833 18635-18635/? A/DEBUG: signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x0
2019-04-18 15:13:46.833 18635-18635/? A/DEBUG: x0 0000000000000000 x1 0000007673841000 x2 0000007655400000 x3 0000000000000009
2019-04-18 15:13:46.833 18635-18635/? A/DEBUG: x4 00000000000001b5 x5 4000000000000000 x6 0000007fec315930 x7 fefefefefefefefe
2019-04-18 15:13:46.833 18635-18635/? A/DEBUG: x8 a418fabaa0c55079 x9 a418fabaa0c55079 x10 00000000000001b5 x11 0000000000000000
2019-04-18 15:13:46.833 18635-18635/? A/DEBUG: x12 0000000000000028 x13 0000000000000000 x14 ffffffffffffffff x15 b940621521957cd9
2019-04-18 15:13:46.833 18635-18635/? A/DEBUG: x16 0000007654b7b9e0 x17 00000076549214e4 x18 4e7bede8878ef2ae x19 0000007673841000
2019-04-18 15:13:46.833 18635-18635/? A/DEBUG: x20 0000007673841000 x21 0000007662513b00 x22 0000000000200019 x23 0000007654e9816a
2019-04-18 15:13:46.833 18635-18635/? A/DEBUG: x24 0000000000000008 x25 a418fabaa0c55079 x26 00000076738c7a98 x27 a418fabaa0c55079
2019-04-18 15:13:46.833 18635-18635/? A/DEBUG: x28 0000007fec3163f0 x29 0000007fec316380 x30 0000007654931664
2019-04-18 15:13:46.833 18635-18635/? A/DEBUG: sp 0000007fec316370 pc 00000076549214e4 pstate 0000000060000000
2019-04-18 15:13:46.834 3661-3675/? D/CompatibilityInfo: mCompatibilityFlags - 0
2019-04-18 15:13:46.834 3661-3675/? D/CompatibilityInfo: applicationDensity - 640
2019-04-18 15:13:46.834 3661-3675/? D/CompatibilityInfo: applicationScale - 1.0
2019-04-18 15:13:46.834 3661-3675/? I/ActivityManager: DSS on for com.lguplus.rms and scale is 1.0
2019-04-18 15:13:46.835 3661-3675/? D/CompatibilityInfo: mCompatibilityFlags - 0
2019-04-18 15:13:46.835 3661-3675/? D/CompatibilityInfo: applicationDensity - 640
2019-04-18 15:13:46.835 3661-3675/? D/CompatibilityInfo: applicationScale - 1.0
2019-04-18 15:13:46.836 18635-18635/? A/DEBUG: backtrace:
2019-04-18 15:13:46.836 18635-18635/? A/DEBUG: #00 pc 000000000024d4e4 /data/app/com.sinest.chan.myapplication-2/lib/arm64/libTrustWalletCore.so (TWStringUTF8Bytes)
2019-04-18 15:13:46.836 18635-18635/? A/DEBUG: #1 pc 000000000025d660 /data/app/com.sinest.chan.myapplication-2/lib/arm64/libTrustWalletCore.so (TWStringJString+16)
2019-04-18 15:13:46.836 18635-18635/? A/DEBUG: #2 pc 000000000025b0c8 /data/app/com.sinest.chan.myapplication-2/lib/arm64/libTrustWalletCore.so (Java_wallet_core_jni_StoredKey_decryptMnemonic+140)
2019-04-18 15:13:46.837 18635-18635/? A/DEBUG: #3 pc 00000000000db490 /system/lib64/libart.so (art_quick_generic_jni_trampoline+144)
2019-04-18 15:13:46.837 18635-18635/? A/DEBUG: #4 pc 00000000000d1eb4 /system/lib64/libart.so (art_quick_invoke_stub+580)
2019-04-18 15:13:46.837 18635-18635/? A/DEBUG: #5 pc 00000000000deb88 /system/lib64/libart.so (_ZN3art9ArtMethod6InvokeEPNS_6ThreadEPjjPNS_6JValueEPKc+208)
2019-04-18 15:13:46.837 18635-18635/? A/DEBUG: #6 pc 000000000028db00 /system/lib64/libart.so (_ZN3art11interpreter34ArtInterpreterToCompiledCodeBridgeEPNS_6ThreadEPNS_9ArtMethodEPKNS_7DexFile8CodeItemEPNS_11ShadowFrameEPNS_6JValueE+312)
2019-04-18 15:13:46.837 18635-18635/? A/DEBUG: #7 pc 0000000000286adc /system/lib64/libart.so (_ZN3art11interpreter6DoCallILb0ELb0EEEbPNS_9ArtMethodEPNS_6ThreadERNS_11ShadowFrameEPKNS_11InstructionEtPNS_6JValueE+592)
2019-04-18 15:13:46.837 18635-18635/? A/DEBUG: #8 pc 0000000000552bf4 /system/lib64/libart.so (MterpInvokeVirtual+608)
2019-04-18 15:13:46.837 18635-18635/? A/DEBUG: #9 pc 00000000000c4894 /system/lib64/libart.so (ExecuteMterpImpl+14228)
How can i solve this problem??
Expected Behavior
Current Behavior
Possible Solution
Steps to Reproduce (for bugs)
1.
2.
3.