Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add jiushiwon/wg-skills --skill crypto-scenario-skillgit clone --depth 1 https://github.com/jiushiwon/wg-skillsWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/jiushiwon/wg-skills/crypto-scenario-skill)<a href="https://agentmods.dev/skills/jiushiwon/wg-skills/crypto-scenario-skill"><img src="https://agentmods.dev/badge/skills/jiushiwon/wg-skills/crypto-scenario-skill/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/jiushiwon/wg-skills/crypto-scenario-skill"><img src="https://agentmods.dev/badge/skills/jiushiwon/wg-skills/crypto-scenario-skill.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00174 | $0.01706 |
| Opus 5.5 | $0.00070 | $0.00682 |
| Sonnet 5.5 | $0.00035 | $0.00341 |
| Haiku 4.5 | $0.00017 | $0.00171 |
Grade A, and why
crypto-scenario-skill scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 20d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 72 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Crypto Scenario Skill
按场景而不是按算法名给结论。每个场景回答三件事:推荐什么、为什么、绝对不能用什么。
使用方式
- 先在下表定位场景 → 拿到推荐算法与禁止项。
- 按
references/code-snippets.md取对应语言的代码范式(Java / Python / Go / Node)。 - 细节(微信支付报文格式、bcrypt 盐机制、JWT 选型)按需读
references/下的专题文件。 - 让 AI 写这类代码时,把
references/ai-guardrails.md的约束块整段贴进 prompt。
场景决策表
| 场景 | 推荐 | 一句话理由 | 绝对禁止 |
|---|---|---|---|
| 用户密码存储 | Argon2id 优先,scrypt 备选,bcrypt 用于存量系统,PBKDF2-HMAC-SHA-256 用于需要 FIPS 合规的场景 | 按环境压测成本参数,使用成熟库与独立随机盐 | MD5 / SHA1 / SHA256 裸哈希、可逆加密、自研 |
| 微信支付回调验签 | RSA-SHA256(平台证书验签)+ 敏感字段 AEAD_AES_256_GCM | 官方强制算法,私钥不出商户 | 回调不验签、敏感字段不加密 |
| 支付宝开放平台签名 | RSA2(SHA256WithRSA) | 支付宝 2015 年定下的标准 | RSA(SHA1)老算法、MD5 |
| 对接第三方开放接口 | HmacSHA256(双方共享密钥) | 双方持有同一密钥即可验 | 把密钥写死在代码里 |
| Webhook 回调验签(自建) | Ed25519(非对称)或 HmacSHA256 | 公钥可分发,私钥不出服务器 | 回调不验签、先处理业务后验签 |
| JWT 登录态签名 | 单服务 HS256(密钥 ≥256 位);多服务互验 RS256 / EdDSA | 自签自发够用就别上非对称 | alg: none、短密钥、密钥进仓库 |
| 数据库敏感字段加密 | AES-256-GCM(应用层)+ 附加认证数据绑字段 | 拖库只见乱码,且防密文搬字段 | ECB 模式、密钥与库同库存放 |
| 文件完整性校验 | SHA-256 | 快、够用、标准化 | MD5、SHA1(已可构造碰撞) |
| Git 提交签名 | SSH(Ed25519,默认已启用)或 GPG | 证明"这笔提交是我发的" | 无 |
| 传输 | TLS 1.3 | 全站强制 | TLS 1.0/1.1、自签名证书上生产 |
连接凭证需要取回时
SSH、数据库密码和第三方 API Key 需要交给目标服务使用。配置仅存凭证引用,秘密放 OS 凭证库或服务端 Secret Manager。确需保存本地密文时使用平台安全存储,服务端自行加密时使用 AEAD 并分离密钥。限制读取权限和有效期,避免把明文放进日志、导出文件或通用 IPC 响应。
SuperShell 实例:Electron 主进程优先用 keytar。keytar 模块加载失败时,现有实现使用 safeStorage 加密本地文件。核查时应确认实际存储后端,Linux 的 basic_text 不应作为安全回退。安全后端不可用时拒绝持久化,或让用户本次输入。优先由主进程取用凭证完成连接,检查渲染进程能否通过 IPC 取回明文。
参考:Electron safeStorage https://www.electronjs.org/docs/latest/api/safe-storage 参考:OWASP 密码存储 https://cheatsheetseries.owasp.org/cheatsheets/Password_Storage_Cheat_Sheet.html
强制红线
- 不自己实现算法 —— 全部用成熟库(Java Bouncy Castle / Spring Security,Python
cryptography+passlib,Gogolang.org/x/crypto,Nodenode:crypto+bcrypt)。 - 密钥永不入库、不进仓库 —— 走环境变量或密钥管理服务,
.env必须 gitignore;启动时校验密钥长度,不达标直接失败退出。 - 用户登录密码只存密码哈希 —— 使用库验证输入,忘记密码走重置。历史哈希在验证成功后按策略升级,写回时防止覆盖并发改密。
- 哈希定长到的是"文件/报文没被改",密码要的是"慢" —— 两类哈希别混用。
- 回调先验签、后处理业务 —— 验签通过前不落库、不发货、不调下游。
- 签名比较用常量时间函数 ——
hmac.compare_digest/crypto.timingSafeEqual,不要用==。 - 日志必须脱敏 —— 密码、密钥、完整身份证/银行卡号一律 mask。
What ships with it
7 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 20d ago Changed · +9 lines 0dac4e4ba772
- 24d ago Changed · +1 lines · +174 tokens per session 89fe4ef5a898
- 1mo ago First seen · 62 lines · 0 tokens per session scan A 737b3dd3e465
crypto-scenario-skill is a skill published in the GitHub repository jiushiwon/wg-skills (154 stars, last pushed 7d ago), licensed Apache-2.0. It adds 174 tokens to every session and 1,706 once invoked, about $0.0007 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-10-24.
crypto-scenario-skill compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| crypto-scenario-skilljiushiwon/wg-skills | Skill | 154 | 7d ago | Apache-2.0 | A | 174 | Claude Code, Codex |
| imagegenopenai/codex | Skill | 137k | today | Apache-2.0 | A | 113 | Codex |
| playwright-climicrosoft/playwright | Skill | 101k | today | Apache-2.0 | A | 19 | Claude Code |
| browser-automationopenclaw/openclaw | Skill | 395k | today | MIT | A | 36 | Claude Code |
| systematic-debuggingobra/superpowers | Skill | 331k | 3d ago | MIT | A | 21 | Claude Code |
| free-llm-apismnfst/awesome-free-llm-apis | Skill | 15k | yesterday | CC0-1.0 | A | 113 | Claude Code, Codex |
| next-cache-components-adoptionvercel/next.js | Skill | 144k | today | MIT | A | 95 | Claude Code |