From 22ee227f209f300459424e9b1ee26dafb0726c3a Mon Sep 17 00:00:00 2001 From: Xe Iaso Date: Thu, 7 Aug 2025 13:50:24 +0000 Subject: [PATCH] fix(anubis): use global cookie prefix variable Signed-off-by: Xe Iaso --- cmd/anubis/main.go | 2 +- docs/docs/CHANGELOG.md | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/cmd/anubis/main.go b/cmd/anubis/main.go index cc8ebd1..2d36ae7 100644 --- a/cmd/anubis/main.go +++ b/cmd/anubis/main.go @@ -49,7 +49,7 @@ var ( cookieDomain = flag.String("cookie-domain", "", "if set, the top-level domain that the Anubis cookie will be valid for") cookieDynamicDomain = flag.Bool("cookie-dynamic-domain", false, "if set, automatically set the cookie Domain value based on the request domain") cookieExpiration = flag.Duration("cookie-expiration-time", anubis.CookieDefaultExpirationTime, "The amount of time the authorization cookie is valid for") - cookiePrefix = flag.String("cookie-prefix", "techaro.lol-anubis", "prefix for browser cookies created by Anubis") + cookiePrefix = flag.String("cookie-prefix", anubis.CookieName, "prefix for browser cookies created by Anubis") cookiePartitioned = flag.Bool("cookie-partitioned", false, "if true, sets the partitioned flag on Anubis cookies, enabling CHIPS support") forcedLanguage = flag.String("forced-language", "", "if set, this language is being used instead of the one from the request's Accept-Language header") hs512Secret = flag.String("hs512-secret", "", "secret used to sign JWTs, uses ed25519 if not set") diff --git a/docs/docs/CHANGELOG.md b/docs/docs/CHANGELOG.md index ae1f39c..7bab554 100644 --- a/docs/docs/CHANGELOG.md +++ b/docs/docs/CHANGELOG.md @@ -31,6 +31,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - The Anubis version number is put in the footer of every page. - The legacy JSON based policy file example has been removed and all documentation for how to write a policy file in JSON has been deleted. JSON based policy files will still work, but YAML is the superior option for Anubis configuration. - A standard library HTTP server log message about HTTP pipelining not working has been filtered out of Anubis' logs. There is no action that can be taken about it. +- The `--cookie-prefix` flag has been fixed so that it is fully respected. ### Breaking changes