APIs & Integrations

AndrewHo
Participante

Content-Security-Policy-Report-Only from app.hubspot.com is reporting errors to browsers

resolver

When embedding a Hubspot form in a website, Chrome is showing the following issues in Devtools:

 

Refused to frame app.hubspot.com because an ancestor violates the following Content Security Policy directive: "frame-ancestors 'self'".

 

I tried several changes to my own site's Content Security Policy however I am sure this is because the Content-Security-Policy-Report-Only is incorrectly configures on the domain app.hubspot.com where this is the directive:

 

frame-ancestors 'self'; report-uri ...

 

As far as I understand how frame-ancestors works, this directive is basically saying that only app.hubspot.com can use the reporting API? However the idea of the Reporting API is that clients send their issues to it when an error or issues occrurs in their browser. Hence I believe the correct change to remove these errors in clients browsers would be to remove the frame-ancestorsdirective.

 

More information is available here: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy-Report-Only

1 Solução aceita
dennisedson
Solução
Equipe de Produto da HubSpot
Equipe de Produto da HubSpot

Content-Security-Policy-Report-Only from app.hubspot.com is reporting errors to browsers

resolver

OK everyone, I have been told that a fix has been deployed.  Let me know what you all are seeing out there now 😀

Exibir solução no post original

43 Respostas 43
dennisedson
Solução
Equipe de Produto da HubSpot
Equipe de Produto da HubSpot

Content-Security-Policy-Report-Only from app.hubspot.com is reporting errors to browsers

resolver

OK everyone, I have been told that a fix has been deployed.  Let me know what you all are seeing out there now 😀

Swarnendu
Membro

Content-Security-Policy-Report-Only from app.hubspot.com is reporting errors to browsers

resolver

Is this happening again? 

https://outplayhq.com/meeting-with-outplay

0 Avaliação positiva
Swarnendu
Membro

Content-Security-Policy-Report-Only from app.hubspot.com is reporting errors to browsers

resolver

Pls help here? The iframe of hubspot meetings embed is not loading

0 Avaliação positiva
MHamlin
Membro

Content-Security-Policy-Report-Only from app.hubspot.com is reporting errors to browsers

resolver

Did this issue get un-fixed? 🙂 'm getting this error today.

0 Avaliação positiva
FFraga
Membro

Content-Security-Policy-Report-Only from app.hubspot.com is reporting errors to browsers

resolver

it seems to be all good now, thanks!

AlbertoSM
Participante | Parceiro
Participante | Parceiro

Content-Security-Policy-Report-Only from app.hubspot.com is reporting errors to browsers

resolver

I have the same issue. Any news?

0 Avaliação positiva
dennisedson
Equipe de Produto da HubSpot
Equipe de Produto da HubSpot

Content-Security-Policy-Report-Only from app.hubspot.com is reporting errors to browsers

resolver

@AlbertoSM , not yet, but I do know that it is being worked on.

0 Avaliação positiva
philipcron
Participante

Content-Security-Policy-Report-Only from app.hubspot.com is reporting errors to browsers

resolver

Same situation here. I tried to update things on my end but it did not fix the issue. Hoping for a fix on HubSpot's side.

https://kpstaffing.com/ 

0 Avaliação positiva
CAndres
Participante

Content-Security-Policy-Report-Only from app.hubspot.com is reporting errors to browsers

resolver

@dennisedson This seems like it can only be fixed on HubSpot's side. 
Could you confirm if HubSpot acknowledges that's the case and if they plan to work on a fix? 




dennisedson
Equipe de Produto da HubSpot
Equipe de Produto da HubSpot

Content-Security-Policy-Report-Only from app.hubspot.com is reporting errors to browsers

resolver

Hey all, The team is looking into this.  I will report back when I have an update.

Jeff_videommerc
Membro

Content-Security-Policy-Report-Only from app.hubspot.com is reporting errors to browsers

resolver

Hi Dennis, did you solve this issue? now even the messages are not delivered via HubSpot forms

dennisedson
Equipe de Produto da HubSpot
Equipe de Produto da HubSpot

Content-Security-Policy-Report-Only from app.hubspot.com is reporting errors to browsers

resolver

The team is looking into it.  Will report back when I have confirmed the resolution

Dpontarelli
Participante | Parceiro Platinum
Participante | Parceiro Platinum

Content-Security-Policy-Report-Only from app.hubspot.com is reporting errors to browsers

resolver

Hello, we're having the exact same issue with the Content Security policy. Has anyone resolved this yet? 

04705
Participante

Content-Security-Policy-Report-Only from app.hubspot.com is reporting errors to browsers

resolver

Same issue is causing your scripts such as forms.hubspot.com from loading in Firefox, Chrome and Safari (browsers detecting it as an invalid CORS request and blocking it), because of this our lead captures from forms aren't working.

GCiampa
Participante

Content-Security-Policy-Report-Only from app.hubspot.com is reporting errors to browsers

resolver

I am having this same issue! Has anyone managed to resolve it?

0 Avaliação positiva
GCiampa
Participante

Content-Security-Policy-Report-Only from app.hubspot.com is reporting errors to browsers

resolver

Hi all, we managed to resolve this issue. In our case, it was because our site did not support iframes. Every Hubspot code is essentially, in an iframe. It took some work form our developer but it was a pretty quick fix.

IWatt
Participante

Content-Security-Policy-Report-Only from app.hubspot.com is reporting errors to browsers

resolver

That's great news, GCiampa. Could your developer provide any guidance as to what the fix was? We are really struggling here with this same issue and would love to see if we could replicate your approach.

dennisedson
Equipe de Produto da HubSpot
Equipe de Produto da HubSpot

Content-Security-Policy-Report-Only from app.hubspot.com is reporting errors to browsers

resolver

The best bet would be work with your site admin to update the content security policy

Here is some documentation on it.

0 Avaliação positiva
tinyfly
Participante

Content-Security-Policy-Report-Only from app.hubspot.com is reporting errors to browsers

resolver

The original poster is correct, this needs to be handled by Hubspot. The frame-ancestors content security policy setting is on Hubspot's side to change. In Hubspot's CSP for `https://app.hubspot.com/` frame-ancestors is set to 'self'. This means that `https://app.hubspot.com` is only allowed to be loaded on app.hubspot.com itself and not in an iframe on any other domains.

 

However, when you use the form embed code it tries to load `https://app.hubspot.com/forms-next-v2-captcha` as part of the payload. So this either needs to be moved to another domain that is allowed to be embedded in iframes or remove the frame-ancestors directive from the app.hubspot.com CSP.

FFraga
Membro

Content-Security-Policy-Report-Only from app.hubspot.com is reporting errors to browsers

resolver

Hi, I'm having the same issue. Page: https://www.kaimaging.com/medical-solutions/reveal-35c-medical/

Content Security Policy of your site blocks some resources because their origin is not included in the content security policy header

 

How's the best way to solve this?

toscanabike
Membro

Content-Security-Policy-Report-Only from app.hubspot.com is reporting errors to browsers

resolver

I also have the same error, plus I cannot see the form properly in mobile... if someone can help, it would be very appreciated. The link is https://toscanabike.it/escursioni_mtb/da-lucca-a-viareggio-in-mountain-bike-nuova-variante/

 

thanx