zhengjim / camille Goto Github PK
View Code? Open in Web Editor NEW基于Frida的Android App隐私合规检测辅助工具
基于Frida的Android App隐私合规检测辅助工具
$ python camille.py com.tencent.mm -t 3
.o88b. .d8b. .88b d88. d888888b db db d88888b
d8P Y8 d8' 8b 88'YbdP
88 88' 88 88 88' 8P 88ooo88 88 88 88 88 88 88 88ooooo 8b 88~~~88 88 88 88 88 88 88 88~~~~~ Y8b d8 88 88 88 88 88 .88. 88booo. 88booo. 88.
Y88P' YP YP YP YP YP Y888888P Y88888P Y88888P Y88888P
https://github.com/zhengjim/camille
[*] hook error
device not found
但是执行frida-ps -U 是可以查看进程的
设备是pixel 安卓8.1.0的版本
TypeError: cannot read property 'overloads' of undefined
[*] hook(getServiceState)方法失败,请检查该方法是否存在!!!
问一下 这个怎么解决
提示: hook fail, try delaying hook, adjusting delay time,加了-t参数了,还是如此
miui13
之前提过的问题,我的包没有加固的,debug的包
#14
大神可以把我交流群二维码放着么,只是技术交流,请大神指导一下
目前只能获取 RandomAccessFile写文件这种操作
其他的敏感API都获取不到调用,之前未更新的可以
合规检测敏感接口开始监控...
Error: java.lang.ClassNotFoundException: Didn't find class "androidx.core.app.ActivityCompat" on path: DexPathList[[zip file "/data/app/com.youloft.calendar-1/base.apk"],nativeLibraryDirectories=[/data/app/com.youloft.calendar-1/lib/arm, /data/app/com.youloft.calendar-1/base.apk!/lib/armeabi-v7a, /system/lib, /vendor/lib]]
Error: query(): specified argument types do not match any of:
.overload('android.net.Uri', '[Ljava.lang.String;', 'java.lang.String', '[Ljava.lang.String;', 'java.lang.String')
.overload('android.net.Uri', '[Ljava.lang.String;', 'java.lang.String', '[Ljava.lang.String;', 'java.lang.String', 'android.os.CancellationSignal')
^C[*] You have stoped hook.
环境:本地PC-macbook pro 、OS版本12.2.1
安卓:魅族MX6 、android版本7.1.1、frida为最新版。
1,目标: 检测极验sdk调用iccid行为
2, 场景: 魅族root真机+sim卡,4g网络把wifi关了
3, 参考其他检测工具的堆栈结果:
android.content.ContentResolver.query(ContentResolver.java:753)\n\n
at android.content.ContentResolver.query(ContentResolver.java:711)\n\n
at java.lang.reflect.Method.invoke(Method.java:-2)\n\n
at com.geetest.onelogin.p.p.d(null:189)\n\nat com.geetest.onelogin.p.p.c(null:156)\n\n
at com.geetest.onelogin.j.d.b(null:152)\n\nat com.geetest.onelogin.j.d.a(null:63)\n\n
at com.geetest.onelogin.m.c.v(null:166)\n\nat com.geetest.onelogin.m.c.b(null:39)\n\n
at com.geetest.onelogin.m.c$2.run(null:139)\n\n
at android.os.Handler.handleCallback(Handler.java:873)\n\n
at android.os.Handler.dispatchMessage(Handler.java:99)\n\n
at android.os.Looper.loop(Looper.java:193)\n\n
at android.app.ActivityThread.main(ActivityThread.java:6718)\n\n
at java.lang.reflect.Method.invoke(Method.java:-2)\n\n'}}
在脚本“device.py”文件,第43行如下
devices = list(filter(lambda d: not d.name.lower().startswith("local"), frida.enumerate_devices()))
会检测处其他无用设备,建议优化如下
devices = list(filter(lambda d: (not d.name.lower().startswith("local")) and (d.type=="usb"), frida.enumerate_devices()))
增肌一个type的usb判定,但未测试adb无线连接是否可行等问题,暂还不熟悉frida使用方法,感觉该脚本非常naisi
[] 2022-11-25 10:59:46 检测到安卓版本:6.0.1
[] 2022-12-25 10:59:46 已加载模块permission,phone,system,app,location,network,camera,bluetooth,file,media,custom
TypeError: cannot read property 'overloads' of undefined
[*] hook(getPackageInfoAsUser)方法失败,请检查该方法是否存在!!!
小米市场ApplicationPackageManager.getPackageInfo传自己的包名会被拒
frida-ps -U
//已经能显示相关数据.但是使用
python camille.py com.example.test
就报错..
unable to connect to remote frida-server
能提示下么 谢谢.
{'type': 'error', 'description': "Error: can't decode byte 0x85 in position 1", 'stack': "Error: can't decode byte 0x85 in position 1\n at (/script1.js:7)", 'fileName': '/script1.js', 'lineNumber': 7, 'columnNumber': 1}
执行命令: python camille.py com.xxx.mds.xxxx -t 3,报错了,不知道咋情况
[*] hook error
unable to inject library into process without libc
使用Arm版本模拟器
错误信息:
% python3 camille.py com.xx.xx -t 3
合规检测敏感接口开始监控... {'type': 'error', 'description': "Error: sendTextMessageInternal(): has more than one overload, use .overload(<signature>) to choose from:\n\t.overload('java.lang.String', 'java.lang.String', 'java.lang.String', 'android.app.PendingIntent', 'android.app.PendingIntent', 'boolean', 'int', 'boolean', 'int')\n\t.overload('java.lang.String', 'java.lang.String', 'java.lang.String', 'android.app.PendingIntent', 'android.app.PendingIntent', 'boolean', 'java.lang.String', 'java.lang.String', 'long')", 'stack': "Error: sendTextMessageInternal(): has more than one overload, use .overload(<signature>) to choose from:\n\t.overload('java.lang.String', 'java.lang.String', 'java.lang.String', 'android.app.PendingIntent', 'android.app.PendingIntent', 'boolean', 'int', 'boolean', 'int')\n\t.overload('java.lang.String', 'java.lang.String', 'java.lang.String', 'android.app.PendingIntent', 'android.app.PendingIntent', 'boolean', 'java.lang.String', 'java.lang.String', 'long')\n at X (frida/node_modules/frida-java-bridge/lib/class-factory.js:563)\n at K (frida/node_modules/frida-java-bridge/lib/class-factory.js:558)\n at set (frida/node_modules/frida-java-bridge/lib/class-factory.js:925)\n at getSMSManager (/script1.js:454)\n at <anonymous> (/script1.js:503)\n at <anonymous> (frida/node_modules/frida-java-bridge/lib/vm.js:11)\n at _performPendingVmOps (frida/node_modules/frida-java-bridge/index.js:238)\n at <anonymous> (frida/node_modules/frida-java-bridge/index.js:213)\n at <anonymous> (frida/node_modules/frida-java-bridge/lib/vm.js:11)\n at _performPendingVmOpsWhenReady (frida/node_modules/frida-java-bridge/index.js:232)\n at perform (frida/node_modules/frida-java-bridge/index.js:192)\n at main (/script1.js:504)\n at apply (native)\n at <anonymous> (frida/runtime/core.js:45)", 'fileName': 'frida/node_modules/frida-java-bridge/lib/class-factory.js', 'lineNumber': 563, 'columnNumber': 1}
请问可以对动态加载的代码进行hook吗?可以对热更新的代码进行hook吗?
run python camille.py -h
AttributeError: partially initialized module 'cv2' has no attribute 'gapi_wip_gst_GStreamerPipeline
fixed by reinstall with 4.5.2.52
pip uninstall opencv-python
pip install opencv-python==4.5.2.52
错误信息:
[*] hook error
need Gadget to attach on jailed Android; its default location is: C:\Users\Android-yulai\AppData\Local\Microsoft\Windows\INetCache\frida\gadget-android-arm64.so
java.lang.UnsatisfiedLinkError: dlopen failed: library "/data/data/{包名}/gadget.so" not found
可以增加下检测剪切板读取的功能吗?如题
如题,运行camille ,模拟器就崩掉然后重启,试了主流的几个模拟器都这样。返回如下报错
[] 2023-06-05 16:46:03 Frida bindings 版本: 16.0.19
[] 2023-06-05 16:46:11 'gbk' codec can't decode byte 0xa7 in position 84: illegal multibyte sequence
[] 2023-06-05 16:46:11 关闭同意隐私状态,状态均为同意前,不影响hook!
[] 2023-06-05 16:46:12 hook fail, try delaying hook, adjusting delay time__
实际检测时,兼容的系统版本高一点会更具有实用价值,比如10.0不再允许后台获取剪切板,获取imei的api也会报错,如果集成了腾讯x5,sdk集成时会判断当前系统如果大于9.0,会针对性处理。实际运行中代码或者第三方sdk 中或多或少存在判断版本系统才去执行某些敏感api的情况,所以用来hook的机子,最好也得兼容到高一点版本的系统,否则会存在漏检。
导出的excel中调用月份提前了一个月
测试机器: Android 13(LineageOS 20) Pixel 2XL
大佬能否建个群或者留个联系方式
找不到文件
本地和网络数据也需要检测
设备: 红米k40
版本: 安卓12/MIUI13.0.7
frida: 16.0.7
问题: 使用依附进程的方式进行 hook, 在2秒钟左右 app 会闪退, 同时没有任何报错
命令: python camille.py 同程旅行 --isattach
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.