Go rust reverse

From oyi77/1ai-skills · View interactive version

Go rust reverse is an AI agent skill from the GitHub repository oyi77/1ai-skills. Use when reverse engineer Go and Rust binaries: recognize the language runtime from go.buildid, runtime symbols, or panic strings, recover function tables and names from pclntab, and rebuild symbols with GoReSym or redress before Ghidra/IDA analysis. Use when analyzing stripped Go/Rust malware, ELF/

How to use this skill

Skill file

Go / Rust Binary Reverse Engineering

Overview

Go and Rust binaries break generic reverse-engineering assumptions. They are

statically linked, carry their own runtimes, and when stripped they leave

massive symbol tables behind (Go's pclntab, Rust's panic strings) that

generic disassemblers ignore. The language-specific shortcut is: recognize

the runtime, recover the metadata, then read the business logic — never wade

through runtime library code.

This skill covers runtime recognition, pclntab/function-name recovery with

GoReSym/redress, and idiomatic decompilation recovery for both languages,

plus a dynamic-analysis note for Go's unusual stack/scheduler behavior. It

complements (does not replace) the generic Ghidra/IDA workflow in

analyzing-go-golang-with-ghidra and similar skills.

Source: cherry-picked and translated from zhaoxuya520/reverse-skill

(skills/go-rust-reverse, MIT license); reference notes

(go-rust-notes.md) inlined.

When to Use

Trigger phrases:

Use this skill when:

inspection, or runtime fingerprints).

Prerequisites

string work.

Artifact-Evidence Routing

For a shipped local executable, use reverse-engineer-anything-with-rea as the

artifact-evidence front door when the answer depends on embedded metadata, decompiled

code, or observed behavior. Preserve the SHA-256 and evidence references, then return to

the phases below for Go/Rust-specific interpretation. A missing pclntab or unsupported

format is an unresolved limitation, not proof that the binary is not Go/Rust.

Workflow

Phase 1: Triage — Identify the Runtime

runtime. symbol residue, main.main references, or Rust panic

strings / rust_begin_unwind.

step.

Phase 2: Go — Recover Metadata

(program counter line table).

pclntab.

values render in the decompiler; follow crypto/* and net/http import

paths to locate network or encryption logic.

Phase 3: Rust — String-Drive the Analysis

first — they are the best roadmap in a stripped Rust binary.

user-visible text to the code that renders it.

poll loop — do not try to read them linearly.

Phase 4: Dynamic (Optional)

on log/config strings first rather than arbitrary addresses.

orientation in both languages.

Phase 5: Business Logic

logic: C2, persistence, exfiltration, or protocol handling.

is an acceptable fallback when pclntab recovery is partial).

Hands-On Example

Triage a stripped Go binary and confirm its runtime before metadata recovery

(Phase 1 — Triage). Ensure the toolchain exists with apt install golang-go

(Debian/Kali; go 1.24 verified here), then list symbols directly:

go tool nm ./sample | grep -E ' main\.main| runtime\.main'
# a35100 T main.main
# a361c0 T main.main.CountFlags.CountFlags.func1

go tool nm (output above verified against a real Go binary) gives an

instant stripped-vs-not read: a symbol-rich result means the binary was NOT

stripped and Go-aware tooling can recover full metadata without pclntab

parsing. Pair it with file ./sample for the runtime fingerprint.

Verification

Run this self-check before claiming completion:

panic strings / crate paths).

are located.

mapping is explicitly labeled as inferred.

identified.

cross-referenced to the decompiled evidence.

When NOT to Use

the additive pclntab/GoReSym layer, not a duplicate.

from reverse-engineering-rust-malware (Rust malware, IDA/Ghidra +

sandbox/IOCs) or analyzing-golang-malware-with-ghidra (Go + Ghidra

scripts); this skill is the toolchain-agnostic, non-malware path.

Anti-Rationalization Table

| Rationalization | Reality |

|---|---|

| "I'll just open it in Ghidra." | A stripped Go/Rust binary without pclntab recovery is a wall of runtime noise; you will burn hours in runtime.*. Recover metadata first. |

| "The Go toolchain names are useless anyway." | main.main, crypto/*, net/http and the pclntab function table are exactly the roadmap you need. |

| "I'll read the whole binary." | String-driven (Rust) and anchor-driven (Go) analysis covers the business logic with a fraction of the surface. |

| "Panic strings are just noise." | In stripped Rust binaries, panic strings and src/ paths are frequently the only surviving source map. |

| "Dynamic analysis is the same as C." | Go's goroutine stacks and scheduler break naive Frida assumptions; break on strings, not addresses. |

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.