From 58429b75f479e85210d2a6d3bd18731e0120545e Mon Sep 17 00:00:00 2001 From: Brian Fox <878612+onematchfox@users.noreply.github.com> Date: Mon, 20 Nov 2023 12:58:28 +0100 Subject: [PATCH] fix: set max for max cookie number to `math.MaxInt` (#16388) * fix: set max for max cookie number to `math.MaxInt32` Signed-off-by: OneMatchFox <878612+onematchfox@users.noreply.github.com> * refactor: set max for max cookie number to `math.MaxInt` Co-authored-by: gdsoumya <44349253+gdsoumya@users.noreply.github.com> Signed-off-by: Brian Fox <878612+onematchfox@users.noreply.github.com> --------- Signed-off-by: OneMatchFox <878612+onematchfox@users.noreply.github.com> Signed-off-by: Brian Fox <878612+onematchfox@users.noreply.github.com> Co-authored-by: gdsoumya <44349253+gdsoumya@users.noreply.github.com> --- util/http/http.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/util/http/http.go b/util/http/http.go index fcf8447e1e2f6..7c13c71fde223 100644 --- a/util/http/http.go +++ b/util/http/http.go @@ -30,7 +30,7 @@ const ( // max number of chunks a cookie can be broken into. To be compatible with // widest range of browsers, you shouldn't create more than 30 cookies per domain -var maxCookieNumber = env.ParseNumFromEnv(common.EnvMaxCookieNumber, 20, 0, math.MaxInt64) +var maxCookieNumber = env.ParseNumFromEnv(common.EnvMaxCookieNumber, 20, 0, math.MaxInt) // MakeCookieMetadata generates a string representing a Web cookie. Yum! func MakeCookieMetadata(key, value string, flags ...string) ([]string, error) {