Authenticatin issue within Salesforce

Hi friends, 

In my company we are using Salesforce and we would like to embed Dashboard withing Salesforce. 

I tried to use the following embed function: 

<apex:iframe src="https://selina.looker.com/embed/dashboards/459?allow_login_screen=true"  width="100%" id="theIframe"/>

if the user is authenticated the it will work perfectly ! 

if the user is not authenticated then it will redirect to the login page. In my company we use Google authentication and for some reason  when we try to login in Looker via google authentication through Salesforce then we get “accounts.google.com refused to connect.”

I have no idea how to solve it .. could you please help me 

Thx you very much 

0 3 1,000
3 REPLIES 3

I bet this is an X-Frame-options issue related to the salesforce iframe. Google.com isn’t allowing the connection (or the salesforce page isn’t allowing it ) due to something related to the iframe options. 

I’m not 100% sure what the fix would be, but you can verify whether this is/isn’t the issue by adding this chrome extension: https://chrome.google.com/webstore/detail/ignore-x-frame-headers/gleekbfjekiniecknbkamfmkohkpodhe?hl... and then trying again.

Thx for your answer @izzy
I tried the extension. and now I see the Gmail login page.. 

I enter my email .. and then I get an error 

Something went wrong

Sorry, something went wrong there. Try again.

 

Next

and if I click Next:

400. That’s an error.

The server cannot process the request because it is malformed. It should not be retried. That’s all we know.

Any idea ? please 

Hi @ben2pop - Google, like most IDPs (identity providers), chooses not to allow the embedding of their credentials UI into other domains. (This is for good reason as it would get users into a habit of entering their Google credentials into what appears to be a non-Google page!)

The best solution at this time, if you can write JS in the parent page, is to listen for JS events from Looker, and if you have not received them after some predetermined amount of time (say 5s) then present the user with the option to navigate to Looker in the top window, so they can authenticate there. The target Looker content can have a link back to the original page, either statically hard-coded, or based on a URL parameter (using either liquid in an html parameter in a dashboard, or using a looker extension)