osint-dashboard/tests
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Sirius DevOps 5a39404384 fix(openapi): declare the admin session cookie on every guarded operation
/openapi.json is served to the internet and declared no securitySchemes at
all, so every one of the 22 mutating operations read as unauthenticated while
the middleware answers 401 on them. The enforcement lives in
AdminAuthMiddleware, not in a route dependency, so FastAPI had nothing to
infer a scheme from.

The spec is now stamped from auth.is_public() — the same allowlist the
middleware enforces — instead of a hand-maintained per-route list:
- components.securitySchemes.adminSession: apiKey in cookie, name
  osint_session (the cookie the middleware actually reads), with the 401/403
  behaviour documented.
- protected operations: security: [{"adminSession": []}] — 19 of the 22
  mutating operations plus GET /api/keys, GET /api/settings, /api/news/models.
- public operations: security: [] (explicit "no auth"; not omitted).
  POST /api/search, POST /api/auth/login and POST /api/auth/logout stay
  public, and the read-only HUD surface is untouched.

Tests pin the pair per documented operation: the real app must answer 401 on
every operation that declares security, and the middleware must admit every
operation that declares []. Verified red on the untouched base (9 failures)
and green after the change.
2026-11-27 00:27:50 -05:00
..
conftest.py feat(auth): public read-only HUD, admin-only API keys and mutations 2026-11-13 20:56:07 -05:00
test_adsb_watch.py fix(adsb): keep aircraft ingest alive with no browser viewport 2026-11-21 17:30:47 -05:00
test_aircraft_popup_frontend.py feat(map): aircraft popup enrichment and emergency/MIL styling 2026-08-31 21:31:20 -04:00
test_api_fires.py Add NASA FIRMS active-fire ingest + /api/fires; API keys management page 2026-08-24 15:37:42 -04:00
test_api_live_layers.py feat(auth): public read-only HUD, admin-only API keys and mutations 2026-11-13 20:56:07 -05:00
test_api_news.py fix(news): unwrap CDATA titles at ingest and on /api/news 2026-11-14 00:47:04 -05:00
test_api_news_blips.py news: per-article proximate geolocation + GET /api/news/blips 2026-11-19 22:50:59 -05:00
test_api_place.py feat(map): right-click place dossier (Nominatim + nearby overlays) 2026-08-31 21:35:00 -04:00
test_api_settings.py feat(auth): public read-only HUD, admin-only API keys and mutations 2026-11-13 20:56:07 -05:00
test_api_stats.py fix(health): ignore future article timestamps; flag unset vessel/FIRMS keys 2026-11-14 00:34:39 -05:00
test_auth.py fix(openapi): declare the admin session cookie on every guarded operation 2026-11-27 00:27:50 -05:00
test_bg_jobs.py chore: remove unused masscan scanner 2026-09-01 00:47:24 -04:00
test_cache_and_timeline.py fix: pipeline reliability — WS, summarizer, ingest, health 2026-08-28 21:49:05 -04:00
test_camera_popup_contract.py fix: hydrate camera popup from GET /api/cameras/{id} 2026-08-28 20:04:53 -04:00
test_camera_publish.py fix(cameras): stop publishing discovery rows as events 2026-11-14 00:30:13 -05:00
test_chokepoints.py feat(map): chokepoint preset catalog + vessels ?src= filter 2026-08-29 14:03:15 -04:00
test_conflicts.py feat(conflicts): GET /api/conflicts catalog + news/GDELT event counts 2026-08-31 21:30:23 -04:00
test_conflicts_frontend.py feat(map): Conflicts layer toggle from /api/conflicts 2026-08-31 21:37:10 -04:00
test_event_ingest.py fix: pipeline reliability — WS, summarizer, ingest, health 2026-08-28 21:49:05 -04:00
test_feed_rail.py fix(hud): hide vessel and FIRMS rows when those feeds are unset 2026-11-14 00:30:04 -05:00
test_fire_aircraft.py feat: lean-Pi WS fan-out, geofences, DVR playback, fire/aircraft correlation 2026-08-28 09:35:18 -04:00
test_fire_ingest.py fix: chunk FIRMS bulk inserts under asyncpg 32767 bind cap 2026-08-28 22:22:12 -04:00
test_fire_sources.py fix(ingest): skip known KEV/FIRMS rows; CI skips unchanged images 2026-08-29 19:32:00 -04:00
test_frontend_reliability.py fix(map): geofence delete, vessel snapshots, sentinel cache, news briefs 2026-08-29 20:40:27 -04:00
test_gdelt_backoff.py fix(gdelt): ingest the 15-minute GKG bulk file, keep the DOC API as fallback 2026-11-21 18:37:31 -05:00
test_gdelt_bulk.py fix(gdelt): ingest the 15-minute GKG bulk file, keep the DOC API as fallback 2026-11-21 18:37:31 -05:00
test_geofence.py feat(geofence): hear quakes, WFIGS incidents, and news pins 2026-11-14 00:40:10 -05:00
test_geofence_frontend.py feat(map): geofence inbox shows cameras and the news line 2026-11-17 19:56:41 +00:00
test_gpsjam.py feat(gpsjam): GPS interference hex overlay API (GPSJAM/ADS-B Exchange) 2026-08-29 14:17:52 -04:00
test_health_ready.py fix(health): ignore future article timestamps; flag unset vessel/FIRMS keys 2026-11-14 00:34:39 -05:00
test_hud_chrome.py fix(map): NEWS ticker fills 32px news-only dock 2026-09-01 17:15:32 -04:00
test_hud_osiris.py chore: remove unused masscan scanner 2026-09-01 00:47:24 -04:00
test_infrastructure.py feat(infra): GET /api/infrastructure Overpass nuclear markers (bbox) 2026-08-31 21:31:31 -04:00
test_ingest_ssrf_and_sources.py feat(auth): public read-only HUD, admin-only API keys and mutations 2026-11-13 20:56:07 -05:00
test_live_layers.py Merge origin/master into UDOT IBI 511 cameras 2026-08-31 22:20:04 -04:00
test_map_payloads.py perf: slim fires/cameras/events/news map payloads 2026-08-27 21:19:42 -04:00
test_new_sources.py fix(ingest): skip known KEV/FIRMS rows; CI skips unchanged images 2026-08-29 19:32:00 -04:00
test_news_scraper.py fix(news): unwrap CDATA titles at ingest and on /api/news 2026-11-14 00:47:04 -05:00
test_phase1_guardrails.py fix(ops): pin TiTiler digest, GIST bbox indexes, single uvicorn worker 2026-09-01 00:47:06 -04:00
test_phase2_api.py feat(geofence): hear quakes, WFIGS incidents, and news pins 2026-11-14 00:40:10 -05:00
test_place_dossier_frontend.py feat(map): right-click place dossier (Nominatim + nearby overlays) 2026-08-31 21:35:00 -04:00
test_satellites.py feat(satellites): CelesTrak GP JSON satellites API with SGP4 propagation 2026-08-31 21:42:50 -04:00
test_sentinel1_frontend.py fix(map): geofence delete, vessel snapshots, sentinel cache, news briefs 2026-08-29 20:40:27 -04:00
test_tracks.py feat: lean-Pi WS fan-out, geofences, DVR playback, fire/aircraft correlation 2026-08-28 09:35:18 -04:00
test_upstream_cache.py fix(ingest): skip known KEV/FIRMS rows; CI skips unchanged images 2026-08-29 19:32:00 -04:00
test_vesselapi.py fix(map): geofence delete, vessel snapshots, sentinel cache, news briefs 2026-08-29 20:40:27 -04:00
test_vessels_snapshot.py fix(map): geofence delete, vessel snapshots, sentinel cache, news briefs 2026-08-29 20:40:27 -04:00
test_ws_manager.py feat: lean-Pi WS fan-out, geofences, DVR playback, fire/aircraft correlation 2026-08-28 09:35:18 -04:00