Authorization Matrix

Build and verify an authorization matrix mapping roles to endpoints — detect unprotected routes, missing ownership checks, and scope misconfigurations

16 stars

Best use case

Authorization Matrix is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

Build and verify an authorization matrix mapping roles to endpoints — detect unprotected routes, missing ownership checks, and scope misconfigurations

Teams using Authorization Matrix should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/authorization-matrix/SKILL.md --create-dirs "https://raw.githubusercontent.com/diegosouzapw/awesome-omni-skill/main/skills/testing-security/authorization-matrix/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/authorization-matrix/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How Authorization Matrix Compares

Feature / AgentAuthorization MatrixStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

Build and verify an authorization matrix mapping roles to endpoints — detect unprotected routes, missing ownership checks, and scope misconfigurations

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

SKILL.md Source

# Authorization Matrix Skill

Build a complete authorization matrix from the codebase and verify every endpoint has appropriate authentication, authorization, and ownership checks.

## Trigger Conditions
- Route configuration changes
- Auth middleware changes
- New handlers are added
- User invokes with "auth matrix" or "authorization-matrix"

## Input Contract
- **Required:** Path to route configuration (main.go or router files)
- **Required:** Path to middleware directory
- **Optional:** Path to handler files for ownership check verification

## Output Contract
- Complete route → auth requirement matrix
- List of unprotected routes (missing auth middleware)
- List of routes missing account ownership verification
- Comparison against the whitelist in rule 121

## Tool Permissions
- **Read:** Route config, middleware, handler files
- **Write:** None (read-only analysis)
- **Search:** Grep for `Use(middleware.Auth`, `GetUserID`, `RequireScope`, `AccountOwnership`

## Execution Steps

1. **Extract all routes**: Parse route registration to build complete endpoint list with HTTP method and path
2. **Identify auth middleware**: Find which route groups use auth middleware
3. **Check whitelist**: Compare unauthenticated routes against the whitelist in rule 121
4. **Verify ownership**: For account-scoped routes (`/accounts/:id/*`), verify ownership middleware is applied
6. **Report**: Produce authorization matrix with pass/fail per check

## Success Criteria
- All routes outside the whitelist are authenticated
- All account-scoped routes verify ownership
- All financial endpoints require appropriate scopes
- No route bypasses auth through misconfiguration

## References
- `.cursor/rules/121-route-auth-enforcement.mdc`
- `.cursor/rules/042-security-authorization.mdc`

Related Skills

add-authorization-methods

16
from diegosouzapw/awesome-omni-skill

Add authorization methods for a new entity to AuthorizationService. Use after creating a resource service. Triggers on "add permissions", "authorization methods", "entity permissions", "add auth methods".

access-control-matrix

16
from diegosouzapw/awesome-omni-skill

Design RBAC/ABAC policies and permission boundaries.

Transition Failure Matrix

16
from diegosouzapw/awesome-omni-skill

Identify failure hotspots in multi-step agent workflows using state transition analysis. Use when debugging agent pipelines, analyzing LLM orchestration failures, or systematically identifying where multi-step processes break down. Creates a grid mapping source states to failure points for targeted debugging.

Env Matrix Dev Stg Prod

16
from diegosouzapw/awesome-omni-skill

Standards for managing environments (development, staging, production) including configs, data policies, and access controls that differ per environment. This skill enables environment parity, reduces

authentication-authorization

16
from diegosouzapw/awesome-omni-skill

Authentication and authorization patterns using Clerk and RBAC

bgo

10
from diegosouzapw/awesome-omni-skill

Automates the complete Blender build-go workflow, from building and packaging your extension/add-on to removing old versions, installing, enabling, and launching Blender for quick testing and iteration.

Coding & Development

security-scanning-security-hardening

16
from diegosouzapw/awesome-omni-skill

Coordinate multi-layer security scanning and hardening across application, infrastructure, and compliance controls.

security-scanning-security-dependencies

16
from diegosouzapw/awesome-omni-skill

You are a security expert specializing in dependency vulnerability analysis, SBOM generation, and supply chain security. Scan project dependencies across ecosystems to identify vulnerabilities, ass...

security-scan

16
from diegosouzapw/awesome-omni-skill

Comprehensive security scanning for CVE vulnerabilities, OWASP Top 10 code patterns, and dependency audits. Use when the user wants to check code security, find vulnerabilities, or audit dependencies.

security-reviewer

16
from diegosouzapw/awesome-omni-skill

Use when conducting security audits, reviewing code for vulnerabilities, or analyzing infrastructure security. Invoke for SAST scans, penetration testing, DevSecOps practices, cloud security reviews.

security-review

16
from diegosouzapw/awesome-omni-skill

Run a targeted security audit on specified files or modules. Uses OWASP-informed checks, dependency vulnerability scanning, and auth/input validation review. Use for security audits, vulnerability checks, or before deploying sensitive code. Keywords: security, audit, vulnerability, OWASP, CVE, secrets, injection, XSS, auth, authentication, authorization

security-review-pr

16
from diegosouzapw/awesome-omni-skill

PR/branch security review focused on HIGH-CONFIDENCE vulnerabilities with minimal false positives. Uses git diff analysis and sub-task parallelization.