From d78201d05fac14d5529bb693255123214265c382 Mon Sep 17 00:00:00 2001 From: Liam Date: Sat, 17 Aug 2024 17:38:34 -0400 Subject: [PATCH] Only allow GET The proxy_cache module will always internally convert HEAD to GET (which is desired). This does not update the request method variables exposed to Lua, so hardcode GET. --- docker/web/aws-signature.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker/web/aws-signature.lua b/docker/web/aws-signature.lua index c204cbb6..31a46f58 100644 --- a/docker/web/aws-signature.lua +++ b/docker/web/aws-signature.lua @@ -76,7 +76,7 @@ end local function get_hashed_canonical_request(timestamp, host, uri) local digest = get_sha256_digest(ngx.var.request_body) - local canonical_request = ngx.req.get_method() .. '\n' + local canonical_request = 'GET' .. '\n' .. uri .. '\n' .. '\n' .. 'host:' .. host .. '\n'