lintsinghua / lintsinghua/DeepAudit

感谢佬开源。感觉文件后缀名提取这些可以写个公共配置

Open
#102 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
7k
Forks
850
PR merge metrics
No merged PRs in 30d

Description

今天运行了一下前端项目(vue),发现很多分析出来的风险死活拿不到行号和file_path,看了下代码发现现在还是挺多硬编码文件后缀名的,比如
any(potential_file.endswith(ext) for ext in ['.py', '.js', '.ts', '.java', '.go', '.php', '.rb', '.c', '.cpp', '.h'])):

TEXT_EXTENSIONS = [
".js", ".ts", ".tsx", ".jsx", ".py", ".java", ".go", ".rs",
".cpp", ".c", ".h", ".cc", ".hh", ".cs", ".php", ".rb",
".kt", ".swift", ".sql", ".sh", ".json", ".yml", ".yaml"
]

r'.*auth.*\.(py|js|ts|tsx|jsx|java|php|swift|m|mm|kt|rs|go)$',

不过感觉这情况也不是很多哈哈哈,以框架命名后缀名的好像就只有包含vue的寥寥几个

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No file or test is named. Search the codebase for the hard-coded endswith list, TEXT_EXTENSIONS, and the auth filename regex, then trace where they determine line numbers and file paths. Consolidate the extension sources into one shared configuration and rerun the frontend analysis described in the issue to confirm those results are populated.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, python
Domain
devtools, security
Issue type
Refactor
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.