8000 setting cssText rather than style · Issue #774 · w3c/webappsec-csp · GitHub
[go: up one dir, main page]

Skip to content

setting cssText rather than style #774

@johanneswilm

Description

@johanneswilm

Aftr reading through the discussion on #212, it's still unclear to me why a CSP policy of style-src-attr 'self' will disallow:

dom.setAttribute("style", "background-col
5D1E
or: blue;")

but not:

dom.style.cssText = "background-color: blue;"

Why is it safer to set the cssText rather than the style attribute?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0