feat: customize proxy ignore headers (close #2763 pr #2766)

* clean referer when use proxy

* feat: customize proxy ignore headers

Co-authored-by: Noah Hsu <i@nn.ci>
This commit is contained in:
EzraRT
2022-12-20 16:08:32 +08:00
committed by GitHub
parent 372030071e
commit 146619134d
7 changed files with 30 additions and 29 deletions

View File

@ -15,23 +15,21 @@ const (
BasePath = "base_path"
SiteTitle = "site_title"
Announcement = "announcement"
AllowIndexed = "allow_indexed"
AllowIndexed = "allow_indexed"
Logo = "logo"
Favicon = "favicon"
MainColor = "main_color"
// preview
TextTypes = "text_types"
AudioTypes = "audio_types"
VideoTypes = "video_types"
ImageTypes = "image_types"
// OfficeTypes = "office_types"
ProxyTypes = "proxy_types"
OfficeViewers = "office_viewers"
PdfViewers = "pdf_viewers"
AudioAutoplay = "audio_autoplay"
VideoAutoplay = "video_autoplay"
TextTypes = "text_types"
AudioTypes = "audio_types"
VideoTypes = "video_types"
ImageTypes = "image_types"
ProxyTypes = "proxy_types"
ProxyIgnoreHeaders = "proxy_ignore_headers"
AudioAutoplay = "audio_autoplay"
VideoAutoplay = "video_autoplay"
// global
HideFiles = "hide_files"

View File

@ -15,7 +15,7 @@ var (
Conf *Config
)
var TypesMap = make(map[string][]string)
var SlicesMap = make(map[string][]string)
var FilenameCharMap = make(map[string]string)
var PrivacyReg []*regexp.Regexp