
Review Security Structure
- 4 installs
- 23 repo stars
- Updated August 4, 2026
- aktsmm/agent-skills
review-security-structure is a skill that runs a defensive, structure-first security review of authorized code using AST maps, call graphs and Source/Sink taint flow.
About
This skill reviews owned or authorized code for security by reading architecture and data flow before full source. It builds or reads a structure map (AST summaries, call graphs, complexity, Source/Sink), models trust boundaries, and traces taint flow to surface vulnerabilities, parser/scanner risks, CI/CD risks and agent tool-boundary risks. A developer uses it to triage SAST results or harden code against adversarial input without producing weaponized exploits.
- Reviews code security structure-first using AST maps, call graphs and complexity
- Traces Source to Sink taint flow to find missing validation and boundary bypasses
- Stays defensive: places uncertain exploitability in Hypotheses, keeps fixes minimal
Review Security Structure by the numbers
- 4 all-time installs (skills.sh)
- Ranked #1,742 of 2,203 Security skills by installs in the Skillselion catalog
- Data as of Aug 5, 2026 (Skillselion catalog sync)
review-security-structure capabilities & compatibility
- Capabilities
- security audit · code review
- Use cases
- security audit · code review
What review-security-structure says it does
Defensively review code or structure artifacts by reading architecture and data flow before reading full source.
If exploitability is uncertain, place the item in Hypotheses rather than Findings.
npx skills add https://github.com/aktsmm/agent-skills --skill review-security-structureAdd your badge
Show developers this skill is listed on Skillselion. Paste this into your README.
| Installs | 4 |
|---|---|
| repo stars | ★ 23 |
| Last updated | August 4, 2026 |
| Repository | aktsmm/agent-skills ↗ |
What it does
Run a defensive, structure-first security review of authorized code using AST, call graph and Source/Sink taint flow.
Who is it for?
Triaging SAST results and finding logic, parser, CI/CD and agent tool-boundary vulnerabilities by reading structure before full source.
Skip if: Unauthorized testing, intrusion, credential theft or producing weaponized proof-of-concept exploits.
When should I use this skill?
You need a security or vulnerability review of code, an AST/structure map review, or SAST triage.
What you get
A structure-first review with Source-to-Sink findings, trust-boundary analysis and minimal defensive fixes.
- Structure map summary
- Findings and Hypotheses
- Minimal verified fixes
By the numbers
- 10-item minimum map contract (entry_points to scan_limits)
- Source/Propagator/Sanitizer/Sink flow model
Files
Review Security Structure
Defensively review code or structure artifacts by reading architecture and data flow before reading full source. Use structural signals to identify vulnerabilities, logic flaws, parser/scanner risks, CI/CD risks, and LLM/agent tool-boundary risks.
When to Use
- security review, vulnerability review, SAST triage, AST, structure map, call graph, Source/Sink, taint flow
- 脆弱性レビュー, セキュリティレビュー, 構造マップ, AST レポート, 依存関係, 複雑度
- Reviewing owned or explicitly authorized code, design docs, scan results, or generated structure maps
- Hardening parsers, scanners, CI/CD tools, file walkers, and agent/tool-call boundaries against malformed or adversarial input
Safety Scope
- Keep the work defensive: review, risk explanation, safe verification ideas, and minimal fixes.
- Do not provide unauthorized testing, intrusion, persistence, evasion, credential theft, weaponized PoC, or destructive external steps.
- If exploitability is uncertain, place the item in Hypotheses rather than Findings.
- If code changes are requested, keep them minimal and verify with existing tests or a focused local check.
Inputs to Prefer
Use provided structure artifacts first, then inspect the smallest code/config range needed.
| Input | Examples |
|---|---|
| Structure | AST summaries, class/function lists, Mermaid graphs, JSON reports |
| Data flow | Source, Propagator, Sanitizer, Sink, taint flow |
| Call graph | caller -> callee edges, boundary-crossing calls, fallback paths |
| Complexity | large functions, branch concentration, exception density |
| Scope/state | variable scope, global state, shared mutable state, auth boundaries |
| Static results | secret scan, dependency scan, lint/type/SAST warnings |
| Context | README, design notes, CI workflow, deployment config |
Structure Map Build
If no equivalent structure artifact exists, create a minimal read-oriented structure map before starting findings review. Do not skip this step unless generation is genuinely blocked; record blockers and limits in the Structure Map Summary.
1. Look for existing artifacts in reports, manifest, tmp, CI output, README, package scripts, Makefile, or workflows. 2. Prefer existing language-aware tools: TypeScript compiler, eslint, dependency graph scripts, language server data, test/coverage config, or standard-library parsers. 3. Favor maps that include summaries, class/call graphs, function metrics, variable scopes, imports, taint flow, static findings, dependency audit, and high-complexity hotspots. 4. Avoid installing new dependencies unless clearly justified. Prefer lockfile-backed local tools. 5. Do not execute the target application behavior just to map it. Keep extraction static or read-only when possible. 6. Redact secret values. Record only kind and location, not token/password/key material. 7. For large repos, map entry points, changed files, public APIs, trust boundaries, and dangerous Sink neighborhoods first.
Minimum map contract:
| Item | Requirement |
|---|---|
| entry_points | CLI, API handlers, commands, jobs, public APIs, workflows |
| files | reviewed files, language, inferred role |
| symbols | classes/functions/methods and inferred responsibility |
| imports | external deps, dangerous APIs, security-boundary deps |
| call_edges | caller -> callee edges when practical |
| complexity | large or high-branch functions when practical |
| sources | HTTP, CLI args, env, files, network, deserialization, LLM input |
| sinks | command, SQL, eval, template, path, file write, network, secret/log, tool call |
| sanitizers | validate, escape, normalize, authn/authz, schema checks |
| scan_limits | missing, approximate, unsupported, or unparsed areas |
Review Flow
1. Gate the target: assume review is allowed for current workspace/user-provided artifacts; ask only if ownership or authorization is unclear. 2. Classify the target: web app, CLI, library, scanner, CI/CD tool, infrastructure definition, data processor, extension, or agent tool. 3. Read an existing structure map, or build the minimal map from the contract above before full source reading. 4. Model trust boundaries: who controls which input, where it flows, what authority the Sink has, and what data is sensitive. 5. Trace Source -> Propagator -> Sanitizer -> Sink. Look for missing validation, wrong order, branch gaps, implicit deserialization, and type-conversion surprises. 6. Review call graph paths that bypass authn/authz, validation, initialization, feature flags, or normal handlers. 7. Review complexity and logic risks: giant functions, broad try/catch, deep nesting, fallback behavior, shared state, TOCTOU, and cache races. 8. For parsers/scanners/file walkers, prioritize crash, unbounded recursion, symlink loops, huge/deep ASTs, encoding edge cases, dependency resolution failures, and detection bypass. 9. For CI/CD, review workflow inputs, artifact/cache trust, token permissions, PR boundaries, release gates, and secret exposure. 10. For LLM/agent code, review prompt injection paths, external document trust, tool-call authorization, path safety, command policy, and log redaction.
Evidence Rules
- Findings require structural signal, reachability, impact, and a defensive verification or fix direction.
- Confidence is High, Medium, or Low. Avoid certainty language unless verified.
- Keep unsupported ideas in Hypotheses with the missing evidence and next check.
- Reference local files with precise paths and line links when possible. Do not paste full source files.
Output Format
Lead with Findings. If there are no confirmed findings, state that clearly first.
Findings
| # | Severity | Confidence | Target | Structural Signal | Reachability | Impact | Defensive Verification | Minimal Fix |
|---|
Structure Map Summary
| Item | Value |
|---|---|
| Source | existing artifact / newly generated / quick extraction / unavailable |
| Artifact | saved path, or none |
| Scope | reviewed paths and boundaries |
| Method | tools, scripts, or manual extraction used |
| Limits | unparsed or approximate areas |
| Redaction | redacted secret values, or none applicable |
Hypotheses
| # | Hypothesis | Missing Evidence | Next Check |
|---|
Code to Inspect
| Priority | Path / Symbol | Why |
|---|
Recommended Fix Plan
1. Fix clear, reachable, high-impact issues first. 2. Add safety guards such as size limits, timeouts, input validation, path normalization, auth checks, and log redaction. 3. Split high-complexity code only where it reduces risk or enables tests. 4. Verify the Source -> Sink path is blocked or constrained after the fix.
Verification Summary
- Checks run: command/tool/read-only review performed, or not run with reason
- Remaining risk: unresolved items, or none
- External references: URLs used, or none
Thanks to / References
Inspired by these structure-first review resources. Treat them as references, not required dependencies.
- https://github.com/harumaki4649/ast-structure-map
- https://qiita.com/harupython/items/ed256553d10578cfec2a
- https://qiita.com/harupython/items/4d572a384c62016c51f2
# Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International (CC BY-NC-SA 4.0)
## English
Copyright (c) 2025-2026 yamapan (aktsmm)
This work is licensed under the Creative Commons Attribution-NonCommercial-ShareAlike 4.0
International License.
You are free to:
- **Share** — copy and redistribute the material in any medium or format
- **Adapt** — remix, transform, and build upon the material
Under the following terms:
- **Attribution** — You must give appropriate credit, provide a link to the
license, and indicate if changes were made. You may do so in any reasonable manner,
but not in any way that suggests the licensor endorses you or your use.
- **NonCommercial** — You may not use the material for commercial purposes.
*(Please contact the author if you wish to use this material for commercial purposes.)*
- **ShareAlike** — If you remix, transform, or build upon the material, you must
distribute your contributions under the same license as the original.
No additional restrictions — You may not apply legal terms or technological
measures that legally restrict others from doing anything the license permits.
**AI/ML Training Restriction** — Use of this content for AI/ML training, data
mining, or other analytical purposes is prohibited without explicit permission.
Full license text: https://creativecommons.org/licenses/by-nc-sa/4.0/legalcode
---
## 日本語
Copyright (c) 2025-2026 yamapan (aktsmm)
この作品はクリエイティブ・コモンズ 表示-非営利-継承 4.0 国際ライセンスの下に提供されています。
あなたは以下の条件に従う限り、自由に:
- **共有** — どのようなメディアやフォーマットでも資料を複製・再配布できます
- **翻案** — 資料をリミックス、変形、および加工することができます
以下の条件に従ってください:
- **表示** — あなたは適切なクレジットを表示し、ライセンスへのリンクを提供し、
変更があったらその旨を示さなければなりません。これらは合理的であればどのような方法で
行っても構いませんが、許諾者があなたやあなたの利用行為を支持していると示唆するような
方法は除きます。
- **非営利** — あなたは営利目的でこの資料を利用してはなりません。
(※商用利用をご希望の場合は、別途ご連絡ください。)
- **継承** — もしあなたがこの資料をリミックス、変形、または加工した場合、
あなたはあなたの貢献部分を元の作品と同じライセンスの下で配布しなければなりません。
追加的な制約は課せません — あなたは、このライセンスが他の者に許諾することを法的に
制限するような法的条項や技術的手段を適用してはなりません。
**AI/MLトレーニング制限** — 本コンテンツをAI/MLモデルのトレーニング、データマイニング、
その他の解析目的での使用は明示的な許可なく禁止されています。
ライセンス全文: https://creativecommons.org/licenses/by-nc-sa/4.0/legalcode.ja
---
## Special Permission for Microsoft Employees / Microsoft 社員向け特別許諾
### English
Microsoft Corporation employees are granted permission to use, copy, modify, and
distribute this material for any purpose within the scope of their employment
duties at Microsoft, including internal business use and customer-facing
activities, without the NonCommercial restriction of this license.
This special permission applies only to work performed as part of official
Microsoft business activities.
### 日本語
Microsoft Corporation の社員は、Microsoft での業務の範疇において、本資料を社内業務
および顧客対応を含むあらゆる目的で使用、複製、改変、配布することが許諾されます。
この場合、本ライセンスの「非営利」制限は適用されません。
この特別許諾は、Microsoft の公式な業務活動の一環として行われる作業にのみ適用されます。
---
## Disclaimer / 免責事項
### English
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR
A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
### 日本語
本ソフトウェアは「現状のまま」で提供され、明示または黙示を問わず、商品性、
特定目的への適合性、および権利非侵害についての保証を含むがこれに限定されない、
いかなる種類の保証も伴いません。作者または著作権者は、契約行為、不法行為、
またはそれ以外であろうと、ソフトウェアに起因または関連し、あるいはソフトウェアの
使用またはその他の扱いによって生じる一切の請求、損害、その他の責任について
責任を負いません。
Related skills
FAQ
Is this offensive tooling?
No. The skill keeps work defensive and does not provide unauthorized testing, intrusion, persistence, evasion or weaponized PoC.
What does it analyze first?
It reads architecture and data flow (AST, call graphs, complexity, Source/Sink) before reading full source.