Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/secnnet/shellcode-generator
https://github.com/secnnet/shellcode-generator
binary-files c code-injection csharp cybersecurity hacking programming python security-testing shellcode shellcode-generator software-exploitation
Last synced: 12 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/secnnet/shellcode-generator
- Owner: secnnet
- License: mit
- Created: 2023-06-18T16:52:59.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2023-06-18T17:01:21.000Z (over 1 year ago)
- Last Synced: 2024-12-07T04:41:15.684Z (2 months ago)
- Topics: binary-files, c, code-injection, csharp, cybersecurity, hacking, programming, python, security-testing, shellcode, shellcode-generator, software-exploitation
- Language: Python
- Homepage:
- Size: 5.86 KB
- Stars: 3
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Shellcode Generator
This is a Python script that generates shellcode in C and C# programming languages from a binary file. Shellcode is commonly used in software exploitation and security testing for tasks such as code injection and payload execution.
## Features
- Generates C shellcode: The script reads a binary file and converts each byte into its hexadecimal representation, producing C shellcode as output.
- Generates C# shellcode: Similar to the C shellcode, the script generates C# shellcode by prefixing each byte with "0x" and separating them with commas.
- Customizable output format: The C shellcode can be split into multiple lines if a maximum length is reached. The script provides flexibility in adjusting the maximum length.
## Usage
1. Make sure you have Python installed on your system.
2. Clone the repository:
`git clone https://github.com/your-username/shellcode-generator.git`
3. Navigate to the project directory:
`cd shellcode-generator`
4. Run the script with the following command:
`python shellcode_generator.py `
- ``: The name of the binary file you want to generate shellcode from.
- ``: Specify the output language as either "c" for C shellcode or "cs" for C# shellcode.5. The generated shellcode will be displayed in the console.
## Examples
To generate C shellcode from a binary file named "payload.bin", run the following command:
`python shellcode_generator.py payload.bin c`
To generate C# shellcode from the same file, use:
`python shellcode_generator.py payload.bin cs`
## License
This project is licensed under the [MIT License](LICENSE).