DD yotta-secret
元钥 —— 跨智能体的密钥 / 凭据泄露源头扫描技能:零依赖自研用「正则 + 熵 + 格式校验」离线扫描源码 / 配置 / .env / git 历史中的疑似密钥与凭据(云厂商 API Key、私钥、口令赋值、URL 内嵌凭据、高熵长 token),输出 text / JSON / CSV,默认打码防二次泄露。触发:用户要排查代码 / 配置 / 仓库里是否泄露了 API Key、密码、私钥、token,要在提交或发布前做密钥检查,或要校验某个字符串是否为已知格式的密钥时。边界:纯本地离线扫描,不联网验证密钥是否有效、不发送任何数据;结果只是「疑似密钥」,是否真实需人工核实;仅用于已获授权 / 自有资产 / 教学环境。
元钥 —— 跨智能体的密钥 / 凭据泄露源头扫描技能:零依赖自研用「正则 + 熵 + 格式校验」离线扫描源码 / 配置 / .env / git 历史中的疑似密钥与凭据(云厂商 API Key、私钥、口令赋值、URL 内嵌凭据、高熵长 token),输出 text / JSON /…
As a process D 45/100 · Unfinished process — weak spots: result and completion, when it triggers, inputs and preconditions
What is at stake
The skill contains fragments that, in the wrong hands, cost money or data. Below: what the installer risks and what the author should do.
The files contain someone else's key or token. If it is live, your agent will call third-party services under a stranger's identity; if it was revoked, the skill's scripts simply fail. Such a key often arrives with the author's whole workspace, personal data included.
The key is visible to everyone who downloaded the skill and has likely been copied by catalog-scanning bots already. Revoke it now, check bills and access logs, then reissue.
How to improve
- Address the high-severity findings: each costs 18 safety points. If one is a false positive, add the rule id to guard.allow in spec.yaml.
- Say in the description WHEN to use the skill ("use when…", example requests): that is the agent's main cue.
- Your own cases (evals/evals.json, 4–6 real requests with expected answers): the full check would then run those instead of a model-drafted suite.
- A spec.yaml with trigger phrases and assertions — a behaviour contract for CI; `skilltest init` writes a template.
Guard findings · 34
-
high Secrets in code
secret-private-keyreferences/rules.md:53Private key material (key header without key body)| pgp_private | PGP 私钥块 | -----BEGIN PGP PRIVATE KEY BLOCK----- … -----END PGP PRIVATE KEY BLOCK----- |
header only
Medium and low: 33
-
medium Secrets in code
secret-private-keyREADME.md:147Private key material (detector / deny-list definition; key header without key body; documentation table row)| private_key | 私钥 | `-----BEGIN PRIVATE KEY----- …
detectorheader onlytable -
medium Secrets in code
secret-private-keyREADME.zh-CN.md:148Private key material (key header without key body; documentation table row)| private_key | 私钥 | `-----BEGIN PRIVATE KEY----- …
header onlytable -
medium Secrets in code
secret-private-keyscripts/test_yotta_secret.py:204Private key material (key header without key body; test fixture / example file; quoted — discussed, not commanded)"-----BEGIN PRIVATE KEY----- …
header onlyfixturequoted -
medium Secrets in code
secret-private-keyscripts/test_yotta_secret.py:209Private key material (key header without key body; test fixture / example file; quoted — discussed, not commanded)"-----BEGIN PRIVATE KEY----- …
header onlyfixturequoted -
medium Secrets in code
secret-private-keyscripts/test_yotta_secret.py:214Private key material (key header without key body; test fixture / example file; quoted — discussed, not commanded)"-----BEGIN PGP PRIVATE KEY BLOCK-----\n"
header onlyfixturequoted -
medium Secrets in code
secret-private-keyscripts/test_yotta_secret.py:500Private key material (key header without key body; test fixture / example file; quoted — discussed, not commanded)pem = "-----BEGIN PRIVATE KEY----- …\n"
header onlyfixturequoted -
medium Secrets in code
secret-private-keyscripts/yotta_secret.py:227Private key material (detector / deny-list definition; key header without key body)r"-----BEGIN PGP PRIVATE KEY BLOCK-----.*?-----END PGP PRIVATE KEY BLOCK-----",
detectorheader only -
medium Secrets in code
secret-private-keySKILL.md:88Private key material (key header without key body; documentation table row)| private_key | 私钥 | `-----BEGIN PRIVATE KEY----- …
header onlytable -
low Secrets in code
secret-github-tokenscripts/test_yotta_secret.py:79GitHub token (placeholder value)"ghp_…890", "p@ssW0rd2024",
placeholder -
low Secrets in code
secret-github-tokenscripts/test_yotta_secret.py:90GitHub token (placeholder value)v = "ghp_…890"
placeholder -
low Secrets in code
secret-aws-keyscripts/test_yotta_secret.py:100AWS access key ID (placeholder value)self.assertIn("aws_access_key", rule_ids("AKIA…PLE"))placeholder -
low Secrets in code
secret-high-entropy-tokenscripts/test_yotta_secret.py:110High-entropy token-like string (may be an id, hash or a credential) (placeholder value)self.assertIn("google_api", rule_ids("AIza…tuv"))placeholder -
low Secrets in code
secret-google-keyscripts/test_yotta_secret.py:110Google API key (placeholder value)self.assertIn("google_api", rule_ids("AIza…tuv"))placeholder -
low Secrets in code
secret-anthropic-keyscripts/test_yotta_secret.py:118Anthropic API key (placeholder value)ids = rule_ids("sk-a…789")placeholder -
low Secrets in code
secret-slack-tokenscripts/test_yotta_secret.py:127Slack token (placeholder value)self.assertIn("slack", rule_ids("xoxb…nop"))placeholder -
low Secrets in code
secret-slack-tokenscripts/test_yotta_secret.py:128Slack token (placeholder value)self.assertIn("slack", rule_ids("xoxp…bcd"))placeholder -
low Secrets in code
secret-github-tokenscripts/test_yotta_secret.py:131GitHub token (placeholder value)self.assertIn("github", rule_ids("ghp_…890"))placeholder -
low Secrets in code
secret-github-tokenscripts/test_yotta_secret.py:132GitHub token (placeholder value)self.assertIn("github", rule_ids("gith…890"))placeholder -
low Secrets in code
secret-high-entropy-tokenscripts/test_yotta_secret.py:152High-entropy token-like string (may be an id, hash or a credential) (test fixture / example file; quoted — discussed, not commanded)"SflK…w5c")
fixturequoted -
low Secrets in code
secret-high-entropy-tokenscripts/test_yotta_secret.py:173High-entropy token-like string (may be an id, hash or a credential) (detector / deny-list definition; test fixture / example file)self.assertIn("twilio", rule_ids("SK01…def"))detectorfixture -
low Secrets in code
secret-password-literalscripts/test_yotta_secret.py:247Hard-coded password / key literal (may be an example) (detector / deny-list definition; test fixture / example file)self.assertIn("credential", rule_ids("password = Sup3rS3cret!123"))detectorfixture -
low Secrets in code
secret-password-literalscripts/test_yotta_secret.py:256Hard-coded password / key literal (may be an example) (detector / deny-list definition; test fixture / example file)self.assertIn("credential", rule_ids(" client_secret: 'S0me…lue!!'"))detectorfixture -
low Secrets in code
secret-high-entropy-tokenscripts/test_yotta_secret.py:299High-entropy token-like string (may be an id, hash or a credential) (test fixture / example file; quoted — discussed, not commanded)v = "Xj8m…0Mn"
fixturequoted -
low Secrets in code
secret-labelled-tokenscripts/test_yotta_secret.py:330Labelled token / key literal (vendor format unknown — verify it is not a live credential) (test fixture / example file; quoted — discussed, not commanded)line = "https://example.com/api?api_key=…"
fixturequoted -
low Secrets in code
secret-password-literalscripts/test_yotta_secret.py:330Hard-coded password / key literal (may be an example) (test fixture / example file; quoted — discussed, not commanded)line = "https://example.com/api?api_key=…"
fixturequoted -
low Secrets in code
secret-labelled-tokenscripts/test_yotta_secret.py:338Labelled token / key literal (vendor format unknown — verify it is not a live credential) (placeholder value)line = "api_key = AIza…tuv"
placeholder -
low Secrets in code
secret-high-entropy-tokenscripts/test_yotta_secret.py:338High-entropy token-like string (may be an id, hash or a credential) (placeholder value)line = "api_key = AIza…tuv"
placeholder -
low Secrets in code
secret-google-keyscripts/test_yotta_secret.py:338Google API key (placeholder value)line = "api_key = AIza…tuv"
placeholder -
low Secrets in code
secret-password-literalscripts/test_yotta_secret.py:338Hard-coded password / key literal (may be an example) (placeholder value)line = "api_key = AIza…tuv"
placeholder -
low Secrets in code
secret-aws-keyscripts/test_yotta_secret.py:344AWS access key ID (placeholder value)line = "a=AKIA…PLE b=ghp_…890"
placeholder -
low Secrets in code
secret-github-tokenscripts/test_yotta_secret.py:344GitHub token (placeholder value)line = "a=AKIA…PLE b=ghp_…890"
placeholder -
low Secrets in code
secret-aws-keyscripts/test_yotta_secret.py:398AWS access key ID (placeholder value)self.write("key.txt", "AKIA…PLE\n")placeholder -
low Secrets in code
secret-password-literalscripts/test_yotta_secret.py:422Hard-coded password / key literal (may be an example) (detector / deny-list definition; test fixture / example file)stdin="password = Sup3rS3cret!123\n")
detectorfixture
Files scanned: 15. Evidence is masked. Grey chips explain why severity was lowered.
Against the Agent Skills spec
- warning
description-no-whendescription does not say WHEN to use the skill (no "use when")
Process rating: all ten parameters 45/100
- 0Result and completion. Does not say what the result is
- 0Inputs and preconditions. Does not say what the process needs to start
- 0Failures and branches. Linear process with no failure handling
- 20When it triggers. No condition that starts the skill
- 30Running it twice. 3 mutating operations with no state check
- 60Tools and files. Uses tools (python) that frontmatter does not declare
- 100Steps. 29 steps
- 100Consistency. Name and required fields are in place
- 100Execution cost. Instruction body is 966 tokens
- 100Progress reporting. Reports progress
- low 10 top-level sections: this looks like several domains in one skill
Everything here is measured from the skill text rather than judged by a model, so the numbers are checkable. A parameter weighs more when it is a more common reason for the process to stall.
Quality signals
- +5Description has no quoted example phrases that should trigger the skill
- +4Description does not say when NOT to use the skill (false activations)
- +3Output format is not stated: the model decides each time
- -31 of 2 scripts are never mentioned in SKILL.md
- +2Single-language instructions
- +3Description length 312: enough signal without eating the budget
- +4Structure: 11 headings
- +3Step-by-step instructions: 29 items
- +4Has examples (1 code blocks)
- +4Reference files are cited in the instructions (4 of 4)
- +1License stated
Quality base 70; lint remarks subtract, signals add up to 100. Result: 74.