Search code examples
cobfuscationllvm-clang

o-llvm (based on llvm3.4) emit obfuscated code


I'm learning how to use o-llvm based on llvm 3.4.

I have a really simple c file, named "Example.c" that I'm obfuscating and compiling.

clang -mllvm -sub Example.c 

Is there a way to emit the obfuscated code as a .c file??


Solution

  • LLVM Obfuscation happens after the C code has been transformed to LLVM IR. There is not really a good way to convert IR directly back into C code either. You can have o-llvm output the obfuscated code as IR though by using the command line arguments

    -S -emit-llvm