fix: redact gateway session header from Caddy logs

This commit is contained in:
2026-08-08 15:05:55 +00:00
parent 96fdbdf218
commit bba8664714
3 changed files with 15 additions and 0 deletions
+6
View File
@@ -38,3 +38,9 @@ test('runtime entrypoint removes raw repository secrets before launching PM2', a
assert.ok(httpsUnset > 0 && httpsUnset < pm2Start);
assert.ok(sshUnset > 0 && sshUnset < pm2Start);
});
test('Caddy runtime logs remove the custom Gateway session header', async () => {
const caddyfile = await fs.readFile(new URL('../caddy/Caddyfile', import.meta.url), 'utf8');
assert.match(caddyfile, /log\s*\{[\s\S]*format filter\s*\{[\s\S]*request>headers>X-Session-Token delete/);
});