Skip to content
This repository has been archived by the owner on Jul 28, 2021. It is now read-only.

CSP Issues? #30

Open
TheLeePriest opened this issue Jul 28, 2020 · 3 comments
Open

CSP Issues? #30

TheLeePriest opened this issue Jul 28, 2020 · 3 comments

Comments

@TheLeePriest
Copy link

Hi,

I have setup the editor and have got everything working fine on my local environment. However when tested on an environment with a CSP an unsafe-eval error is thrown in to the console making the editor unusable.

Is this a known issue? And is there a work around for this?

Thanks

@swtalk
Copy link

swtalk commented Jul 28, 2020 via email

@ambichetan
Copy link

ambichetan commented Dec 17, 2020

Hi,

I have setup the editor and have got everything working fine on my local environment. However when tested on an environment with a CSP an unsafe-eval error is thrown in to the console making the editor unusable.

Is this a known issue? And is there a work around for this?

Thanks

I am also facing issue in prod environment, everything works fine on local machine though. The root cause seems to be with tui-image-editor.js file importing dependency libraries using eval(...) expression, which throws CSP error for any app using CSP directive: "script-src 'self'". It works fine if I add 'unsafe-eval', but it could be a security risk.

Please update the respective webpack bundle script to import dependencies without eval expression.

@swtalk
Copy link

swtalk commented Dec 17, 2020 via email

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants