fix(deps): update dependency sanitize-html to v2 [security] #523
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
^1.27.5
->^2.0.0
GitHub Vulnerability Alerts
CVE-2024-21501
Versions of the package sanitize-html before 2.12.1 are vulnerable to Information Exposure when used on the backend and with the style attribute allowed, allowing enumeration of files in the system (including project dependencies). An attacker could exploit this vulnerability to gather details about the file system structure and dependencies of the targeted server.
CVE-2022-25887
The package sanitize-html before 2.7.1 are vulnerable to Regular Expression Denial of Service (ReDoS) due to insecure global regular expression replacement logic of HTML comment removal.
Release Notes
apostrophecms/sanitize-html (sanitize-html)
v2.12.1
Compare Source
post-css
. This fixes a vulnerability in which information about the existence or non-existence of files on a server could be disclosed via properly crafted HTML input when thestyle
attribute is allowed by the configuration. Thanks to the Snyk Security team for the disclosure and to Dylan Armstrong for the fix.v2.12.0
Compare Source
Introduced the
allowedEmptyAttributes
option, enabling explicit specification of empty string values for select attributes, with the default attribute set toalt
. Thanks to Na for the contribution.Clarified the use of SVGs with a new test and changes to documentation. Thanks to Gauav Kumar for the contribution.
Do not process source maps when processing style tags with PostCSS.
v2.11.0
Compare Source
false
inallowedClasses
attributes. Thanks to Kevin Jiang for this fix!.idea
temp files to.gitignore
v2.10.0
Compare Source
disallowedTagMode
is set to any variant ofescape
-- just escape the disallowed tags that are present. This fixes issue #464. Thanks to Daniel LiebnertagAllowed()
helper function which takes a tag name and checks it againstoptions.allowedTags
and returnstrue
if the tag is allowed andfalse
if it is not.v2.9.0
Compare Source
v2.8.1
Compare Source
v2.8.0
Compare Source
htmlparser2
to new major version^8.0.0
. Thanks to Kedar Chandrayan for this contribution.v2.7.3
Compare Source
false
, then do not assume that all tags are allowed. Rather, allow no tags in this case, to be on the safe side. This matches the existing documentation and fixes issue #176. Thanks to Kedar Chandrayan for the fix.v2.7.2
Compare Source
Kedar Chandrayan for the report and the fix.
v2.7.1
Compare Source
v2.7.0
Compare Source
<img />
tags. Thanks to Zade Viggers.v2.6.1
Compare Source
!important
when used.transformTags
options that was reported on issue #506. Thanks to Alex Rantos.v2.6.0
Compare Source
allowedClasses
option. Thanks to Alex Rantos.v2.5.3
Compare Source
v2.5.2
Compare Source
null
,undefined
or implicitundefined
when value is not provided. Thanks to Artem Kostiuk for the contribution.v2.5.1
Compare Source
allowedScriptHostnames
andallowedScriptDomains
options now implicitly purge the inline content of all script tags, not just those withsrc
attributes. This behavior was already strongly implied by the fact that they purged it in the case where asrc
attribute was actually present, and is necessary for the feature to provide any real security. Thanks to Grigorii Duca for pointing out the issue.v2.5.0
Compare Source
allowedScriptHostnames
option, it enables you to specify which hostnames are allowed in a script tag.allowedScriptDomains
option, it enables you to specify which domains are allowed in a script tag. Thank you to Yorick Girard for this and theallowedScriptHostnames
contribution.v2.4.0
Compare Source
allowedClasses
. Thanks to zhangbenber for the contribution.v2.3.3
Compare Source
allowedSchemes
and related options did not properly block schemes containing a hyphen, plus sign, period or digit, such asms-calculator:
. Thanks to Lukas Euler for pointing out the issue.parser
option, especiallydecodeEntities: false
. See the documentation.v2.3.2
Compare Source
yarn add
syntax. Thanks to Tagir Khadshiev for the contribution.v2.3.1
Compare Source
v2.3.0
Compare Source
htmlparser2
to new major version^6.0.0
. Thanks to Bogdan Chadkin for the contribution.v2.2.0
Compare Source
tel
to the defaultallowedSchemes
. Thanks to Arne Herbots for this contribution.v2.1.2
Compare Source
v2.1.1
Compare Source
allowedClasses
with an'*'
wildcard selector. Thanks to Clemens Damke for this contribution.v2.1.0
Compare Source
sup
added to the default allowed tags list. Thanks to Julian Lam for the contribution.allowedTags
README documentation. Thanks to Marco Arduini for the contribution.v2.0.0
Compare Source
nestingLimit
option added.is-plain-object
package with named export. Thanks to Bogdan Chadkin for the contribution.postcss
package and drop Node 11 and Node 13 support (enforced by postcss).Backwards compatibility breaks:
allowedTags
array was updated significantly. This mostly added HTML tags to be more comprehensive by default. You should review your projects and consider theallowedTags
defaults if you are not already overriding them.Configuration
📅 Schedule: Branch creation - "" in timezone GMT, Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR has been generated by Mend Renovate. View repository job log here.