rikkaapps / riru-moduletemplate Goto Github PK
View Code? Open in Web Editor NEWModule template of Riru.
License: MIT License
Module template of Riru.
License: MIT License
Which modules are recomended for this zip and for magisk
[email protected]
Yes
Originally posted by @thulay880 in google/omaha#278 (comment)
whih makes riru.sh
not working
师傅,理解错我意思了,不是riru那个启动模块启动我编写riru模板生成的so,而是我编写riru模板so时,去hook app的so,然后没hook到他的加载,而且一遍历maps查看系统so可以,但是一查看libnative-lib.so这种,就crash了,所以我实现是hook dlopen去监控so的加载,但是app的so一直没监控到,只监控到几个小so
settings.gradle需要include 一下'':module" 似乎好像不太需要ignore ?
在实现一个注入需求时,发现forkAndSpecializePost这个方法执行的时候,自定义的so还未加载进来,能请教下有啥解决办法吗
should've postponed changes to riru.sh/gradle settings or make it compatible with both
So I have this device with PE Rom, forkAndSpecializePost is rarely called in this ROM.
However forkAndSpecializePre is perfectly called (I have log the function and it executed fine).
I have tested on other devices, my module works fine and forkAndSpecializePost is called perfectly.
Is there work around for this?
Here is my code:
static void forkAndSpecializePre(
JNIEnv *env, jclass clazz, jint *_uid, jint *gid, jintArray *gids, jint *runtimeFlags,
jobjectArray *rlimits, jint *mountExternal, jstring *seInfo, jstring *niceName,
jintArray *fdsToClose, jintArray *fdsToIgnore, jboolean *is_child_zygote,
jstring *instructionSet, jstring *appDataDir, jboolean *isTopApp, jobjectArray *pkgDataInfoList,
jobjectArray *whitelistedDataInfoList, jboolean *bindMountAppDataDirs, jboolean *bindMountAppStorageDirs) {
enablePlugin = isPluginAvailable(env, *appDataDir);
}
static void forkAndSpecializePost(JNIEnv *env, jclass clazz, jint res) {
if (res == 0) {
// in app process
if (enablePlugin) {
int ret;
pthread_t ntid;
if ((ret = pthread_create(&ntid, NULL, loadPluginThread, NULL))) {
LOGE("Error: %s\n", strerror(ret));
}
}
} else {
// in zygote process, res is child pid
// don't print log here, see https://github.com/RikkaApps/Riru/blob/77adfd6a4a6a81bfd20569c910bc4854f2f84f5e/riru-core/jni/main/jni_native_method.cpp#L55-L66
}
}```
我看新版模版需要自己修改 模版本身的地方不多了。。
build.gradle中需要自己改的部分可以直接从外部文件读取?
这样模版更新就不用在一行一行解决conflict 了 : (
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.