zarn
Zarn
Zarn
现代Perl应用程序的轻量级静态代码安全分析
进行静态分析,ZARN能够识别可能的漏洞:为此,使用AST分析对每个文件进行解析以识别出存在风险并随后运行污点跟踪过程的令牌,以确认是否可以利用是否可以验证恶意代理是否能够针对问题中的方法。
当前,Zarn进行单个文件上下文分析,这意味着它无法识别与所分析的文件没有直接相关的漏洞。但是将来,我们计划实施呼叫图分析,以确定与要分析的文件无直接相关的漏洞。
您可以阅读有关Zarn的完整出版物:现代Perl应用程序的轻量级静态安全分析工具。
# Download
$ git clone https://github.com/htrgouvea/zarn && cd zarn
# Install libs dependencies
$ sudo cpanm --installdeps .$ perl zarn.pl --rules rules/quick-wins.yml --source ../nozaki --sarif report.sarif
[warn] - FILE:../nozaki/lib/Functions/Helper.pm Potential: Timing Attack.
[vuln] - FILE:../nozaki/lib/Engine/Orchestrator.pm Potential: Path Traversal.
[vuln] - FILE:../nozaki/lib/Engine/Orchestrator.pm Potential: Path Traversal.
[warn] - FILE:../nozaki/lib/Engine/FuzzerThread.pm Potential: Timing Attack. rules :
- id : ' 0001 '
category : info
name : Debug module enabled
message : Debug modules can expose sensitive information and potentially create security vulnerabilities.
sample :
- Dumper
- id : ' 0002 '
category : vuln
name : Code Injection
message : Occur when untrusted data is executed as code, allowing attackers to run arbitrary commands on the server.
sample :
- system
- eval
- exec
- qx
- id : ' 0003 '
category : vuln
name : Path Traversal
message : Occur when user input is not properly sanitized, allowing attackers to access files and directories outside of the intended directory structure.
sample :
- open name : ZARN SAST
on :
push :
branches : [ "main" ]
pull_request :
branches : [ "main" ]
schedule :
- cron : " 28 23 * * 1 "
jobs :
zarn :
name : Security Static Analysis with ZARN
runs-on : ubuntu-20.04
steps :
- name : Checkout code
uses : actions/checkout@v4
- name : Perform Static Analysis
uses : htrgouvea/[email protected]
- name : Send result to Github Security
uses : github/codeql-action/upload-sarif@v3
with :
sarif_file : result.sarif您的贡献和建议是衷心的♥欢迎。请参阅此处的贡献指南。请,通过问题页面报告错误,有关安全问题,请参阅此处的安全策略。 (✿✿)此项目遵循此样式指南:( https://github.com/htrgouvea/perl-style-guide)。
这项工作是根据MIT许可证获得许可的。