GithubHelp home page GithubHelp logo

spmn / gta.android.asiloader Goto Github PK

View Code? Open in Web Editor NEW
15.0 5.0 5.0 21 KB

PoC shared library (.so) loader for Android apps

License: GNU General Public License v3.0

Makefile 3.29% C 85.48% Batchfile 11.23%
gtasa android asi loader

gta.android.asiloader's Introduction

GTA.Android.ASILoader

Proof of concept shared library (.so) loader for GTA III/VC/SA/LCS

Quick info

Android provides two locations for apps to store files into:

  1. internal storage: no permissions needed, only the owning app can access the files (not even the user!)
  2. external storage: permissions needed, any app can access the files (including the user)

For security reasons, Android apps can load shared libraries from these locations only:

  1. APK (hard/time consuming to patch)
  2. system directories (not writable by the user/app)
  3. internal storage (readable/writable by the app only)

Usually, mods circumvent this loader restriction by packing the .so files directly into the APK. However, this approach comes with a big downside: you have to rebuild and reinstall the APK every time you make a change to the mod.

Solution

A master mod (ASI Loader) is packed into the APK like a normal mod. Everytime the app starts, the ASI Loader scans Android/data/<appid>/files/ASI/ directory for .asi files, copies them to internal storage then loads them into the process.

This way libs can be updated with a simple adb push to the app external directory.

Requirements

  • GTA .apk file (preferably the latest version, otherwise the .patch file might fail)
  • Android NDK
  • apktool
  • uber-apk-signer

Installation

  1. Unpack the APK (apktool)
  2. Apply: (patch)
    • src/patches/WarMedia.patch for GTA III/VC/SA
    • src/patches/GTAActivityBase.patch for GTA LCS
  3. Build the ASI Loader (ndk-build)
  4. Copy libASILoader.so to <unpack>/lib/armeabi-v7a/
  5. Rebuild the APK (apktool)
  6. Sign the APK (uber-apk-signer)
  7. Copy and install the signed APK

If everything went good, you should see a message in logcat from the ASI Loader at game startup. You can also build and load the example mod.

gta.android.asiloader's People

Contributors

spmn avatar

Stargazers

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

Watchers

 avatar  avatar  avatar  avatar  avatar

gta.android.asiloader's Issues

No pc users

What about people that dont have pc how are we gonna build the lib?

Bc some plugins have builders inside github

Need more information

Hello spmn . I am Hand101 . I just want to let you know that the readme doesn't provide much information on how this could be installed. Thanks to ChatGPT i was able to figure that out. You have only mentioned GTA III , GTA VC , GTA SA , GTA LCS. This asi loader does also work for Bully Anniversary Edition. Most important factor is you have to tell that to install this. You need Android-ndk.cmd as environment variable. then actual command for ndk-build and the process of patch you have to have WarMedia.smali on the folder smali/com/wardrumstudios and run the command -- patch -p1 < WarMedia.patch . Also if possible message me on discord . I need some more help in developing some more mods. Apart form that it is a really nice modification. I even though is unable to understand what half of the codes does. I asked ChatGPT how exactly does your rainbow hud works. it told me its not like it directly messes with the hud colors it does something else i can't remember. You are such a great modder. you should be able to help me right . I wanna make more ASI mods.

I need the libASILoader.so file

Hi, i am trying to make a mod for gta 3 android, but unfortunately i don't have a pc, so i can't build the library, can someone please give me libASILoader.so? My discord is hackerusuprem

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.