Skip to content

Conversation

@h20190011
Copy link

Issue was with support of depricated function and the parameter , path the android shell .

@h20190011
Copy link
Author

h20190011 commented Nov 3, 2020

I have Fixed the bug related to process.popen() in #53

I have reproduced the issue on my local system.

Setup: -
Ubuntu 18.04
Python 3.8
Android API 18
Android Linux kernel version 4.4

We need to make below chages to analyzer/android/lib/api/adb.py file :-

search for function execute_sample(package,activity)

#proc = subprocess.Popen("["/system/bin/am", "start","-n ", package + "/" + activity], stdout=subprocess.PIPE, shell=True, stderr=subprocess.PIPE)
to
subprocess.Popen("/system/bin/am start -n "+ package + "/" + activity, stdout=subprocess.PIPE, shell=True, stderr=subprocess.PIPE, executable='/system/bin/sh')

The issue is with subprocess.Popen() functions parameter.
Reference:- https://docs.python.org/3/library/subprocess.html

Changed in version 3.6: args parameter accepts a path-like object if shell is False and a sequence containing path-like objects on POSIX.

I have throughly tested the fixed. After fixing the issue, I didn't get bug.

h20190011 and others added 3 commits November 3, 2020 15:53
we have developed a SHELL SCRIPT that extracts the android kernel SYSTEM CALLS during app execution and generate a log file. This shell script generates the system call log file for every android app in our dataset. 
Output of SHELL SCRIPT is system calls log file. This extracted system call acts as features in ML/Data science research community.
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