1

我需要用 afl-fuzz 编译 openssl 1.0.1f 版本,然后在应用程序中使用它来查找 heartbleed bug。到目前为止我已经做到了;转到 openssl1.0.1f 目录并运行以下命令

./config CC="afl-gcc" CXX="afl-g++"
./config no-shared no-idea no-mdc2 no-rc5 no-comp enable-tlsext no-ssl2
 make depend
 make && make install

一切正常,但是在编译过程中,我看到的gcc -I是编译文件的命令,而不是afl-gcc最后看到的 Instrumentation 详细信息,因为我在使用 afl-fuzz 编译的简单程序中看到了它。我不确定 openssl 是用 gcc 还是 afl-gcc 编译的。我也gccafl-gccMakefile 替换了,但没有结果。

有人可以解释一下所有关于 openssl 和 afl-fuzz 的博客吗,我只找到了这些命令。

谢谢。

4

1 回答 1

1

在手动更改 Makefile 后,我犯了一个简单的错误,即调用 ./configure。每个 ./configure 命令都会覆盖以前的 Makefile。所以我的步骤应该按照以下顺序。

./config no-shared no-idea no-mdc2 no-rc5 no-comp enable-tlsext no-ssl2
make depend
Manually replace every occurrence of `gcc`to `afl-gcc` in Makefile 
make && make install

谢谢。

于 2018-12-28T10:17:25.337 回答