-
Notifications
You must be signed in to change notification settings - Fork 8.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Change default value of csp.disableUnsafeEval to 'true' #150157
Conversation
Documentation preview: |
Pinging @elastic/kibana-security (Team:Security) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I left some comments and tried to answer the questions to the reviewers.
LGTM!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
I was going to ask if that can even be done outside of the scope of a major. This seems like a breaking change to me (unless I misunderstand the potential implications for users)? |
💚 Build Succeeded
Metrics [docs]Public APIs missing comments
Unknown metric groupsAPI count
History
To update your PR or re-run it, just comment with: cc @watson |
@pgayvallet technically it shouldn't have any impact on our users, unless they use a 3rd party plugin that replies on |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, thanks for elaborating. In that case, LGTM
Doesn't feel mandatory, but it would probably be slightly better yeah. BWC can easily be done via a
I think so yeah |
Re: "changing default value of While technically it can be a breaking change for certain users, I feel that the benefits of the improved security outweigh potential risks here. Moreover, we have a well defined escape hatch\workaround for those users that might be affected. Re: "Will be removed in 8.8.0." I'm slightly nervous here, we recently explicitly called out Alternatively, we can stop relying on it internally and mark it as Re: As @pgayvallet mentioned, it's an easy\safe change with |
@azasypkin I'll update the deprecation message saying it will be marked as unused in |
We also can just say "in future version" to not commit to any specific release and do it whenever we feel like it, but up to you. |
👍 Now the deprecation notice says:
|
Today the
unsafe-eval
source expression is "on" by default in the Kibana Content Security Policy (CSP). Users can choose to setcsp.disableUnsafeEval
totrue
to removeunsafe-eval
from the CSP.Once we land support for inline partials in(Update: Landed!), we can change the default behaviour so@kbn/handlebars
unsafe-eval
is not present in our CSP unless users explicitly opt in. In this PR I do that by change the default value ofcsp.disableUnsafeEval
fromfalse
totrue
.Closes #150156
Release notes
The default value of
csp.disableUnsafeEval
is nowtrue
instead offalse
. This means that theunsafe-eval
source expression isn't present by default in the Kibana Content Security Policy (CSP). If you depend onunsafe-eval
, please setcsp.disableUnsafeEval
tofalse
.Questions to reviewers
csp.disableUnsafeEval
tocsp.enableUnsafeEval
now that the default value has changed fromfalse
totrue
? Obviously we'd still need keep support forcsp.disableUnsafeEval
around as a negated alias.Blocked by