From dc35d7ac53345ceafef46418c85f4fdbd991c808 Mon Sep 17 00:00:00 2001 From: Abhishek Govindarasu Date: Fri, 27 Sep 2024 21:16:18 -0700 Subject: [PATCH] log prog --- hook/handlers/index.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/hook/handlers/index.go b/hook/handlers/index.go index 51cf321..cb1eef2 100644 --- a/hook/handlers/index.go +++ b/hook/handlers/index.go @@ -1,6 +1,7 @@ package handlers import ( + "fmt" "io" "net/http" "strings" @@ -28,6 +29,9 @@ func Index(w http.ResponseWriter, r *http.Request) { body = []byte{} } + for key := range r.Header { + fmt.Println(key, ":", r.Header.Get(key)) + headers := http.Header{} for key := range response.Headers { if !(strings.HasPrefix(key, "Cf-") || key == "Cdn-Loop" || key == "X-Real-IP" || key == "X-Forwarded-For" || key == "X-Forwarded-Proto") {