mirror of
https://github.com/argoproj/argo-cd
synced 2026-05-24 01:38:43 +00:00
feat: set X-XSS-Protection while serving static content (#5412)
Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
This commit is contained in:
parent
bef46390ea
commit
8014cf3c03
1 changed files with 1 additions and 0 deletions
|
|
@ -833,6 +833,7 @@ func (server *ArgoCDServer) newStaticAssetsHandler(dir string, baseHRef string)
|
|||
if server.XFrameOptions != "" {
|
||||
w.Header().Set("X-Frame-Options", server.XFrameOptions)
|
||||
}
|
||||
w.Header().Set("X-XSS-Protection", "1")
|
||||
|
||||
// serve index.html for non file requests to support HTML5 History API
|
||||
if acceptHTML && !fileRequest && (r.Method == "GET" || r.Method == "HEAD") {
|
||||
|
|
|
|||
Loading…
Reference in a new issue