all repos — honk @ 7f97e03d0a119386abfe1e91fb24ed8f782f4d84

my fork of honk

remove csp shit
Anirudh Oppiliappan x@icyphox.sh
Wed, 21 Jun 2023 21:30:21 +0300
commit

7f97e03d0a119386abfe1e91fb24ed8f782f4d84

parent

7473567cf7c74e629b8bf7c5149540931ea16db5

1 files changed, 0 insertions(+), 8 deletions(-)

jump to
M web.goweb.go

@@ -2679,13 +2679,6 @@ time.Sleep(50 * time.Minute)

} } -func addcspheaders(next http.Handler) http.Handler { - return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { - w.Header().Set("Content-Security-Policy", "default-src cdn.icyphox.sh; script-src 'self'; connect-src 'self'; style-src 'self' cdn.icyphox.sh; img-src 'self'; media-src 'self'; report-uri /csp-violation") - next.ServeHTTP(w, r) - }) -} - func emuinit() { var emunames []string dir, err := os.Open(dataDir + "/emus")

@@ -2777,7 +2770,6 @@ h()

} mux := mux.NewRouter() - mux.Use(addcspheaders) mux.Use(login.Checker) mux.Handle("/api", login.TokenRequired(http.HandlerFunc(apihandler)))