000
INITIALIZING
OPEN SOURCE · v0.1.0

mcp-oauth-audit

Dynamic OAuth 2.1 & DCR auditor for deployed MCP servers.
6 HTTP-level checks. Catches the phishing primitives the MCP spec requires you to handle — and most servers don’t.

pipx install git+https://github.com/veloxlabsio/mcp-oauth-audit.git

Why a second tool

mcp-scan reads source

Static AST analysis. Runs before you deploy. Catches code-level bugs in MCP server authors’ own implementations.

mcp-oauth-audit probes HTTP

Dynamic black-box. Runs against a live server. Catches misconfigurations you can only see from the outside — the ones integrators inherit blind.

Both matter

A scanner that only reads source misses what the deployment actually exposes. A prober that only hits HTTP misses bugs hiding in logic. Run both.

What it catches today

Registration (DCR — RFC 7591)

Probes the /register endpoint

MOA-010
HIGH
Arbitrary external redirect_uri accepted
Server registers clients with attacker-controlled redirect_uri on unrelated domains — the phishing primitive.
MOA-011
CRITICAL
Dangerous URI schemes accepted
Registration allows javascript: or data: as redirect target. Direct XSS on the authorization response.
MOA-030
MEDIUM
client_secret issued to a public client
Server sets token_endpoint_auth_method=“none” but still returns a secret. Confused threat model.

Metadata (RFC 8414)

Fetches /.well-known/oauth-authorization-server

MOA-001
HIGH
Missing or malformed AS metadata
Required fields (issuer, authorization_endpoint, token_endpoint) missing or wrong type.
MOA-020
HIGH
Implicit flow still advertised
response_types_supported contains token. RFC 9700 §2.1.2 forbids this for new deployments.
MOA-021
MEDIUM
PKCE missing or plain advertised
code_challenge_methods_supported absent or lists plain. Downgrade risk; only S256 is safe.

Auditor vs a misconfigured server

Simulated run against an MCP server with all 6 common misconfigurations. The auditor flags 5 findings, exits non-zero, and finishes in ~2 seconds — CI-ready.

terminal · mcp-oauth-audit vs vulnerable-mcp
$ mcp-oauth-audit https://vulnerable-mcp.example.com
mcp-oauth-audit    target: https://vulnerable-mcp.example.com
checks run  6
findings    5
 
Summary by severity
━━━━━━━━━━━━━━━━━━━━━━━━
critical  1
high      3
medium    1
low       0
info      0
 
── CRITICAL  MOA-011  DCR accepts javascript: redirect_uri
    Registration returned 201 for redirect_uri='javascript:alert(1)'
 
── HIGH      MOA-010  DCR accepts arbitrary external redirect_uri
    Registered client with redirect_uri='http://attacker.example.com/cb'
 
── HIGH      MOA-020  Implicit flow advertised in metadata
    response_types_supported contains 'token' — RFC 9700 forbids this
 
── HIGH      MOA-030  Public client issued a client_secret
    token_endpoint_auth_method='none' but server returned client_secret='abc123...'
 
── MEDIUM    MOA-021  PKCE 'plain' method advertised
    code_challenge_methods_supported contains 'plain' — downgrade risk
 
 audit complete · 5 findings · 2.1s · exit 1 (HIGH/CRITICAL present)
1
CRITICAL
3
HIGH
1
MEDIUM
2.1s
RUNTIME
CRITICAL MOA-011
DCR accepts javascript: redirect_uri
POST /register → 201 Created · redirect_uri=“javascript:alert(1)”
HIGH MOA-010
DCR accepts arbitrary external redirect_uri
POST /register → 201 · redirect_uri=“http://attacker.example.com/cb”
HIGH MOA-020
Implicit flow advertised in metadata
response_types_supported contains “token” — RFC 9700 §2.1.2 violation
HIGH MOA-030
Public client issued a client_secret
token_endpoint_auth_method=“none” but response contained client_secret
MEDIUM MOA-021
PKCE plain method advertised
code_challenge_methods_supported contains “plain” — downgrade risk

Try it in 30 seconds

01

Install

$ pipx install git+https://github.com/veloxlabsio/mcp-oauth-audit.git
02

Audit any MCP server

$ mcp-oauth-audit https://my-mcp-server.example.com
03

Get JSON for CI

$ mcp-oauth-audit https://my-mcp-server.example.com --output json
04

Local dev with self-signed certs

$ mcp-oauth-audit https://localhost:8443 --insecure

Built different

Black-box only

No source access needed. Runs against any reachable MCP server, whether you wrote it or inherited it.

Deterministic

Same server, same findings. No LLM, no heuristic scoring. Each check is a spec assertion against the HTTP response.

Ethical by default

No token endpoint probing. No rate-limit abuse. Only checks that would pass a responsible-disclosure review.

CI-native

Non-zero exit on HIGH or CRITICAL. JSON output. Finishes in 2–3 seconds. Drop it into a deploy gate.

What v0.1 does NOT check

A security tool that silently skips coverage is worse than none. Here’s what’s deliberately out of scope today:

Roadmap: GitHub Issues ↗

Audit your MCP server's OAuth surface.
Before your integrators do.