exploiting-auth-session

Confirms JWT, session, and cookie vulnerabilities by firing tampered tokens at staging endpoints.

Updated Jun 24, 2026
One-click install
npx skills add https://github.com/bs-koo/gx-security --skill exploiting-auth-session-bs-koo
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: exploiting-auth-session
Source: https://github.com/bs-koo/gx-security/tree/main/skills/exploiting-auth-session
Command: npx skills add https://github.com/bs-koo/gx-security --skill exploiting-auth-session-bs-koo

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve? Static scans can flag suspected authentication and session weaknesses, but they cannot prove whether a JWT signature is actually verified, whether logout really invalidates a token, or whether login cookies lack security flags. This Skill dynamically confirms exploitability against a running staging or local target, eliminating false positives with real HTTP evidence. ## Core Features & Use Cases - JWT Tampering Tests: Fires four mutated token variants (alg=none, signature stripped, role escalation, expired) at a protected endpoint and flags any 2xx response as a signature-verification vulnerability. - Token Reuse & Cookie Checks: Verifies whether a token still works after logout and inspects Set-Cookie headers for missing Secure, HttpOnly, and SameSite attributes. - Fail-Closed Safety Gate: Every request passes through scope_guard, which blocks production or public targets at the code level; all probes are non-destructive GETs. - Use Case: After a static scan flags JWT handling in a Spring Boot app, run this Skill against http://localhost:8080 with a test account to confirm whether a forged admin token is actually accepted, then generate a severity-ranked report. ## Quick Start Ask the AI to run the auth-session penetration test against your local staging URL with a test account to confirm whether JWT tampering and token reuse actually succeed.

Frequently Asked Questions about exploiting-auth-session

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I test if a JWT signature is actually verified by my API?▼

Send mutated token variants to a protected endpoint: one with alg=none, one with the signature stripped, one with a modified role claim, and one expired. If any returns a 2xx status instead of 401 or 403, the server is not properly verifying signatures.

How to check if logout invalidates a session token?▼

Call a protected endpoint with a valid token to confirm 200, call the logout endpoint, then replay the same token. A 2xx response after logout means the token was not invalidated; note that stateless JWTs without a denylist cannot be revoked server-side by design.

What cookie security flags should a login response set?▼

Session cookies should set Secure, HttpOnly, and SameSite attributes. Missing Secure allows transmission over plain HTTP, missing HttpOnly exposes the cookie to JavaScript theft via XSS, and missing SameSite enables CSRF via cross-site requests.

Can this penetration test run against production servers?▼

No. The scope_guard tool enforces a fail-closed check that blocks production and public targets at the code level before any request is fired. It is restricted to authorized staging or local environments owned by the organization.

Why does token reuse after logout show as undetermined for JWTs?▼

Stateless JWTs cannot be invalidated server-side without a denylist, so a 2xx after logout is marked undetermined rather than vulnerable. The finding notes that this is expected behavior unless a token denylist is implemented.