npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

frida-host

v1.0.0

Published

Multi-file support for frida

Downloads

4

Readme

frida-host

frida-host, a opensource software that allows you to use multiple source files when using frida.

996.icu LICENSE


Purpose

This project is useful when your script is going big. This usually happen during reverse-engineering some C++ project that you may face reading a complex structure (class) in stdlib (like Vec or std::string). Also this project can bring you Typescript support!

But you may ask, what's the difference between this project and frida-compile?

Basically, both can do the same thing, build bundles. The difference is that this project is more easy to use. Check out the following table so you will know!

| / | frida-host | frida-compile | |-------------------|--------------------|---------------------| | Bundle creation | ESBuild | TSC | | Performance | ESBuild Level Fast | TSC Level Fast | | Attach to Process | :white_check_mark: | :x: | | Reload-on-Change | :white_check_mark: | :x: | | Lightweight | :white_check_mark: | :white_check_mark: | | Type checking | :x: | :white_check_mark: |

How to use

A recommend file stucture is given below

- remote/
    - init.js (default entrypoint)
    - other scripts...
- host.config.js (server file)

Install necessary packages

pnpm install frida-host @types/frida-gum frida esbuild

frida package is required because frida node binding is compiled when you install the package, and the same concept applies to esbuild, since it's written in golang.

Typescript package is not required to use typescript in your project, however it is recommended to install. You should always run tsc -noEmit to do type checking becuase ESBuild does not do type checking at all.

# Optional if you'd like to use Typescript
pnpm install typescript -D

Server File

You need to create a config file. Recommended name is 'ff.config.js'. Use the following template to get started quickly.

const { defineConfig, startHost } = require('frida-host')

const conf = defineConfig({
    target: {
        name: "App",
        package: "com.example.app",
        source: "usb"
    },
    attachPreference: "try",
    entryPoint: "./remote/init.js"
})

await startHost(conf)

CLI

You can always use provided CLI to do the exactly same thing as Server File Method does. However, some feature like messageHandler is impossible to implement in CLI tool, so they are not exist in the CLI tool. If you need to use messageHandler, you must use Server File Method

Here is an example on how to spawn and hook 'com.example.app' through usb

$ frida-host ./remote/init.js -u -p com.example.app -t App -s

For more help, please use --help

$ frida-host --help