Borrowing it
Nothing to install: this file belongs to dslsdzc/rev-skills. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/dslsdzc/rev-skills/main/.claude/skills/re-whitebox/SKILL.mdgit clone --depth 1 https://github.com/dslsdzc/rev-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/dslsdzc/rev-skills/re-whitebox)<a href="https://agentmods.dev/skills/dslsdzc/rev-skills/re-whitebox"><img src="https://agentmods.dev/badge/skills/dslsdzc/rev-skills/re-whitebox/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/dslsdzc/rev-skills/re-whitebox"><img src="https://agentmods.dev/badge/skills/dslsdzc/rev-skills/re-whitebox.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector pass
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.00041 | $0.03140 |
| Opus 5 | $0.00020 | $0.01570 |
| Sonnet 5 | $0.00008 | $0.00628 |
| Haiku 4.5 | $0.00004 | $0.00314 |
Grade A, and why
re-whitebox 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 today.
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 — 113 lines — stays where its author put it; the contents beside it link to each section on GitHub.
白盒加密分析
何时使用 / 何时不用
- 用:加密实现"看不到密钥"——无标准库 API、密钥不在文件/内存/资源里显式存在(密钥被藏进实现本身)
- 用:反编译看到大段只读查找表(几百 KB 起)+ 函数体几乎全是查表逻辑,没有标准算法结构(无 Crypt* 调用、无标准 S-box 常量、无 OpenSSL 符号)
- 用:DRM/许可证/App 内加密、固件授权校验里怀疑白盒实现(Chow 类白盒 AES、白盒 SM4 等)
- 不用:普通加密实现(走 [[re-crypto-id]] → [[re-crypto-keys]] → [[re-crypto-decrypt]] 常规链路)
- 不用:算法与密钥都已知(直接解密)
- 前置检查:加壳/混淆样本先脱壳去混淆([[re-anti-analysis]]),白盒表与代码被壳层污染时无法分析
工具准备
静态为主(免沙箱);涉及"表加密运行时解密"时需动态取表(默认沙箱,[[re-analyze/platform-tips]] 最高原则)。所有工具先验证再使用。
python3 —— 表提取与密钥推导脚本
- 安装与验证见 [[re-proto-rev]] 工具准备(python3);大表处理建议 numpy(
pip install numpy)
反编译器 —— 定位查表代码与表地址
- [[re-ghidra]](默认,导入→自动分析→反编译);[[re-ida]] / [[re-radare2]] 按
RE_DECOMPILER会话变量 - 验证见对应技能工具准备;表地址/大小以反编译工具的 Data 视图为准
[[re-angr]] —— 可选(符号执行辅助索引关系求解)
- 全平台:
pip install angr - 验证:
python3 -c "import angr; print(angr.__version__)" - 用途: 查表代码被混淆/索引关系复杂时,符号执行直接求"输入字节 → 表项"的对应关系
[[re-memdump]] —— 表加密(运行时解密)时动态取表
- 默认转储优先(gcore,见 [[re-analyze/platform-tips]]「直读 vs 转储」决策表)
- 验证见 [[re-memdump]] 工具准备
操作步骤
按顺序执行,每步产物(表文件/脚本/恢复密钥)存档 sha256 + 路径,供报告引用([[re-ioc]])。
-
白盒实现识别(查找表特征、无标准库调用的大段查表代码):
# 静态侧: 找 .rodata/.data 里的查表候选——256 条 4/8 字节条目、连续、值分布均匀 objdump -h sample.bin | grep -E 'rodata|data' # 反编译确认: 函数体是否"state 异或常量 → 查表 → 组合"结构、有无 Crypt* / OpenSSL 符号- 特征清单: ① 大段只读表(白盒 AES 一轮 4 张 256×4 字节表,Chow 类编码后表集可达 700KB-1MB+)② 函数体以查表为主、无标准轮函数形态 ③ 无标准常量([[re-crypto-id]] 的 AES S-box/Rcon 指纹不命中)④ 无密码学 API 导入([[re-imports]] 干净)
- 反编译确认: 对表地址做 xref(Ghidra
Ctrl+Shift+F),看引用函数的形态——"查表 + 组合"而非"轮函数 + 常数表"即为白盒候选 - 与 [[re-crypto-id]] 的分工: 常规指纹命中 → 标准算法链路;指纹全不命中但有大表 → 白盒假设(见坑 4)
-
表提取:
- Ghidra: 选中表数据段右键 Export(或脚本
getBytes整段 dump);IDA:ida_bytes.get_bytes(start, size)导出 - 解析脚本(按条目宽度/字节序):
import struct data = open('tables.bin','rb').read() for off in range(0, len(data), 4): # 4 字节条目(AES T 表): 每条 [S(x)<<24 | ...] v = struct.unpack_from('<I', data, off)[0] # 记录值分布/每字节位模式,输出供步骤 3 分析 - 记录: 每张表地址、尺寸、条目宽度、被哪些函数引用——表↔函数↔轮数的对应关系是密钥恢复的地图
- Ghidra: 选中表数据段右键 Export(或脚本
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.
- today Changed · +1 lines d6329c22cdef
- 9d ago First seen · 112 lines · 41 tokens per session scan A 3012969adbfe
re-whitebox is a skill published in the GitHub repository dslsdzc/rev-skills (54 stars, last pushed today), licensed Apache-2.0. It adds 41 tokens to every session and 3,140 once invoked, about $0.0002 per session on Opus 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-09-03.
Other skills, from other repositories
analyzing-golang-malware-with-ghidra
Reverse engineer Go-compiled malware in Ghidra by parsing Go buildinfo and pclntab structures, recovering stripped/obfuscated function names (e.g. via GoResolver), and extracting embedded module/dependency strings and types from Go binaries. Use when analyzing a Go-language malware sample, deobfuscating a…
analyzing-golang-malware-with-ghidra
Reverse engineer Go-compiled malware in Ghidra by parsing Go buildinfo and pclntab structures, recovering stripped/obfuscated function names (e.g. via GoResolver), and extracting embedded module/dependency strings and types from Go binaries. Use when analyzing a Go-language malware sample, deobfuscating a…
Reverse Engineering & Binary Analysis
Binary analysis, assembly interpretation, disassembly, decompilation, firmware RE, and protocol reverse engineering.
analyzing-golang-malware-with-ghidra
Reverse engineer Go-compiled malware using Ghidra with specialized scripts for function recovery, string extraction, and type reconstruction in stripped Go binaries.
reverse-engineering-arm-binaries
Reverse engineers ARM/AArch64 malware by identifying the architecture and instruction set state (ARM/Thumb), parsing ELF/Mach-O ARM headers, and orienting analysis around the ARM calling convention. Activates for requests to reverse ARM binaries, analyze AArch64 malware, or handle ARM/Thumb instruction-set decoding.
reverse-engineering-binaries-with-ghidra
Uses Ghidra to disassemble and decompile a binary, navigate to key routines via imports and strings, annotate decompiled code, and run headless scripts to automate extraction of C2, crypto, and config. Activates for requests to reverse engineer with Ghidra, decompile a binary, or script Ghidra headless analysis.