showdar-skills 0.2.0

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 (304) hide show
  1. package/LICENSE +9 -0
  2. package/README.md +322 -0
  3. package/bin/showdar.js +118 -0
  4. package/bundles/bugfix.yaml +4 -0
  5. package/bundles/design.yaml +4 -0
  6. package/bundles/feature.yaml +4 -0
  7. package/bundles/release.yaml +4 -0
  8. package/bundles/upgrade.yaml +4 -0
  9. package/commands/opencode/showdar/build.md +6 -0
  10. package/commands/opencode/showdar/debug.md +6 -0
  11. package/commands/opencode/showdar/design.md +6 -0
  12. package/commands/opencode/showdar/git.md +6 -0
  13. package/commands/opencode/showdar/ops.md +7 -0
  14. package/commands/opencode/showdar/plan.md +6 -0
  15. package/commands/opencode/showdar/quality.md +7 -0
  16. package/commands/opencode/showdar/recover.md +6 -0
  17. package/commands/opencode/showdar/requirements.md +7 -0
  18. package/commands/opencode/showdar/review.md +6 -0
  19. package/commands/opencode/showdar/security.md +7 -0
  20. package/commands/opencode/showdar/ship.md +6 -0
  21. package/commands/opencode/showdar/skill.md +6 -0
  22. package/commands/opencode/showdar/test.md +6 -0
  23. package/commands/opencode/showdar/understand.md +6 -0
  24. package/commands/opencode/showdar/upgrade.md +6 -0
  25. package/engine/csv.mjs +45 -0
  26. package/engine/detect-stack.mjs +48 -0
  27. package/engine/rank.mjs +40 -0
  28. package/engine/search.mjs +20 -0
  29. package/package.json +28 -0
  30. package/profiles/backend.json +1 -0
  31. package/profiles/developer.json +1 -0
  32. package/profiles/full.json +1 -0
  33. package/profiles/minimal.json +1 -0
  34. package/profiles/product.json +1 -0
  35. package/profiles/qa.json +1 -0
  36. package/router/conflicts.yaml +50 -0
  37. package/router/skill-map.yaml +54 -0
  38. package/router/triggers.yaml +30 -0
  39. package/skills/showdar-build/SKILL.md +154 -0
  40. package/skills/showdar-build/data/change-smells.csv +24 -0
  41. package/skills/showdar-build/data/index.json +14 -0
  42. package/skills/showdar-build/examples/change-surface.md +18 -0
  43. package/skills/showdar-build/references/architecture-boundaries.md +3 -0
  44. package/skills/showdar-build/references/error-handling.md +3 -0
  45. package/skills/showdar-build/references/feature-flags.md +3 -0
  46. package/skills/showdar-build/references/minimal-change.md +3 -0
  47. package/skills/showdar-build/scripts/change-surface.mjs +5 -0
  48. package/skills/showdar-build/stacks/dart.md +3 -0
  49. package/skills/showdar-build/stacks/flutter.md +3 -0
  50. package/skills/showdar-build/stacks/kotlin.md +3 -0
  51. package/skills/showdar-build/stacks/nextjs.md +3 -0
  52. package/skills/showdar-build/stacks/node-fastify.md +3 -0
  53. package/skills/showdar-build/stacks/node-nestjs.md +3 -0
  54. package/skills/showdar-build/stacks/react-native.md +3 -0
  55. package/skills/showdar-build/stacks/react.md +3 -0
  56. package/skills/showdar-build/stacks/rust-tauri.md +3 -0
  57. package/skills/showdar-build/stacks/swift.md +3 -0
  58. package/skills/showdar-build/stacks/typescript.md +3 -0
  59. package/skills/showdar-debug/SKILL.md +179 -0
  60. package/skills/showdar-debug/data/failure-patterns.csv +34 -0
  61. package/skills/showdar-debug/data/index.json +14 -0
  62. package/skills/showdar-debug/examples/evidence-log.md +19 -0
  63. package/skills/showdar-debug/references/async-races.md +3 -0
  64. package/skills/showdar-debug/references/build-failures.md +3 -0
  65. package/skills/showdar-debug/references/hypothesis-driven-debugging.md +3 -0
  66. package/skills/showdar-debug/references/memory.md +3 -0
  67. package/skills/showdar-debug/references/networking.md +3 -0
  68. package/skills/showdar-debug/references/performance.md +3 -0
  69. package/skills/showdar-debug/scripts/collect-context.mjs +8 -0
  70. package/skills/showdar-debug/scripts/lib/detect-stack.mjs +48 -0
  71. package/skills/showdar-debug/stacks/android.md +21 -0
  72. package/skills/showdar-debug/stacks/docker.md +21 -0
  73. package/skills/showdar-debug/stacks/flutter.md +21 -0
  74. package/skills/showdar-debug/stacks/ios.md +21 -0
  75. package/skills/showdar-debug/stacks/nextjs.md +21 -0
  76. package/skills/showdar-debug/stacks/node.md +21 -0
  77. package/skills/showdar-debug/stacks/react-native.md +21 -0
  78. package/skills/showdar-debug/stacks/react.md +21 -0
  79. package/skills/showdar-debug/stacks/tauri.md +21 -0
  80. package/skills/showdar-design/SKILL.md +179 -0
  81. package/skills/showdar-design/data/accessibility.csv +16 -0
  82. package/skills/showdar-design/data/colors.csv +13 -0
  83. package/skills/showdar-design/data/components.csv +20 -0
  84. package/skills/showdar-design/data/index.json +25 -0
  85. package/skills/showdar-design/data/motion.csv +13 -0
  86. package/skills/showdar-design/data/products.csv +19 -0
  87. package/skills/showdar-design/data/stacks/compose.csv +9 -0
  88. package/skills/showdar-design/data/stacks/flutter.csv +9 -0
  89. package/skills/showdar-design/data/stacks/html-tailwind.csv +9 -0
  90. package/skills/showdar-design/data/stacks/nextjs.csv +9 -0
  91. package/skills/showdar-design/data/stacks/nuxt.csv +9 -0
  92. package/skills/showdar-design/data/stacks/react-native.csv +9 -0
  93. package/skills/showdar-design/data/stacks/react.csv +9 -0
  94. package/skills/showdar-design/data/stacks/svelte.csv +9 -0
  95. package/skills/showdar-design/data/stacks/swiftui.csv +9 -0
  96. package/skills/showdar-design/data/stacks/tauri.csv +9 -0
  97. package/skills/showdar-design/data/stacks/vue.csv +9 -0
  98. package/skills/showdar-design/data/styles.csv +13 -0
  99. package/skills/showdar-design/data/typography.csv +13 -0
  100. package/skills/showdar-design/data/ui-patterns.csv +19 -0
  101. package/skills/showdar-design/examples/design-brief.md +19 -0
  102. package/skills/showdar-design/references/accessibility.md +5 -0
  103. package/skills/showdar-design/references/anti-ai-ui.md +5 -0
  104. package/skills/showdar-design/references/architecture.md +12 -0
  105. package/skills/showdar-design/references/interaction.md +5 -0
  106. package/skills/showdar-design/references/layout.md +5 -0
  107. package/skills/showdar-design/references/release-readiness.md +12 -0
  108. package/skills/showdar-design/references/responsive.md +5 -0
  109. package/skills/showdar-design/references/security.md +12 -0
  110. package/skills/showdar-design/references/visual-hierarchy.md +7 -0
  111. package/skills/showdar-design/scripts/lib/csv.mjs +40 -0
  112. package/skills/showdar-design/scripts/lib/rank.mjs +35 -0
  113. package/skills/showdar-design/scripts/lib/search.mjs +20 -0
  114. package/skills/showdar-design/scripts/search.mjs +38 -0
  115. package/skills/showdar-design/stacks/flutter.md +13 -0
  116. package/skills/showdar-design/stacks/html-tailwind.md +12 -0
  117. package/skills/showdar-design/stacks/jetpack-compose.md +13 -0
  118. package/skills/showdar-design/stacks/nextjs.md +12 -0
  119. package/skills/showdar-design/stacks/nuxt.md +11 -0
  120. package/skills/showdar-design/stacks/react-native.md +13 -0
  121. package/skills/showdar-design/stacks/react.md +12 -0
  122. package/skills/showdar-design/stacks/svelte.md +11 -0
  123. package/skills/showdar-design/stacks/swiftui.md +12 -0
  124. package/skills/showdar-design/stacks/tauri.md +12 -0
  125. package/skills/showdar-design/stacks/vue.md +12 -0
  126. package/skills/showdar-git/SKILL.md +291 -0
  127. package/skills/showdar-git/data/git-workflows.csv +7 -0
  128. package/skills/showdar-git/data/index.json +14 -0
  129. package/skills/showdar-git/examples/commit-task-only.md +15 -0
  130. package/skills/showdar-git/examples/conflict-stop.md +7 -0
  131. package/skills/showdar-git/examples/explicit-push.md +7 -0
  132. package/skills/showdar-git/examples/feature-merge-no-push.md +13 -0
  133. package/skills/showdar-git/references/operation-safety.md +34 -0
  134. package/skills/showdar-git/scripts/inspect-git-state.mjs +53 -0
  135. package/skills/showdar-ops/SKILL.md +160 -0
  136. package/skills/showdar-ops/data/index.json +14 -0
  137. package/skills/showdar-ops/data/ops-patterns.csv +12 -0
  138. package/skills/showdar-ops/examples/explicit-deployment.md +5 -0
  139. package/skills/showdar-ops/examples/fix-existing-ci.md +5 -0
  140. package/skills/showdar-ops/examples/inspect-ci-readonly.md +7 -0
  141. package/skills/showdar-ops/examples/rollback-plan.md +5 -0
  142. package/skills/showdar-ops/examples/staging-plan.md +5 -0
  143. package/skills/showdar-ops/references/ci-cd.md +5 -0
  144. package/skills/showdar-ops/references/containers.md +5 -0
  145. package/skills/showdar-ops/references/deployment.md +5 -0
  146. package/skills/showdar-ops/references/desktop-release.md +3 -0
  147. package/skills/showdar-ops/references/environments.md +5 -0
  148. package/skills/showdar-ops/references/mobile-release.md +3 -0
  149. package/skills/showdar-ops/references/observability.md +5 -0
  150. package/skills/showdar-ops/references/rollback.md +5 -0
  151. package/skills/showdar-ops/scripts/inspect-ops-state.mjs +54 -0
  152. package/skills/showdar-plan/SKILL.md +159 -0
  153. package/skills/showdar-plan/data/index.json +14 -0
  154. package/skills/showdar-plan/data/planning-checklists.csv +25 -0
  155. package/skills/showdar-plan/examples/feature-plan.md +19 -0
  156. package/skills/showdar-plan/references/architecture.md +5 -0
  157. package/skills/showdar-plan/references/requirements.md +5 -0
  158. package/skills/showdar-plan/references/risk-analysis.md +5 -0
  159. package/skills/showdar-plan/references/scope.md +5 -0
  160. package/skills/showdar-plan/references/task-decomposition.md +5 -0
  161. package/skills/showdar-plan/scripts/collect-planning-context.mjs +9 -0
  162. package/skills/showdar-plan/scripts/lib/detect-stack.mjs +48 -0
  163. package/skills/showdar-plan/stacks/backend.md +3 -0
  164. package/skills/showdar-plan/stacks/mobile.md +3 -0
  165. package/skills/showdar-plan/stacks/web.md +3 -0
  166. package/skills/showdar-quality/SKILL.md +166 -0
  167. package/skills/showdar-quality/data/index.json +14 -0
  168. package/skills/showdar-quality/data/quality-patterns.csv +11 -0
  169. package/skills/showdar-quality/references/qa-guide.md +20 -0
  170. package/skills/showdar-recover/SKILL.md +164 -0
  171. package/skills/showdar-recover/data/index.json +14 -0
  172. package/skills/showdar-recover/data/recovery-signals.csv +23 -0
  173. package/skills/showdar-recover/examples/recovery-report.md +18 -0
  174. package/skills/showdar-recover/references/failed-runs.md +3 -0
  175. package/skills/showdar-recover/references/interrupted-session.md +3 -0
  176. package/skills/showdar-recover/references/merge-conflicts.md +3 -0
  177. package/skills/showdar-recover/references/partial-implementation.md +3 -0
  178. package/skills/showdar-recover/scripts/inspect-state.mjs +5 -0
  179. package/skills/showdar-requirements/SKILL.md +172 -0
  180. package/skills/showdar-requirements/data/index.json +14 -0
  181. package/skills/showdar-requirements/data/requirements-patterns.csv +11 -0
  182. package/skills/showdar-requirements/references/analysis-guide.md +30 -0
  183. package/skills/showdar-review/SKILL.md +155 -0
  184. package/skills/showdar-review/data/index.json +14 -0
  185. package/skills/showdar-review/data/review-patterns.csv +27 -0
  186. package/skills/showdar-review/examples/finding.md +16 -0
  187. package/skills/showdar-review/references/architecture.md +3 -0
  188. package/skills/showdar-review/references/correctness.md +3 -0
  189. package/skills/showdar-review/references/maintainability.md +3 -0
  190. package/skills/showdar-review/references/performance.md +3 -0
  191. package/skills/showdar-review/references/security.md +3 -0
  192. package/skills/showdar-review/references/testing.md +3 -0
  193. package/skills/showdar-review/scripts/collect-diff.mjs +5 -0
  194. package/skills/showdar-review/stacks/android.md +3 -0
  195. package/skills/showdar-review/stacks/flutter.md +3 -0
  196. package/skills/showdar-review/stacks/ios.md +3 -0
  197. package/skills/showdar-review/stacks/nextjs.md +3 -0
  198. package/skills/showdar-review/stacks/node-backend.md +3 -0
  199. package/skills/showdar-review/stacks/react-native.md +3 -0
  200. package/skills/showdar-review/stacks/react.md +3 -0
  201. package/skills/showdar-review/stacks/swift-kotlin.md +3 -0
  202. package/skills/showdar-review/stacks/typescript.md +3 -0
  203. package/skills/showdar-security/SKILL.md +169 -0
  204. package/skills/showdar-security/data/index.json +14 -0
  205. package/skills/showdar-security/data/security-patterns.csv +13 -0
  206. package/skills/showdar-security/examples/api-authorization-review.md +9 -0
  207. package/skills/showdar-security/examples/mobile-deeplink-review.md +7 -0
  208. package/skills/showdar-security/examples/secret-exposure-review.md +5 -0
  209. package/skills/showdar-security/examples/threat-model-open-assumptions.md +11 -0
  210. package/skills/showdar-security/references/authz-secrets.md +7 -0
  211. package/skills/showdar-security/references/mobile-security.md +7 -0
  212. package/skills/showdar-security/references/supply-chain.md +5 -0
  213. package/skills/showdar-security/references/threat-modeling.md +12 -0
  214. package/skills/showdar-security/scripts/inspect-security-surface.mjs +47 -0
  215. package/skills/showdar-ship/SKILL.md +234 -0
  216. package/skills/showdar-ship/data/index.json +14 -0
  217. package/skills/showdar-ship/data/release-checks.csv +28 -0
  218. package/skills/showdar-ship/examples/release-report.md +25 -0
  219. package/skills/showdar-ship/references/migrations.md +12 -0
  220. package/skills/showdar-ship/references/post-deploy.md +12 -0
  221. package/skills/showdar-ship/references/release-readiness.md +13 -0
  222. package/skills/showdar-ship/references/rollback.md +12 -0
  223. package/skills/showdar-ship/references/secrets.md +3 -0
  224. package/skills/showdar-ship/scripts/detect-targets.mjs +5 -0
  225. package/skills/showdar-ship/scripts/lib/detect-stack.mjs +48 -0
  226. package/skills/showdar-ship/scripts/release-check.mjs +6 -0
  227. package/skills/showdar-ship/stacks/android.md +33 -0
  228. package/skills/showdar-ship/stacks/docker.md +30 -0
  229. package/skills/showdar-ship/stacks/electron.md +7 -0
  230. package/skills/showdar-ship/stacks/ios.md +34 -0
  231. package/skills/showdar-ship/stacks/nextjs.md +30 -0
  232. package/skills/showdar-ship/stacks/node-backend.md +37 -0
  233. package/skills/showdar-ship/stacks/orchestration.md +12 -0
  234. package/skills/showdar-ship/stacks/tauri.md +35 -0
  235. package/skills/showdar-ship/stacks/web.md +35 -0
  236. package/skills/showdar-test/SKILL.md +164 -0
  237. package/skills/showdar-test/data/index.json +14 -0
  238. package/skills/showdar-test/data/test-strategy.csv +22 -0
  239. package/skills/showdar-test/examples/regression.md +14 -0
  240. package/skills/showdar-test/references/e2e.md +3 -0
  241. package/skills/showdar-test/references/integration.md +3 -0
  242. package/skills/showdar-test/references/regression.md +3 -0
  243. package/skills/showdar-test/references/test-smells.md +3 -0
  244. package/skills/showdar-test/references/unit.md +3 -0
  245. package/skills/showdar-test/scripts/detect-test-tools.mjs +6 -0
  246. package/skills/showdar-test/stacks/android-testing.md +13 -0
  247. package/skills/showdar-test/stacks/detox.md +13 -0
  248. package/skills/showdar-test/stacks/flutter-test.md +13 -0
  249. package/skills/showdar-test/stacks/integration-test.md +13 -0
  250. package/skills/showdar-test/stacks/jest.md +13 -0
  251. package/skills/showdar-test/stacks/playwright.md +13 -0
  252. package/skills/showdar-test/stacks/react-native-testing.md +17 -0
  253. package/skills/showdar-test/stacks/react-testing-library.md +13 -0
  254. package/skills/showdar-test/stacks/vitest.md +13 -0
  255. package/skills/showdar-test/stacks/xctest.md +13 -0
  256. package/skills/showdar-understand/SKILL.md +159 -0
  257. package/skills/showdar-understand/data/architecture-signals.csv +28 -0
  258. package/skills/showdar-understand/data/index.json +14 -0
  259. package/skills/showdar-understand/examples/repository-audit.md +17 -0
  260. package/skills/showdar-understand/references/architecture-signals.md +25 -0
  261. package/skills/showdar-understand/references/dependency-analysis.md +9 -0
  262. package/skills/showdar-understand/references/repository-analysis.md +24 -0
  263. package/skills/showdar-understand/scripts/inspect-repo.mjs +16 -0
  264. package/skills/showdar-understand/scripts/lib/detect-stack.mjs +48 -0
  265. package/skills/showdar-understand/stacks/android.md +3 -0
  266. package/skills/showdar-understand/stacks/backend.md +5 -0
  267. package/skills/showdar-understand/stacks/electron.md +3 -0
  268. package/skills/showdar-understand/stacks/fastify.md +3 -0
  269. package/skills/showdar-understand/stacks/flutter.md +3 -0
  270. package/skills/showdar-understand/stacks/ios.md +3 -0
  271. package/skills/showdar-understand/stacks/mobile.md +5 -0
  272. package/skills/showdar-understand/stacks/nestjs.md +3 -0
  273. package/skills/showdar-understand/stacks/nextjs.md +3 -0
  274. package/skills/showdar-understand/stacks/node.md +3 -0
  275. package/skills/showdar-understand/stacks/react-native.md +3 -0
  276. package/skills/showdar-understand/stacks/react.md +3 -0
  277. package/skills/showdar-understand/stacks/tauri.md +3 -0
  278. package/skills/showdar-upgrade/SKILL.md +162 -0
  279. package/skills/showdar-upgrade/data/compatibility-checklist.csv +24 -0
  280. package/skills/showdar-upgrade/data/index.json +14 -0
  281. package/skills/showdar-upgrade/examples/upgrade-report.md +18 -0
  282. package/skills/showdar-upgrade/references/breaking-changes.md +3 -0
  283. package/skills/showdar-upgrade/references/compatibility.md +3 -0
  284. package/skills/showdar-upgrade/references/dependency-resolution.md +3 -0
  285. package/skills/showdar-upgrade/references/migration-strategy.md +3 -0
  286. package/skills/showdar-upgrade/references/rollback.md +3 -0
  287. package/skills/showdar-upgrade/scripts/inspect-dependencies.mjs +6 -0
  288. package/skills/showdar-upgrade/scripts/lib/detect-stack.mjs +48 -0
  289. package/skills/showdar-upgrade/stacks/android.md +15 -0
  290. package/skills/showdar-upgrade/stacks/cocoapods-spm.md +17 -0
  291. package/skills/showdar-upgrade/stacks/expo.md +17 -0
  292. package/skills/showdar-upgrade/stacks/flutter.md +17 -0
  293. package/skills/showdar-upgrade/stacks/gradle.md +13 -0
  294. package/skills/showdar-upgrade/stacks/ios.md +15 -0
  295. package/skills/showdar-upgrade/stacks/nextjs.md +17 -0
  296. package/skills/showdar-upgrade/stacks/node.md +17 -0
  297. package/skills/showdar-upgrade/stacks/react-native.md +17 -0
  298. package/skills/showdar-upgrade/stacks/react.md +17 -0
  299. package/skills/showdar-upgrade/stacks/tauri-rust.md +15 -0
  300. package/src/adapters.js +44 -0
  301. package/src/catalog.js +57 -0
  302. package/src/project.js +287 -0
  303. package/src/runtime.js +9 -0
  304. package/src/validate.js +310 -0
