Skip to content

Block Potential XSS #1

@evanplaice

Description

@evanplaice

Due to the eval-like nature of this module, it's possible for externally fetched templates to introduce cross-site-scripting exploits.

To fix this, check the domain of the fetch URL against the site domain. Throw if they don't match. Alternatively, add a param called safe (default true) that -- when set to false -- will allow loading templates from other domains.

Changes

  • add throw if domain-other-than-origin
  • add 'safe' param to circumvent the check when set to false

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