Giter VIP home page Giter VIP logo

hopon's Introduction

HopOn

Easily inject code into OS X apps

You're gonna get some hop-ons.

This code is rough, but workable. I'm not an expert in mach_inject, XPC, or launchd, so this may be buggy. But it's at least a start.

Injecting Code with HopOn

Here's a rough outline of the steps to use HopOn:

  1. Add HopOn as a submodule

  2. Bootstrap HopOn: script/bootstrap.

  3. Add HopOn.xcodeproj to your project or workspace.

  4. Add HopOn.framework and com.diephouse.matt.HopOn-Injector to your project's dependencies.

  5. Add a build phase to copy HopOn.framework into your app's Frameworks directory.

  6. Add a build phase to copy com.diephouse.matt.HopOn-Injector to Contents/Library/LaunchServices in the Wrapper destination.

  7. Set the Runpath Search Paths to @loader_path/../Frameworks in your app's build settings.

  8. Add a file called HOPON_HOST_IDENTIFIER in a directory above the HopOn directory that contains the identifier of your app. This is needed for the launch service's permissions.

  9. Add a SMPrivilegedExecutables dictionary to your app's info.plist with the key com.diephouse.matt.HopOn-Identifier and the value identifier "com.diephouse.matt.HopOn-Identifier".

  10. Create a "Bundle" target in your app to host the injected code. You can add classes and use +load or a function like this:

attribute((constructor)) void load() { ... }


0. Copy your bundle into your app in a build phase.

0. In your app, call `+[HopOn injectBundleAtURL: intoApplication:];` to inject your bundle into a target app.

## License
Available under the MIT License.

hopon's People

Contributors

jspahrsummers avatar mdiep avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.