opencode-skills-collection 4.0.42 → 4.0.44

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (297) hide show
  1. package/bundled-skills/.antigravity-install-manifest.json +49 -1
  2. package/bundled-skills/api-rate-limit-handler/SKILL.md +282 -0
  3. package/bundled-skills/api-security/SKILL.md +205 -0
  4. package/bundled-skills/api-security/references/jwt-oauth-testing.md +123 -0
  5. package/bundled-skills/api-security/references/rest-graphql-testing.md +137 -0
  6. package/bundled-skills/apk-reverse/SKILL.md +438 -0
  7. package/bundled-skills/apk-reverse/references/android-advanced.md +365 -0
  8. package/bundled-skills/apk-reverse/references/apk-security-checklist.md +230 -0
  9. package/bundled-skills/apk-reverse/references/frida-bypass-kit.md +70 -0
  10. package/bundled-skills/apk-reverse/references/frida-cookbook.md +472 -0
  11. package/bundled-skills/attack-chain/SKILL.md +185 -0
  12. package/bundled-skills/attack-chain/references/attack-playbooks.md +126 -0
  13. package/bundled-skills/attack-chain/references/evasion-cheatsheet.md +133 -0
  14. package/bundled-skills/attack-chain/references/lifecycle-checklist.md +37 -0
  15. package/bundled-skills/attack-chain/references/phases.md +490 -0
  16. package/bundled-skills/binary-diff/SKILL.md +320 -0
  17. package/bundled-skills/binary-diff/references/prompt-template.md +173 -0
  18. package/bundled-skills/browser-extension-reverse/SKILL.md +99 -0
  19. package/bundled-skills/browser-extension-reverse/references/extension-analysis.md +10 -0
  20. package/bundled-skills/case-review/SKILL.md +167 -0
  21. package/bundled-skills/cloud-k8s/SKILL.md +124 -0
  22. package/bundled-skills/cloud-k8s/references/k8s-cloud-checklist.md +16 -0
  23. package/bundled-skills/code-audit/SKILL.md +92 -0
  24. package/bundled-skills/code-audit/references/sast-review-checklist.md +10 -0
  25. package/bundled-skills/database-security/SKILL.md +81 -0
  26. package/bundled-skills/database-security/references/db-misconfig-checklist.md +9 -0
  27. package/bundled-skills/diagram-generator/SKILL.md +199 -0
  28. package/bundled-skills/diagram-generator/references/README.md +3 -0
  29. package/bundled-skills/diagram-generator/references/diagram-patterns.md +254 -0
  30. package/bundled-skills/digital-forensics/SKILL.md +93 -0
  31. package/bundled-skills/digital-forensics/references/forensics-triage.md +10 -0
  32. package/bundled-skills/docs/integrations/jetski-cortex.md +3 -3
  33. package/bundled-skills/docs/integrations/jetski-gemini-loader/README.md +1 -1
  34. package/bundled-skills/docs/maintainers/repo-growth-seo.md +1 -1
  35. package/bundled-skills/docs/maintainers/skills-update-guide.md +1 -1
  36. package/bundled-skills/docs/sources/sources.md +9 -0
  37. package/bundled-skills/docs/users/aas-core.md +1 -1
  38. package/bundled-skills/docs/users/bundles.md +1 -1
  39. package/bundled-skills/docs/users/claude-code-skills.md +1 -1
  40. package/bundled-skills/docs/users/gemini-cli-skills.md +1 -1
  41. package/bundled-skills/docs/users/kiro-integration.md +1 -1
  42. package/bundled-skills/docs/users/usage.md +3 -3
  43. package/bundled-skills/docs/users/visual-guide.md +4 -4
  44. package/bundled-skills/docs-generator/SKILL.md +197 -0
  45. package/bundled-skills/docs-generator/references/security-report-templates.md +348 -0
  46. package/bundled-skills/docs-generator/references/templates.md +102 -0
  47. package/bundled-skills/docs-generator/references/vendor-report-rules.md +263 -0
  48. package/bundled-skills/dotnet-reverse/SKILL.md +197 -0
  49. package/bundled-skills/dotnet-reverse/references/common-workflow.md +171 -0
  50. package/bundled-skills/dotnet-reverse/references/obfuscators.md +145 -0
  51. package/bundled-skills/dotnet-reverse/references/sharp-tools.md +164 -0
  52. package/bundled-skills/edr-bypass-re/SKILL.md +248 -0
  53. package/bundled-skills/edr-bypass-re/references/hook-survey.md +226 -0
  54. package/bundled-skills/edr-bypass-re/references/telemetry-blinding.md +346 -0
  55. package/bundled-skills/edr-bypass-re/references/unhook-techniques.md +338 -0
  56. package/bundled-skills/email-security/SKILL.md +81 -0
  57. package/bundled-skills/email-security/references/email-auth-checklist.md +8 -0
  58. package/bundled-skills/firmware-pentest/SKILL.md +381 -0
  59. package/bundled-skills/firmware-pentest/references/emba-automated-analysis.md +192 -0
  60. package/bundled-skills/firmware-pentest/references/emulation-and-fuzz.md +337 -0
  61. package/bundled-skills/firmware-pentest/references/extraction-methodology.md +285 -0
  62. package/bundled-skills/ghidra-reverse/SKILL.md +98 -0
  63. package/bundled-skills/ghidra-reverse/references/ghidra-cheatsheet.md +12 -0
  64. package/bundled-skills/go-rust-reverse/SKILL.md +82 -0
  65. package/bundled-skills/go-rust-reverse/references/go-rust-notes.md +5 -0
  66. package/bundled-skills/hardware-security/SKILL.md +80 -0
  67. package/bundled-skills/hardware-security/references/debug-interface-triage.md +7 -0
  68. package/bundled-skills/ida-reverse/SKILL.md +401 -0
  69. package/bundled-skills/ida-reverse/references/LOCAL-SETUP.md +66 -0
  70. package/bundled-skills/ida-reverse/references/ida-mcp-cheatsheet.md +515 -0
  71. package/bundled-skills/identity-federation/SKILL.md +81 -0
  72. package/bundled-skills/identity-federation/references/sso-flow-checklist.md +9 -0
  73. package/bundled-skills/instructree/SKILL.md +94 -0
  74. package/bundled-skills/js-reverse/SKILL.md +239 -0
  75. package/bundled-skills/js-reverse/references/ast-deobfuscation.md +3 -0
  76. package/bundled-skills/js-reverse/references/automation-entry.md +12 -0
  77. package/bundled-skills/js-reverse/references/env-patching.md +6 -0
  78. package/bundled-skills/js-reverse/references/fallbacks.md +8 -0
  79. package/bundled-skills/js-reverse/references/instrumentation.md +9 -0
  80. package/bundled-skills/js-reverse/references/local-rebuild.md +11 -0
  81. package/bundled-skills/js-reverse/references/mcp-task-template.md +30 -0
  82. package/bundled-skills/js-reverse/references/node-env-rebuild.md +9 -0
  83. package/bundled-skills/js-reverse/references/output-contract.md +9 -0
  84. package/bundled-skills/js-reverse/references/task-artifacts.md +11 -0
  85. package/bundled-skills/js-reverse/references/task-input-template.md +11 -0
  86. package/bundled-skills/js-reverse/references/tool-defaults.md +7 -0
  87. package/bundled-skills/llm-security/SKILL.md +160 -0
  88. package/bundled-skills/llm-security/references/agent-obedience-engineering.md +243 -0
  89. package/bundled-skills/llm-security/references/agent-security-testing.md +116 -0
  90. package/bundled-skills/llm-security/references/owasp-llm-top10.md +48 -0
  91. package/bundled-skills/llm-security/references/prompt-injection-methodology.md +107 -0
  92. package/bundled-skills/loki-mode/examples/todo-app-generated/backend/package-lock.json +4 -4
  93. package/bundled-skills/loki-mode/examples/todo-app-generated/backend/package.json +1 -1
  94. package/bundled-skills/lore/SKILL.md +104 -298
  95. package/bundled-skills/lore/references/audit-template.md +21 -4
  96. package/bundled-skills/lore/references/compatibility.md +51 -121
  97. package/bundled-skills/lore/references/config.md +22 -23
  98. package/bundled-skills/lore/references/entry-format.md +33 -3
  99. package/bundled-skills/lore/references/history-command.md +98 -2
  100. package/bundled-skills/lore/references/platform-mirrors.md +45 -16
  101. package/bundled-skills/lore/references/stale-new-markers.md +10 -8
  102. package/bundled-skills/lore/references/summary-template.md +8 -1
  103. package/bundled-skills/lore/references/workflows.md +192 -0
  104. package/bundled-skills/lore/scripts/README.md +14 -13
  105. package/bundled-skills/lore/scripts/README.zh-CN.md +14 -13
  106. package/bundled-skills/lore/scripts/find_duplicates.py +14 -4
  107. package/bundled-skills/lore/scripts/find_stale.py +68 -16
  108. package/bundled-skills/lore/scripts/history.py +235 -23
  109. package/bundled-skills/lore/scripts/id_hash.py +7 -4
  110. package/bundled-skills/lore/scripts/list_entries.py +82 -13
  111. package/bundled-skills/macos-reverse/SKILL.md +85 -0
  112. package/bundled-skills/macos-reverse/references/macho-triage.md +10 -0
  113. package/bundled-skills/malware-analysis/SKILL.md +311 -0
  114. package/bundled-skills/malware-analysis/references/anti-analysis-techniques.md +205 -0
  115. package/bundled-skills/malware-analysis/references/sandbox-orchestration.md +204 -0
  116. package/bundled-skills/malware-analysis/references/yara-sigma-rules.md +232 -0
  117. package/bundled-skills/mobile-reverse/SKILL.md +222 -0
  118. package/bundled-skills/mobile-reverse/references/anti-detection-bypass.md +182 -0
  119. package/bundled-skills/mobile-reverse/references/frida-objection-deep.md +218 -0
  120. package/bundled-skills/mobile-reverse/references/ios-reverse-guide.md +177 -0
  121. package/bundled-skills/muapi-media/SKILL.md +311 -0
  122. package/bundled-skills/ot-ics/SKILL.md +117 -0
  123. package/bundled-skills/ot-ics/references/ot-safe-assessment.md +10 -0
  124. package/bundled-skills/patch-diff-exploit/SKILL.md +278 -0
  125. package/bundled-skills/patch-diff-exploit/references/diff-tools-comparison.md +271 -0
  126. package/bundled-skills/patch-diff-exploit/references/patch-tuesday-workflow.md +253 -0
  127. package/bundled-skills/patch-diff-exploit/references/root-cause-and-poc.md +198 -0
  128. package/bundled-skills/pentest-tools/SKILL.md +346 -0
  129. package/bundled-skills/pentest-tools/references/ai-pentest-agents.md +148 -0
  130. package/bundled-skills/pentest-tools/references/ai-pentesting-landscape-2026.md +73 -0
  131. package/bundled-skills/pentest-tools/references/automation-loop-pattern.md +153 -0
  132. package/bundled-skills/pentest-tools/references/awesome-pentest-digest.md +175 -0
  133. package/bundled-skills/pentest-tools/references/burpsuite-mcp-guide.md +769 -0
  134. package/bundled-skills/pentest-tools/references/client-side-lab-playbook.md +155 -0
  135. package/bundled-skills/pentest-tools/references/kali-mcp-ecosystem.md +119 -0
  136. package/bundled-skills/pentest-tools/references/msf-protocol.md +169 -0
  137. package/bundled-skills/pentest-tools/references/network-attack-defense.md +350 -0
  138. package/bundled-skills/pentest-tools/references/nuclei-guide-2026.md +157 -0
  139. package/bundled-skills/pentest-tools/references/payloads.md +32 -0
  140. package/bundled-skills/pentest-tools/references/pentest-ai-agents-matrix.md +117 -0
  141. package/bundled-skills/pentest-tools/references/pentest-loop.md +270 -0
  142. package/bundled-skills/pentest-tools/references/recon-pipeline.md +154 -0
  143. package/bundled-skills/pentest-tools/references/templates/findings.md +21 -0
  144. package/bundled-skills/pentest-tools/references/templates/progress.md +17 -0
  145. package/bundled-skills/pentest-tools/references/templates/rules.md +35 -0
  146. package/bundled-skills/pentest-tools/references/templates/scope.md +29 -0
  147. package/bundled-skills/pentest-tools/references/templates/task_plan.md +27 -0
  148. package/bundled-skills/pentest-tools/references/web-attack-cheatsheet.md +387 -0
  149. package/bundled-skills/pentest-tools/src-hunter/SKILL.md +243 -0
  150. package/bundled-skills/pentest-tools/src-hunter/references/README.en.md +115 -0
  151. package/bundled-skills/pentest-tools/src-hunter/references/README.md +148 -0
  152. package/bundled-skills/pentest-tools/src-hunter/references/dictionaries/00-index.md +44 -0
  153. package/bundled-skills/pentest-tools/src-hunter/references/dictionaries/chinese-srcfingerprints.md +515 -0
  154. package/bundled-skills/pentest-tools/src-hunter/references/dictionaries/default-credentials-cn.md +274 -0
  155. package/bundled-skills/pentest-tools/src-hunter/references/industry/00-index.md +66 -0
  156. package/bundled-skills/pentest-tools/src-hunter/references/industry/banking-finance.md +338 -0
  157. package/bundled-skills/pentest-tools/src-hunter/references/industry/telecom-isp.md +315 -0
  158. package/bundled-skills/pentest-tools/src-hunter/references/methodology/00-index.md +68 -0
  159. package/bundled-skills/pentest-tools/src-hunter/references/methodology/01-attack-priority.md +143 -0
  160. package/bundled-skills/pentest-tools/src-hunter/references/methodology/02-bypass-toolkit.md +357 -0
  161. package/bundled-skills/pentest-tools/src-hunter/references/methodology/03-evidence-discipline.md +205 -0
  162. package/bundled-skills/pentest-tools/src-hunter/references/methodology/04-control-gap-hunting.md +238 -0
  163. package/bundled-skills/pentest-tools/src-hunter/references/methodology/05-srctimebox-priority.md +161 -0
  164. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/intranet/adcs/346/224/273/345/207/273.md +254 -0
  165. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/intranet/exchange/346/224/273/345/207/273.md +254 -0
  166. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/intranet/sharepoint/346/224/273/345/207/273.md +113 -0
  167. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/intranet//344/277/241/346/201/257/346/224/266/351/233/206.md +947 -0
  168. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/intranet//345/205/215/346/235/200/344/270/216/350/247/204/351/201/277.md +780 -0
  169. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/intranet//345/207/255/350/257/201/347/252/203/345/217/226.md +1259 -0
  170. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/intranet//345/237/237/346/270/227/351/200/217/346/224/273/345/207/273.md +753 -0
  171. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/intranet//346/235/203/351/231/220/346/217/220/345/215/207.md +819 -0
  172. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/intranet//346/235/203/351/231/220/347/273/264/346/214/201.md +577 -0
  173. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/intranet//346/250/252/345/220/221/347/247/273/345/212/250.md +838 -0
  174. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/intranet//351/232/247/351/201/223/344/273/243/347/220/206.md +604 -0
  175. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/web/ai/345/256/211/345/205/250.md +698 -0
  176. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/web/api/345/256/211/345/205/250.md +1935 -0
  177. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/web/csrf/350/267/250/347/253/231/350/257/267/346/261/202/344/274/252/351/200/240.md +952 -0
  178. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/web/jwt/345/256/211/345/205/250.md +496 -0
  179. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/web/lfi-rfi/346/226/207/344/273/266/345/214/205/345/220/253.md +1365 -0
  180. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/web/rce/350/277/234/347/250/213/344/273/243/347/240/201/346/211/247/350/241/214.md +1329 -0
  181. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/web/sql-nosql/346/263/250/345/205/245.md +1924 -0
  182. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/web/ssrf/346/234/215/345/212/241/347/253/257/350/257/267/346/261/202/344/274/252/351/200/240.md +1256 -0
  183. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/web/ssti/346/250/241/346/235/277/346/263/250/345/205/245.md +1151 -0
  184. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/web/websocket/345/256/211/345/205/250.md +487 -0
  185. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/web/xss/350/267/250/347/253/231/350/204/232/346/234/254.md +1465 -0
  186. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/web/xxe/345/256/236/344/275/223/346/263/250/345/205/245.md +815 -0
  187. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/web//344/270/232/345/212/241/351/200/273/350/276/221/346/274/217/346/264/236.md +594 -0
  188. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/web//344/272/221/345/256/211/345/205/250/346/274/217/346/264/236.md +561 -0
  189. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/web//344/276/233/345/272/224/351/223/276/346/224/273/345/207/273.md +399 -0
  190. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/web//345/216/237/345/236/213/351/223/276/346/261/241/346/237/223.md +401 -0
  191. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/web//345/274/200/346/224/276/351/207/215/345/256/232/345/220/221.md +396 -0
  192. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/web//346/226/207/344/273/266/346/274/217/346/264/236.md +0 -0
  193. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/web//346/241/206/346/236/266/346/274/217/346/264/236.md +2304 -0
  194. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/web//347/202/271/345/207/273/345/212/253/346/214/201.md +339 -0
  195. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/web//347/274/223/345/255/230/344/270/216cdn/345/256/211/345/205/250.md +497 -0
  196. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/web//350/256/244/350/257/201/346/274/217/346/264/236.md +1778 -0
  197. package/bundled-skills/pentest-tools/src-hunter/references/payloader/by-category/web//350/257/267/346/261/202/350/265/260/347/247/201.md +854 -0
  198. package/bundled-skills/pentest-tools/src-hunter/references/payloader/index.md +69 -0
  199. package/bundled-skills/pentest-tools/src-hunter/references/payloader/tools/web/346/270/227/351/200/217.md +662 -0
  200. package/bundled-skills/pentest-tools/src-hunter/references/payloader/tools/windows/346/270/227/351/200/217.md +100 -0
  201. package/bundled-skills/pentest-tools/src-hunter/references/payloader/tools//344/277/241/346/201/257/346/224/266/351/233/206.md +852 -0
  202. package/bundled-skills/pentest-tools/src-hunter/references/payloader/tools//345/206/205/347/275/221/346/270/227/351/200/217.md +873 -0
  203. package/bundled-skills/pentest-tools/src-hunter/references/payloader/tools//345/207/255/350/257/201/347/252/203/345/217/226.md +186 -0
  204. package/bundled-skills/pentest-tools/src-hunter/references/payloader/tools//345/237/237/346/270/227/351/200/217.md +50 -0
  205. package/bundled-skills/pentest-tools/src-hunter/references/payloader/tools//345/257/206/347/240/201/346/224/273/345/207/273.md +462 -0
  206. package/bundled-skills/pentest-tools/src-hunter/references/payloader/tools//346/235/203/351/231/220/346/217/220/345/215/207.md +168 -0
  207. package/bundled-skills/pentest-tools/src-hunter/references/payloader/tools//346/274/217/346/264/236/345/210/251/347/224/250.md +445 -0
  208. package/bundled-skills/pentest-tools/src-hunter/references/payloader/tools//347/263/273/347/273/237/345/221/275/344/273/244.md +410 -0
  209. package/bundled-skills/pentest-tools/src-hunter/references/payloader/tools//347/272/242/351/230/237/345/267/245/345/205/267.md +64 -0
  210. package/bundled-skills/pentest-tools/src-hunter/references/payloader/tools//347/274/226/347/240/201/350/247/243/347/240/201.md +226 -0
  211. package/bundled-skills/pentest-tools/src-hunter/references/payloader/tools//351/232/247/351/201/223/344/273/243/347/220/206.md +84 -0
  212. package/bundled-skills/pentest-tools/src-hunter/references/payloader/waf-bypass.md +6504 -0
  213. package/bundled-skills/pentest-tools/src-hunter/references/playbooks/00-index.md +57 -0
  214. package/bundled-skills/pentest-tools/src-hunter/references/playbooks/api-rest.md +2050 -0
  215. package/bundled-skills/pentest-tools/src-hunter/references/playbooks/arbitrary-x-authz.md +481 -0
  216. package/bundled-skills/pentest-tools/src-hunter/references/playbooks/dos.md +615 -0
  217. package/bundled-skills/pentest-tools/src-hunter/references/playbooks/file-upload.md +1365 -0
  218. package/bundled-skills/pentest-tools/src-hunter/references/playbooks/graphql.md +253 -0
  219. package/bundled-skills/pentest-tools/src-hunter/references/playbooks/http-smuggling.md +924 -0
  220. package/bundled-skills/pentest-tools/src-hunter/references/playbooks/info-disclosure.md +432 -0
  221. package/bundled-skills/pentest-tools/src-hunter/references/playbooks/intranet-postexp.md +4845 -0
  222. package/bundled-skills/pentest-tools/src-hunter/references/playbooks/llm-prompt-injection.md +1394 -0
  223. package/bundled-skills/pentest-tools/src-hunter/references/playbooks/logic-flaws.md +1796 -0
  224. package/bundled-skills/pentest-tools/src-hunter/references/playbooks/mobile.md +397 -0
  225. package/bundled-skills/pentest-tools/src-hunter/references/playbooks/oauth-saml-jwt.md +2504 -0
  226. package/bundled-skills/pentest-tools/src-hunter/references/playbooks/path-traversal.md +1297 -0
  227. package/bundled-skills/pentest-tools/src-hunter/references/playbooks/race-conditions.md +207 -0
  228. package/bundled-skills/pentest-tools/src-hunter/references/playbooks/rce.md +4829 -0
  229. package/bundled-skills/pentest-tools/src-hunter/references/playbooks/sqli.md +1620 -0
  230. package/bundled-skills/pentest-tools/src-hunter/references/playbooks/ssrf-cache-host.md +2098 -0
  231. package/bundled-skills/pentest-tools/src-hunter/references/playbooks/unauth-access.md +330 -0
  232. package/bundled-skills/pentest-tools/src-hunter/references/playbooks/xss.md +1159 -0
  233. package/bundled-skills/pentest-tools/src-hunter/references/templates/report-submission.md +346 -0
  234. package/bundled-skills/pentest-tools/src-hunter/references/tools/mcp-jshook.md +174 -0
  235. package/bundled-skills/poka-yoke/SKILL.md +172 -0
  236. package/bundled-skills/project-state-governor/SKILL.md +1 -1
  237. package/bundled-skills/project-state-governor/references/project-state-schema.md +1 -1
  238. package/bundled-skills/protocol-reverse/SKILL.md +108 -0
  239. package/bundled-skills/protocol-reverse/references/protocol-workflow.md +29 -0
  240. package/bundled-skills/pwn-chain/SKILL.md +209 -0
  241. package/bundled-skills/pwn-chain/references/heap-pwn.md +283 -0
  242. package/bundled-skills/pwn-chain/references/kernel-pwn.md +370 -0
  243. package/bundled-skills/pwn-chain/references/stack-pwn.md +312 -0
  244. package/bundled-skills/radare2/SKILL.md +460 -0
  245. package/bundled-skills/radare2/references/cheatsheet.md +129 -0
  246. package/bundled-skills/radio-sdr/SKILL.md +77 -0
  247. package/bundled-skills/radio-sdr/references/sdr-lab-rules.md +6 -0
  248. package/bundled-skills/reverse-browser-automation/SKILL.md +249 -0
  249. package/bundled-skills/reverse-browser-automation/references/playwright-cheatsheet.md +425 -0
  250. package/bundled-skills/reverse-engineering/SKILL.md +213 -0
  251. package/bundled-skills/reverse-engineering/dsl-vm-reverse/SKILL.md +388 -0
  252. package/bundled-skills/reverse-engineering/references/ai-assisted-re.md +149 -0
  253. package/bundled-skills/reverse-engineering/references/anti-analysis.md +836 -0
  254. package/bundled-skills/reverse-engineering/references/awesome-re-resources.md +135 -0
  255. package/bundled-skills/reverse-engineering/references/crypto-decode-tools.md +220 -0
  256. package/bundled-skills/reverse-engineering/references/elf-analysis.md +296 -0
  257. package/bundled-skills/reverse-engineering/references/field-notes.md +540 -0
  258. package/bundled-skills/reverse-engineering/references/go-reverse.md +240 -0
  259. package/bundled-skills/reverse-engineering/references/kernel-driver-reverse.md +298 -0
  260. package/bundled-skills/reverse-engineering/references/languages-compiled.md +587 -0
  261. package/bundled-skills/reverse-engineering/references/languages-platforms.md +486 -0
  262. package/bundled-skills/reverse-engineering/references/languages.md +499 -0
  263. package/bundled-skills/reverse-engineering/references/nonpe-format-cookbook.md +301 -0
  264. package/bundled-skills/reverse-engineering/references/ollvm-deobfuscation.md +501 -0
  265. package/bundled-skills/reverse-engineering/references/patterns-ctf-2.md +397 -0
  266. package/bundled-skills/reverse-engineering/references/patterns-ctf-3.md +719 -0
  267. package/bundled-skills/reverse-engineering/references/patterns-ctf.md +532 -0
  268. package/bundled-skills/reverse-engineering/references/patterns.md +801 -0
  269. package/bundled-skills/reverse-engineering/references/platforms-hardware.md +304 -0
  270. package/bundled-skills/reverse-engineering/references/platforms.md +442 -0
  271. package/bundled-skills/reverse-engineering/references/re-agent-workflow.md +240 -0
  272. package/bundled-skills/reverse-engineering/references/tools-advanced.md +822 -0
  273. package/bundled-skills/reverse-engineering/references/tools-dynamic.md +846 -0
  274. package/bundled-skills/reverse-engineering/references/tools.md +546 -0
  275. package/bundled-skills/spec-driven-loop/SKILL.md +203 -0
  276. package/bundled-skills/spec-driven-loop/references/agent-and-judge-contracts.md +120 -0
  277. package/bundled-skills/spec-driven-loop/references/document-templates.md +184 -0
  278. package/bundled-skills/supply-chain-security/SKILL.md +180 -0
  279. package/bundled-skills/supply-chain-security/references/cicd-pipeline-security.md +137 -0
  280. package/bundled-skills/supply-chain-security/references/sbom-sca-methodology.md +74 -0
  281. package/bundled-skills/thick-client/SKILL.md +104 -0
  282. package/bundled-skills/thick-client/references/thick-client-checklist.md +9 -0
  283. package/bundled-skills/threat-hunting/SKILL.md +94 -0
  284. package/bundled-skills/threat-hunting/references/hunting-loop.md +5 -0
  285. package/bundled-skills/threat-intelligence/SKILL.md +176 -0
  286. package/bundled-skills/threat-intelligence/references/x-public-intelligence.md +93 -0
  287. package/bundled-skills/tree-ring-memory/SKILL.md +29 -9
  288. package/bundled-skills/wifi-wireless/SKILL.md +80 -0
  289. package/bundled-skills/wifi-wireless/references/wireless-lab-rules.md +6 -0
  290. package/bundled-skills/windows-ad/SKILL.md +109 -0
  291. package/bundled-skills/windows-ad/references/ad-attack-paths.md +12 -0
  292. package/package.json +1 -1
  293. package/skills_index.json +1281 -3
  294. package/bundled-skills/lore/README.md +0 -386
  295. package/bundled-skills/lore/README.zh-CN.md +0 -386
  296. package/bundled-skills/lore/WORKFLOWS.md +0 -216
  297. package/bundled-skills/lore/WORKFLOWS.zh-CN.md +0 -216
