基于 SOC 职业分类
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
直接命令不会经过审查 Prompt;运行前请先检查来源。
npx skills add https://github.com/cxcscmu/SkillLearnBench --skill csv-reporting命令会保持在同一行。复制前请横向滚动并检查完整内容。
想先保存到本地?可下载 SkillsMP 当前能够提供的文件。
正在显示 SKILL.md
Handles reading, populating, and saving .docx files using the python-docx library. Use this skill for any tasks involving template filling or modifying Word documents.
Perform various data analysis on SEC 13-F and obtain some insights of fund activities such as number of holdings, AUM, and change of holdings between two quarters.
This skill includes search capability in 13F, such as fuzzy search a fund information using possibly inaccurate name, or fuzzy search a stock cusip info using its name.
| name | csv-reporting |
| description | Output vulnerability reports as a formatted CSV file. |
After parsing a vulnerability JSON report from a tool like Trivy, it is common to output the extracted findings to a CSV file for security audits or compliance checks.
This Python code snippet demonstrates how to export vulnerabilities to a CSV file according to a defined schema, such as: Package,Version,CVE_ID,Severity,CVSS_Score,Fixed_Version,Title,Url.
import csv
import json
def generate_csv(json_path, csv_path):
with open(json_path, 'r', encoding='utf-8') as f:
trivy_report = json.load(f)
# Required CSV fields
fieldnames = ['Package', 'Version', 'CVE_ID', 'Severity', 'CVSS_Score', 'Fixed_Version', 'Title', 'Url']
with open(csv_path, 'w', newline='', encoding='utf-8') as f:
writer = csv.DictWriter(f, fieldnames=fieldnames)
writer.writeheader()
for result in trivy_report.get('Results', []):
for vuln in result.get('Vulnerabilities', []):
# Only include HIGH and CRITICAL severities
severity = vuln.get('Severity', '')
if severity not in ['HIGH', 'CRITICAL']:
continue
# Prepare the row
row = {
'Package': vuln.get('PkgName', ''),
'Version': vuln.get('InstalledVersion', ''),
'CVE_ID': vuln.get('VulnerabilityID', ''),
'Severity': severity,
'CVSS_Score': extract_cvss(vuln),
'Fixed_Version': vuln.get('FixedVersion', 'N/A'),
'Title': vuln.get('Title', vuln.get('Description', '')).replace('\n', ' ').strip()[:100],
'Url': vuln.get('PrimaryURL', '')
}
writer.writerow(row)
# The extract_cvss function would be defined elsewhere or imported
This ensures properly-formatted tabular reports. Note how it limits the output strictly to HIGH and CRITICAL vulnerabilities.