Skip to content

dimasma0305/Go-Embed-Extractor

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 

Repository files navigation

Go-Embed-Extractor

This repository contains a Python script to extract files embedded in Go binaries using the embed package.

Usage

You can use the extract_embed.py script to extract embedded files from a Go binary.

Prerequisites

  • Python 3
  • pyelftools library

You can install the required library using pip:

pip install pyelftools

Running the Script

Run the script by providing the path to the Go binary as an argument:

python3 extract_embed.py <binary_path> [optional_hex_addr]
  • <binary_path>: Path to the compiled Go binary.
  • [optional_hex_addr]: (Optional) The virtual address of the embed.FS variable. If not provided, the script attempts to auto-detect it.

Example

python3 extract_embed.py ./my_go_app

The extracted files will be saved in the extracted_embed directory.

About

Exxtract golang embeded file from golang binary

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages