Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Invalid SHA-512 integrity after deployment #595

Open
hmaier-fws opened this issue Aug 29, 2023 · 1 comment
Open

Invalid SHA-512 integrity after deployment #595

hmaier-fws opened this issue Aug 29, 2023 · 1 comment
Assignees
Labels
maintenance Minor updates or code refactoring not impacting current functions

Comments

@hmaier-fws
Copy link
Contributor

Issue

mdEditor Version (find version under settings): https://github.com/adiwg/mdEditor/tree/99f027be

mdEditor Web Address (enter the URL): Current DEVELOP branch deployed to gh-pages

Issue Description:

Browser throws error:

Failed to find a valid digest in the 'integrity' attribute for resource 'https://go.mdeditor.org/assets/vendor-c268ca4ccc457053f9f16d66a5743391.css' with computed SHA-512 integrity 'mmE9eEeu2uUCyyOLbutrLxnRnL5CrbF6OP1RDxShKbzYtbSSYfyM7FQFp0eN81Ig4yGQpV9yOPb83gBbeQSulA=='. The resource has been blocked.

and icons do not display:

2023-08-29 01_21_15-Import

Steps to reproduce (Bug reports only):

  1. The application was built locally and renders as expected with no errors
  2. When deployed to production the above behavior was observed
  3. Behavior observed in both Chrome and Edge

Temporary work around:

The index.html (on the gh-pages branch) was manually edited to set the integrity value from a SHA to null:

<link rel="stylesheet" href="/assets/vendor-c268ca4ccc457053f9f16d66a5743391.css" integrity="" >

This seemed to provide a temporary fix and the page renders as expected.

@hmaier-fws hmaier-fws added bug Unexpected problem or unintended behavior !!Priority!! Needs to happen ASAP! labels Aug 29, 2023
@jwaspin
Copy link
Contributor

jwaspin commented Aug 29, 2023

 if (environment === 'production') {
    //ENV.rootURL = '/mdEditor';
    ENV.locationType = 'hash';
  }

That snippet starts on line 101 of config/environment.js

Looks like that might be the issue. Index.html is expecting a value for rootURL before adding /assets/vendor.css

@hmaier-fws hmaier-fws added maintenance Minor updates or code refactoring not impacting current functions and removed bug Unexpected problem or unintended behavior !!Priority!! Needs to happen ASAP! labels Dec 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
maintenance Minor updates or code refactoring not impacting current functions
Projects
None yet
Development

No branches or pull requests

3 participants