You need to sign in to do that
Don't have an account?
Avish Samdani 5
I am getting CSP error while embed a component using salesforce Canvas app.
I have created one lightning component. The lightning component is rendering the canvas app content. Cacnvas app content is loading perfectly. In the canvas app there is button, On click of that button they are opening the content in i-frame. When I click button I am getting the following error:
Refused to frame "IFrame content URL" because an ancestor violates the following Content Security Policy directive: "frame-ancestors Canvas app url".
Is there any configuration we need to change in salesforce. As far as I know this is blocking by CSP.
Refused to frame "IFrame content URL" because an ancestor violates the following Content Security Policy directive: "frame-ancestors Canvas app url".
Is there any configuration we need to change in salesforce. As far as I know this is blocking by CSP.
Check steps mentioned below and try to disable clickjack under setup-->session settings.
https://help.salesforce.com/s/articleView?id=sf.csp_trusted_sites.htm&type=5
https://salesforce.stackexchange.com/questions/262697/content-security-policy-error-while-loading-apex-iframe
Please mark as Best Answer if above information was helpful.
Thanks,
Thank you for your response. I already try to disable clickjack & I have also added URL in CSP trusted. But It didn't work for me.