Skip to content
cccskills
FreePublished on GitHub

security-check

提交或推送前的安全检查,扫描 API Key、访问令牌等敏感信息。

The English summary is being prepared. Showing the original description.

See how to install

Files included (3)

  • SKILL.md1.6 KB
  • scripts/security_check.sh1.5 KB
  • scripts/security_reset.sh4.1 KB

SKILL.md (original)

Review the instructions the agent will receive before you install.

安全检查

在提交和推送代码前,必须检查是否包含敏感信息,特别是 API Keys 和访问令牌。

检查内容

API Keys 和访问令牌

  • sk- 开头的 API Keys(如 OpenAI、Anthropic、阿里云等)
  • AIzaSy 开头的 Google API Keys
  • pk_ 开头的公钥
  • 其他常见的 API 令牌格式

提交前(Commit)

先进行检查

bash skills/security-check/scripts/security_check.sh commit

若未输出 staging area is clear,说明暂存区存在敏感信息。

若存在敏感信息

  1. 立即删除或替换:将真实 API Key 替换为占位符
  2. 使用环境变量:将敏感信息移到环境变量中
  3. 添加到 .gitignore:确保包含敏感信息的文件不被提交
  4. 必须拒绝提交和推送动作

推送前(Push)

先进行检查

bash skills/security-check/scripts/security_check.sh push

若未输出 all commits are clear,说明存在敏感信息,相关 commit hash 已写入 task/sensitive_commits.txt。

若存在敏感信息

  1. 立即删除或替换:将真实 API Key 替换为占位符
  2. 使用环境变量:将敏感信息移到环境变量中
  3. 添加到 .gitignore:确保包含敏感信息的文件不被提交
  4. 必须使用下面的脚本清理历史记录
# 根据 task/sensitive_commits.txt 中的检查结果 reset,避免 commit 记录泄密
bash skills/security-check/scripts/security_reset.sh
  1. 必须拒绝提交和推送动作

Reviews

No reviews yet. Tell others what you thought.

Comments

No login needed. Share how it worked for you, ask a question, or note where it did not run.

No comments yet. Be the first to write one.

Comments are published right away. Do not include personal information such as email addresses or phone numbers. Up to 2 URLs.

0 / 1,000 characters

This form is protected by reCAPTCHA, and the Google Privacy Policy and Terms of Service apply.

More skills from this repository

在进行 Code Review 时,使用这个技能对 LoongCollector 变更进行安全导向、架构一致性优先的深度代码评审。

The English summary is being prepared. Showing the original description.

alibaba/loongcollector2.2KUpdated Oct 16, 2026

commit

Free

按 Conventional Commits 规范编写提交信息。在创建 git commit 时使用。

The English summary is being prepared. Showing the original description.

alibaba/loongcollector2.2KUpdated Oct 16, 2026

编译 LoongCollector C++ 与 Go 组件。涉及构建、单元测试或镜像时使用。

The English summary is being prepared. Showing the original description.

alibaba/loongcollector2.2KUpdated Oct 16, 2026

Design document writing conventions. Use when writing or reviewing technical design documents.

The English summary is being prepared. Showing the original description.

alibaba/loongcollector2.2KUpdated Oct 16, 2026

e2e

Free

LoongCollector E2E 测试全流程指南:设计、编写、运行和调试。当需要编写新 E2E 测试、运行现有测试、或排查 E2E 测试失败时使用此 skill。

The English summary is being prepared. Showing the original description.

alibaba/loongcollector2.2KUpdated Oct 16, 2026

LoongCollector E2E Testing Framework Development Guide. Use this rule when you need to understand E2E testing framework architecture, develop new test behavior functions, or extend testing capabilities. Contains detailed BDD testing framework usage, test behavior function development and registration workflows, and comprehensive reference of existing testing capabilities. Example: When adding custom test behaviors for new plugins, use this rule to understand how to write and register new test functions. Example: When developing E2E tests, use this rule to understand the e2e framework.

The English summary is being prepared. Showing the original description.

alibaba/loongcollector2.2KUpdated Oct 16, 2026

See all skills by alibaba

Report a problem with this skill