Image refused to load due to content security policy violation

0

Hello, I uploaded web files provided by our customer to be hosted by an S3 bucket and once I used the URL to display everything worked except one image that could not be loaded and the error message is:"Refused to frame 'https://xxxxxxx.com' becaused it violates the following content security policy directive: "frame-src 'self'. https://xxxxxxx.com

How can I fix it in I guess lambda edge function? We used cloudformation templates.

I am a cloud engineer but do not know much about web stuff.

Many thanks for your help in advance. Del

1 Antwort
0

Your request is violating Content security policy directive as you've mentioned it as ""frame-src 'self'". If you have index.html file, please change the meta tag as shown in the below link. For example you can modify it to - <meta http-equiv="Content-Security-Policy" content="script-src 'self' http://localhost:5000 'unsafe-inline' 'unsafe-eval';">

Link - https://stackoverflow.com/questions/31211359/refused-to-load-the-script-because-it-violates-the-following-content-security-po

AWS
beantwortet vor einem Jahr

Du bist nicht angemeldet. Anmelden um eine Antwort zu veröffentlichen.

Eine gute Antwort beantwortet die Frage klar, gibt konstruktives Feedback und fördert die berufliche Weiterentwicklung des Fragenstellers.

Richtlinien für die Beantwortung von Fragen