From 4680aef783ebb011979a1698406b5f7c7b5831b3 Mon Sep 17 00:00:00 2001 From: Azareal Date: Fri, 31 Jul 2020 15:53:33 +1000 Subject: [PATCH] set RefNoRef to true when using an external domain for StaticResBase --- common/site.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/common/site.go b/common/site.go index f0b878ca..28350678 100644 --- a/common/site.go +++ b/common/site.go @@ -123,6 +123,8 @@ type config struct { ExtraCSPOrigins string StaticResBase string // /s/ + //DynStaticResBase string + //AvatarResBase string Noavatar string // ? - Move this into the settings table? ItemsPerPage int // ? - Move this into the settings table? @@ -242,6 +244,7 @@ func ProcessConfig() (err error) { host := uurl.Hostname() if !local(host) { Config.ExtraCSPOrigins += " " + host + Config.RefNoRef = true // Avoid leaking origin data to the CDN } if Config.StaticResBase != "" { StaticFiles.Prefix = Config.StaticResBase