Show HN: RustAegis – Writing a VM-based obfuscator without using 'unsafe'

github.com

2 points by kunzz 8 hours ago

I wanted to see if I could build a robust obfuscation engine and virtual machine in Rust without resorting to unsafe code. RustAegis is the result.

It protects functions by compiling them into custom bytecode, encrypting them via AES-GCM, and running them on an embedded VM. To make analysis harder, it uses randomized opcode tables (changing every build) and MBA transformations.

While it targets anti-tamper and anti-reversing use cases, it was also a deep dive into writing interpreters in safe Rust.

https://github.com/onurkun/RustAegis

Feedback welcome!