@@ -0,0 +1,172 @@
1
+ ---
2
+ name: poka-yoke
3
+ description: "Mistake-proof code, config and process: make the wrong action impossible or self-announcing rather than documented."
4
+ category: development
5
+ risk: safe
6
+ source: rainmanjam/poka-yoke
7
+ source_repo: rainmanjam/poka-yoke
8
+ source_type: community
9
+ date_added: "2026-08-25"
10
+ author: rainmanjam
11
+ tags: [mistake-proofing, code-review, api-design, guardrails, reliability]
12
+ tools: [claude, cursor, codex]
13
+ license: "MIT"
14
+ license_source: "https://github.com/rainmanjam/poka-yoke/blob/v0.1.2/LICENSE"
15
+ ---
16
+
17
+ # Poka-Yoke: Mistake-Proofing for Software
18
+
19
+ Shigeo Shingo's insight, from the Toyota Production System: **people will always make
20
+ mistakes; that is not the problem worth solving. The problem is letting a mistake become a
21
+ defect.** So you stop trying to make humans more careful and start redesigning the work so
22
+ the mistake either cannot physically happen or announces itself immediately.
23
+
24
+ A poka-yoke ("poh-kah yoh-kay", ポカヨケ) is a *device*: a jig, a shape, a counter: not
25
+ an instruction. In software: a type, a constraint, a hook, a schema, a state machine. The
26
+ single most important consequence:
27
+
28
+ > **A comment, a docstring, a wiki page, a code review checklist, or a line in CLAUDE.md
29
+ > saying "don't do X" is not a poka-yoke.** It is training. Training degrades. A device
30
+ > does not. If your proposed fix relies on someone remembering something, keep going.
31
+
32
+ ## When to Use This Skill
33
+
34
+ - Use when the user says "poka-yoke this", "mistake-proof it", or "make this harder to get wrong".
35
+ - Use when designing an interface, schema or state machine and the ask is "make invalid states unrepresentable" or "so callers cannot screw it up".
36
+ - Use when auditing existing code for footguns: "what could bite us here", "what is easy to misuse".
37
+ - Use after an incident, when the fix must close the class rather than the case: "make sure this never happens again", "this is the third time".
38
+ - Especially for money, auth, permissions, deletion, migrations and pipelines, where failure is silent.
39
+
40
+ ## The two axes
41
+
42
+ Every real poka-yoke answers two questions. Use both when you classify a hazard or propose a
43
+ device. They are the difference between this method and generic code review.
44
+
45
+ ### Axis 1, Regulatory function: what happens when the mistake occurs?
46
+
47
+ This is a strict preference ladder. Always reach for the highest rung you can afford.
48
+
49
+ | Rung | Name | What it does | Software examples |
50
+ |---|---|---|---|
51
+ | **1** | **Control** | The mistake is **impossible**. The work cannot proceed. | Type won't compile · `NOT NULL` / `CHECK` / unique constraint · required function argument · private constructor + smart constructor · PreToolUse hook returns deny · protected branch |
52
+ | **2** | **Warning** | The mistake is possible but **announced at the moment it happens**. | Lint error in the editor · failing CI gate · runtime assertion that throws · confirmation prompt naming the exact thing being destroyed |
53
+ | **3** | **Detection** | The mistake ships, and something **finds it afterward**. | Tests · monitoring · alerting · reconciliation job |
54
+ | **0** | *(not a poka-yoke)* | Relies on a human remembering. | Docs · comments · training · "be careful" · review checklists |
55
+
56
+ Shingo's rule: prefer **control** over **warning**, always, and only settle for warning when
57
+ control is genuinely too expensive, then say *why* out loud. In software the honest reason
58
+ is usually "the language can't express it" or "it would break every existing caller," and
59
+ both are worth stating explicitly so the tradeoff is visible.
60
+
61
+ ### Axis 2, Setting function: how does the device notice?
62
+
63
+ Shingo's three detection methods map cleanly onto software. These are your **inspection
64
+ lenses**, run all three over any interface and you will find hazards that a general
65
+ code review misses.
66
+
67
+ | Method | Factory floor | The question to ask code | Software devices |
68
+ |---|---|---|---|
69
+ | **Contact** | The part physically won't seat unless it's the right shape and orientation | **Can the wrong thing fit?** | Distinct types instead of shared primitives · branded/newtype IDs · parse-don't-validate at boundaries · units in the type · discriminated unions instead of bags of optionals |
70
+ | **Fixed-value** | A counter says all 6 screws were fitted | **Can the wrong count or an incomplete set pass?** | Exhaustive `match`/`switch` over an enum · required fields · "all migrations applied" check · row-count guard on a bulk write · checksums · config validated as a whole at boot |
71
+ | **Motion-step** | A sensor confirms step 3 happened before step 4 | **Can the steps happen in the wrong order, or be skipped?** | Typestate · builder that cannot `.build()` until required steps run · state machines with illegal transitions unrepresentable · idempotency keys · RAII / `defer` / context managers · transactions |
72
+
73
+ ### The third principle: inspect at the source
74
+
75
+ Shingo separated **source inspection** from **informative inspection**, which finds the defect
76
+ only after it exists and comes in two forms. Ranked best first, that is three places you can
77
+ put the device.
78
+
79
+ 1. **Source inspection**: check the *conditions* before the error can occur. Designed in
80
+ where you can, enforced at runtime where you cannot.
81
+ The type, the constraint, the signature.
82
+ 2. **Self-check** (informative): the work checks itself as it happens. Runtime. Assertions,
83
+ fail-fast, validation at the boundary.
84
+ 3. **Successive check** (informative): the next station checks the previous one. Review, CI,
85
+ QA.
86
+
87
+ Push every device as far up this list as it will go. A CI gate that catches a bad migration
88
+ is good; a schema that makes the bad migration unwritable is better and costs less forever.
89
+
90
+ ## How to use this skill
91
+
92
+ Apply the method directly to the subject in front of you. A Terraform module, a support
93
+ runbook, a spreadsheet everyone edits, a release checklist, a
94
+ prompt template, an onboarding process, a physical workflow: the method works on any of them,
95
+ because Shingo developed it on an assembly line, for people fitting springs into switches, and
96
+ not for software at all.
97
+
98
+ Applying it directly means four steps, in order:
99
+
100
+ 1. **Name what is being done, and by whom.** A device protects a specific action taken by a
101
+ specific person or system. "The pipeline" is not an action; "an engineer re-runs the deploy
102
+ job after it fails halfway" is.
103
+ 2. **Run the three lenses** over that action, can the wrong thing fit, can an incomplete or
104
+ wrong-sized set pass, can the steps happen in the wrong order. Most subjects yield
105
+ something on at least one.
106
+ 3. **For each hazard found, state it as a mistake someone could make**, what happens when they
107
+ do, whether it is silent, and what exists today to stop it.
108
+ 4. **Propose the highest-rung device you can afford**, and say which rung it reaches. If you
109
+ land on Warning, say what Control would have required and why you did not take it.
110
+
111
+ Then apply the two rules in *How to talk about this* below: name the mistake rather than the
112
+ mistaken, and never let the answer come out as "be more careful" or "document it". Those are
113
+ rung zero, and the whole method exists because they do not work.
114
+
115
+ **If the request is bare**, `/poka-yoke` with nothing attached, look at what is actually in
116
+ front of you: the current diff, the file under discussion, the thing the conversation has been
117
+ about. Say what you picked in one line before starting, so it is cheap to redirect you. If
118
+ there is genuinely no subject, ask what they want mistake-proofed rather than guessing.
119
+
120
+ ## How to talk about this
121
+
122
+ Two habits keep the analysis honest and keep people from getting defensive:
123
+
124
+ **Name the mistake, not the mistaken.** "This signature lets a caller swap the two IDs" is
125
+ actionable and true. "The developer should have been more careful" is neither. Shingo was
126
+ emphatic that blaming the operator is how organizations avoid fixing the process. Write
127
+ findings about the code's affordances, never about who wrote it.
128
+
129
+ **Say which rung you achieved, and what stopped you going higher.** A recommendation that
130
+ reads "added a runtime assertion (warning), control would need a newtype, which touches 40
131
+ call sites" gives the reader a real decision. One that reads "added validation" does not.
132
+
133
+ ## Example
134
+
135
+ Suppose a destructive API accepts `deleteAccount(accountId: string, tenantId: string)`.
136
+ The two identifiers can be swapped, and the call can target an account outside the caller's
137
+ tenant.
138
+
139
+ 1. **Contact lens:** two plain strings have the same shape, so the wrong value fits.
140
+ 2. **Motion-step lens:** deletion can run before tenant ownership is established.
141
+ 3. **Control device:** replace the strings with distinct validated ID types and expose a
142
+ deletion operation that accepts only an account loaded through the authenticated tenant.
143
+ 4. **Warning fallback:** if compatibility prevents that interface change, reject ownership
144
+ mismatches at the boundary and require a confirmation that names the exact account. State
145
+ explicitly that this is weaker than making the invalid call unrepresentable.
146
+ 5. **Detection:** retain audit logging and reconciliation for failures the control does not
147
+ cover; do not present those after-the-fact checks as the poka-yoke itself.
148
+
149
+ ## Applying changes
150
+
151
+ Propose before you edit. Show the hazard, the proposed device, and the rung it reaches, then
152
+ wait for a go-ahead before changing files: the whole point of this method is that it changes
153
+ the shape of an interface, and that is precisely the kind of change people want to see first.
154
+ Once approved, apply it and record the prevented mistake where future maintainers can verify
155
+ the constraint without mistaking the explanation itself for the device.
156
+
157
+ The exception is when someone has explicitly asked you to write new code: mistake-proofing
158
+ *is* the code they asked for, so build it, then narrate which hazards
159
+ you designed out and why.
160
+
161
+ ## Limitations
162
+
163
+ - Poka-yoke reduces predictable misuse; it cannot prove that a design is correct or cover
164
+ hazards the analysis never identifies.
165
+ - The strongest control may be unavailable in the current language, platform or compatibility
166
+ envelope. When that happens, state the tradeoff and retain appropriate tests, monitoring and
167
+ recovery paths instead of presenting a warning as complete prevention.
168
+ - A guard can itself be wrong, overbroad or operationally expensive. Validate proposed devices
169
+ against real callers and failure modes, especially for destructive, financial, authentication
170
+ and authorization flows.
171
+ - This method complements, but does not replace, domain review, security review, testing,
172
+ observability or incident response.
@@ -216,7 +216,7 @@ Example:
216
216
  session DONE != task DONE
