[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M7B4PK2C73Z7V4E53CYNWDZH":3,"skill-same:01M7B4PK2C73Z7V4E53CYNWDZH":99},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":15,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":45,"commitSha":46,"skillDirectory":47,"forksCount":13,"repositoryHtmlUrl":48,"repositoryHomepageUrl":6,"ownerHtmlUrl":49,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":50,"install":51,"resources":64},"01M7B4PK2C73Z7V4E53CYNWDZH","analyzing-golang-malware-with-ghidra",null,"Reverse engineer Go-compiled malware in Ghidra by parsing Go buildinfo and pclntab structures, recovering stripped\u002Fobfuscated function names (e.g. via GoResolver), and extracting embedded module\u002Fdependency strings and types from Go binaries. Use when analyzing a Go-language malware sample, deobfuscating a garble-packed Go binary, or recovering function names and third-party dependencies from a stripped Go executable.","vikasvardhanv\u002Fjerry_skills","vikasvardhanv","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F99010657?v=4","01M7B2B0VN78W7529RQX5BR6DZ","01M7B2B0WDNTXJHRK3QNPNWRP6",0,"Apache-2.0","https:\u002F\u002Fgithub.com\u002Fvikasvardhanv\u002Fjerry_skills\u002Fblob\u002Fmain\u002Fskills\u002Fcurated_premium_skills\u002FAnthropic-Cybersecurity-Skills\u002Fskills\u002Fanalyzing-golang-malware-with-ghidra\u002FLICENSE","https:\u002F\u002Fgithub.com\u002Fvikasvardhanv\u002Fjerry_skills\u002Fblob\u002Fmain\u002Fskills\u002Fcurated_premium_skills\u002FAnthropic-Cybersecurity-Skills\u002Fskills\u002Fanalyzing-golang-malware-with-ghidra\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: analyzing-golang-malware-with-ghidra\ndescription: Reverse engineer Go-compiled malware in Ghidra by parsing Go buildinfo\n  and pclntab structures, recovering stripped\u002Fobfuscated function names (e.g. via\n  GoResolver), and extracting embedded module\u002Fdependency strings and types from Go\n  binaries. Use when analyzing a Go-language malware sample, deobfuscating a garble-packed\n  Go binary, or recovering function names and third-party dependencies from a stripped\n  Go executable.\ndomain: cybersecurity\nsubdomain: malware-analysis\ntags:\n- golang\n- ghidra\n- reverse-engineering\n- malware-analysis\n- binary-analysis\n- go-malware\n- disassembly\nversion: '1.0'\nauthor: mahipal\nlicense: Apache-2.0\nnist_csf:\n- DE.AE-02\n- RS.AN-03\n- ID.RA-01\n- DE.CM-01\nmitre_attack:\n- T1027\n- T1620\n- T1140\n- T1059\n---\n# Analyzing Golang Malware with Ghidra\n\n## Overview\n\nGo (Golang) has become a popular language for malware authors due to its cross-compilation capabilities, static linking that produces self-contained binaries, and the complexity it introduces for reverse engineering. Go binaries contain the entire runtime, standard library, and all dependencies statically linked, resulting in large binaries (often 5-15MB) with thousands of functions. Ghidra struggles with Go-specific string formats (non-null-terminated), stripped function names, and goroutine concurrency patterns. Specialized tools like GoResolver (Volexity, 2025) use control-flow graph similarity to automatically deobfuscate and recover function names in stripped or obfuscated Go binaries.\n\n\n## When to Use\n\n- When investigating security incidents that require analyzing golang malware with ghidra\n- When building detection rules or threat hunting queries for this domain\n- When SOC analysts need structured procedures for this analysis type\n- When validating security monitoring coverage for related attack techniques\n\n## Prerequisites\n\n- Ghidra 11.0+ with JDK 17+\n- GoResolver plugin (for function name recovery)\n- Go Reverse Engineering Tool Kit (go-re.tk)\n- Python 3.9+ for helper scripts\n- Understanding of Go runtime internals (goroutines, channels, interfaces)\n- Familiarity with Go binary structure (pclntab, moduledata, itab)\n\n## Key Concepts\n\n### Go Binary Structure\n\nGo binaries embed rich metadata in the `pclntab` (PC Line Table) structure, which maps program counters to function names, source files, and line numbers. Even stripped binaries retain this metadata. The `moduledata` structure contains pointers to type information, itabs (interface tables), and the pclntab itself. Go strings are stored as a pointer-length pair rather than null-terminated C strings.\n\n### Function Recovery in Stripped Binaries\n\nDespite stripping symbol tables, Go binaries retain function names within the pclntab. However, obfuscation tools like garble rename functions to random strings. GoResolver addresses this by computing control-flow graph signatures of obfuscated functions and matching them against a database of known Go standard library and third-party package functions.\n\n### Crate\u002FDependency Extraction\n\nGo's dependency management embeds module paths and version strings in the binary. Extracting these reveals the malware's third-party dependencies (HTTP libraries, encryption packages, C2 frameworks), which provides insight into capabilities without full reverse engineering.\n\n## Workflow\n\n### Step 1: Initial Binary Analysis\n\n```python\n#!\u002Fusr\u002Fbin\u002Fenv python3\n\"\"\"Analyze Go binary metadata for malware analysis.\"\"\"\nimport struct\nimport sys\nimport re\n\n\ndef find_go_build_info(data):\n    \"\"\"Extract Go build information from binary.\"\"\"\n    # Go buildinfo magic: \\xff Go buildinf:\n    magic = b'\\xff Go buildinf:'\n    offset = data.find(magic)\n    if offset == -1:\n        return None\n\n    print(f\"[+] Go build info at offset 0x{offset:x}\")\n\n    # Extract Go version string nearby\n    go_version = re.search(rb'go\\d+\\.\\d+(?:\\.\\d+)?', data[offset:offset+256])\n    if go_version:\n        print(f\"  Go Version: {go_version.group().decode()}\")\n\n    return offset\n\n\ndef find_pclntab(data):\n    \"\"\"Locate the pclntab (PC Line Table) structure.\"\"\"\n    # pclntab magic bytes vary by Go version\n    magics = {\n        b'\\xfb\\xff\\xff\\xff\\x00\\x00': \"Go 1.2-1.15\",\n        b'\\xfa\\xff\\xff\\xff\\x00\\x00': \"Go 1.16-1.17\",\n        b'\\xf1\\xff\\xff\\xff\\x00\\x00': \"Go 1.18-1.19\",\n        b'\\xf0\\xff\\xff\\xff\\x00\\x00': \"Go 1.20+\",\n    }\n\n    for magic, version in magics.items():\n        offset = data.find(magic)\n        if offset != -1:\n            print(f\"[+] pclntab found at 0x{offset:x} ({version})\")\n            return offset, version\n\n    return None, None\n\n\ndef extract_function_names(data, pclntab_offset):\n    \"\"\"Extract function names from pclntab.\"\"\"\n    if pclntab_offset is None:\n        return []\n\n    functions = []\n    # Function name strings follow specific patterns\n    func_pattern = re.compile(\n        rb'(?:main|runtime|fmt|net|os|crypto|encoding|io|sync|'\n        rb'syscall|reflect|strings|bytes|path|time|math|sort|'\n        rb'github\\.com|golang\\.org)[\u002F\\.][\\w\u002F.]+',\n    )\n\n    for match in func_pattern.finditer(data):\n        name = match.group().decode('utf-8', errors='replace')\n        if len(name) > 4 and len(name) \u003C 200:\n            functions.append(name)\n\n    return sorted(set(functions))\n\n\ndef extract_go_strings(data):\n    \"\"\"Extract Go-style strings (pointer+length pairs).\"\"\"\n    # Go strings are not null-terminated; extract readable sequences\n    strings = []\n    ascii_pattern = re.compile(rb'[\\x20-\\x7e]{10,}')\n\n    for match in ascii_pattern.finditer(data):\n        s = match.group().decode('ascii')\n        # Filter for interesting malware strings\n        interesting = [\n            'http', 'https', 'tcp', 'udp', 'dns',\n            'cmd', 'shell', 'exec', 'upload', 'download',\n            'encrypt', 'decrypt', 'key', 'token', 'password',\n            'c2', 'beacon', 'agent', 'implant', 'bot',\n            'mutex', 'persist', 'registry', 'scheduled',\n        ]\n        if any(kw in s.lower() for kw in interesting):\n            strings.append(s)\n\n    return strings\n\n\ndef extract_dependencies(data):\n    \"\"\"Extract Go module dependencies from binary.\"\"\"\n    deps = []\n    # Module paths follow pattern: github.com\u002Fuser\u002Frepo\n    dep_pattern = re.compile(\n        rb'((?:github\\.com|gitlab\\.com|golang\\.org|gopkg\\.in|'\n        rb'go\\.etcd\\.io|google\\.golang\\.org)\u002F[^\\x00\\s]{5,80})'\n    )\n\n    for match in dep_pattern.finditer(data):\n        dep = match.group().decode('utf-8', errors='replace')\n        deps.append(dep)\n\n    unique_deps = sorted(set(deps))\n    return unique_deps\n\n\ndef analyze_go_binary(filepath):\n    \"\"\"Full analysis of Go malware binary.\"\"\"\n    with open(filepath, 'rb') as f:\n        data = f.read()\n\n    print(f\"[+] Analyzing Go binary: {filepath}\")\n    print(f\"  File size: {len(data):,} bytes\")\n    print(\"=\" * 60)\n\n    # Build info\n    find_go_build_info(data)\n\n    # pclntab\n    pclntab_offset, go_version = find_pclntab(data)\n\n    # Functions\n    functions = extract_function_names(data, pclntab_offset)\n    print(f\"\\n[+] Recovered {len(functions)} function names\")\n\n    # Categorize functions\n    categories = {\n        \"network\": [], \"crypto\": [], \"os_exec\": [],\n        \"file_io\": [], \"main\": [], \"third_party\": [],\n    }\n    for f in functions:\n        if 'net\u002F' in f or 'http' in f.lower():\n            categories[\"network\"].append(f)\n        elif 'crypto' in f:\n            categories[\"crypto\"].append(f)\n        elif 'os\u002Fexec' in f or 'syscall' in f:\n            categories[\"os_exec\"].append(f)\n        elif 'os.' in f or 'io\u002F' in f:\n            categories[\"file_io\"].append(f)\n        elif f.startswith('main.'):\n            categories[\"main\"].append(f)\n        elif 'github.com' in f or 'golang.org' in f:\n            categories[\"third_party\"].append(f)\n\n    for cat, funcs in categories.items():\n        if funcs:\n            print(f\"\\n  [{cat}] ({len(funcs)} functions):\")\n            for fn in funcs[:10]:\n                print(f\"    {fn}\")\n\n    # Dependencies\n    deps = extract_dependencies(data)\n    print(f\"\\n[+] Dependencies ({len(deps)}):\")\n    for dep in deps[:20]:\n        print(f\"    {dep}\")\n\n    # Suspicious strings\n    sus_strings = extract_go_strings(data)\n    print(f\"\\n[+] Suspicious strings ({len(sus_strings)}):\")\n    for s in sus_strings[:20]:\n        print(f\"    {s}\")\n\n\nif __name__ == \"__main__\":\n    if len(sys.argv) \u003C 2:\n        print(f\"Usage: {sys.argv[0]} \u003Cgo_binary>\")\n        sys.exit(1)\n    analyze_go_binary(sys.argv[1])\n```\n\n### Step 2: Ghidra Analysis Script\n\n```python\n# Ghidra script (run within Ghidra's script manager)\n# Save as AnalyzeGoBinary.py in Ghidra scripts directory\n\n# @category MalwareAnalysis\n# @description Analyze Go binary structure and recover metadata\n\ndef analyze_go_binary_ghidra():\n    \"\"\"Ghidra script for Go binary analysis.\"\"\"\n    from ghidra.program.model.mem import MemoryAccessException\n\n    program = getCurrentProgram()\n    memory = program.getMemory()\n    listing = program.getListing()\n\n    print(\"[+] Go Binary Analysis Script\")\n    print(f\"  Program: {program.getName()}\")\n\n    # Find pclntab\n    pclntab_magics = [\n        bytes([0xf0, 0xff, 0xff, 0xff]),  # Go 1.20+\n        bytes([0xf1, 0xff, 0xff, 0xff]),  # Go 1.18-1.19\n        bytes([0xfa, 0xff, 0xff, 0xff]),  # Go 1.16-1.17\n        bytes([0xfb, 0xff, 0xff, 0xff]),  # Go 1.2-1.15\n    ]\n\n    for magic in pclntab_magics:\n        addr = memory.findBytes(\n            program.getMinAddress(), magic, None, True, None\n        )\n        if addr:\n            print(f\"[+] pclntab found at {addr}\")\n            # Create label\n            program.getSymbolTable().createLabel(\n                addr, \"go_pclntab\", None,\n                ghidra.program.model.symbol.SourceType.ANALYSIS\n            )\n            break\n\n    # Fix Go string definitions\n    # Go strings are ptr+len, not null terminated\n    print(\"[+] Fixing Go string references...\")\n\n    # Search for function names containing package paths\n    symbol_table = program.getSymbolTable()\n    func_count = 0\n    for symbol in symbol_table.getAllSymbols(True):\n        name = symbol.getName()\n        if ('.' in name and\n            any(pkg in name for pkg in\n                ['main.', 'runtime.', 'net.', 'crypto.', 'os.'])):\n            func_count += 1\n\n    print(f\"[+] Found {func_count} Go function symbols\")\n\n\n# Execute\nanalyze_go_binary_ghidra()\n```\n\n## Validation Criteria\n\n- Go version and build information extracted from binary\n- pclntab located and parsed for function name recovery\n- Third-party dependencies identified revealing malware capabilities\n- Main package functions enumerated for targeted analysis\n- Network, crypto, and OS exec functions categorized\n- Ghidra analysis correctly labels Go runtime structures\n\n## References\n\n- [CUJO AI - Reverse Engineering Go Binaries with Ghidra](https:\u002F\u002Fcujo.com\u002Fblog\u002Freverse-engineering-go-binaries-with-ghidra\u002F)\n- [Volexity GoResolver](https:\u002F\u002Fwww.volexity.com\u002Fblog\u002F2025\u002F04\u002F01\u002Fgoresolver-using-control-flow-graph-similarity-to-deobfuscate-golang-binaries-automatically\u002F)\n- [Go Reverse Engineering Tool Kit](https:\u002F\u002Fgo-re.tk\u002Fabout\u002F)\n- [SentinelOne AlphaGolang](https:\u002F\u002Fwww.sentinelone.com\u002Flabs\u002Falphagolang-a-step-by-step-go-malware-reversing-methodology-for-ida-pro\u002F)\n- [Go Binary Reversing Notes](https:\u002F\u002Fgist.github.com\u002F0xdevalias\u002F4e430914124c3fd2c51cb7ac2801acba)\n","# Analyzing Golang Malware with Ghidra\n\n## Overview\n\nGo (Golang) has become a popular language for malware authors due to its cross-compilation capabilities, static linking that produces self-contained binaries, and the complexity it introduces for reverse engineering. Go binaries contain the entire runtime, standard library, and all dependencies statically linked, resulting in large binaries (often 5-15MB) with thousands of functions. Ghidra struggles with Go-specific string formats (non-null-terminated), stripped function names, and goroutine concurrency patterns. Specialized tools like GoResolver (Volexity, 2025) use control-flow graph similarity to automatically deobfuscate and recover function names in stripped or obfuscated Go binaries.\n\n\n## When to Use\n\n- When investigating security incidents that require analyzing golang malware with ghidra\n- When building detection rules or threat hunting queries for this domain\n- When SOC analysts need structured procedures for this analysis type\n- When validating security monitoring coverage for related attack techniques\n\n## Prerequisites\n\n- Ghidra 11.0+ with JDK 17+\n- GoResolver plugin (for function name recovery)\n- Go Reverse Engineering Tool Kit (go-re.tk)\n- Python 3.9+ for helper scripts\n- Understanding of Go runtime internals (goroutines, channels, interfaces)\n- Familiarity with Go binary structure (pclntab, moduledata, itab)\n\n## Key Concepts\n\n### Go Binary Structure\n\nGo binaries embed rich metadata in the `pclntab` (PC Line Table) structure, which maps program counters to function names, source files, and line numbers. Even stripped binaries retain this metadata. The `moduledata` structure contains pointers to type information, itabs (interface tables), and the pclntab itself. Go strings are stored as a pointer-length pair rather than null-terminated C strings.\n\n### Function Recovery in Stripped Binaries\n\nDespite stripping symbol tables, Go binaries retain function names within the pclntab. However, obfuscation tools like garble rename functions to random strings. GoResolver addresses this by computing control-flow graph signatures of obfuscated functions and matching them against a database of known Go standard library and third-party package functions.\n\n### Crate\u002FDependency Extraction\n\nGo's dependency management embeds module paths and version strings in the binary. Extracting these reveals the malware's third-party dependencies (HTTP libraries, encryption packages, C2 frameworks), which provides insight into capabilities without full reverse engineering.\n\n## Workflow\n\n### Step 1: Initial Binary Analysis\n\n```python\n#!\u002Fusr\u002Fbin\u002Fenv python3\n\"\"\"Analyze Go binary metadata for malware analysis.\"\"\"\nimport struct\nimport sys\nimport re\n\n\ndef find_go_build_info(data):\n    \"\"\"Extract Go build information from binary.\"\"\"\n    # Go buildinfo magic: \\xff Go buildinf:\n    magic = b'\\xff Go buildinf:'\n    offset = data.find(magic)\n    if offset == -1:\n        return None\n\n    print(f\"[+] Go build info at offset 0x{offset:x}\")\n\n    # Extract Go version string nearby\n    go_version = re.search(rb'go\\d+\\.\\d+(?:\\.\\d+)?', data[offset:offset+256])\n    if go_version:\n        print(f\"  Go Version: {go_version.group().decode()}\")\n\n    return offset\n\n\ndef find_pclntab(data):\n    \"\"\"Locate the pclntab (PC Line Table) structure.\"\"\"\n    # pclntab magic bytes vary by Go version\n    magics = {\n        b'\\xfb\\xff\\xff\\xff\\x00\\x00': \"Go 1.2-1.15\",\n        b'\\xfa\\xff\\xff\\xff\\x00\\x00': \"Go 1.16-1.17\",\n        b'\\xf1\\xff\\xff\\xff\\x00\\x00': \"Go 1.18-1.19\",\n        b'\\xf0\\xff\\xff\\xff\\x00\\x00': \"Go 1.20+\",\n    }\n\n    for magic, version in magics.items():\n        offset = data.find(magic)\n        if offset != -1:\n            print(f\"[+] pclntab found at 0x{offset:x} ({version})\")\n            return offset, version\n\n    return None, None\n\n\ndef extract_function_names(data, pclntab_offset):\n    \"\"\"Extract function names from pclntab.\"\"\"\n    if pclntab_offset is None:\n        return []\n\n    functions = []\n    # Function name strings follow specific patterns\n    func_pattern = re.compile(\n        rb'(?:main|runtime|fmt|net|os|crypto|encoding|io|sync|'\n        rb'syscall|reflect|strings|bytes|path|time|math|sort|'\n        rb'github\\.com|golang\\.org)[\u002F\\.][\\w\u002F.]+',\n    )\n\n    for match in func_pattern.finditer(data):\n        name = match.group().decode('utf-8', errors='replace')\n        if len(name) > 4 and len(name) \u003C 200:\n            functions.append(name)\n\n    return sorted(set(functions))\n\n\ndef extract_go_strings(data):\n    \"\"\"Extract Go-style strings (pointer+length pairs).\"\"\"\n    # Go strings are not null-terminated; extract readable sequences\n    strings = []\n    ascii_pattern = re.compile(rb'[\\x20-\\x7e]{10,}')\n\n    for match in ascii_pattern.finditer(data):\n        s = match.group().decode('ascii')\n        # Filter for interesting malware strings\n        interesting = [\n            'http', 'https', 'tcp', 'udp', 'dns',\n            'cmd', 'shell', 'exec', 'upload', 'download',\n            'encrypt', 'decrypt', 'key', 'token', 'password',\n            'c2', 'beacon', 'agent', 'implant', 'bot',\n            'mutex', 'persist', 'registry', 'scheduled',\n        ]\n        if any(kw in s.lower() for kw in interesting):\n            strings.append(s)\n\n    return strings\n\n\ndef extract_dependencies(data):\n    \"\"\"Extract Go module dependencies from binary.\"\"\"\n    deps = []\n    # Module paths follow pattern: github.com\u002Fuser\u002Frepo\n    dep_pattern = re.compile(\n        rb'((?:github\\.com|gitlab\\.com|golang\\.org|gopkg\\.in|'\n        rb'go\\.etcd\\.io|google\\.golang\\.org)\u002F[^\\x00\\s]{5,80})'\n    )\n\n    for match in dep_pattern.finditer(data):\n        dep = match.group().decode('utf-8', errors='replace')\n        deps.append(dep)\n\n    unique_deps = sorted(set(deps))\n    return unique_deps\n\n\ndef analyze_go_binary(filepath):\n    \"\"\"Full analysis of Go malware binary.\"\"\"\n    with open(filepath, 'rb') as f:\n        data = f.read()\n\n    print(f\"[+] Analyzing Go binary: {filepath}\")\n    print(f\"  File size: {len(data):,} bytes\")\n    print(\"=\" * 60)\n\n    # Build info\n    find_go_build_info(data)\n\n    # pclntab\n    pclntab_offset, go_version = find_pclntab(data)\n\n    # Functions\n    functions = extract_function_names(data, pclntab_offset)\n    print(f\"\\n[+] Recovered {len(functions)} function names\")\n\n    # Categorize functions\n    categories = {\n        \"network\": [], \"crypto\": [], \"os_exec\": [],\n        \"file_io\": [], \"main\": [], \"third_party\": [],\n    }\n    for f in functions:\n        if 'net\u002F' in f or 'http' in f.lower():\n            categories[\"network\"].append(f)\n        elif 'crypto' in f:\n            categories[\"crypto\"].append(f)\n        elif 'os\u002Fexec' in f or 'syscall' in f:\n            categories[\"os_exec\"].append(f)\n        elif 'os.' in f or 'io\u002F' in f:\n            categories[\"file_io\"].append(f)\n        elif f.startswith('main.'):\n            categories[\"main\"].append(f)\n        elif 'github.com' in f or 'golang.org' in f:\n            categories[\"third_party\"].append(f)\n\n    for cat, funcs in categories.items():\n        if funcs:\n            print(f\"\\n  [{cat}] ({len(funcs)} functions):\")\n            for fn in funcs[:10]:\n                print(f\"    {fn}\")\n\n    # Dependencies\n    deps = extract_dependencies(data)\n    print(f\"\\n[+] Dependencies ({len(deps)}):\")\n    for dep in deps[:20]:\n        print(f\"    {dep}\")\n\n    # Suspicious strings\n    sus_strings = extract_go_strings(data)\n    print(f\"\\n[+] Suspicious strings ({len(sus_strings)}):\")\n    for s in sus_strings[:20]:\n        print(f\"    {s}\")\n\n\nif __name__ == \"__main__\":\n    if len(sys.argv) \u003C 2:\n        print(f\"Usage: {sys.argv[0]} \u003Cgo_binary>\")\n        sys.exit(1)\n    analyze_go_binary(sys.argv[1])\n```\n\n### Step 2: Ghidra Analysis Script\n\n```python\n# Ghidra script (run within Ghidra's script manager)\n# Save as AnalyzeGoBinary.py in Ghidra scripts directory\n\n# @category MalwareAnalysis\n# @description Analyze Go binary structure and recover metadata\n\ndef analyze_go_binary_ghidra():\n    \"\"\"Ghidra script for Go binary analysis.\"\"\"\n    from ghidra.program.model.mem import MemoryAccessException\n\n    program = getCurrentProgram()\n    memory = program.getMemory()\n    listing = program.getListing()\n\n    print(\"[+] Go Binary Analysis Script\")\n    print(f\"  Program: {program.getName()}\")\n\n    # Find pclntab\n    pclntab_magics = [\n        bytes([0xf0, 0xff, 0xff, 0xff]),  # Go 1.20+\n        bytes([0xf1, 0xff, 0xff, 0xff]),  # Go 1.18-1.19\n        bytes([0xfa, 0xff, 0xff, 0xff]),  # Go 1.16-1.17\n        bytes([0xfb, 0xff, 0xff, 0xff]),  # Go 1.2-1.15\n    ]\n\n    for magic in pclntab_magics:\n        addr = memory.findBytes(\n            program.getMinAddress(), magic, None, True, None\n        )\n        if addr:\n            print(f\"[+] pclntab found at {addr}\")\n            # Create label\n            program.getSymbolTable().createLabel(\n                addr, \"go_pclntab\", None,\n                ghidra.program.model.symbol.SourceType.ANALYSIS\n            )\n            break\n\n    # Fix Go string definitions\n    # Go strings are ptr+len, not null terminated\n    print(\"[+] Fixing Go string references...\")\n\n    # Search for function names containing package paths\n    symbol_table = program.getSymbolTable()\n    func_count = 0\n    for symbol in symbol_table.getAllSymbols(True):\n        name = symbol.getName()\n        if ('.' in name and\n            any(pkg in name for pkg in\n                ['main.', 'runtime.', 'net.', 'crypto.', 'os.'])):\n            func_count += 1\n\n    print(f\"[+] Found {func_count} Go function symbols\")\n\n\n# Execute\nanalyze_go_binary_ghidra()\n```\n\n## Validation Criteria\n\n- Go version and build information extracted from binary\n- pclntab located and parsed for function name recovery\n- Third-party dependencies identified revealing malware capabilities\n- Main package functions enumerated for targeted analysis\n- Network, crypto, and OS exec functions categorized\n- Ghidra analysis correctly labels Go runtime structures\n\n## References\n\n- [CUJO AI - Reverse Engineering Go Binaries with Ghidra](https:\u002F\u002Fcujo.com\u002Fblog\u002Freverse-engineering-go-binaries-with-ghidra\u002F)\n- [Volexity GoResolver](https:\u002F\u002Fwww.volexity.com\u002Fblog\u002F2025\u002F04\u002F01\u002Fgoresolver-using-control-flow-graph-similarity-to-deobfuscate-golang-binaries-automatically\u002F)\n- [Go Reverse Engineering Tool Kit](https:\u002F\u002Fgo-re.tk\u002Fabout\u002F)\n- [SentinelOne AlphaGolang](https:\u002F\u002Fwww.sentinelone.com\u002Flabs\u002Falphagolang-a-step-by-step-go-malware-reversing-methodology-for-ida-pro\u002F)\n- [Go Binary Reversing Notes](https:\u002F\u002Fgist.github.com\u002F0xdevalias\u002F4e430914124c3fd2c51cb7ac2801acba)\n",{"name":5,"tags":24,"author":32,"domain":33,"license":14,"version":34,"nist_csf":35,"subdomain":28,"description":7,"mitre_attack":40},[25,26,27,28,29,30,31],"golang","ghidra","reverse-engineering","malware-analysis","binary-analysis","go-malware","disassembly","mahipal","cybersecurity","1.0",[36,37,38,39],"DE.AE-02","RS.AN-03","ID.RA-01","DE.CM-01",[41,42,43,44],"T1027","T1620","T1140","T1059","main","1eb986d0b0ecc180291597e08eb5a58288843536","skills\u002Fcurated_premium_skills\u002FAnthropic-Cybersecurity-Skills\u002Fskills\u002Fanalyzing-golang-malware-with-ghidra","https:\u002F\u002Fgithub.com\u002Fvikasvardhanv\u002Fjerry_skills","https:\u002F\u002Fgithub.com\u002Fvikasvardhanv","2026-08-25 13:16:33",{"source":8,"skillName":5,"commands":52,"prompt":62,"zipAvailable":63},[53,56,59],{"tool":54,"command":55},"npx","npx skills add vikasvardhanv\u002Fjerry_skills --skill analyzing-golang-malware-with-ghidra",{"tool":57,"command":58},"bunx","bunx skills add vikasvardhanv\u002Fjerry_skills --skill analyzing-golang-malware-with-ghidra",{"tool":60,"command":61},"pnpm","pnpm dlx skills add vikasvardhanv\u002Fjerry_skills --skill analyzing-golang-malware-with-ghidra","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fvikasvardhanv\u002Fjerry_skills\u002Fblob\u002Fmain\u002Fskills\u002Fcurated_premium_skills\u002FAnthropic-Cybersecurity-Skills\u002Fskills\u002Fanalyzing-golang-malware-with-ghidra\u002FSKILL.md",true,[65,71,75,81,85,89,95],{"path":66,"resourceType":67,"resourceTypeDesc":68,"sizeBytes":69,"sourceHtmlUrl":70},"assets\u002Ftemplate.md","ASSET","资产文件",752,"https:\u002F\u002Fgithub.com\u002Fvikasvardhanv\u002Fjerry_skills\u002Fblob\u002Fmain\u002Fskills\u002Fcurated_premium_skills\u002FAnthropic-Cybersecurity-Skills\u002Fskills\u002Fanalyzing-golang-malware-with-ghidra\u002Fassets\u002Ftemplate.md",{"path":72,"resourceType":72,"resourceTypeDesc":73,"sizeBytes":74,"sourceHtmlUrl":15},"LICENSE","许可证",11255,{"path":76,"resourceType":77,"resourceTypeDesc":78,"sizeBytes":79,"sourceHtmlUrl":80},"references\u002Fapi-reference.md","REFERENCE","参考文档",2602,"https:\u002F\u002Fgithub.com\u002Fvikasvardhanv\u002Fjerry_skills\u002Fblob\u002Fmain\u002Fskills\u002Fcurated_premium_skills\u002FAnthropic-Cybersecurity-Skills\u002Fskills\u002Fanalyzing-golang-malware-with-ghidra\u002Freferences\u002Fapi-reference.md",{"path":82,"resourceType":77,"resourceTypeDesc":78,"sizeBytes":83,"sourceHtmlUrl":84},"references\u002Fstandards.md",882,"https:\u002F\u002Fgithub.com\u002Fvikasvardhanv\u002Fjerry_skills\u002Fblob\u002Fmain\u002Fskills\u002Fcurated_premium_skills\u002FAnthropic-Cybersecurity-Skills\u002Fskills\u002Fanalyzing-golang-malware-with-ghidra\u002Freferences\u002Fstandards.md",{"path":86,"resourceType":77,"resourceTypeDesc":78,"sizeBytes":87,"sourceHtmlUrl":88},"references\u002Fworkflows.md",1606,"https:\u002F\u002Fgithub.com\u002Fvikasvardhanv\u002Fjerry_skills\u002Fblob\u002Fmain\u002Fskills\u002Fcurated_premium_skills\u002FAnthropic-Cybersecurity-Skills\u002Fskills\u002Fanalyzing-golang-malware-with-ghidra\u002Freferences\u002Fworkflows.md",{"path":90,"resourceType":91,"resourceTypeDesc":92,"sizeBytes":93,"sourceHtmlUrl":94},"scripts\u002Fagent.py","SCRIPT","脚本",9117,"https:\u002F\u002Fgithub.com\u002Fvikasvardhanv\u002Fjerry_skills\u002Fblob\u002Fmain\u002Fskills\u002Fcurated_premium_skills\u002FAnthropic-Cybersecurity-Skills\u002Fskills\u002Fanalyzing-golang-malware-with-ghidra\u002Fscripts\u002Fagent.py",{"path":96,"resourceType":91,"resourceTypeDesc":92,"sizeBytes":97,"sourceHtmlUrl":98},"scripts\u002Fprocess.py",4706,"https:\u002F\u002Fgithub.com\u002Fvikasvardhanv\u002Fjerry_skills\u002Fblob\u002Fmain\u002Fskills\u002Fcurated_premium_skills\u002FAnthropic-Cybersecurity-Skills\u002Fskills\u002Fanalyzing-golang-malware-with-ghidra\u002Fscripts\u002Fprocess.py",[100,108,115,122,129,136],{"skillNo":101,"name":102,"nameZh":6,"description":103,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":104,"licenseFileUrl":6,"sourceHtmlUrl":105,"categories":106,"keywords":107,"publishedAt":19},"01M7BESR1CJ3H5SP9XM8KYJZ9W","syllabus","Generates a curated supplementary reading list from any course syllabus using Consensus academic search. Grill-me intake (syllabus input format + course audience + year range) plus a grouping forcing-options checkpoint before any search runs — so the reading list matches the course's level and recency need. Parses the syllabus to extract topics and learning outcomes, searches Consensus for recent peer-reviewed papers per topic, and produces a professionally formatted .docx with clickable Consensus links, plain-language summaries calibrated to audience level, and Bloom-higher-order discussion questions tied to course learning goals. Use when the user uploads a syllabus, course outline, or curriculum document and wants supplementary readings (e.g., 'create a reading list from this syllabus', 'find recent papers for my course') — even casual mentions with a syllabus attached should trigger this skill.","MIT","https:\u002F\u002Fgithub.com\u002Fvikasvardhanv\u002Fjerry_skills\u002Fblob\u002Fmain\u002Fskills\u002Fresearch\u002Fsyllabus\u002Fskills\u002Fsyllabus\u002FSKILL.md",[],[],{"skillNo":109,"name":110,"nameZh":6,"description":111,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":104,"licenseFileUrl":6,"sourceHtmlUrl":112,"categories":113,"keywords":114,"publishedAt":19},"01M7BES1YA6R97W7QPMFFM1PED","pulse","Multi-source recency research skill that takes the pulse of any topic across Reddit, Hacker News, the open web, and optionally X\u002FTwitter within a configurable recent window (default 30 days). Forcing intake clarifies topic specificity, angle (trend\u002Fsentiment\u002Fproblems\u002Fopportunities\u002Fcomparison), time window, and platform scope before searching. Returns a synthesized briefing with citations, engagement metrics, and cross-platform pattern analysis. Use when the user requests multi-source recency intelligence on a topic (e.g., 'pulse on [topic]', 'what's happening with [topic]', 'what are people saying about [topic]', 'current conversation about [topic]', 'take the pulse of [topic]', 'trending: [topic]', 'find me info on [topic]'), and for competitor research, trend discovery, tool comparisons, and audience sentiment analysis.","https:\u002F\u002Fgithub.com\u002Fvikasvardhanv\u002Fjerry_skills\u002Fblob\u002Fmain\u002Fskills\u002Fresearch\u002Fpulse\u002Fskills\u002Fpulse\u002FSKILL.md",[],[],{"skillNo":116,"name":117,"nameZh":6,"description":118,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":104,"licenseFileUrl":6,"sourceHtmlUrl":119,"categories":120,"keywords":121,"publishedAt":19},"01M7BERNHYGY035AR00VRT03KE","patent","Patent prior-art and landscape intelligence skill — not generic patent help. Commits to one of five sub-use-cases via forcing intake (novelty search \u002F freedom-to-operate \u002F competitive landscape \u002F acquisition diligence \u002F litigation prior-art) before any search runs. Searches Google Patents, Espacenet, USPTO, and optionally Lens.org for citation-graph signals. Output is an editable Word document (.docx) with verdict, ranked closest art (claim-text extracted), CPC-class-aware landscape, family-resolved hits, geographic coverage, FTO flags where applicable, strategy recommendations, and full audit log. Use when the user asks for patent searching or analysis (e.g., 'prior art search for [invention]', 'freedom to operate analysis for [product]'). Produces search signal, not legal advice — always recommends consulting a patent attorney before filing or licensing decisions. Trademark, copyright, and trade-secret questions are out of scope.","https:\u002F\u002Fgithub.com\u002Fvikasvardhanv\u002Fjerry_skills\u002Fblob\u002Fmain\u002Fskills\u002Fresearch\u002Fpatent\u002Fskills\u002Fpatent\u002FSKILL.md",[],[],{"skillNo":123,"name":124,"nameZh":6,"description":125,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":104,"licenseFileUrl":6,"sourceHtmlUrl":126,"categories":127,"keywords":128,"publishedAt":19},"01M7BERCK1EAKTWW7R436WAR0J","notebooklm","Browser automation skill for controlling Google's NotebookLM. Use when the user wants anything done in NotebookLM (e.g., 'open NotebookLM', 'check my [name] notebook', 'ask my notebook about X', 'add [source] to NotebookLM', 'generate a Video Overview from my notebook', 'use NotebookLM Studio'). Handles reading and querying notebooks, adding sources (URLs, text, files, YouTube links, synthesized content), generating Studio outputs (Audio\u002FVideo Overviews, Mind Maps, Reports incl. Briefing Doc\u002FStudy Guide\u002FFAQ, Flashcards, Quiz, slide decks, infographics — discover the exact set from the live Studio panel; the UI evolves fast), and creating new notebooks. Requires browser automation environment — fails gracefully when unavailable.","https:\u002F\u002Fgithub.com\u002Fvikasvardhanv\u002Fjerry_skills\u002Fblob\u002Fmain\u002Fskills\u002Fresearch\u002Fnotebooklm\u002Fskills\u002Fnotebooklm\u002FSKILL.md",[],[],{"skillNo":130,"name":131,"nameZh":6,"description":132,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":104,"licenseFileUrl":6,"sourceHtmlUrl":133,"categories":134,"keywords":135,"publishedAt":19},"01M7BEQZAZAQRTXFJRY7RHV3TY","litreview","Academic literature orientation skill that searches papers via free keyless APIs (PubMed E-utilities + OpenAlex) by default — with the Consensus MCP as an optional enhancement lane when connected — builds a strategic search plan using PICO (default) or SPIDER \u002F Decomposition \u002F hybrid as fallbacks, and synthesizes findings into a formatted Word (.docx) research guide. Grill-me intake (research question specificity + framework hint + tentative depth) before the recon search; a second forcing checkpoint after Phase 2 confirms framework + sub-areas + depth before searches consume budget. Configurable depth (5\u002F10\u002F20 queries) controls coverage vs. speed. Output is a 'launching pad' — an orientation guide that lets a researcher dive in confidently, not a finished review. Use when the user starts literature-oriented research (e.g., 'litreview on [topic]', 'literature review on [topic]', 'I'm starting a literature review on X', 'I'm writing a paper on X', 'help me research X', 'I'm doing research on X', 'can you help me research X'). Do NOT use for single one-off paper searches wanting a quick list — that's a plain PubMed\u002FOpenAlex (or Consensus) query.","https:\u002F\u002Fgithub.com\u002Fvikasvardhanv\u002Fjerry_skills\u002Fblob\u002Fmain\u002Fskills\u002Fresearch\u002Flitreview\u002Fskills\u002Flitreview\u002FSKILL.md",[],[],{"skillNo":137,"name":138,"nameZh":6,"description":139,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":104,"licenseFileUrl":6,"sourceHtmlUrl":140,"categories":141,"keywords":142,"publishedAt":19},"01M7BEQKJ45K31QK5VRAQSVJCJ","grants","NIH grant research skill for clinical researchers. Grill-me intake (research idea + career stage + preliminary data + environment + submission posture + known institute targets) locks down the funding strategy before any search runs. Runs a 5-facet Consensus positioning analysis (with draft Significance\u002FInnovation language), maps the research to the right NIH institutes and study sections via RePORTER, finds NOSIs and funded overlap, and produces an editable Word document (.docx) with budget\u002Fscope-aware mechanism recommendations, submission timelines, and a mandatory program officer recommendation. Use when the user asks about research funding or makes any grant-related request (e.g., 'grants for [topic]', 'find grants for my research idea', 'what grants match my research', 'help me find NIH funding', 'grant opportunities for my research'). NIH-only scope — non-NIH funders (PCORI, DOD CDMRP, VA, foundations) are out of scope and flagged at intake.","https:\u002F\u002Fgithub.com\u002Fvikasvardhanv\u002Fjerry_skills\u002Fblob\u002Fmain\u002Fskills\u002Fresearch\u002Fgrants\u002Fskills\u002Fgrants\u002FSKILL.md",[],[]]