Skip to content

HuntMemory (HMem) πŸ”βš‘

License: GPL v3 Platform Architecture Rust Kotlin Jetpack Compose

HuntMemory (HMem) is a high-performance process memory editor and scanner designed exclusively for Android 10+ (API 29+) on ARM64 (arm64-v8a / aarch64-linux-android).

The project pairs a modern Jetpack Compose floating overlay UI with an ultra-fast Rust 2024 scanning core accelerated by ARM NEON SIMD, interfacing directly with the Linux kernel via the HMKPM (KernelPatch Module).


🧭 Documentation Navigation


πŸ“± Target Device Requirements

To run HuntMemory on your device:

  1. Architecture: Physical 64-bit ARM device (arm64-v8a / aarch64).
  2. Android Version: Android 10.0+ (API level 29 or higher).
  3. Kernel Version: Kernel Linux 4.14+.
  4. Root Environment: Magisk 26+, KernelSU, or APatch with root granted.
  5. KernelPatch & HuntMemory-KPM (HMKPM):
    • Device kernel patched with KernelPatch or KPM-Manager.
    • HMKPM loaded to enable direct MMU memory manipulation via the SYS_GETRESUID syscall hook.
  6. Overlay Permission:
    • Grant "Display over other apps" (SYSTEM_ALERT_WINDOW) when prompted on the initial launch.

πŸ›οΈ System Architecture Preview

HuntMemory isolates presentation, privileged operations, and native computation across distinct security domains:

graph TD
    subgraph UI_Space ["Android App (Userspace - App Process)"]
        UI["Overlay UI (Jetpack Compose)"]
        VK["Virtual Keyboard (QWERTY / NUM / HEX)"]
        Canvas_UI["LuaCanvasOverlay (GPU / DrawScope)"]
        Tabs["Tabs (Process / Scan / Table / Lua / Settings)"]
        Conn["HMemServiceConnection (IPC Client)"]
    end

    subgraph Root_Space ["Root Service (Userspace - UID 0 via libsu)"]
        RS["HMemService (RootService AIDL)"]
        NB["NativeBridge (JNI @FastNative)"]
        subgraph Rust_Engine ["Rust Engine (libhmem_jni.so)"]
            SCAN["Scanner (ARM NEON SIMD)"]
            EDIT["Editor & FreezeEngine (Worker Thread)"]
            SCRIPT["Lua 5.4 Engine (mlua + gg.* API)"]
            MAPS["Maps & Pagemap Streaming Parser"]
            KPMC["HMKPM Client (mlock + Syscall Hook)"]
        end
    end

    subgraph Kernel_Space ["Kernel Space (KernelPatch Module)"]
        KPM["HMKPM (KernelPatch Module)"]
        PGD["MMU Page Table Walking (task->mm->pgd)"]
        MEM["Target Process Physical RAM"]
    end

    UI --> Conn
    VK --> UI
    Tabs --> UI
    Conn -- "AIDL / Binder IPC" --> RS
    RS --> NB
    NB --> Rust_Engine
    SCRIPT -. "Canvas & UI Callbacks" .-> Canvas_UI
    KPMC -- "Syscall getresuid (Magic 0x00484D4B504D)" --> KPM
    KPM --> PGD
    PGD --> MEM

✨ Key Features

  • 🎯 SIMD-Accelerated Memory Scanning:

    • ARM NEON Intrinsics: Vectorized memory evaluation processing up to 16 bytes per cycle.
    • Multi-Type & Auto Scan: Search across multiple integer and floating-point types simultaneously.
    • Range & Group Scanning: Locate values within bounds or discover structured variables grouped closely in memory (spec:distance).
    • Unknown & Differential Scans: Track dynamic values with Increased, Decreased, Changed, Unchanged, and delta filters.
  • πŸ“œ Lua 5.4 Scripting & GameGuardian Compatibility:

    • Native hmem.* & gg.* Support: Direct compatibility for running existing GameGuardian scripts.
    • Dynamic Overlay Menus & Dialogs: Create custom floating cheat menus, prompts, and choice selectors in Jetpack Compose directly from Lua.
    • On-Screen Canvas Overlay (ESP/HUD): Hardware-accelerated 2D lines, bounding boxes, circles, and text rendering overlaying target games.
  • πŸ” Obscured & Scientific Number Support:

    • XOR-Keypair Decryption: Native detection and editing for Anti-Cheat Toolkit (ACTk) obscured types (ObscuredInt, ObscuredFloat, ObscuredDouble, ObscuredLong).
    • BigDouble / Scientific Structs: Parse and modify scientific mantissa/exponent structures used by incremental engines (BreakInfinity / Decimal).
  • πŸ—ΊοΈ Comprehensive Memory Region Filtering:

    • Automatically classifies memory mappings: Anonymous [A], C++ Alloc [CA], C++ BSS [CB], C++ Data [CD], C++ Heap [CH], Java Heap [JH], Stack [S], Ashmem [AS], and Libraries [XA].
    • Pagemap residency verification and zram swap awareness.
  • ✏️ Real-Time Memory Editing & Freeze Engine:

    • Single and batch memory writing.
    • Low-overhead native background thread maintaining locked values at configurable intervals.
  • πŸ“± Modern Floating Overlay UI:

    • Fully resizable and movable overlay built with Jetpack Compose Material 3.
    • Integrated Contextual Virtual Keyboard: Custom QWERTY, Numeric, and Hexadecimal input without triggering system IME displacements.

πŸ› οΈ Quick Build

# Clone repository
git clone https://github.com/Yervant7/HuntMemory.git
cd HuntMemory

# Add ARM64 Rust target & cargo-ndk
rustup target add aarch64-linux-android
cargo install cargo-ndk

# Compile Debug APK (Rust native library compiles automatically)
.\gradlew assembleDebug

For complete compilation guidelines, refer to the Building Guide.