DC-154: forward_auth enforcement endpoint (whois + access map + sensitive step-up) + tests

This commit is contained in:
Hermes committed 2026-10-03 22:30:23 -07:00
1 parent 88f7600693
commit aac2343df3
6 files changed
+789 -1

No files matched your search

@@ -195,7 +195,10 @@ function csrfValidationMiddleware(req, res, next) {
return new RegExp(pattern).test(req.path);
}
return false;
}) || req.path.startsWith('/api/v1/auth/gate/');
}) || req.path.startsWith('/api/v1/auth/gate/')
// DC-154: Caddy forward_auth fires on every protected request including
// POSTs — it presents a device identity (whois), never a CSRF token.
|| req.path.startsWith('/api/v1/network/forward-auth');
if (isExcluded) {
return next();