• Stars
    star
    224
  • Rank 176,804 (Top 4 %)
  • Language
    Python
  • Created almost 4 years ago
  • Updated almost 4 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

基于FastAPI实现的Frida-RPC工具,自动解析JavaScript文件生成对应API接口

Logo

Welcome to arida 👋

Version Documentation License: 暂无

基于FastAPI实现的Frida-RPC工具,只需开发好相对应app的Frida-Js脚本,即可自动生成相应的基于FastAPIFrida-RPC工具

原理介绍:https://mp.weixin.qq.com/s/U6RNZTFyLp5GsGU8o17x3Q

🏠 Homepage

Demo

Do By You Self!

实现原理

Python执行PyexecJs通过Js的AST树结构获取Frida-Js脚本中rpc.exports的方法以及对应方法的参数个数,根据方法名和参数个数通过types.FunctionDefPython AST字节码来动态生成新的Function对象,并且结合pydanticcreate_model自动生成的参数模型注册到FastAPI的路由系统中,实现Frida-RPC的功能。

工作流程

工作流程

核心功能

  1. 管理JavaScript文件,具备APP-文件的映射关系

  2. 自动针对现有的JavaScript方法生成相应的API方法

  3. 自动生成Open API文档

Install

1. git clone [email protected]:lateautumn4lin/arida.git

2. conda create -n arida python==3.8

3. conda install --yes --file requirements.txt

Usage

1. uvicorn main:app --reload

2. watch 127.0.0.1:8000/docs 

eg:

生成的fastapi的api结构图

对应api的参数图

如何开发自己的接口呢?

  1. Config文件中写入自己的App信息

  2. Apps目录写开发相应的Frida-Js脚本,可参考其他两个文件

Run tests

uvicorn main:app --reload

测试Apk地址:

1. https://www.wandoujia.com/apps/6612700

2. https://www.wandoujia.com/apps/7666802

eg:

测试图

参考资料

  1. https://www.cnblogs.com/olivetree123/p/5067685.html(python动态创建函数)

  2. http://blog.soliloquize.org/2016/07/06/Python%E5%8A%A8%E6%80%81%E5%88%9B%E5%BB%BA%E5%87%BD%E6%95%B0/

  3. https://zhuanlan.zhihu.com/p/103665038(python字节码)

  4. https://www.jianshu.com/p/2006a8c75bb2(FastAPI动态建模)

  5. https://github.com/xonsh/xonsh/pull/3304/files(python AST解析参考)

Author

👤 Lateautumn4lin

🤝 Contributing

Contributions, issues and feature requests are welcome!
Feel free to check issues page. You can also take a look at the contributing guide.

Show your support

Give a ⭐️ if this project helped you!

📝 License

Copyright © 2020 Lateautumn4lin.
This project is 暂无 licensed.


This README was generated with ❤️ by readme-md-generator

More Repositories

1

Review_Reverse

JavaScript
1,442
star
2

headwolf

Scaffolding for agile development based on Xposed and Sekiro/基于Xposed和Sekiro搭建的敏捷开发的脚手架🎁献给懒汉们的小礼物😘只需四步!部署完一个Hook项目!👋👋新版本只需两步!!!
Java
218
star
3

awsome-magisk

关于Magisk生态的研究
94
star
4

KernelModification

研究内核改机策略
C
41
star
5

dirty_algorithm

常用的加密算法理解以及魔改、对抗思路
C++
40
star
6

AwsomeReverseTools

逆向工具大集合:脱壳dex重打包脚本;Frida Dump so脚本
Python
34
star
7

hook_play

👍日常Hook小玩法,具体参考文章可见公众号《云爬虫技术研究笔记》
Java
16
star
8

TechPaoding

公众号《技术拆解官》相关代码库-当代庖丁(TechPaoding)
Java
9
star
9

SecCase

检测对抗沉淀
JavaScript
7
star
10

android_kprobe_hook_architecture

An engineering project about android kprobe hook
C
4
star
11

live_analysis_system

直播数据分析系统,竞品参照飞瓜,新榜数据等数据分析平台。目前系统可监控范围包含抖音、快手、淘宝的直播,需要可联系。
4
star
12

tcc0lin.github.io

HTML
3
star
13

KubernetesResearch

✖️该项目是围绕Kubernetes集群以及其周边生态组件做的一些实践,具体DEMO展示可以看看项目介绍。
Shell
3
star
14

OkHttpLife

掘金小册《一个请求的惊奇人生-深度展现OkHttp的生命轨迹》资源
2
star
15

giantlegs

Large distributed crawler system
1
star
16

tcc0lin_blog

1
star
17

cloudcrawler_repository

公众号代码案例
Java
1
star
18

aioinit

🔑🔒Automatically create enterprise version of aiohttp project,基于Aiohttp的企业级项目自动化构建工具,帮你专注于业务开发。
1
star