Go API

Prerequisites

Capabilities

FeatureDescription
Device enumerationList all attached/available Frida devices
Process enumerationList running processes on a device
Application enumerationList installed applications on a device
AttachAttach to a running process by PID or name
Spawn + attachSpawn a new process and attach to it
Information retrievalQuery metadata about devices, applications, processes

Getting Started

Minimal Example: Enumerate Devices

 1package main
 2
 3import (
 4    "fmt"
 5
 6    "github.com/frida/frida-go/frida"
 7)
 8
 9func main() {
10    manager := frida.NewDeviceManager()
11    devices, err := manager.EnumerateDevices()
12    if err != nil {
13        panic(err)
14    }
15
16    fmt.Printf("[*] Frida version: %s\n", frida.Version())
17    fmt.Println("[*] Devices: ")
18    for _, device := range devices {
19        fmt.Printf("[*] %s => %s\n", device.Name(), device.ID())
20    }
21}

Expected output:

$ go build main.go && ./main
[*] Frida version: 16.0.3
[*] Devices:
[*] Local System => local
[*] Local Socket => socket

Key Types

Full API Reference

See https://pkg.go.dev/github.com/frida/frida-go/frida for the complete type and method documentation.