{"id":30581461,"url":"https://github.com/t1erno/bin2shellcode","last_synced_at":"2025-08-29T06:29:14.438Z","repository":{"id":304545091,"uuid":"1019105325","full_name":"T1erno/bin2shellcode","owner":"T1erno","description":"C++ tool and library for converting .bin files to shellcode in multiple output formats.","archived":false,"fork":false,"pushed_at":"2025-08-18T02:55:18.000Z","size":24,"stargazers_count":30,"open_issues_count":0,"forks_count":10,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-08-18T04:25:04.658Z","etag":null,"topics":["bin2shellcode","cpp","hacking","redteam","shellcode","shellcode-injection"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/T1erno.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-07-13T18:42:06.000Z","updated_at":"2025-08-18T02:55:08.000Z","dependencies_parsed_at":"2025-07-13T20:42:12.620Z","dependency_job_id":"2cda0790-0f8d-486f-8cb7-77914a65b652","html_url":"https://github.com/T1erno/bin2shellcode","commit_stats":null,"previous_names":["t1erno/bin2shellcode"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/T1erno/bin2shellcode","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/T1erno%2Fbin2shellcode","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/T1erno%2Fbin2shellcode/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/T1erno%2Fbin2shellcode/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/T1erno%2Fbin2shellcode/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/T1erno","download_url":"https://codeload.github.com/T1erno/bin2shellcode/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/T1erno%2Fbin2shellcode/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":272641813,"owners_count":24968807,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-29T02:00:10.610Z","response_time":87,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bin2shellcode","cpp","hacking","redteam","shellcode","shellcode-injection"],"created_at":"2025-08-29T06:29:13.197Z","updated_at":"2025-08-29T06:29:14.423Z","avatar_url":"https://github.com/T1erno.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# bin2shellcode\n\nSimple tool for converting .bin files into different shellcode formats.\nThe conversion logic is available as a static library so it can be reused for other projects.\n\n```\nbin2shellcode 1.0.0\n=======================\n\nUsage:\n  bin2shellcode --input \u003cpath\u003e --format \u003cn\u003e [--varname \u003cname\u003e]\n  bin2shellcode \u003cpath\u003e \u003cn\u003e [\u003cname\u003e]\n\nOptions:\n  -i, --input \u003cpath\u003e      Path to the .bin to convert (required)\n  -f, --format \u003cn\u003e        Output format (1-11) (required)\n  -n, --varname \u003cname\u003e    Name of the output variable (default: shellcode)\n  -h, --help              Show this help and exit\n  -v, --version           Show version and exit\n\nFormats:\n  #   Description\n  -------------------------------------------------------\n  1   Raw hex bytes                   (fc 48 81 ...)\n  2   Base64 string                   (SGVsbG8uLi4=)\n  3   C                               (unsigned char shellcode[] = \"\\x90\\x90...\")\n  4   Ruby                            (unsigned char buf[] = \"\\x90\\x90...\")\n  5   Python                          (shellcode = b\"\\x90\\x90...\")\n  6   PowerShell                      ([Byte[]] $shellcode = 0x90,0x90,...)\n  7   C#                              (byte[] shellcode = { 0x90, 0x90, ... })\n  8   Hex string                      (9090...)\n  9   UUID list                       (fc4881e4-f0ff-ffff-...)\n  10  Go                              ([]byte{0x90, 0x90, ...})\n  11  Rust                            (let shellcode: \u0026[u8] = \u0026[0x90, 0x90, ...];)\n\nExamples:\n  Convert \"payload.bin\" to a C byte array:\n      bin2shellcode -i payload.bin -f 1\n```\n\n## Linux dependencies\n\n`cmake` and a C++ compiler (GCC or Clang) are required. On Debian based\nsystems they can be installed with:\n\n```bash\nsudo apt install build-essential cmake\n```\n\nOn Arch Linux install the required packages with:\n\n```bash\nsudo pacman -S base-devel cmake\n```\n\n## Building on Linux\n\n```bash\nmkdir build -p \u0026\u0026 cd build\ncmake .. -DCMAKE_BUILD_TYPE=Release\ncmake --build .\n```\n\n### Create a `.deb` package\n\n```bash\ncmake --build . --target package\n```\n\n## Installing on Linux (Admin required)\n\nFrom the *build* directory run:\n\n```bash\nsudo cmake --install .\n```\n\nThis copies the binary and library to `/usr/local` by default.\nRemember to run this command as administrator in order to install the programs.\n\n## Windows dependencies\n\nInstall the required tools with [Scoop](https://scoop.sh) (Recomended): \n\n```powershell\nscoop install llvm cmake ninja\n```\n\n## Building on Windows\n\n```powershell\nmkdir build -Force ; cd build\ncmake -S .. -G Ninja -DCMAKE_CXX_COMPILER=\"clang++.exe\" -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=\"C:/Program Files/bin2shellcode\"\ncmake --build .\n```\n\n## Installing on Windows (Admin required)\n\nRun the installation from an elevated PowerShell prompt:\n\n```powershell\ncmake --install . --prefix \"C:/Program Files/bin2shellcode\"\n```\n\nThe executable is copied to `C:\\Program Files\\bin2shellcode\\bin`\ntogether with `libbin2shellcode.lib`. To permanently add the folder to the `PATH`\nyou can run:\n\n```powershell\nsetx PATH \"$Env:PATH;C:\\Program Files\\bin2shellcode\\bin\"\n```\n\n## Running the tests\n\nTo compile and run the tests from *build* use `CTest`.\nMake sure to configure the project in **Debug** mode so the `assert`\nstatements in the test program are executed:\n\n```bash\ncmake .. -DCMAKE_BUILD_TYPE=Debug\ncmake --build .\ncmake --build . --target test\nctest --output-on-failure\n```\n\n## Uninstall (Admin required)\n\n```bash\ncmake --build . --target uninstall\n```\n\n## Cleanup\n\n```bash\ncmake --build . --target clean-build\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ft1erno%2Fbin2shellcode","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ft1erno%2Fbin2shellcode","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ft1erno%2Fbin2shellcode/lists"}