Skip to content

Fullpage redirect with JavaScript doesn't work in Rails 5.2 due to Content Security Policy #535

@damhonglinh

Description

@damhonglinh

Reproduce steps:

  1. In Chrome, go to https://myapp-domain.com/login?shop=abc.myshopify.com
  2. You will see an error in DevTools console: Refused to execute inline script because it violates the following Content Security Policy directive: "script-src 'self' https:". Either the 'unsafe-inline' keyword, a hash ('sha256-sometokenhere='), or a nonce ('nonce-...') is required to enable inline execution

This happens in Rails 5.2 (for example I use 5.2.0.beta2) and is due to a new security feature in Rails 5.2: rails/rails#31162

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions