Skip to content

fix(platform-browser): disallow event handler attributes in Meta - #70127

Open
SkyZeroZx wants to merge 2 commits into
angular:mainfrom
SkyZeroZx:fix/event-handle-meta
Open

fix(platform-browser): disallow event handler attributes in Meta#70127
SkyZeroZx wants to merge 2 commits into
angular:mainfrom
SkyZeroZx:fix/event-handle-meta

Conversation

@SkyZeroZx

Copy link
Copy Markdown
Contributor

Prevent arbitrary MetaDefinition properties from writing on* handlers directly to meta elements. Browser events can execute these handlers, including on meta elements rendered in the document body.

Reject handler attributes case-insensitively before matching or mutating tags.

Fixes #70126

@angular-robot angular-robot Bot added the area: core Issues related to the framework runtime label Aug 8, 2026
@ngbot ngbot Bot added this to the Backlog milestone Aug 8, 2026
@SkyZeroZx
SkyZeroZx marked this pull request as ready for review August 9, 2026 22:45
@pullapprove
pullapprove Bot requested a review from crisbeto August 9, 2026 22:45

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we go with this fix, we probably also want to cover the prototype keys.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

Prevent arbitrary MetaDefinition properties from writing on* handlers directly to meta elements. Browser events can execute these handlers, including on meta elements rendered in the document body.

Reject handler attributes case-insensitively before matching or mutating tags.

Fixes angular#70126
@SkyZeroZx
SkyZeroZx force-pushed the fix/event-handle-meta branch from 448bf39 to 30c0429 Compare August 14, 2026 19:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: core Issues related to the framework runtime

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Meta service allows executable event-handler attributes

2 participants