Manus에서 모든 스킬 실행
원클릭으로
원클릭으로
원클릭으로 Manus에서 모든 스킬 실행
시작하기secure-code-review
스타5,009
포크812
업데이트2026년 1월 15일 14:00
安全代码审查的专业技能和方法论
설치
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SKILL.md
readonly메뉴
安全代码审查的专业技能和方法论
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SOC 직업 분류 기준
满配示例技能包:SKILL.md + scripts/、references/、assets/ 等可选目录;验证 Eino skill 与 HTTP 包内路径(仅授权安全测试与教学)。
API安全测试的专业技能和方法论
业务逻辑漏洞测试的专业技能和方法论
云安全审计的专业技能和方法论
命令注入漏洞测试的专业技能和方法论
容器安全测试的专业技能和方法论
| name | secure-code-review |
| description | 安全代码审查的专业技能和方法论 |
| version | 1.0.0 |
安全代码审查是识别代码中安全漏洞的重要方法。本技能提供安全代码审查的方法、工具和最佳实践。
检查项目:
检查项目:
检查项目:
检查项目:
使用SAST工具:
# SonarQube
sonar-scanner
# Checkmarx
# 使用Web界面
# Fortify
sourceanalyzer -b project build.sh
sourceanalyzer -b project -scan
# Semgrep
semgrep --config=auto .
审查清单:
危险函数:
# Python危险函数
eval()
exec()
pickle.loads()
os.system()
subprocess.call()
// Java危险函数
Runtime.exec()
ProcessBuilder()
Class.forName()
// PHP危险函数
eval()
exec()
system()
passthru()
危险代码:
String query = "SELECT * FROM users WHERE id = " + userId;
Statement stmt = connection.createStatement();
ResultSet rs = stmt.executeQuery(query);
安全代码:
String query = "SELECT * FROM users WHERE id = ?";
PreparedStatement stmt = connection.prepareStatement(query);
stmt.setInt(1, userId);
ResultSet rs = stmt.executeQuery();
危险代码:
document.innerHTML = userInput;
element.innerHTML = "<div>" + userInput + "</div>";
安全代码:
element.textContent = userInput;
element.setAttribute("data-value", userInput);
// 或使用编码库
element.innerHTML = escapeHtml(userInput);
危险代码:
import os
os.system("ping " + user_input)
安全代码:
import subprocess
subprocess.run(["ping", "-c", "1", validated_input])
危险代码:
String filePath = "/uploads/" + fileName;
File file = new File(filePath);
安全代码:
String basePath = "/uploads/";
String fileName = Paths.get(fileName).getFileName().toString();
String filePath = basePath + fileName;
File file = new File(filePath);
if (!file.getCanonicalPath().startsWith(basePath)) {
throw new SecurityException("Invalid path");
}
危险代码:
String apiKey = "1234567890abcdef";
String password = "admin123";
安全代码:
String apiKey = System.getenv("API_KEY");
String password = keyStore.getPassword("db_password");
# 启动SonarQube
docker run -d -p 9000:9000 sonarqube
# 运行扫描
sonar-scanner \
-Dsonar.projectKey=myproject \
-Dsonar.sources=. \
-Dsonar.host.url=http://localhost:9000
# 安装
pip install semgrep
# 运行扫描
semgrep --config=auto .
# 使用规则
semgrep --config=p/security-audit .
# 创建数据库
codeql database create database --language=java --source-root=.
# 运行查询
codeql database analyze database security-and-quality.qls --format=sarif-latest