comex / substitute

A free runtime modification library.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

How is the dylib API gonna work?

rweichler opened this issue · comments

Are you gonna do it similar to dlopening everything in /Library/MobileSubstrate/DynamicLibraries... or something else? You said something about bundling this in a standalone application... how exactly would that work?

Also do you have an IRC chan?

And which iOS device/version are you primarily testing this on?

Is this substitute available on any Cydia Source yet?

@rweichler As of now it will be working like CydiaSubstrate: Substitute looks for the .dylib and the appropriate .plist in /Library/substitute/DynamicLibraries/ (but unlike CydiaSubstrate it requires a appropriate .plist to exist).
This information can be found in /ios-bootstrap/bundle-loader.m.

@shinvou thanks. I made a channel on freenode #substitute if anyone wants to join.

commented

To catch up with this:

  • Sorry I haven't really done anything in the last week. I've been busy with other things, so this is still broken and should not be installed; thus it is not on any source. That will probably change tomorrow or Friday.
  • Yes, the iOS interface for loading into the system is a copy of the Substrate one, although I expect to add some functionality for hot loading/unloading.
  • I'm testing this on iOS 8, but I want it to work on 7 as well; this is an arbitrary cutoff, but I'm not terribly interested in testing things on old platforms, since for most use cases you could just use Substrate.

As for bundling into a standalone application, if you want to interpose calls from some system library in your own app only, you can just statically link Substitute; might even be able to sneak into the App Store this way, although it's almost certainly against the rules. If you want to port to other platforms, you can also reuse however much makes sense... maybe contribute your changes back if you're nice (though the LGPL does require releasing the source of modified versions of Substitute itself).

Thanks for your work, I've been waiting for something like!
Quick question: Will substitute require WX memory pages like substrate does ?

commented

I'm rather late, but to answer that question: direct function hooking requires the ability to change writable pages to executable, because that's pretty near unavoidable (maybe not completely, but the alternative would be a big mess). However, the library also supports dynamic interposing of symbol imports, which does not require WX.

Closing this since there doesn't seem to be an actual bug.