Error while accessing iframe from chorme extension, content_security_policy error

551 Views Asked by At

I am trying to access the Iframe from the chrome plugin and get the below error.

Refused to frame 'https://mysite.co/' because an ancestor violates the following Content Security Policy directive: "frame-ancestors *".

I have already added this below line in my menifest.json file but it not works.

"content_security_policy": "script-src 'self' https://mysite.co/"

Please guide.

1

There are 1 best solutions below

0
Parth Solanki On BEST ANSWER

I found the solution, I have to add child-src for the iframe as below.

"content_security_policy": "script-src 'self' https://mysite.co; child-src https://mysite.co; object-src 'self'"