Sentinel.
API Security Study

Sentinel
Security Lab

Backend study project in Spring Boot 3. Register a local API, run read-only HTTP checks, and get findings with severity levels and a risk score — built to practice security while developing your own services.

7 Check TypesAsync ScansJWT AnalysisLocal Targets Only
Scans completed42
View Source

Request flow

1Client (Postman / curl)
2Sentinel API :8080
3Your local API

Bearer JWT on every call. WebClient runs checks with caps and timeouts — read-only, no exploitation.

Scanners

7 Security Check Types

Pick which checks to run per scan, or trigger all seven at once with POST /api/scans/full/{targetId}.

Security Headers

HSTS, CSP, X-Frame-Options, X-Content-Type-Options, Referrer-Policy, Permissions-Policy, Server disclosure.

CORS

Wildcard origin, reflected arbitrary origin, null origin acceptance.

Swagger / Actuator

Public docs endpoints and Spring Boot Actuator exposure (/actuator/env, /actuator/mappings).

JWT

alg=none acceptance, expired token accepted, endpoints accessible without auth.

Rate Limiting

No HTTP 429 after repeated requests, missing rate-limit headers.

HTTP Response

Stack traces in error bodies, DB error messages, internal filesystem paths.

Unauthenticated Paths

Common paths that respond 200 without a token (/api/admin, /h2-console, /graphql).

Security Headers

1/7

HSTS, CSP, X-Frame-Options, X-Content-Type-Options, Referrer-Policy, Permissions-Policy, Server disclosure.

Modules

Application Structure

auth · target · scan · reports — PostgreSQL persists targets, jobs, and findings.

JWT

auth

Register and login. Bearer token for all scan and target operations.

targets

target

Register a local API as scan target. Only private/local IPs allowed — public URLs rejected.

async

scan

POST /api/scans returns 202. Scanners run in a bounded pool (2 core / 5 max); poll for status.

reports

reports

Findings grouped by severity with risk score. Generate and fetch structured reports.

Observability stack

Docker Compose brings PostgreSQL, Redis, Prometheus, and Grafana. Metrics at :9090, dashboards at :3000 — same pattern as other backend projects in the portfolio.

Patterns

Core Ideas

Read-only by design

Not an attack tool — HTTP checks with timeouts to catch misconfigurations in APIs you own while developing.

Async scan jobs

Immediate 202 response; status flows PENDING → RUNNING → COMPLETED. Dashboard aggregates severity and risk score.

JWT analysis endpoint

Decode tokens without needing the secret — useful when reviewing auth behavior during development.

Tech Stack

Java 21Spring Boot 3.2Spring SecurityJWT (JJWT)WebClientPostgreSQL 16FlywayDocker ComposePrometheusGrafanaOpenAPI 3

Engineering Notes

Local targets only

localhost, 127.x, 10.x, 192.168.x and 172.16–31.x are accepted. Public IPs are rejected at registration.

WebClient for outbound scans

Reactor Netty keeps I/O non-blocking while running multiple check types against the registered target.

Study project, honest scope

Built to practice API security concepts in Spring Boot — findings are educational, not a commercial scanner.