Live data from Hacker News

Saurik releases Substrate for Android

cydiasubstrate.com

1–10 of 39 posts

Re: Saurik releases Substrate for Android

#3
Looks a lot like XposedFramework:

https://github.com/rovo89/XposedBridge/wiki/Development-tuto...

Xposed has allowed me to iterate much more rapidly on framework tweaks, and also keep them much cleaner (since now I just have the "hooks" instead of directly changing Android framework). Also, I can run on more devices because I don't have to replace some framework JAR which the vendor tweaked substantially.

Re: Saurik releases Substrate for Android

#4
post #3

Looks a lot like XposedFramework: https://github.com/rovo89/XposedBridge/wiki/Development-tuto... Xposed has allowed me to iterate much more rapidly on framework tweaks, and also keep them much cleaner (since now I just have the "hooks" instead of directly changing Android framework). Also, I can run on more devices because I don't have to replace some framework JAR which the vendor tweaked substantially.

saurik wrote a comparison of Xposed and Substrate that may be interesting to you: http://www.cydiasubstrate.com/id/34058d37-3198-414f-a696-73e...

> That said, at some level the libraries are fairly similar: the core mechanism by which a method is hooked in Xposed (swapping it out for a JNI implementation) is actually the same one that I described in the talk I gave on Substrate at a conference called Android Open in 2011. The result is that there are some similarities in the functionality offered by the two frameworks.

> Thankfully, Substrate's injection mechanism does not conflict with the one used by Xposed: therefore, if users or developers would like to have both frameworks installed, that is actually possible. There are some places where the two libraries "disagree" (such as Xposed totally removing the Java security model that Substrate preserves), but the resulting behavior is harmless.

Re: Saurik releases Substrate for Android

#5
This is probably completely off-topic, but could this be used to create the ability to deny permissions to applications? As a privacy-sensitive person, I would like to prevent some applications from receiving certain permissions, while still using them (for example, why should a game have access to my contacts?), but Android doesn't provide that functionality.

Would this be possible/viable with this framework? I might give it a shot, if so.

Re: Saurik releases Substrate for Android

#7
post #5

This is probably completely off-topic, but could this be used to create the ability to deny permissions to applications? As a privacy-sensitive person, I would like to prevent some applications from receiving certain permissions, while still using them (for example, why should a game have access to my contacts?), but Android doesn't provide that functionality. Would this be possible/viable with this framework? I migh…

Not answering your question, but applications for Android are generally written with the assumption that they have whatever permissions they requested at install time, and may behave unpredictably if calls to things that are supposed to have already been authorized raise exceptions. I would expect that if you managed to do this, lots of applications would crash.

Re: Saurik releases Substrate for Android

#8
post #5

This is probably completely off-topic, but could this be used to create the ability to deny permissions to applications? As a privacy-sensitive person, I would like to prevent some applications from receiving certain permissions, while still using them (for example, why should a game have access to my contacts?), but Android doesn't provide that functionality. Would this be possible/viable with this framework? I migh…

Yes, you could hook the permission checking methods and deny them. I think there are packages that do this already (or don't throw the Permission exception but instead return an empty contact list, etc).

Re: Saurik releases Substrate for Android

#9
post #5

This is probably completely off-topic, but could this be used to create the ability to deny permissions to applications? As a privacy-sensitive person, I would like to prevent some applications from receiving certain permissions, while still using them (for example, why should a game have access to my contacts?), but Android doesn't provide that functionality. Would this be possible/viable with this framework? I migh…

Not answering your question, but applications for Android are generally written with the assumption that they have whatever permissions they requested at install time, and may behave unpredictably if calls to things that are supposed to have already been authorized raise exceptions. I would expect that if you managed to do this, lots of applications would crash.

I'm pretty sure you could fake most permissions convincingly. After all, how is an app to know that that empty contact list or those GPS coordinates on the top of mount Everest aren't actually real?

Re: Saurik releases Substrate for Android

#10
post #8
post #5

This is probably completely off-topic, but could this be used to create the ability to deny permissions to applications? As a privacy-sensitive person, I would like to prevent some applications from receiving certain permissions, while still using them (for example, why should a game have access to my contacts?), but Android doesn't provide that functionality. Would this be possible/viable with this framework? I migh…

Yes, you could hook the permission checking methods and deny them. I think there are packages that do this already (or don't throw the Permission exception but instead return an empty contact list, etc).

Hmm, could you point me to any? A search didn't turn anything up, but I haven't done any Android development, so I'm far from an expert.
Post reply on HN