217
217
  task DONE != milestone DONE
218
218
  milestone DONE != workstream DONE
219
- workstream DONE != mission success
219
+ workstream COMPLETED != mission success
220
220
  ```
221
221
 
222
222
  ## 5. Session bootstrap and recall
@@ -31,7 +31,7 @@ detailed record no longer affects future work.
31
31
 
32
32
  ## Milestones
33
33
  ### [Milestone ID or name]
34
- - Status: PROPOSED | ACTIVE | BLOCKED | PAUSED | DONE | DEFERRED
34
+ - Status: PROPOSED | ACTIVE | BLOCKED | PAUSED | DONE | CANCELLED | DEFERRED
35
35
  - Goal: ...
36
36
  - DoD: ...
37
37
  - Parent: ...
@@ -0,0 +1,108 @@
1
+ ---
2
+ name: protocol-reverse
3
+ description: "Authorized reverse engineering of custom binary protocols, Protobuf/gRPC schemas, WebSocket frames, and PCAP-driven protocol recovery."
4
+ risk: safe
5
+ source: "https://github.com/zhaoxuya520/reverse-skill"
6
+ source_repo: "zhaoxuya520/reverse-skill"
7
+ source_type: community
8
+ date_added: "2026-08-25"
9
+ license: "MIT"
10
+ license_source: "https://github.com/zhaoxuya520/reverse-skill/blob/main/LICENSE"
11
+ ---
12
+ # Protocol Reverse Engineering
13
+ ## When to Use
14
+
15
+ - Documenting an undocumented wire protocol from captures.
16
+ - Decoding structured traffic during an authorized analysis.
17
+
18
+
19
+ ## 适用场景
20
+
21
+ - 自定义 TCP/UDP 二进制协议
22
+ - Protobuf / gRPC / FlatBuffers / MessagePack
23
+ - WebSocket / MQTT / 私有 RPC
24
+ - PCAP / PCAPNG 还原字段与状态机
25
+ - 客户端-服务端校验、序列号、加密帧头
26
+
27
+ ## 不走本 skill
28
+
29
+ | 情况 | 去哪 |
30
+ |------|------|
31
+ | 仅 HTTP 参数签名 / JS 加密 | `js-reverse/` |
32
+ | 仅 TLS 证书问题 | `pentest-tools/` 或浏览器代理 |
33
+ | 固件内协议栈深挖 + 仿真 | `firmware-pentest/` 后再回本 skill |
34
+
35
+ ## 工作流
36
+
37
+ ### Phase 1 — 采集与分诊
38
+
39
+ ```text
40
+ □ 拿到样本:PCAP / 代理导出 / 客户端日志 / 二进制
41
+ □ 标记方向:C→S / S→C;是否有握手、心跳、重连
42
+ □ 固定头?魔数?长度字段?TLV?定长?
43
+ □ 是否压缩(zlib/gzip/lz4)或加密(AES/ChaCha 帧内)
44
+ □ tshark -r cap.pcap -T fields -e frame.number -e ip.src -e tcp.payload
45
+ ```
46
+
47
+ ### Phase 2 — 帧布局还原
48
+
49
+ ```text
50
+ □ 对齐多个同类消息,找不变字节 / 自增序列号
51
+ □ 长度字段:大端/小端、含头/不含头
52
+ □ 校验:CRC16/32、checksum、HMAC 位置
53
+ □ 画出状态机:Connect → Auth → Ready → Request/Response → Close
54
+ □ 工具:Wireshark 自定义 dissector 草稿 / ImHex / 010 Editor 模板 / Kaitai Struct
55
+ ```
56
+
57
+ ### Phase 3 — 序列化与加密
58
+
59
+ ```text
60
+ □ Protobuf:.proto 恢复(blackboxprotobuf / pbtk / protoc --decode_raw)
61
+ □ gRPC:HTTP/2 headers + protobuf body
62
+ □ 加密:找密钥派生(客户端 so/dll/JS)→ 联合 ida-reverse / js-reverse / apk-reverse
63
+ □ 重放:仅在授权 scope 内;先无害字段再敏感操作
64
+ ```
65
+
66
+ ### Phase 4 — 产物
67
+
68
+ ```text
69
+ MUST 产出:
70
+ - 消息类型表(name / opcode / fields)
71
+ - 至少 1 条可复现的解码命令或脚本
72
+ - Evidence:原始 hex 摘录 + 解码结果(脱敏)
73
+ ```
74
+
75
+ ## 工具链
76
+
77
+ | 工具 | 必需 | 用途 | 自举 |
78
+ |------|------|------|------|
79
+ | tshark / Wireshark | 强烈建议 | PCAP 解析 | 手动 / winget |
80
+ | Python3 | 是 | 解码脚本 | 系统 |
81
+ | blackboxprotobuf | 可选 | 未知 protobuf | pip |
82
+ | ImHex / 010 | 可选 | 结构模板 | 手动 |
83
+ | IDA / r2 / Ghidra | 按需 | 客户端序列化函数 | 见对应 skill |
84
+
85
+ ## 参考
86
+
87
+ - `references/protocol-workflow.md` — 帧布局与 Protobuf 速查
88
+ - 相关:`../ida-reverse/` `../js-reverse/` `../firmware-pentest/` `../pentest-tools/`
89
+
90
+ ## 路由上下文
91
+
92
+ **上游**: `MASTER-ROUTING` R21 · `routing.md`
93
+ **下游**: 需客户端算法 → `ida-reverse`/`js-reverse`;需利用重放 → `pentest-tools`/`api-security`
94
+ **同级**: `malware-analysis`(C2 协议)、`digital-forensics`(流量取证)
95
+
96
+ ## 任务完成自检
97
+
98
+ - [ ] 是否还原了消息布局或状态机(而非只贴 hex)?
99
+ - [ ] 是否有可复现解码命令?
100
+ - [ ] 是否遵守 scope / 脱敏?
101
+ - [ ] 是否回写 field-journal / 报告 Checklist?
102
+
103
+ ## Limitations
104
+
105
+ - Encrypted or session-keyed protocols need key material first.
106
+ - Stateful protocols may require long, varied capture sessions.
107
+
108
+ > Adapted from [zhaoxuya520/reverse-skill](https://github.com/zhaoxuya520/reverse-skill) (MIT).
@@ -0,0 +1,29 @@
1
+ # Protocol reverse 速查
2
+
3
+ > 适用:`protocol-reverse` skill · 2026-07-18
4
+
5
+ ## 常见布局模式
6
+
7
+ | 模式 | 特征 | 提示 |
8
+ |------|------|------|
9
+ | 定长头+体 | 前 2/4 字节长度 | 注意是否包含头长 |
10
+ | 魔数 | 固定 `0xDEAD` 等 | 便于流再同步 |
11
+ | TLV | type-length-value 重复 | type 枚举即消息字典 |
12
+ | Protobuf | 字段号 varint | `protoc --decode_raw` |
13
+ | 加密帧 | 熵高、无明文 URL | 先找 nonce/IV 邻域 |
14
+
15
+ ## 最小 Python 骨架
16
+
17
+ ```python
18
+ import struct
19
+ def parse_frame(buf: bytes):
20
+ magic, length, msg_type = struct.unpack_from(">IHI", buf, 0)
21
+ body = buf[10:10+length]
22
+ return {"magic": magic, "type": msg_type, "body": body}
23
+ ```
24
+
25
+ ## PCAP 提取 TCP payload
26
+
27
+ ```bash
28
+ tshark -r cap.pcap -Y "tcp.port==4433" -T fields -e tcp.payload | head
29
+ ```
@@ -0,0 +1,209 @@
1
+ ---
2
+ name: pwn-chain
3
+ description: "Go from reverse engineering to a working exploit: stack/heap/kernel pwn workflows with pwntools, libc-database, ROP, and stabilization from CTF to authorized remote targets."
4
+ risk: offensive
5
+ source: "https://github.com/zhaoxuya520/reverse-skill"
6
+ source_repo: "zhaoxuya520/reverse-skill"
7
+ source_type: community
8
+ date_added: "2026-08-25"
9
+ license: "MIT"
10
+ license_source: "https://github.com/zhaoxuya520/reverse-skill/blob/main/LICENSE"
11
+ ---
12
+ > **⚠️ AUTHORIZED USE ONLY**
13
+ > This skill is for educational purposes or authorized security assessments only.
14
+ > You must have explicit, written permission from the system owner before using this tool.
15
+ > Misuse of this tool is illegal and strictly prohibited.
16
+
17
+ > **Mandatory confirmation gate**
18
+ > Before running any command that probes, exploits, changes, persists on, extracts data from, or attempts credential access against a target:
19
+ > 1. Ask the user to state the exact target URL, IP, account, or resource.
20
+ > 2. Ask the user to confirm written authorization and the permitted scope.
21
+ > 3. Show the exact command(s) and explain their expected effect.
22
+ > 4. Wait for explicit confirmation in the current conversation.
23
+ >
24
+ > Without that confirmation, remain read-only and provide defensive guidance only. Prefer a sandbox, disposable VM, or controlled lab.
25
+
26
+ ## When to Use
27
+
28
+ - A binary vulnerability is understood and needs a reliable exploit.
29
+ - Porting a CTF-style exploit to an authorized real-world target.
30
+
31
+ ## 适用范围
32
+
33
+ 当任务属于以下场景时使用本 skill:
34
+
35
+ 1. **拿到二进制 + 已知漏洞点** — 静态/审计/fuzz 已经找到溢出/UAF/double free,需要从触发到拿 shell
36
+ 2. **CTF 题已经本地通了,远程打不通** — 远端环境差异导致脚本失效,需要稳定化
37
+ 3. **真实目标的二进制利用** — SRC / 红队场景下,已经识别到内存损坏漏洞,需要构造 RCE
38
+ 4. **Linux 内核驱动的 ioctl bug** — 用户态触发,目标是提权到 root
39
+
40
+ **前提**:你已经知道"哪里炸了"。本 skill 不负责发现漏洞(那是 fuzzing / 审计),只负责"从漏洞点写出 exploit"。
41
+
42
+ ### 与其他 skill 的分工
43
+
44
+ | 场景 | 用什么 |
45
+ |------|--------|
46
+ | 识别 custom VM / anti-debug / 复杂 obfuscation | `reverse-engineering/` |
47
+ | 从零打开二进制做静态分析 | `ida-reverse/` 或 `radare2/` |
48
+ | **有漏洞点,写 exploit 打通远程** | **本 skill** |
49
+ | 把 pwn 拿到的 shell 整合进完整攻击链 | `attack-chain/`(下游) |
50
+
51
+ `reverse-engineering/` 关注"理解程序在干什么"(模式识别、协议还原、解 CTF 题里的奇怪机制);本 skill 关注"把已经看懂的漏洞变成可执行的攻击"。两者经常配套使用,但分工清晰。
52
+
53
+ ## 核心工作流
54
+
55
+ ```text
56
+ Step 1: 确认漏洞类型 + 保护机制
57
+ ├─ checksec ./vuln(NX / Canary / PIE / RELRO / Fortify)
58
+ ├─ file ./vuln + readelf -d ./vuln
59
+ ├─ 漏洞分类:栈溢出 / 格式化字符串 / 堆 (UAF/DF/OF) / 整数 / 竞态 / 内核
60
+ └─ → 决定走哪个 references/
61
+
62
+ Step 2: 选择利用策略
63
+ ├─ NX 关 + 无 ASLR → 直接 shellcode
64
+ ├─ NX 开 + 给 libc → ret2libc / one_gadget
65
+ ├─ NX 开 + 不给 libc → leak 后 libc-database 反查
66
+ ├─ 堆 → 按 glibc 版本对应技术 (tcache/fastbin/unsorted/large)
67
+ └─ 内核 → commit_creds / modprobe_path / core_pattern
68
+
69
+ Step 3: 准备 libc + gadget
70
+ ├─ libc-database:./find puts 0x6f0
71
+ ├─ ROPgadget --binary ./libc.so.6 --only "pop|ret"
72
+ ├─ one_gadget ./libc.so.6
73
+ └─ 计算 base:leak_addr - libc.sym['puts']
74
+
75
+ Step 4: 写 pwntools 模板(本地 process)
76
+ ├─ context.binary = ELF('./vuln')
77
+ ├─ p = process('./vuln') / p = gdb.debug('./vuln','b *main+xx')
78
+ ├─ payload = cyclic(N) + p64(ret) + ...
79
+ └─ p.interactive()
80
+
81
+ Step 5: 本地通
82
+ ├─ 反复 attach + 看寄存器 + 调 offset
83
+ ├─ 用 pwndbg/GEF 的 vmmap / heap / bins / telescope
84
+ └─ 跑通后切 remote()
85
+
86
+ Step 6: 远程稳定化
87
+ ├─ libc 偏移:用 leak 反查 libc-database,不要拍脑袋
88
+ ├─ 栈对齐:16-byte 不对齐 → movaps 崩 → 加一个 ret gadget
89
+ ├─ 远程网络延迟 → recvuntil 精确锚字符串,禁用模糊 sleep
90
+ ├─ 远程缓冲:sendlineafter 比 sendline 更稳
91
+ ├─ 堆喷成功率:放大 spray 数量 + 留 padding chunk 防合并
92
+ └─ 多次跑:写 while True 验证成功率 ≥ 95%
93
+ ```
94
+
95
+ ## 典型场景
96
+
97
+ ### 场景 1:远程 64 位二进制 (NX+PIE+canary, 给了 libc)
98
+
99
+ ```text
100
+ 已有:./vuln(64-bit ELF, NX, PIE, canary)+ ./libc.so.6 + nc host port
101
+ 漏洞:read(buf, 0x200) 但 buf 只有 0x40 字节 → 栈溢出
102
+ 保护:canary 拦住,PIE 让 .text 随机化
103
+
104
+ 策略:
105
+ 1. 先 leak canary(栈/格式化字符串/部分读)
106
+ 2. 再 leak 一个 libc 函数地址(puts@got)
107
+ 3. 用 libc.address = leaked - libc.sym['puts'] 算 libc base
108
+ 4. one_gadget ./libc.so.6 选一个约束能满足的 magic gadget
109
+ 5. payload = padding + canary + saved_rbp + (pop_rdi + bin_sh + system) 或直接 one_gadget
110
+ 6. 加一个 ret gadget 修栈对齐(关键!)
111
+ ```
112
+
113
+ 完整模板参见 `references/stack-pwn.md`。
114
+
115
+ ### 场景 2:Linux 内核驱动 ioctl 越界写 → 拿 root
116
+
117
+ ```text
118
+ 已有:vmlinux + bzImage + initramfs.cpio.gz + 自定义 vuln.ko
119
+ 漏洞:ioctl(0x1337, ptr) 里 copy_from_user 长度可控 → kernel heap overflow (kmalloc-64 slab)
120
+ 保护:SMEP, SMAP, KASLR, KPTI
121
+
122
+ 策略:
123
+ 1. 改 init 脚本拿到 root shell(CTF)或先 leak KASLR base 再继续(真实)
124
+ 2. 通过 /proc/kallsyms(可能限权)或未初始化堆喷 leak 内核基址
125
+ 3. 在 kmalloc-64 slab 里喷 tty_struct / msg_msg / pipe_buffer
126
+ 4. 覆盖 vtable 指针指向用户态 → 不行(SMEP),改走 stack pivot + 内核 ROP
127
+ 5. ROP 链:prepare_kernel_cred(0) → commit_creds → swapgs+iretq → 用户态 execve("/bin/sh")
128
+ 6. 或更省事:覆盖 modprobe_path 为 "/tmp/x",写一个 /tmp/x,然后触发 modprobe
129
+ ```
130
+
131
+ 完整模板参见 `references/kernel-pwn.md`。
132
+
133
+ ## 按需自举 (On-Demand Bootstrap)
134
+
135
+ ### 工具依赖
136
+
137
+ | 工具 | 用途 | 安装方式 |
138
+ |------|------|---------|
139
+ | pwntools | exploit 编写框架 | `pip install pwntools` |
140
+ | GEF | gdb 增强(推荐内核 + 用户态) | `git clone https://github.com/bata24/gef` (fork 维护活跃) |
141
+ | pwndbg | gdb 增强(堆调试体验最好) | `git clone https://github.com/pwndbg/pwndbg && ./setup.sh` |
142
+ | ROPgadget | gadget 搜索 | `pip install ropgadget` |
143
+ | Ropper | gadget 搜索(备选,支持架构多) | `pip install ropper` |
144
+ | one_gadget | libc magic gadget 查找 | `gem install one_gadget`(需 ruby) |
145
+ | libc-database | libc 指纹反查 | `git clone https://github.com/niklasb/libc-database && ./get` |
146
+ | qemu-system-x86_64 | 内核题调试 | `apt install qemu-system-x86` |
147
+ | binwalk / cpio | initramfs 拆包 | `apt install binwalk cpio` |
148
+ | patchelf | 切换 libc 版本 | `apt install patchelf` |
149
+
150
+ ### Bootstrap 检查脚本
151
+
152
+ ```bash
153
+ # 一键检查 + 安装核心工具
154
+ for t in pwntools ropgadget ropper; do
155
+ pip show $t >/dev/null 2>&1 || pip install $t
156
+ done
157
+
158
+ command -v one_gadget >/dev/null || gem install one_gadget
159
+
160
+ [ -d ~/tools/libc-database ] || git clone https://github.com/niklasb/libc-database ~/tools/libc-database
161
+ [ -d ~/tools/libc-database/db ] || (cd ~/tools/libc-database && ./get ubuntu debian)
162
+
163
+ [ -d ~/tools/pwndbg ] || (git clone https://github.com/pwndbg/pwndbg ~/tools/pwndbg && cd ~/tools/pwndbg && ./setup.sh)
164
+ ```
165
+
166
+ ### 同一工具自动安装失败 2 次后
167
+
168
+ 停止重试,输出结构化手动安装步骤(pip 源 / gem 源 / git 国内镜像 / apt 源)让用户确认。
169
+
170
+ ## 路由上下文
171
+
172
+ **上游入口**: `skills/SKILL.md`(总控)、`routing.md`
173
+ **触发条件**: 有二进制 + 已识别漏洞点,需要写 exploit
174
+
175
+ **上游 skill(先用它们再回到本 skill)**:
176
+ - 还没看懂二进制在干什么 → `reverse-engineering/`
177
+ - 需要静态详细分析 → `ida-reverse/`
178
+ - 快速侦察确认架构/保护机制 → `radare2/`
179
+
180
+ **下游 skill(拿到 shell 之后)**:
181
+ - 整合进完整攻击链(横向、提权、持久化)→ `attack-chain/`
182
+
183
+ **子模块导航**:
184
+ - 栈类利用(ret2libc / ret2csu / one_gadget / 栈对齐)→ `references/stack-pwn.md`
185
+ - 堆类利用(tcache / fastbin / unsorted / large bin / FILE struct)→ `references/heap-pwn.md`
186
+ - 内核 pwn(kROP / SMEP-SMAP 绕过 / KASLR leak / modprobe_path)→ `references/kernel-pwn.md`
187
+
188
+ ## 注意事项
189
+
190
+ - **不要在本地跑通就交差** — 本地 libc / ASLR / 网络环境都和远程不同,必须在 remote 模式下连续跑 20 次以上验证稳定性
191
+ - **libc 版本必须确认** — 用 leak + libc-database 反查,不要假设是 Ubuntu 22.04 默认 libc
192
+ - **栈对齐是 64 位的常见坑** — `movaps xmm0, [rsp]` 在 rsp 未 16 字节对齐时段错误,加一个空 `ret` gadget 解决
193
+ - **堆利用对 glibc 版本极敏感** — tcache 在 2.27 引入,safe-linking 在 2.32 引入,2.34 移除 hooks,每个版本利用路径不同
194
+ - **内核 pwn 必须先确认 cpu 标志** — qemu 启动参数里有没有 +smep +smap +pku 直接决定 ROP 链怎么写
195
+ - **KASLR leak 一次就够** — 拿到一个内核地址后所有地址都算偏移,不要反复 leak
196
+
197
+ ## 任务完成自检(声称完成前 MUST 通过)
198
+
199
+ - [ ] 我是否执行了工作流中的每一步(而不是只阅读)?
200
+ - [ ] 我是否基于 `tool-index` 使用了真实工具路径?
201
+ - [ ] 我是否产出了可复现证据(命令/脚本/截图/报告)?
202
+ - [ ] 我是否完成并回写了 RULES 要求的 Checklist 项?
203
+
204
+ ## Limitations
205
+
206
+ - Exploit development only on systems you are authorized to attack.
207
+ - Mitigations (full RELRO, CFI, MTE) raise difficulty substantially.
208
+
209
+ > Adapted from [zhaoxuya520/reverse-skill](https://github.com/zhaoxuya520/reverse-skill) (MIT).