KLEE
💎Vulnerabiltiies to be discovered
The next vulnerabilities should be discovered in this sections:
VULN-RECOVERY-OOB
⚙️AFL++ setup
If you didn't set up the
Use
dynamic-analysis profile's infrastructure, please do so by running the command docker-compose --profile dynamic-analysis up.Use
docker exec --interactive --tty klee bash to enter the container where the CLI application is contained.📚KLEE documentation
The KLEE documentation is available here.
Steps
Obtaining the LLVM bytecode
- At the moment, the files from
sandcastle/c_modulesare used to compile a shared object usingMakefile. Copy the folder with C sources in/root/analysis/klee/c_modulesand modifytest.cto callgenerate_recovery_tokenwith two variables, which are both marked as symbolic variables (with theklee_make_symbolicmethod) - Use
clangto generate the LLVM bytecode.
🚧Solution
To display the solution of this task, enter the text i-surrender-to-the-code-security-gods in the field below.
Symbolically executing the LLVM bytecode
- Use
kleeto run the generated file with the LLVM bytecode
🚧Solution
To display the solution of this task, enter the text i-surrender-to-the-code-security-gods in the field below.
Validating the test cases
- Compile again the program using the
-lkleeRuntestflag. - For each test case, run the program and check if it is crashing.
- Inspect the associated
test<n>.<type>.errfile to see where in the program the problem appears.
🚧Solution
To display the solution of this task, enter the text i-surrender-to-the-code-security-gods in the field below.