使用 conan audit 扫描依赖项¶
一个新命令 conan audit 已在 Conan 2.14 中添加。它提供了一种内置方式,可以扫描您的依赖项以查找已知的 CVE。
有关身份验证、使用示例、输出格式以及设置私有提供程序的逐步指南,请参阅 检查包漏洞。简而言之
在 audit.conan.io 注册。
通过您收到的确认电子邮件激活您的帐户。
保存您的令牌,该令牌在激活后会显示在页面上。
配置 Conan 以使用您的令牌:
conan audit provider auth conancenter --token=<token>
运行扫描
# Check a specific reference
conan audit list zlib/1.2.13
# Scan the entire dependency graph
conan audit scan . # Path to the conanfile.py/txt
此命令还支持使用您自己的 JFrog 平台作为漏洞扫描的私有提供程序。有关更多详细信息,请参阅 添加私有提供程序 部分。
另请参阅
有关所有
conan audit
子命令及其选项的详细参考文档,请查阅 conan audit 命令参考。阅读专门的博客文章以了解更多信息。