-
Notifications
You must be signed in to change notification settings - Fork 24.9k
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
Upgrade to the latest OWASP HTML sanitizer #50765
Conversation
This commit upgrades the OWASP HTML sanitizer used by watcher to the latest version and also upgrades guava, which it depends on. The guava upgrade also requires the addition of a new dependency that guava itself requires as of version 27.0. Relates elastic#50395
Pinging @elastic/es-core-features (:Core/Features/Watcher) |
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 just pushed a change that removes a test that checks the behavior when the html sanitizer is used with templated values like |
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.
Still LGTM
@elasticmachine update branch |
This commit upgrades the OWASP HTML sanitizer used by watcher to the latest version and also upgrades guava, which it depends on. The guava upgrade also requires the addition of a new dependency that guava itself requires as of version 27.0. The sanitizer's behavior has changed to re-write these templated values with a comment that results in this output `{<!-- -->{ctx.metadata.name}}`. This would be an issue if we attempted to sanitize the template, but the code that uses the sanitizer runs the rendered string through the sanitizer, which means that the templated values have been replaced already. Relates elastic#50395
This commit upgrades the OWASP HTML sanitizer used by watcher to the latest version and also upgrades guava, which it depends on. The guava upgrade also requires the addition of a new dependency that guava itself requires as of version 27.0. The sanitizer's behavior has changed to re-write these templated values with a comment that results in this output `{<!-- -->{ctx.metadata.name}}`. This would be an issue if we attempted to sanitize the template, but the code that uses the sanitizer runs the rendered string through the sanitizer, which means that the templated values have been replaced already. Relates #50395
This commit upgrades the OWASP HTML sanitizer used by watcher to the latest version and also upgrades guava, which it depends on. The guava upgrade also requires the addition of a new dependency that guava itself requires as of version 27.0. The sanitizer's behavior has changed to re-write these templated values with a comment that results in this output `{<!-- -->{ctx.metadata.name}}`. This would be an issue if we attempted to sanitize the template, but the code that uses the sanitizer runs the rendered string through the sanitizer, which means that the templated values have been replaced already. Relates elastic#50395
This commit upgrades the OWASP HTML sanitizer used by watcher to the
latest version and also upgrades guava, which it depends on. The guava
upgrade also requires the addition of a new dependency that guava
itself requires as of version 27.0.
Relates #50395