Skip to content

Commit

Permalink
🐛 set referrerPolicy+xContentType to null (#2262)
Browse files Browse the repository at this point in the history
If they are not present, set them to null instead of empty string

Signed-off-by: Dominik Richter <dominik.richter@gmail.com>
  • Loading branch information
arlimus authored Oct 17, 2023
1 parent 79fa5b1 commit 0d74fa7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions providers/network/resources/http.go
Original file line number Diff line number Diff line change
Expand Up @@ -319,12 +319,12 @@ func (x *mqlHttpHeaderXssProtection) id() (string, error) {

func (x *mqlHttpHeader) xContentTypeOptions() (string, error) {
params, ok := x.Params.Data["X-Content-Type-Options"]
return parseSingleHeaderValue(params, ok, &x.XFrameOptions)
return parseSingleHeaderValue(params, ok, &x.XContentTypeOptions)
}

func (x *mqlHttpHeader) referrerPolicy() (string, error) {
params, ok := x.Params.Data["Referrer-Policy"]
return parseSingleHeaderValue(params, ok, &x.XFrameOptions)
return parseSingleHeaderValue(params, ok, &x.ReferrerPolicy)
}

func (x *mqlHttpHeader) contentType() (*mqlHttpHeaderContentType, error) {
Expand Down

0 comments on commit 0d74fa7

Please sign in to comment.