@@ -0,0 +1,155 @@
1
+ ---
2
+ name: showdar-review
3
+ description: Use when reviewing code or diffs for general correctness, architecture, performance, maintainability, or tests.
4
+ ---
5
+
6
+ # Showdar Review
7
+
8
+ ## Purpose
9
+
10
+ - Find defects and material engineering risks in a change without inventing style complaints.
11
+ - Prioritize reachable correctness/security failures over cosmetic preferences.
12
+ - Review the changed behavior in repository context, not isolated diff syntax.
13
+ - Produce actionable findings with location, evidence, impact, and recommended correction.
14
+ - Use `data/review-patterns.csv` as a risk prompt, not as an automatic lint rule.
15
+
16
+ ## When to use
17
+
18
+ - Reviewing a pull request, branch, staged/uncommitted diff, or proposed patch.
19
+ - Pre-merge quality pass after implementation/tests.
20
+ - Focused security/performance/architecture review of changed paths.
21
+ - Evaluating whether tests prove the behavior introduced by a change.
22
+
23
+ ## When not to use
24
+
25
+ - The user asks to implement the change rather than review it.
26
+ - There is no concrete code/change/design to inspect.
27
+ - Do not turn code review into a repository-wide refactoring wishlist.
28
+ - Formatter/linter-owned style issues are out of scope unless they hide correctness.
29
+
30
+ ## Inputs and assumptions
31
+
32
+ - Base/reference revision or the current change set.
33
+ - Repository instructions and relevant surrounding source/tests.
34
+ - Use `scripts/collect-diff.mjs` to collect a read-only diff summary when appropriate.
35
+ - A finding is valid only when a concrete scenario shows the risk is reachable.
36
+ - Existing repository conventions matter; do not impose a different architecture by preference.
37
+
38
+ ## Non-negotiable rules
39
+
40
+ - Do not invent findings.
41
+ - Every finding includes exact location, evidence, impact, and recommended change.
42
+ - Severity reflects user/system impact and likelihood, not reviewer taste.
43
+ - Review changed behavior plus the minimum surrounding context needed to validate assumptions.
44
+ - Security/auth checks must be verified server/owner-side; client checks are not sufficient policy proof.
45
+ - Do not spend review budget on formatting already automated.
46
+ - If no material findings exist, say so and mention residual verification limits.
47
+
48
+ ## Workflow
49
+
50
+ ### Phase 1 — understand intent and diff
51
+ - Identify intended behavior and changed files/symbols.
52
+ - Read tests and nearby ownership boundaries before judging implementation.
53
+ - Note generated/vendor changes separately.
54
+
55
+ ### Phase 2 — correctness pass
56
+ - Apply `references/correctness.md` to inputs, state transitions, ordering, lifecycle, errors, serialization, nullability, concurrency, and edge cases.
57
+ - Trace at least one happy path and one important failure path.
58
+
59
+ ### Phase 3 — security and data pass
60
+ - Apply `references/security.md` where auth, input, secrets, storage, networking, files, URLs, or sensitive data are touched.
61
+ - Check authorization at authoritative boundaries.
62
+
63
+ ### Phase 4 — architecture and maintainability pass
64
+ - Apply `references/architecture.md` and `references/maintainability.md`.
65
+ - Check policy ownership, dependency direction, public contracts, type safety, and complexity introduced.
66
+
67
+ ### Phase 5 — performance pass
68
+ - Apply `references/performance.md` to realistic hot paths/scales.
69
+ - Look for N+1, event-loop/thread blocking, render/rebuild churn, image/bundle/memory cost.
70
+
71
+ ### Phase 6 — tests pass
72
+ - Apply `references/testing.md`.
73
+ - Ask whether tests can fail for the real changed behavior and critical regression. Use `data/review-patterns.csv` as a searchable prompt across correctness, architecture, security, performance, concurrency, data integrity, API design, state, mobile lifecycle, accessibility, testing, observability, and maintainability.
74
+
75
+ ### Phase 7 — severity and dedupe
76
+ - Merge findings with the same root cause.
77
+ - Assign P0/P1/P2/P3 only after impact is clear.
78
+ - Drop speculative issues that lack a reachable scenario.
79
+
80
+ ## Decision points
81
+
82
+ - P0: exploitable/critical data loss/outage or universally blocking defect with immediate action required.
83
+ - P1: high-impact correctness/security/performance issue likely in realistic use.
84
+ - P2: material edge-case/maintainability/test gap that can produce defects but is not immediately severe.
85
+ - P3: worthwhile improvement with low defect risk; use sparingly.
86
+ - Existing pattern imperfect but safe? Do not demand redesign unless the change worsens it or violates requirement.
87
+ - Potential issue depends on impossible caller/state? Drop the finding.
88
+
89
+ ## Stack detection
90
+
91
+ - TypeScript: `stacks/typescript.md` for unsafe casts/external data/impossible state.
92
+ - React Native: `stacks/react-native.md` for lifecycle/list/native/accessibility/release surfaces.
93
+ - Flutter: `stacks/flutter.md` for rebuild/async/layout/disposal/platform concerns.
94
+ - Node backend: `stacks/node-backend.md` for auth/idempotency/transaction/event-loop/resource concerns.
95
+ - Unsupported stack: inspect framework lifecycle and repository conventions before applying generic concerns.
96
+
97
+ ## Failure modes
98
+
99
+ - Commenting on naming/formatting while missing auth or state defects.
100
+ - Severity inflation: every finding labeled blocking.
101
+ - “Could maybe” findings with no concrete input/state path.
102
+ - Reviewing diff only and missing surrounding contract/owner.
103
+ - Requesting abstraction because reviewer prefers a pattern.
104
+ - Missing generated/native/deployment impact of a small source change.
105
+ - Treating test count as evidence of test quality.
106
+
107
+ ## Stop conditions
108
+
109
+ - Stop when the requested outcome is outside this skill and hand off to the more appropriate workflow.
110
+ - Stop before destructive, irreversible, production, credential, publishing, or deployment actions unless the user explicitly approved them.
111
+ - Stop when required evidence is unavailable and proceeding would require guessing about behavior, ownership, or safety.
112
+ - Stop when a repository instruction conflicts with this playbook; repository/user instructions win.
113
+ - Stop when all changed behavior has received correctness plus relevant security/architecture/performance/test passes and findings are deduplicated/evidence-backed.
114
+
115
+ ## Escalation conditions
116
+
117
+ - Escalate suspected critical security/data-loss issues with clear evidence and avoid exploit amplification beyond what is needed to explain remediation.
118
+ - Ask for missing base/diff/context when it prevents judging behavior.
119
+ - If change is too large to review reliably, split by subsystem/commit and state the review boundary.
120
+ - If generated code dominates, identify source generator/inputs before reviewing generated diffs line-by-line.
121
+
122
+ ## Verification
123
+
124
+ - Re-read every finding and identify the exact execution/input path that triggers it.
125
+ - Confirm referenced line/symbol exists in the current change/context.
126
+ - Check whether existing tests or guards already invalidate the finding.
127
+ - Verify severity matches impact/likelihood.
128
+ - Remove duplicate/style-only/speculative findings.
129
+ - If claiming clean review, state what was and was not executed/tested.
130
+
131
+ ## Output contract
132
+
133
+ - Findings ordered P0 -> P3.
134
+ - Each finding: **severity/title**, **location**, **evidence**, **impact/scenario**, **recommended change**.
135
+ - After findings: brief **verification gaps/residual risk** if relevant.
136
+ - If no findings: say no material findings found and state unverified areas.
137
+ - Keep praise/summary secondary; findings are the primary review artifact.
138
+
139
+ ## Anti-patterns
140
+
141
+ - Nitpicking formatter-owned style.
142
+ - Inventing a bug from an unfamiliar API without checking its contract.
143
+ - Reviewing architecture as if repository were greenfield.
144
+ - P0/P1 severity without realistic impact.
145
+ - Recommending “add tests” without naming missing invariant.
146
+ - Large code rewrite suggestion when a local correctness fix is sufficient.
147
+
148
+ ## Example
149
+
150
+ **P1 — authorization missing on export endpoint**
151
+ - Location: route handler.
152
+ - Evidence: authentication exists but workspace membership check used by sibling endpoints is absent.
153
+ - Impact: authenticated user with another workspace ID can request export.
154
+ - Recommendation: enforce server-side membership policy and add cross-workspace integration test.
155
+ - See `examples/finding.md`.
@@ -0,0 +1,14 @@
1
+ {
2
+ "version": 1,
3
+ "skill": "showdar-review",
4
+ "datasets": [
5
+ {
6
+ "file": "data/review-patterns.csv",
7
+ "idField": "id",
8
+ "requiredColumns": ["id", "category", "pattern", "risk", "evidence", "good", "bad", "severity", "false_positive_notes", "tags", "reference", "stack"],
9
+ "searchableFields": ["category", "pattern", "risk", "evidence", "good", "bad", "false_positive_notes", "tags"],
10
+ "filterFields": ["category", "severity", "stack"],
11
+ "reference": "references/correctness.md"
12
+ }
13
+ ]
14
+ }
@@ -0,0 +1,27 @@
1
+ id,category,pattern,risk,evidence,good,bad,severity,false_positive_notes,tags,reference,stack
2
+ correctness-null,correctness,unchecked external null,invalid input crashes or corrupts state,reachable payload and missing-field path,narrow validate and return typed error,cast and dereference directly,P1,known non-null internal invariant with proof is not a finding,nullability,references/correctness.md,typescript
3
+ correctness-error,correctness,error path loses state,failed operation leaves UI or data falsely successful,inject failure and inspect state transition,preserve failed state and recovery action,catch then show success,P1,logging-only catch with propagated error is acceptable,error state,references/correctness.md,*
4
+ correctness-order,correctness,ordering assumption,completion order changes result or side effect,controlled interleaving or event trace,version/cancel/idempotency guard,last callback wins,P1,serial execution proven by owner contract is safe,ordering,references/correctness.md,*
5
+ correctness-boundary,correctness,off-by-one or empty boundary,first last empty or maximum item behaves wrong,table of boundary inputs,explicit boundary tests,only typical input tested,P2,unreachable values should be excluded by validated contract,boundary,references/correctness.md,*
6
+ architecture-owner,architecture,policy in wrong owner,duplicate policy diverges across callers,call graph and sibling behavior,centralize at actual owner,caller-specific patches,P1,local policy is fine when callers intentionally differ,ownership,references/architecture.md,*
7
+ architecture-cycle,architecture,new dependency cycle,initialization and change surface become coupled,imports or package graph,break cycle at stable contract,add another barrel or service,P1,type-only cycle with no runtime effect may be lower risk,dependency cycle,references/architecture.md,typescript
8
+ architecture-abstraction,architecture,abstraction without leverage,indirection hides one simple behavior,new layer has one consumer,keep local or show volatility boundary,generic factory and interface,P2,second consumer or real plugin boundary can justify it,abstraction,references/maintainability.md,*
9
+ security-authz,security,authorization only in client,API can be called without policy,request route lacks owner-side check,enforce policy at server/service,disable button or hide route,P0,public endpoint with no protected resource is not an authz gap,authorization,references/security.md,node
10
+ security-input,security,unvalidated trust input,injection path or malformed data reaches interpreter,request/file/query value flow,validate and parameterize at boundary,regex or UI validation only,P0,validated typed internal values need no duplicate parser,input validation,references/security.md,node
11
+ security-secret,security,secret in log/artifact,credential or personal data exposure,log/build/diff contains value,redact and verify by name/metadata,print env or token,P0,public non-sensitive build metadata is not a secret,secret handling,references/security.md,*
12
+ security-path,security,unbounded path or URL,SSRF traversal or arbitrary file access,attacker controls path/host and sink,allowlist resolve and constrain path,concatenate user value into sink,P0,static trusted path with no attacker input is safe,path security,references/security.md,node
13
+ performance-loop,performance,I/O or query inside loop,N+1 latency and load,query count grows with item count,batch or prefetch with measured bound,add cache without invalidation,P1,small bounded list with explicit product limit may be acceptable,n-plus-one,references/performance.md,node
14
+ performance-render,performance,broad render state,typing/list interaction misses frame budget,profiler render count and data size,narrow owner or virtualization after measurement,memoize every subtree,P1,measured small subtree with budget proof is not a finding,render churn,references/performance.md,react
15
+ performance-event-loop,performance,synchronous heavy work on event loop,all requests stall,profile or input-size growth,stream worker or chunk work,add timeout around blocking call,P1,small bounded work should be stated as such,event loop,references/performance.md,node
16
+ performance-memory,performance,resource retained across lifecycle,memory grows with repeated flow,heap/listener/image/resource delta,dispose and bound cache,raise memory limit,P1,transient allocation returning to baseline is not retention,memory,references/performance.md,react-native
17
+ concurrency-lost-update,concurrency,read-modify-write without lock,lost update or duplicate effect,two overlapping callers and final state,transaction/version/unique constraint,check then write without guard,P1,serialized owner with documented lock is safe,lost update,references/correctness.md,node
18
+ concurrency-retry,concurrency,retry repeats effect,network timeout leaves unknown commit and retry duplicates,request id and durable effect,idempotency key and safe retry,retry every mutation,P1,idempotent operation with proof is not a finding,idempotency,references/correctness.md,*
19
+ data-transaction,data integrity,related writes not atomic,partial state after error,fail second write and inspect DB,one transaction or compensating action,separate commits with no recovery,P1,eventually consistent workflow must document repair path,transaction,references/correctness.md,node
20
+ data-migration,data integrity,destructive schema change,old app or rollback cannot read data,old/new schema compatibility,expand migrate contract,drop/rename in one rollout,P1,offline one-shot system with backup and explicit version gate may differ,migration,references/architecture.md,*
21
+ api-validation,api design,ambiguous error contract,clients cannot recover consistently,status/body mismatch and callers,stable error code and validation shape,throw arbitrary string,P1,internal function with typed domain error may not need HTTP shape,error contract,references/correctness.md,node
22
+ api-versioning,api design,breaking response without migration,old consumer fails on deploy,consumer versions and fixture,additive/versioned change and contract test,remove field silently,P1,all consumers atomically versioned can avoid compatibility window,compatibility,references/architecture.md,*
23
+ mobile-disposal,mobile,async callback after disposal,crash or stale navigation,await crosses unmount/dispose and writes state,cancel/guard lifecycle and test leave-enter,ignore cancellation,P1,operation owned by process lifetime not screen is safe,lifecycle,references/maintainability.md,react-native
24
+ mobile-accessibility,mobile,custom control lacks semantics,screen reader or keyboard cannot operate,role/name/state/focus inspection,native control or complete semantics,clickable visual-only container,P1,decorative noninteractive element is not a finding,accessibility,references/testing.md,react-native
25
+ tests-mock,testing,mock-only behavior proof,regression passes while real boundary is broken,test never observes output/state,assert observable behavior at lowest real level,assert only mock call,P2,mock is valid for unavailable nondeterministic external system,mocks,references/testing.md,*
26
+ tests-flaky,testing,arbitrary sleep or retry hides flake,slow nondeterministic CI and masked race,timing primitive and retry config,barrier/event/state synchronization,increase timeout or retry,P2,documented bounded polling of external state can be valid,flaky,references/testing.md,playwright
27
+ observability-correlation,observability,operation lacks correlation,incident cannot join request/job/logs,request or job path without id,propagate redacted correlation and outcome,log raw payload only,P2,local pure function need not create correlation,diagnostics,references/maintainability.md,node
@@ -0,0 +1,16 @@
1
+ # Example finding
2
+
3
+ Severity: P1 — authorization missing on export endpoint.
4
+
5
+ Location: `routes/export.ts`, before the export job is queued.
6
+
7
+ Evidence: the handler checks authentication but never verifies workspace
8
+ membership. Sibling read endpoints call `requireWorkspaceMember`, while this
9
+ route accepts a caller-provided workspace ID and starts a long-running job.
10
+
11
+ Impact: any authenticated user who guesses a workspace ID can request its data.
12
+ The issue is exploitable without a client bug and should block release.
13
+
14
+ Recommended fix: enforce the shared membership policy before queueing work,
15
+ return the existing forbidden response, and add an integration test for a user
16
+ from another workspace. Re-check that logs and job payloads do not expose data.
@@ -0,0 +1,3 @@
1
+ # Architecture review
2
+
3
+ Check ownership and dependency direction, public contract changes, duplicated policy, cross-layer leakage, lifecycle, generated/native ownership, and whether a new abstraction earns its cost. Trace one producer-to-consumer path and one failure path. Do not demand a preferred pattern when the existing design is coherent and safe; report only a reachable defect or material risk introduced by the change.
@@ -0,0 +1,3 @@
1
+ # Correctness review
2
+
3
+ Trace changed behavior through inputs, state transitions, failure paths, concurrency, lifecycle, and outputs. Check invalid assumptions, missing branches, stale state, ordering, boundary values, nullability, serialization mismatch, retry/idempotency, and resource leaks. A finding needs a concrete reachable input/state path, evidence in the current code, impact, and a correction that preserves the intended contract.
@@ -0,0 +1,3 @@
1
+ # Maintainability review
2
+
3
+ Prefer clear contracts, local reasoning, typed state, explicit error behavior, and testable boundaries. Flag complexity that materially raises defect risk; skip personal style preferences already owned by formatter/linter.
@@ -0,0 +1,3 @@
1
+ # Performance review
2
+
3
+ Review named hot paths, algorithmic growth, repeated I/O, N+1 queries, render/rebuild churn, image/bundle cost, event-loop/main-thread blocking, memory retention, and unnecessary network work. Require realistic workload or profiler evidence where possible. Prioritize a measurable regression with user impact over generic optimization preference; state the scale at which it matters.
@@ -0,0 +1,3 @@
1
+ # Security review
2
+
3
+ Inspect authentication and authorization at the authoritative owner, input validation, injection, secret handling, sensitive logging, insecure storage, SSRF/file/path handling, dependency trust, mobile deep links, IPC/capabilities, and data exposure. Follow attacker-controlled input to a sink and state prerequisites. Distinguish a reachable exploit from a theoretical concern; do not report client-only visibility as security enforcement.
@@ -0,0 +1,3 @@
1
+ # Testing review
2
+
3
+ Ask whether tests can fail for the right regression. Check missing critical branch/contract coverage, fragile mocks, non-determinism, timing sleeps/retries, leaked state, and whether changed behavior has proof at the lowest effective level. Name the missing invariant and the smallest test boundary that would catch it. Do not equate test count, snapshots, or coverage percentage with behavior proof.
@@ -0,0 +1,5 @@
1
+ #!/usr/bin/env node
2
+ import { spawnSync } from 'node:child_process';
3
+ const cwd=process.argv[2]??process.cwd(); const base=process.argv[3]??'HEAD';
4
+ const run=a=>{const r=spawnSync('git',a,{cwd,encoding:'utf8'});return r.status===0?r.stdout.trim():null};
5
+ console.log(JSON.stringify({base,status:run(['status','--short']),files:run(['diff','--name-only',base])?.split('\n').filter(Boolean)??[],stat:run(['diff','--stat',base]),diff:run(['diff','--no-ext-diff','--unified=3',base])},null,2));
@@ -0,0 +1,3 @@
1
+ # Android review
2
+
3
+ Check lifecycle-aware coroutines, state restoration, main-thread work, permissions, manifest/resources, navigation, accessibility, and process death. Review Gradle/AGP/JDK and release/R8/signing impact when native configuration changes. Require a reachable scenario for each finding.
@@ -0,0 +1,3 @@
1
+ # Flutter review
2
+
3
+ Review state ownership/rebuild scope, async lifecycle guards, constraints/layout overflow, list laziness, platform channels, disposal, semantics/text scaling, and native runner impact.
@@ -0,0 +1,3 @@
1
+ # iOS review
2
+
3
+ Review lifecycle/task cancellation, data decoding, thread/actor ownership, permissions, deep links, accessibility, and native package/config changes. Check scheme, deployment target, entitlements, privacy usage, and release diagnostics when touched. Do not infer a signing defect from source-only changes without target evidence.
@@ -0,0 +1,3 @@
1
+ # Next.js review
2
+
3
+ Check server/client boundaries, route handlers, authorization, cache/revalidation, hydration determinism, metadata, image cost, and route loading/error behavior. A client guard is not authorization. A successful build does not prove runtime cache or environment behavior; ask for route-level evidence.
@@ -0,0 +1,3 @@
1
+ # Node backend review
2
+
3
+ Review request validation, authz, idempotency, transactions, pool/resource cleanup, event-loop blocking, retry semantics, observability, shutdown, and migration compatibility.
@@ -0,0 +1,3 @@
1
+ # React Native review
2
+
3
+ Review lifecycle/navigation, list virtualization, unstable render inputs, image cost, native module/API compatibility, permissions, keyboard/safe-area behavior, and release-native changes.
@@ -0,0 +1,3 @@
1
+ # React review
2
+
3
+ Review state ownership, effect synchronization, stable keys, hydration, semantic HTML, focus, and data-fetching boundaries. Require a concrete stale-state, accessibility, or render-cost scenario before reporting. Distinguish derived state from an intentional user-editable draft.
@@ -0,0 +1,3 @@
1
+ # Swift and Kotlin review
2
+
3
+ Look for unsafely shared mutable state, cancellation leaks, unchecked decoded input, blocking main/UI work, and platform lifecycle violations. Prefer type narrowing, explicit ownership, structured concurrency, and tests at the affected boundary over broad defensive guards.
@@ -0,0 +1,3 @@
1
+ # TypeScript review
2
+
3
+ Watch unsound casts, `any` at boundaries, impossible union states, unchecked external data, promise/error typing, mutation of shared objects, and APIs that erase useful types. Prefer narrowing and explicit domain types over assertion chains.
@@ -0,0 +1,169 @@
1
+ ---
2
+ name: showdar-security
3
+ description: Use when assessing threat models, attack surfaces, trust boundaries, auth/authz, secrets, exposure, or exploitability.
4
+ ---
5
+
6
+ # Showdar Security
7
+
8
+ ## Purpose
9
+
10
+ - Perform evidence-backed security analysis, threat modeling, secure-design review, and implementation-security guidance.
11
+ - Follow sensitive data from requirements, code, configuration, architecture, dependencies, and runtime boundaries to its security outcome.
12
+ - Produce practical findings with affected assets, trust boundaries, impact, exploitability, remediation, residual risk, and verification.
13
+ - Use `data/security-patterns.csv` as a focused prompt set and load `references/threat-modeling.md` when modeling a larger flow.
14
+
15
+ ## When to use
16
+
17
+ - The user asks for a threat model, security posture review, attack-surface map, or secure-design review.
18
+ - A change involves authentication, authorization, sessions, tokens, secrets, credentials, sensitive data, storage, URLs, files, IPC, or permissions.
19
+ - The user asks to review an API for authz, IDOR/BOLA, injection, SSRF, XSS, CSRF, or data exposure risk.
20
+ - A mobile flow involves deep links, WebViews, local storage, biometrics, app lifecycle, or Android/iOS permission boundaries.
21
+ - A backend, desktop, dependency, supply-chain, or security-configuration change needs a security regression assessment.
22
+
23
+ ## When not to use
24
+
25
+ - Do not use this for general correctness, maintainability, architecture, performance, or test review; use `showdar-review`.
26
+ - Do not use this to diagnose the root cause of an observed crash or failure; use `showdar-debug`.
27
+ - Do not implement automated tests; use `showdar-test`. Do not own QA scenario or regression planning; use `showdar-quality`.
28
+ - Do not perform offensive exploitation, credential guessing, network attacks, destructive probes, or production changes by default.
29
+ - Do not treat a generic word such as “review” as security intent without security, auth, exposure, secret, threat, or exploitability context.
30
+
31
+ ## Inputs and assumptions
32
+
33
+ - Prefer the supplied requirement, change diff, repository instructions, architecture, schemas, handlers, state models, configuration, dependency manifests, and tests.
34
+ - Record the evidence boundary: files, commands, environments, versions, and runtime surfaces actually inspected.
35
+ - Never print secret values, tokens, keys, cookies, passwords, credentials, personal data, or sensitive payloads; report only redacted names, locations, and metadata.
36
+ - Separate confirmed issue, suspected risk, accepted control, unknown, and open decision. A code smell is not automatically an exploitable vulnerability.
37
+ - Preserve application constraints and existing security controls unless evidence shows they are unsafe or the user explicitly changes scope.
38
+
39
+ ## Non-negotiable rules
40
+
41
+ - Use evidence for every finding: location, data flow, reachable condition, affected asset, and trust boundary.
42
+ - Do not invent vulnerabilities, attacker capabilities, exploitability, severity, or stakeholder decisions that evidence does not support.
43
+ - Distinguish exploitability from theoretical weakness and state attacker prerequisites instead of claiming exploitability without proof.
44
+ - Explain impact, exploitability/preconditions, affected scope, bounded remediation, residual risk, and verification for actionable findings.
45
+ - Assign P0/P1/P2/P3 or Info only when impact and realistic reachability are sufficiently evidenced; do not label everything critical.
46
+ - Review authorization at the authoritative owner, not only client visibility or route guards. Check API authorization, IDOR/BOLA, role/tenant boundaries, and object ownership.
47
+ - Check validation and output handling for injection, unsafe deserialization, command execution, path traversal, file upload, SSRF, XSS, and CSRF where the stack makes them relevant.
48
+ - Check authentication, session/token lifecycle, refresh/revocation, credential exposure, secrets handling, storage, encryption use, sensitive logging, and privacy boundaries.
49
+ - Check mobile deep links, WebViews, local storage, biometric/auth flows, native permissions, and Android/iOS bridges; check Tauri/Electron IPC, capabilities, filesystem, and command boundaries.
50
+ - Check dependency and supply-chain risk, security configuration, permissions, and security regression coverage without adding offensive tooling.
51
+
52
+ ## Workflow
53
+
54
+ ### Phase 1: establish scope and evidence
55
+
56
+ 1. Identify the requested decision: threat model, review, checklist, remediation guidance, or regression verification.
57
+ 2. Map changed and reachable surfaces: actors, assets, entry points, data stores, integrations, jobs, native bridges, and runtime boundaries.
58
+ 3. Read only relevant source, configuration, schemas, manifests, tests, and existing security documentation; record what was not inspected.
59
+ 4. Redact sensitive values immediately. Keep filenames, variable names, hashes, and safe metadata only when they do not disclose secrets.
60
+
61
+ ### Phase 2: map the attack surface
62
+
63
+ - List assets and their confidentiality, integrity, availability, or privacy impact.
64
+ - Identify actors, authorization decisions, anonymous and authenticated entry points, and trust boundaries.
65
+ - Trace attacker-controlled input through validation, parsing, storage, logging, rendering, network calls, command execution, or filesystem access.
66
+ - Identify controls at the correct owner: server/API, backend service, native platform, desktop host, browser, or client UI.
67
+
68
+ ### Phase 3: assess practical threats
69
+
70
+ - Consider spoofing/authentication, tampering/integrity, repudiation/auditability, information disclosure, denial of service, and elevation of privilege when useful.
71
+ - Test reasoning against denial, expired/revoked sessions, duplicate requests, cross-tenant objects, malformed input, offline/retry state, deep-link impersonation, and permission changes.
72
+ - State the exact preconditions for a finding: attacker access, account role, network position, feature flag, platform, configuration, or user action.
73
+ - Classify each result as confirmed issue, suspected risk, control, unknown, or open decision.
74
+
75
+ ### Phase 4: prioritize and remediate
76
+
77
+ - Prefer the smallest fix that closes the actual trust-boundary or data-flow gap.
78
+ - Order work by realistic impact and exploitability, then by scope and verification cost.
79
+ - Preserve compatible behavior, migration constraints, and existing controls; call out when a safe fix requires a stakeholder or platform decision.
80
+ - Define a security regression check for each remediation and identify external evidence that remains unavailable.
81
+
82
+ ## Decision points
83
+
84
+ - Use a security review when concrete code, configuration, or architecture is available; use a threat model when actors, assets, and boundaries need to be made explicit first.
85
+ - Use a checklist only after identifying the context: auth, payments, upload, deep links, API endpoints, WebView, local storage, or desktop IPC.
86
+ - Treat missing authorization, data ownership, secret rotation, privacy, encryption, deletion, or production access rules as escalation items.
87
+ - Use P0/Critical for immediate severe impact with credible reachability, P1/High for realistic high-impact exposure, P2/Medium for material bounded risk, P3/Low for limited impact, and Info for evidence or hardening with no demonstrated vulnerability.
88
+ - Do not force CVSS, OWASP labels, or STRIDE terminology when a plain risk explanation is clearer.
89
+
90
+ ## Stack detection
91
+
92
+ - Web/Next.js: inspect browser/server boundaries, cookies, CSRF, XSS/output encoding, SSRF, cache/privacy, headers, and runtime configuration.
93
+ - Backend/API/Node: inspect schema validation, authorization, tenant/object ownership, idempotency, timeouts, deserialization, logging, persistence, and dependency exposure.
94
+ - React Native/Flutter/iOS/Android: inspect deep links, WebViews, local storage, biometrics, permission states, lifecycle, native bridges, signing boundaries, and supported OS behavior.
95
+ - Tauri/Electron: inspect IPC commands, capability policy, serialization, preload/context isolation, filesystem paths, shell/command execution, updater, and packaging permissions.
96
+ - Docker and CI/CD: inspect build context, image provenance, dependency installation, secret injection, token permissions, artifact exposure, and workflow trust boundaries without changing infrastructure by default.
97
+
98
+ ## Failure modes
99
+
100
+ - Calling a theoretical weakness exploitable without a reachable source-to-sink path or prerequisites.
101
+ - Treating client-side hiding as authorization, a dependency age as a vulnerability, or a missing scanner as proof of insecurity.
102
+ - Printing a secret while trying to prove secret exposure, or copying credentials into a report, command, fixture, or patch.
103
+ - Inflating severity, duplicating one root cause across many findings, or recommending a broad rewrite when a bounded control closes the gap.
104
+ - Reviewing only the named file while ignoring the authoritative authorization owner, trust boundary, or consuming caller.
105
+
106
+ ## Stop conditions
107
+
108
+ - Stop before declaring exploitability when the relevant code path, configuration, attacker prerequisite, or runtime boundary was not observed.
109
+ - Stop before suggesting production or destructive security changes when authorization, rollback, maintenance window, or data impact is unknown.
110
+ - Stop and report an open decision when a secure behavior depends on an unstated role, tenant, retention, consent, encryption, or platform policy.
111
+ - Stop before any offensive probe, credential access, network attack, or secret handling beyond redacted metadata; request separate explicit scope if required.
112
+
113
+ ## Escalation conditions
114
+
115
+ - Escalate credible credential, token, private-key, personal-data, payment, cross-tenant, command-execution, or production-integrity exposure immediately with redacted evidence.
116
+ - Escalate missing ownership or authorization rules, secret rotation responsibility, privacy/compliance requirements, encryption/key management, and unsupported platform/version decisions.
117
+ - Escalate suspected supply-chain compromise, malicious dependency behavior, tampered release artifact, or CI token over-privilege without attempting to investigate offensively.
118
+ - Escalate a conflict between current controls and supplied requirements instead of silently choosing the weaker interpretation.
119
+
120
+ ## Verification
121
+
122
+ - Re-check every finding against its source location, affected asset, trust boundary, preconditions, impact, and severity rationale.
123
+ - Verify that remediation closes the data-flow or authorization gap and does not expose new secrets, logs, permissions, or compatibility regressions.
124
+ - Add or request a deterministic security regression test at the right boundary; hand automated implementation to `showdar-test`.
125
+ - Separate local evidence from unavailable external evidence such as provider scans, penetration tests, mobile store review, production telemetry, or secret rotation confirmation.
126
+ - Report residual risk and unverified assumptions explicitly; never claim a clean security posture from a limited review.
127
+
128
+ ## Output contract
129
+
130
+ ### Security review
131
+
132
+ 1. Summary
133
+ 2. Attack surface
134
+ 3. Findings
135
+ 4. Severity
136
+ 5. Evidence
137
+ 6. Impact
138
+ 7. Remediation
139
+ 8. Residual risk
140
+ 9. Verification
141
+
142
+ Each finding includes status (`confirmed issue`, `suspected risk`, `control`, `unknown`, or `open decision`), affected asset/trust boundary, severity only when supported, exact redacted evidence, exploitability/preconditions, impact, remediation, and verification.
143
+
144
+ ### Threat model
145
+
146
+ Use the smallest useful set of: Assets, Actors, Trust boundaries, Entry points, Threats, Controls, Gaps, and Priority mitigations. Use STRIDE-like reasoning only when it improves coverage.
147
+
148
+ ### Security checklist
149
+
150
+ Choose only context-relevant checks for auth, payments, file upload, deep links, API endpoints, WebView, local storage, or desktop IPC. Mark each item observed, passed, failed, not applicable, or unknown, with evidence and an owner.
151
+
152
+ ## Anti-patterns
153
+
154
+ - “No issues found” without stating files, boundaries, evidence limits, and residual risk.
155
+ - One giant generic OWASP checklist that hides the actual changed data flow.
156
+ - Critical severity for every missing hardening control, scanner warning, or old dependency.
157
+ - Secret values, exploit payloads, credential guesses, destructive commands, or production changes in the report.
158
+ - Treating requirements, current behavior, and assumptions as the same security fact.
159
+ - Replacing the application architecture instead of fixing the smallest proven boundary failure.
160
+
161
+ ## Example
162
+
163
+ **Request:** “Review this API for authorization and data exposure risks.”
164
+
165
+ - **Evidence:** inspect route, handler, policy owner, object lookup, tenant filter, response serializer, logs, and tests; record exact paths without printing tokens or data.
166
+ - **Threat model:** authenticated user is an actor, account records are assets, API boundary is the entry point, and the authorization middleware-to-query boundary is the trust boundary.
167
+ - **Confirmed issue:** if a request-supplied object ID reaches a query without owner/tenant enforcement, report a confirmed IDOR/BOLA path with role and account prerequisites.
168
+ - **Remediation:** enforce owner/tenant authorization at the authoritative service boundary and add a cross-account regression test.
169
+ - **Residual risk:** provider WAF, production telemetry, and secret rotation remain unverified unless evidence was supplied.
@@ -0,0 +1,14 @@
1
+ {
2
+ "version": 1,
3
+ "skill": "showdar-security",
4
+ "datasets": [
5
+ {
6
+ "file": "data/security-patterns.csv",
7
+ "idField": "id",
8
+ "requiredColumns": ["id", "category", "prompt", "evidence", "output", "risk", "tags", "reference", "stack"],
9
+ "searchableFields": ["category", "prompt", "evidence", "output", "risk", "tags"],
10
+ "filterFields": ["category", "stack"],
11
+ "reference": "references/threat-modeling.md"
12
+ }
13
+ ]
14
+ }
@@ -0,0 +1,13 @@
1
+ id,category,prompt,evidence,output,risk,tags,reference,stack
2
+ threat-model,threat-model,What assets actors entry points and trust boundaries define this threat model?,requirements architecture data flow runtime boundaries,concise threat model with threats controls gaps and priority mitigations,unmapped boundaries hide practical attack paths,"threat model,attack surface,trust boundaries",references/threat-modeling.md,*
3
+ authz-review,authorization,Can the authoritative owner enforce role tenant and object authorization?,routes handlers policies queries serializers authorization tests,confirmed or suspected authz gap with IDOR/BOLA preconditions and remediation,client-only checks expose cross-account data,"authorization,IDOR BOLA,API authz",references/authz-secrets.md,node;nextjs
4
+ secrets-review,secrets,Where can credentials tokens keys or private data be exposed or logged?,env names CI config logs storage bundle and reports,redacted exposure finding with rotation owner and verification,secret values in reports create a second incident,"secrets,credentials,redaction,sensitive logging",references/authz-secrets.md,*
5
+ input-injection,input,Which untrusted inputs reach interpreters files URLs queries or rendered output?,schemas parsers sinks encoding and network/file calls,bounded injection SSRF XSS CSRF or path-risk analysis,untraced input reaches a dangerous sink,"input validation,injection,SSRF,XSS CSRF",references/authz-secrets.md,react;node;nextjs
6
+ mobile-deeplink,mobile,What happens when an untrusted deep link or WebView payload reaches a mobile action?,navigation intent filters WebView bridge local storage biometrics and permissions,platform-specific deep-link security review with lifecycle and recovery checks,web assumptions fail across mobile trust boundaries,"mobile deep link,WebView,local storage,biometric permissions",references/mobile-security.md,react-native;flutter;ios;android
7
+ api-exposure,api,Which API responses and errors reveal sensitive data across auth and tenant boundaries?,OpenAPI handlers serializers logs and integration tests,API data-exposure review with owner-side control and redacted evidence,overbroad responses leak private or cross-tenant data,"API authorization,sensitive data,tenant boundary",references/authz-secrets.md,node;nextjs
8
+ desktop-ipc,desktop,Which Tauri or Electron IPC commands cross into filesystem shell or native capabilities?,preload commands capability policy serialization and path validation,desktop boundary review with command and permission mitigations,renderer input can reach privileged native operations,"desktop IPC,command execution,filesystem permissions",references/mobile-security.md,tauri;electron
9
+ dependency-supply-chain,dependency,What dependency and build-chain trust assumptions affect this release?,lockfiles provenance install scripts CI permissions and artifacts,supply-chain risk with evidence and bounded controls,dependency age alone is not proof of a vulnerability,"dependency,supply chain,unsafe deserialization",references/supply-chain.md,node;docker
10
+ session-tokens,session,Are authentication session and refresh tokens validated rotated revoked and stored safely?,issuance refresh logout expiry storage cookies and tests,session lifecycle gaps with attacker prerequisites and regression evidence,stale or replayable tokens extend unauthorized access,"authentication,session tokens,refresh revocation",references/authz-secrets.md,react;node;react-native
11
+ storage-encryption,storage,Does sensitive data use appropriate storage and encryption boundaries?,database mobile storage key management backups and access policy,storage and encryption review with key ownership and residual risk,plaintext persistence expands compromise impact,"storage,encryption,key management,privacy",references/mobile-security.md,node;react-native;ios;android
12
+ security-regression,regression,Which security controls need deterministic regression coverage after this change?,changed boundary authz input data storage dependency and tests,security regression scope handed to showdar-test without claiming execution,security fixes regress when only happy paths are checked,"security regression,regression coverage,verification",references/threat-modeling.md,*
13
+ logging-privacy,logging,Do logs metrics traces and error responses avoid secrets and unnecessary personal data?,logging config telemetry serializers redaction tests and retention,privacy-safe observability review with redacted evidence,diagnostic output can become a data-exposure surface,"logging,privacy,data exposure",references/authz-secrets.md,node;react-native
@@ -0,0 +1,9 @@
1
+ # API authorization review
2
+
3
+ **Request:** Review an account endpoint for authorization and data exposure.
4
+
5
+ **Evidence:** Read the route, handler, policy owner, object lookup, tenant filter, serializer, logs, and tests. Record paths and redacted identifiers only.
6
+
7
+ **Finding format:** State whether the issue is confirmed or suspected, the affected account asset and API trust boundary, the caller role and prerequisites, impact, severity rationale, bounded remediation, residual risk, and verification.
8
+
9
+ **Example:** If a request ID reaches a lookup without owner/tenant enforcement, report the reachable IDOR/BOLA path and enforce authorization at the service boundary. Add a cross-account regression test through `showdar-test`; do not infer security from client-side route hiding.
@@ -0,0 +1,7 @@
1
+ # Mobile deep-link security review
2
+
3
+ **Scope:** Review a React Native deep link that opens a payment or account screen.
4
+
5
+ Check URL parsing, allowlisted hosts/routes, authentication state, token handoff, replay, WebView navigation, native intent filters, background/resume state, and local storage. Separate iOS and Android evidence.
6
+
7
+ Mark missing link ownership, permission, or authentication decisions as open questions. Do not open attacker-controlled links, access device credentials, or claim exploitability without a reachable path and prerequisites.
@@ -0,0 +1,5 @@
1
+ # Secret exposure and configuration review
2
+
3
+ Inspect environment file names, CI configuration, source history when in scope, bundles, logs, crash reports, examples, and telemetry configuration. Output only locations, variable names, hashes, or counts that do not disclose values.
4
+
5
+ For a suspected exposure, state evidence status, affected credential or data boundary, rotation owner, blast radius, and verification needed. Treat rotation and revocation as explicit operational actions; do not silently change credentials.
@@ -0,0 +1,11 @@
1
+ # Threat model with unresolved assumptions
2
+
3
+ **Assets:** account data and session tokens.
4
+
5
+ **Actors:** anonymous visitor, authenticated user, support operator, and service account as supplied or observed.
6
+
7
+ **Trust boundaries:** browser/mobile client to API, API to data store, and CI to release artifact.
8
+
9
+ **Threats and controls:** consider cross-account access, token replay, sensitive logs, malformed input, and artifact tampering; list only controls observed in code or configuration.
10
+
11
+ **Open questions:** who owns tenant authorization, which deep-link hosts are trusted, how long sessions remain valid, and who can rotate credentials. Do not convert these decisions into invented requirements.
@@ -0,0 +1,7 @@
1
+ # Authentication, authorization, and secrets
2
+
3
+ Inspect the authoritative owner of each decision. For APIs, follow identity and tenant/object IDs through middleware, service policy, query filters, serializers, and audit logs. Test the reasoning for anonymous, wrong-role, cross-tenant, expired, revoked, duplicate, and replayed requests.
4
+
5
+ For sessions and tokens, check issuance, audience, expiry, refresh, rotation, revocation, storage, cookie flags, deep-link handoff, logout, and error handling. For secrets, report only the variable or file name and location; never copy values into output. Check CI logs, bundles, source control, crash reports, telemetry, and examples as exposure surfaces.
6
+
7
+ Recommend the smallest owner-side fix and a regression check. Secret rotation, key ownership, privacy retention, and compliance decisions remain explicit open decisions when not supplied.
@@ -0,0 +1,7 @@
1
+ # Mobile, WebView, and desktop boundaries
2
+
3
+ For React Native, Flutter, iOS, and Android, inspect URL/deep-link parsing, intent filters, universal/app links, WebView navigation and bridges, local storage, biometric fallback, permission transitions, foreground/background state, screenshots, backups, and native bridge arguments.
4
+
5
+ For Tauri and Electron, inspect preload/context isolation, IPC command allowlists, capability policy, serialization, path normalization, shell execution, filesystem permissions, updater channels, signing, and renderer-to-host trust boundaries.
6
+
7
+ Split acceptance by platform and lifecycle. A client-side guard is not authoritative authorization. Keep device, signing, store, and production checks separate from local evidence.
@@ -0,0 +1,5 @@
1
+ # Dependency and supply-chain review
2
+
3
+ Inspect lockfiles, install scripts, registries, provenance, artifact integrity, dependency permissions, CI token scope, untrusted pull-request inputs, and build context. Distinguish known advisory evidence from an age or naming concern.
4
+
5
+ Recommend bounded controls such as pinned or reviewed versions, least-privilege tokens, protected publishing, reproducible artifacts, and reviewable update paths. Do not download suspicious packages, execute untrusted payloads, probe a network, or claim compromise without evidence.
@@ -0,0 +1,12 @@
1
+ # Threat modeling
2
+
3
+ Start with assets, actors, entry points, trust boundaries, and the decision the review must support. Trace the most important attacker-controlled input to its first authoritative control and final sensitive sink.
4
+
5
+ Use a compact table when useful:
6
+
7
+ | Asset | Actor/entry point | Trust boundary | Threat | Existing control | Gap/evidence |
8
+ | --- | --- | --- | --- | --- | --- |
9
+
10
+ Consider spoofing, tampering, repudiation, information disclosure, denial of service, and privilege escalation only where they explain a reachable risk. Record prerequisites such as account role, network position, platform, feature flag, or user action.
11
+
12
+ Separate confirmed issues from suspected risks and unknowns. A missing control is not automatically exploitable; state what evidence would confirm it. Keep secret values and sensitive payloads redacted.