dfqin / androidnativeencryption Goto Github PK
View Code? Open in Web Editor NEWA native encrypt demo
Home Page: http://www.jianshu.com/p/2cd6acb2fdc4
A native encrypt demo
Home Page: http://www.jianshu.com/p/2cd6acb2fdc4
10-16 17:55:27.906 23993-23993/? A/art: art/runtime/runtime.cc:422] at void java.lang.System.loadLibrary(java.lang.String) (System.java:1530)
10-16 17:55:27.906 23993-23993/? A/art: art/runtime/runtime.cc:422] at void trip.com.haowma.util.network.SecureUtil.() (SecureUtil.java:16)
System.loadLibrary("native-lib");
1 SIGN_FRONT_DEBUG SIGN_END_DEBUG 是哪几位,怎么来的,我debug模式得到了SIGN_END_DEBUG的值但是SIGN_FRONT_DEBUG 怎么还是和你的一样,debug签名不一样啊
2 native解密报错
3 不支持中文
4 服务器怎么解密呢
JNI DETECTED ERROR IN APPLICATION: negative jsize: -147
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] in call to NewByteArray
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] from byte[] com.dfqin.encrypt.SecureUtil.decryptData(android.content.Context, byte[])
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] "main" prio=5 tid=1 Runnable
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] | group="main" sCount=0 dsCount=0 obj=0x74f37698 self=0x55a30e9af0
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] | sysTid=14623 nice=-1 cgrp=top_visible sched=0/0 handle=0x7fa8621000
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] | state=R schedstat=( 1932406944 72594288 1354 ) utm=161 stm=32 core=3 HZ=100
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] | stack=0x7fecc6c000-0x7fecc6e000 stackSize=8MB
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] | held mutexes= "mutator lock"(shared held)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #00 pc 000000000048b384 /system/lib64/libart.so (_ZN3art15DumpNativeStackERNSt3__113basic_ostreamIcNS0_11char_traitsIcEEEEiPKcPNS_9ArtMethodEPv+236)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #1 pc 000000000045a77c /system/lib64/libart.so (_ZNK3art6Thread4DumpERNSt3__113basic_ostreamIcNS1_11char_traitsIcEEEE+220)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #2 pc 000000000030e690 /system/lib64/libart.so (ZN3art9JavaVMExt8JniAbortEPKcS2+1000)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #3 pc 000000000030ef48 /system/lib64/libart.so (_ZN3art9JavaVMExt9JniAbortVEPKcS2_St9__va_list+116)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #4 pc 0000000000142974 /system/lib64/libart.so (_ZN3art11ScopedCheck6AbortFEPKcz+144)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #05 pc 0000000000149e38 /system/lib64/libart.so (_ZN3art11ScopedCheck5CheckERNS_18ScopedObjectAccessEbPKcPNS_12JniValueTypeE.constprop.116+7644)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #06 pc 0000000000156e8c /system/lib64/libart.so (_ZN3art8CheckJNI17NewPrimitiveArrayEPKcP7_JNIEnviNS_9Primitive4TypeE+476)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #07 pc 0000000000009b2c /data/app/com.dfqin.encrypt-1/lib/arm64/libnative-lib.so (_ZN7_JNIEnv12NewByteArrayEi+36)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #08 pc 0000000000009cc0 /data/app/com.dfqin.encrypt-1/lib/arm64/libnative-lib.so (_ZN11EncodeUtils11decryptDataEP7_JNIEnvRP11_jbyteArrayi+296)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #09 pc 0000000000008bf4 /data/app/com.dfqin.encrypt-1/lib/arm64/libnative-lib.so (???)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #10 pc 0000000000128768 /system/lib64/libart.so (art_quick_generic_jni_trampoline+152)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #11 pc 000000000011edd8 /system/lib64/libart.so (art_quick_invoke_static_stub+600)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #12 pc 000000000012dae4 /system/lib64/libart.so (_ZN3art9ArtMethod6InvokeEPNS_6ThreadEPjjPNS_6JValueEPKc+344)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #13 pc 00000000004cd95c /system/lib64/libart.so (artInterpreterToCompiledCodeBridge+212)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #14 pc 00000000002a7ea8 /system/lib64/libart.so (_ZN3art11interpreter6DoCallILb0ELb0EEEbPNS_9ArtMethodEPNS_6ThreadERNS_11ShadowFrameEPKNS_11InstructionEtPNS_6JValueE+480)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #15 pc 00000000000dde00 /system/lib64/libart.so (ZN3art11interpreter15ExecuteGotoImplILb0ELb0EEENS_6JValueEPNS_6ThreadEPKNS_7DexFile8CodeItemERNS_11ShadowFrameES2+22200)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #16 pc 0000000000285cb0 /system/lib64/libart.so (artInterpreterToInterpreterBridge+220)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #17 pc 00000000002a7ea8 /system/lib64/libart.so (_ZN3art11interpreter6DoCallILb0ELb0EEEbPNS_9ArtMethodEPNS_6ThreadERNS_11ShadowFrameEPKNS_11InstructionEtPNS_6JValueE+480)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #18 pc 00000000000dde00 /system/lib64/libart.so (ZN3art11interpreter15ExecuteGotoImplILb0ELb0EEENS_6JValueEPNS_6ThreadEPKNS_7DexFile8CodeItemERNS_11ShadowFrameES2+22200)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #19 pc 0000000000285cb0 /system/lib64/libart.so (artInterpreterToInterpreterBridge+220)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #20 pc 00000000002a7ea8 /system/lib64/libart.so (_ZN3art11interpreter6DoCallILb0ELb0EEEbPNS_9ArtMethodEPNS_6ThreadERNS_11ShadowFrameEPKNS_11InstructionEtPNS_6JValueE+480)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #21 pc 00000000000dde78 /system/lib64/libart.so (ZN3art11interpreter15ExecuteGotoImplILb0ELb0EEENS_6JValueEPNS_6ThreadEPKNS_7DexFile8CodeItemERNS_11ShadowFrameES2+22320)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #22 pc 00000000002858b8 /system/lib64/libart.so (_ZN3art11interpreter30EnterInterpreterFromEntryPointEPNS_6ThreadEPKNS_7DexFile8CodeItemEPNS_11ShadowFrameE+96)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #23 pc 000000000053a470 /system/lib64/libart.so (artQuickToInterpreterBridge+632)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #24 pc 00000000001288a4 /system/lib64/libart.so (art_quick_to_interpreter_bridge+100)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] native: #25 pc 0000000001616870 /data/dalvik-cache/arm64/system@[email protected] (???)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] at com.dfqin.encrypt.SecureUtil.decryptData(Native method)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] at com.dfqin.encrypt.SecureUtil.decryptData(SecureUtil.java:21)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] at com.dfqin.encrypt.MainActivity.nativeDecode(MainActivity.java:129)
10-12 10:23:44.284 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] at com.dfqin.encrypt.MainActivity.onClick(MainActivity.java:60)
10-12 10:23:44.285 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] at android.view.View.performClick(View.java:5264)
10-12 10:23:44.285 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] at android.view.View$PerformClick.run(View.java:21297)
10-12 10:23:44.285 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] at android.os.Handler.handleCallback(Handler.java:743)
10-12 10:23:44.285 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] at android.os.Handler.dispatchMessage(Handler.java:95)
10-12 10:23:44.285 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] at android.os.Looper.loop(Looper.java:150)
10-12 10:23:44.285 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] at android.app.ActivityThread.main(ActivityThread.java:5546)
10-12 10:23:44.285 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] at java.lang.reflect.Method.invoke!(Native method)
10-12 10:23:44.285 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:794)
10-12 10:23:44.285 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410] at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:684)
10-12 10:23:44.285 14623-14623/com.dfqin.encrypt A/art: art/runtime/java_vm_ext.cc:410]
10-12 10:23:44.285 14623-14623/com.dfqin.encrypt A/art: art/runtime/runtime.cc:368] Runtime aborting...
10-12 10:23:44.285 14623-14623/com.dfqin.encrypt A/art: art/runtime/runtime.cc:368]
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.