github / github/secure_headers

Set `default-src` CSP Attribute to `none` by default

未關閉
#482 1 則留言 0 個 reaction 已指派 0 人 在 GitHub 檢視
主要語言
Ruby
星號
3.2k
分支
253
平均合併
19 小時 11 分鐘
30 天內合併 PR
1

描述

At GitHub, we set the `default-src` CSP attribute to `none`. This provides the strictest possible CSP as it'll thus only allow CSP directives that the user explicitly has allowlisted.

It would be desirable to set this default in `secure_headers` as well:

https://github.com/github/secure_headers/blob/7f89df2dafb22f1833702eef4a01d4794b2066f0/lib/secure_headers/headers/content_security_policy_config.rb#L133

This would be a breaking change, so if this is desirable, this would fit well in with https://github.com/github/secure_headers/issues/480

貢獻指南

開啟貢獻指南

評估

這個 Issue 還沒有評估資料。

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。