mirror of https://github.com/garrytan/gstack.git
fix: restore token in /health for localhost extension auth
The CSO security fix stripped the token from /health to prevent leaking when tunneled. But the extension needs it to authenticate on localhost. Now returns token only when not tunneled (safe: localhost-only path). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
7b60c0bbe6
commit
52226dafe2
|
|
@ -1290,7 +1290,9 @@ async function start() {
|
|||
};
|
||||
// Sensitive fields only served on localhost (not through tunnel).
|
||||
// currentUrl reveals internal URLs, currentMessage reveals user intent.
|
||||
// token needed by extension to authenticate subsequent requests.
|
||||
if (!tunnelActive) {
|
||||
healthResponse.token = AUTH_TOKEN;
|
||||
healthResponse.currentUrl = browserManager.getCurrentUrl();
|
||||
healthResponse.chatEnabled = true;
|
||||
healthResponse.agent = {
|
||||
|
|
|
|||
Loading…
Reference in New Issue