lucapiccolboni / crylogger Goto Github PK
View Code? Open in Web Editor NEWCRYLOGGER: Detecting Crypto Misuses for Android and Java Apps Dynamically
License: MIT License
CRYLOGGER: Detecting Crypto Misuses for Android and Java Apps Dynamically
License: MIT License
I have reviewed the other two issues about cryptolog, which should be located in /data/data/com.example.aes/cache, (I am using the example app right now) but still didn't figure out how to solve the problem I am facing. I have two problems listed below.
Thank you!
As title. Thanks a lot ~~
I fetched some apks from some Android application stores, but met some problem when installing
---------------adb: failed to install /home/zhang/documents/code/crylogger/scripts/data/apks/com.ss.android.article.news_8.3.3.apk: Failure [INSTALL_FAILED_NO_MATCHING_ABIS: Failed to extract native libraries, res=-113]
It seems that the problem was caused because it uses the arm binaries.
However, support_for_arm_binaries_on_android_9_and_11_system_images says that
If you were previously unable to use the Android Emulator because your app depended on ARM binaries, you can now use the Android 9 x86 system image or any Android 11 system image to run your app โ it is no longer necessary to download a specific system image to run ARM binaries. These Android 9 and Android 11 system images support ARM by default and provide dramatically improved performance when compared to those with full ARM emulation.
I verified the document by downloading the android 9 and android 11 image from Android Studio, and then ran the Android Studio emulator and installed apk com.ss.android.article.news_8.3.3.apk
successfully by running adb install -g com.ss.android.article.news_8.3.3.apk
.
It seems that the android 9/11 x86 image could provided ARM compatibility but my compiled crylogger failed to do that.
Have you met the INSTALL_FAILED_NO_MATCHING_ABIS failure? And how do you solve it?
Thanks in advance.
In the setup file, lunch sdk_phone_x86-userdebug
is used for compiling android.
Could sdk_phone_x86-userdebug
be substituted by other target platforms? And why this target platform is chosen?
Thanks in advance.
The OpenGapps version used in the setup_opengapps.sh
is not available anymore.
https://sourceforge.net/projects/opengapps/files/x86/20210127/open_gapps-x86-9.0-super-20210127.zip
However,
https://sourceforge.net/projects/opengapps/files/x86/20210126/open_gapps-x86-9.0-super-20210126.zip is available. Do you think this version can be used?
I followed the instructions in the README and executed the commands in order, but when I reached the 'Collect the logs' step, 'cryptolog | failed' was printed. By looking at the script file, I found the problem was that there was no no application.cryptolog. in /data/data/com.example.aes/cache/, which led to The run_cmd function returns Error, I want to know how to solve it.
Thanks in advance.
After few successful apps analysis the process either fails in pinning step or gets stuck in pinning step.
When the process is stuck in pinning step the emulator displays a blank/white screen
I think this is a limitation of the emulator itself and may not be solvable from project end. I am wondering if you faced similar issue and if yes, how did you deal with it?
Right now I am restarting the emulator and then re-execute run.py. For a large number of app analysis this is not a suitable solution.
To overcome this, I am planning to execute multiple emulators and parallel the analysis process. Multiple emulators cannot be run from same source I think, I got the following error,
emulator: ERROR: There's another emulator instance running with the current AVD '<build>'. Exiting...
How about I copy crylogger source into multiple location and execute emulators from each of them but pointing work_dir to the same location. Do you foresee any potential issues with this idea? Thanks!
I have used a fresh install of Ubuntu 18.04 and and followed the procedure mentioned in readme. When I execute emulator -writable-system
, the emulator gets started but stops with Segmentation fault.
I have also tried with macOS but it didn't help. Have you faced any similar issue? If yes, how do you resolve this?
Thanks in advance.
Before running the "Emulator Setup" the distutils
package is required.
Distutils package is available only for python3 and AOSP requires python 2.7. Still the package is required. Otherwise getting the following error,
no module named distutils.dir_util
Please add the following line in documentaiton,
sudo apt-get install python3-distutils -y
Repo tool is required. Please add the following link in documentation,
https://source.android.com/setup/develop#installing-repo
Additionally,
sudo apt-get install curl -y
sudo apt-get install lzip
sudo apt-get install m4
sudo apt install python-pip -y
pip install zxcvbn
pip install numpy
This repo should be cloned with --recursive
flag, otherwise dj-on-github/sp800_22_tests
files will not get downloaded.
sudo apt-get install git -y
git clone --recursive https://github.com/lucapiccolboni/crylogger.git
sudo apt-get install cpu-checker
kvm-ok
sudo chown $USER /dev/kvm
I do all the things , but when i install my apk on emulator and run monkey, it told me no souch file "/tmp/application.cryptolog".I found it on deltas\libcore\ojluni\src\main\java\java\security\CRYLogger.java. I can not create that file, so i change the path to "/data/local/tmp/application.cryptolog". Will it works or something else i should do.Please~~~~~help~~~~help~~~~~
I noticed in the implementation of CRYLOGGER, you used
private static FileOutputStream stream;
to record the log instead of using the android.util.Log library.
What is the intent of this design?
Thanks in advance.
It seems simply apply the changes in scripts/delta
folder to AOSP source code would work. The problem is how to correctly modify current.txt
and openjdk_java_files.bp
.
Could you provide some advice about how to check the correction of the migration?
By the way, is there any method to only build the changed module and apply the changes instead of building the whole AOSP from scratch ?
Thanks in advance
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.