Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

fix($sanitize): blacklist the usemap attribute #14903

Closed
wants to merge 2 commits into from

Conversation

gkalpak
Copy link
Member

@gkalpak gkalpak commented Jul 12, 2016

Backport of 234053f.

BREAKING CHANGE:

The $sanitize service will now remove instances of the usemap attribute from any elements passed to it.

This attribute is used to reference another element by name or id. Since the name and id attributes are already blacklisted, a sanitized usemap attribute could only reference unsanitized content, which is a security risk.

@petebacondarwin
Copy link
Contributor

LGTM

@attritionorg
Copy link

Is this fix related to http://pivotal.io/security/cve-2016-0926?

@gkalpak
Copy link
Member Author

gkalpak commented Jul 13, 2016

@attritionorg , I doubt it, since this is a backport of 234053f, which has been fixed since January 22, 2016.

@gkalpak gkalpak force-pushed the fix-sanitize-blacklist-usemap branch 2 times, most recently from 9663574 to bcbba15 Compare July 13, 2016 09:56
… a security exploit

Backport of 234053f.

BREAKING CHANGE:

The `$sanitize` service will now remove instances of the `usemap` attribute from any elements passed
to it.

This attribute is used to reference another element by `name` or `id`. Since the `name` and `id`
attributes are already blacklisted, a sanitized `usemap` attribute could only reference unsanitized
content, which is a security risk.
@gkalpak gkalpak force-pushed the fix-sanitize-blacklist-usemap branch 2 times, most recently from f816828 to ebce5b0 Compare July 13, 2016 10:44
@gkalpak gkalpak force-pushed the fix-sanitize-blacklist-usemap branch from ebce5b0 to 9f63bb4 Compare July 13, 2016 10:52
gkalpak added a commit that referenced this pull request Jul 13, 2016
… a security exploit

Backport of 234053f.

Closes #14903

BREAKING CHANGE:

The `$sanitize` service will now remove instances of the `usemap` attribute from any elements passed
to it.

This attribute is used to reference another element by `name` or `id`. Since the `name` and `id`
attributes are already blacklisted, a sanitized `usemap` attribute could only reference unsanitized
content, which is a security risk.
@gkalpak
Copy link
Member Author

gkalpak commented Jul 13, 2016

Merged as ac0d528 and dd4ce50.

@gkalpak gkalpak closed this Jul 13, 2016
@gkalpak gkalpak deleted the fix-sanitize-blacklist-usemap branch July 13, 2016 12:00
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants