cpplumber
0.1.0 - Initial release

Cpplumber是一種靜態分析工具,可幫助檢測和跟踪C ++源代碼信息,這些信息洩漏到編譯後的可執行文件中。
該項目用鏽蝕書寫,取決於libclang,因此它是跨平台,可用於使用最新的C和C ++標準的項目。
想像一下,您有一個源文件file1.c ,您已將其編譯到a.out中,並且您想知道某些字符串字符的字體是否在a.out中結束,您可以簡單地做:
$ cpplumber --bin a.out file1.c
[2022-09-24T19:57:14Z INFO cpplumber] Gathering source files...
[2022-09-24T19:57:14Z INFO cpplumber] Filtering suppressed files...
[2022-09-24T19:57:14Z INFO cpplumber] Extracting artifacts from source files...
[2022-09-24T19:57:15Z INFO cpplumber] Filtering suppressed artifacts...
[2022-09-24T19:57:15Z INFO cpplumber] Looking for leaks in 'a.out'...
"My_Super_Secret_API_Key" (string literal) leaked at offset 0x14f20 in "/full/path/to/a.out" [declared at /full/path/to/file1.c:5]
Error: Leaks detected!
完整的用戶文檔可在此處提供(也可以作為Markdown)。
構建項目需要Rust版本1.63.0或更高。
git clone https://github.com/ergrelet/cpplumber.git
cd cpplumber
cargo build --release
如果您安裝了生鏽,則可以輕鬆安裝帶有cargo的CPPLUMBER:
cargo install --git https://github.com/ergrelet/cpplumber --tag 0.1.0
之後,您可以通過命令行從任何地方調用cpplumber 。
請記住,您需要安裝所需的依賴項,以使cpplumber正確運行。查看用戶文檔以獲取更多詳細信息。