Workaround for web-view blocking google authentication within a web application - firebase

Good Morning,
So I am facing a dilemma using Firebase Auth (specifically Google OAuth).
Google seems to have blocked the use of their OAuth when a user access my site via a web-view (for example they have clicked on the link in TikTok and the website has opened within a view in TikTok)
It makes sense as to why Google has blocked this, however, this is now stopping my ads from being successful as users see the ad, click on the link, and then it opens up in the TikTok web view, and then they can't log into my web application.
I'm using the simple Firebase Authentication plugin, with Nuxt/Firebase the code for it is as below:
const provider = new this.$fireModule.auth.GoogleAuthProvider()
provider.setCustomParameters({
prompt: 'select_account'
})
this.$fire.auth.signInWithPopup(provider)
Does anyone know any workaround? I've googled this so much but the only real solution I have come across is if I'm creating an android/ios app and this is not a mobile application, this is just a web application.
Thanks so much for your help.

Related

PWA with Windows Authentication

On the high level, I have a PWA with React frontend and .netcore backend. I use service worker for caching and offline ability, in conjunction with workbox plugins for some precaching feature.
The app uses Windows Authentication. Which works fine if it wasn't a PWA app. It also works fine the first time the PWA app launches, I get the username, password login popup.
However from the second time visiting the app, it wouldn't show the login popup, the app fails at pulling data from the backend because it is unauthenticated. One weird behavior is that, if I open Chrome Dev Tools(by F12), then the login popup immediately shows up.
I thought it's caching related and somehow the service worker interfered with the server side authentication workflow. Maybe because the index page is cached by the workbox precache plugins, and it did not cache with the fetch header of 'credentials': 'include'? I tried adding the fetch option to other api routes, which are cached by workbox plugin RegisterRoute. However I didn't find a way to add it to the precacheAndRoute(self.__WB__MANIFEST). Wondering if that's the problem. But I'm also not sure why having Dev Tools open would trigger the popup to display.
Any input is appreciated.

Can I use Firebase Dynamic Links for a web app?

I don't see any option for Web under "receiving dynamic links" in Firebase Dynamic links page.
Without the SDK, there's no way to connect a post-install user with a pre-install click.
I have a desktop app that runs on node.js like a web app, using nw.js. What I'm trying to do is create referral links for users. After someone clicks a referral link, I need to be able to track his referrer. But the problem is that link is only going to take him to the download page, after he downloads and opens up the app for the first time, how can I reach his referrer info? The desktop app has no connection with the website that users download from.
I understand that this can be done with Dynamic Links SDK but can I use that SDK in a web app?(desktop app actually but runs with HTML/node.js)
The post-install deeplinking in Dynamic Links is just for Android and iOS - so there isn't an equivalent for a desktop app.

Facebook Logon not working properly with Azure Mobile Client in Xamarin.Forms

I'm implementing Facebook Logon with Azure Mobile Client in Xamarin.Forms. In iOS, after entering login name and password, it directed to the confirmation page but I couldn't click anything on the screen. The loading icon kept running and should represent that the loading hadn't completed yet. Anyone encountered similar situation and anything I could do to fix it?
There are/were issues with Facebook auth on Azure App Service due to a deprecation in the Facebook side of the OAuth dance. See https://social.msdn.microsoft.com/Forums/en-US/397f6952-57bf-4c28-b383-6bba08d28f9a/facebook-login-failures-with-app-service-authentication-authorization?forum=windowsazurewebsitespreview for more details.

Membership.OpenAuth with Twitter works but keeps asking to Authorize App

I am using ASP.NET forms (not MVC) along with their out of the box templated solution for logging using Facebook, Twitter, etc (all wrapped up in Microsoft.AspNet.Membership.OpenAuth).
Everything seems to be working fine except for one thing: Every time a user logs in with Twitter, they are being redirected to Twitter and asked to Authorize the application. Regardless of whether they have done it already (i.e. The user logins for first time, authorizes against the Twitter app, get redirected back to our site perfectly. Then they log out, and go to log in again, and they are re-prompted to authorize. The application shows up in the list of approved apps under the user's Twitter account.
I have ready some places where people are having similar problems, but not using the Microsoft libraries. They seem to point to using a different URL when launching to Twitter, however, I don't seem to be able to find that level of granularity with the MS libraries.
Has anyone been able to reproduce/solve this issue using these libraries? I am not intimately familiar with how this all works, but I notice that DotNetOpenAuth is also a part of my references. If this is the library that is feeding the Membership.OpenAuth classes, perhaps there is an update that I need? My DotNetOpenAuth.OAuth version shows 4.1.0.0 and runtime version if v.4.0.30319.
Thanks,
J
I had the same problem. I'm using the following to connect to twitter:
OAuthWebSecurity.RegisterTwitterClient(key, secret)
and using the latest OpenAuth 4.3.0.0
Login works ok, but it keeps asking to Authorize App each time.
Turned out that in my Twitter App settings I did not have the following ticked
Allow this application to be used to Sign in with Twitter
When I ticked this, the normal OAuthWebSecurity.RegisterTwitterClient() worked fine

Creating a simple Google App using ASP.NET

We are working to integrate one of our client's existing accounting system into Google App. Eventually we need to list it on Google App Marketplace.
Here is what we have already done:
Downloaded the sample .NET app available from Google - this one
Created a vendor profile on the Google Apps Marketplace
Listed our test application on the Google Apps Marketplace
So far we have ONLY been able to authenticate the user using DotNetOpenAuth.
We are struggling with following issues:
Unable to access the Calendar Data API and display the next appointment. We are getting 401 Unauthorized when querying the Calendar Data API.
To access the Calendar Data API we need to have a ConsumerKey & a ConsumerSecret - which is made available ONLY after you submit your application for Approval.
We submitted the app for approval to get a ConsumerKey & a ConsumerSecret although its just a pilot app that we are building first. We don't want that app to be published as of now but we could not find a way to keep that listing private and available ONLY for dev & testing purpose as of now.
We have placed the ConsumerKey & ConsumerSecret in the sample marketplace app but even now we get a 401 Unauthorized access while quering the Calendar Data API.
We have already spent 2-3 days trying to find proper documentation for this and get it to work but in vain. Any help / guidance to get it to work and also keep the listing private in dev mode until we are ready, would be really appreciated.
Here is the modified 2 page source code i am trying to run.
There are some key misconceptions in your post.
Your keys are already available to you. Open Marketplace, click on "My Vendor Profile" top right, and look right under the listing, below the stars: View OAuth Consumer Key link is there. If it isn't, you did not mark your app as an installable one. To fix that, create a new app entry, and make sure you provide a valid manifest.
To test your new app, BEFORE you submit your app for approval, open the Marketplace page for it and click the Add it now button. You will be offered a field to enter the Google Apps domain name to test with.
Only domains you add your app to will be accessible with the marketplace key.
Chances are if you sort these two things out things will start working :)

Resources