This repository consists of the communication interface between Xposed framework and module app noumena.
libxposed / service Goto Github PK
View Code? Open in Web Editor NEWLicense: Apache License 2.0
License: Apache License 2.0
We are working on this API with @canyie and @tiann.
We are proposing an API that allows Xposed modules to communicate with the Xposed framework. For modules to this API, they have to implementation
-ly depend on us.
We will provide an aidl
interface for modules to RPC framework's methods. Modules can get an implementation of such an aidl
interface by calling a static method. Let say its name is IXpoedService getService()
, where we will grab the binder from the framework.
Two options to get the binder for root frameworks:
getService
can directly return the binder.getService
to return the binder.To get the binder from another app, the only way is to use ContentProvider
. Thus, for non-root frameworks to provide such an API, they have to register a content provider with a certain authority: say io.github.xposed-service
. Then we can get the content provider can use call
to binder from the framework.
HOWEVER, using a content provider requires context
, which is not available before binding the application. For non-root frameworks, I supposed they are loading framework after Application
is created.
To sum up, the getService
should look like:
IXPosedService getService() {
if (sService != null) return sService; // For the first option of root framework, it should always be the case.
sService = getFromContentProvider(); // For non-root framework, get it from content provider.
return sService;
}
A brief aidl
API is proposed as:
parcelable Application {
String packageName;
int userId;
}
interface IXposedService {
const String FEATURE_X = "xposed.feature.x"; // some constants
int getXposedApi(); // 89 for example
String getFrameworkName(); // LSPosed for example
String getFrameworkVersionName(); // v1 for example
int getFrameworkVersionCode(); // 233 for example
List<String> getSupportedFeatures(); // ["x"] for example. Should match predefined constants
bool isFeatureSupported(String); // pass predefined constants to it
XRemoteSharedPreference getRemoteSharedPreference(String name); // An alternative to XSharedPreference
List<Application> getScope(); // Scopes of the modules. ["android", "com.android.systemui"] for example.
// How about returning PackageInfo instead?
bool setScope(List<Application>); // Set scopes to provided package names. Futher user confirm is required.
// return false only if framework fails to pop confirm windows.
// Should a callback provided?
// For modules targeting API 30+, it's hard for them to query all packages from all users.
// Maybe we can provide an interface to help them?
// Other interface suggestions are welcome.
}
@yujincheng08
Hello, why can't I index this library in Android Studio?
The previous Could not find io.github.libxposed:api:100 also had a similar error, but I found the warehouse file in the actions of https://github.com/libxposed/api and downloaded it to my local warehouse. I don't know how to solve the problem of io.github.libxposed:service-interface:100, hope to get your reply!
Error message:
Configuration cache state could not be cached: field importDirs
of task :daemon:compileDebugAidl
of type com.android.build.gradle.tasks.AidlCompile
: error writing value of type 'org.gradle.api.internal.artifacts.configurations.DefaultConfiguration$ConfigurationFileCollection'
Could not resolve all files for configuration ':daemon:debugCompileClasspath'.
Could not find io.github.libxposed:service-interface:100.
Required by:
project :daemon
Description
When we use the android studio to build the project that throws out an error about Xposed Interface can not be resolved, please look at the screenshot below:
I'm a beginner on about the java language, that would be grateful if you guys can figure it out for me please with this project.
Thanks!
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.