step-up-labs / firebase-authentication-dotnet

C# library for Firebase Authentication
MIT License
383 stars 131 forks source link

Phone Number Authentication #58

Open cabauman opened 6 years ago

cabauman commented 6 years ago

Do you have plans to add phone number authentication? If not, would you mind pointing me in the general direction of how I might implement this myself? I can't find anything related in the officail rest docs: https://firebase.google.com/docs/reference/rest/auth

bezysoftware commented 6 years ago

As far as I know there is no official documentation for any type of firebase authentication. When implementing the oauth / email authentication, I had to sniff the traffic generated by the official javascript library (using Fiddler). It probably shouldn't be that difficult to do

EmilAlipiev commented 6 years ago

@bezysoftware link above is official documentation indeed but I cant find anything regarding Phone authentication. @cabauman did you find any rest api information for sms authentication. it seems that it is not supported using rest api.

cabauman commented 6 years ago

@EmilAlipiev I didn't find anything. I'll probably just end up using Authy or something like that as a fallback

EmilAlipiev commented 6 years ago

@cabauman i didnt know about this service. it looks interesting but you still have to pay for sms and email services while firebase offer free option.

mektebi commented 6 years ago

Any updates?

EmilAlipiev commented 6 years ago

I asked this question to google team directly and they told me that rest API doesnt have phone Auth and they have no plan to implement it over the API.

cabauman commented 6 years ago

Thanks Emil. Good to know.

My workaround for my project that needed phone auth was wrapping the Xamarin Android and iOS bindings into a shared API so I could use them from a netstandard library: https://github.com/cabauman/FirebaseAuthWrapper

danmincu commented 4 years ago

I also looked into this and why there is no phone login. I think the lack of support revolves around the fact that if the call is not protected by something like captcha the service could be easily abused! The end point that is starting the process takes a phone number and a recaptcha token

https://www.googleapis.com/identitytoolkit/v3/relyingparty/sendVerificationCode?key=YourKey

{"phoneNumber":"+16135556666","recaptchaToken":"03AOLTBLRezJbMZ2K21mdT9rk-BmTc-......w"}

Firebase API have a C++ version for it, wondering how that works?! I might be only for C++ for mobile where the call obtains some hardware identification preventing spam? I wish firebase would create a usecase where this type of login would be possible. Thoughts?

bezysoftware commented 4 years ago

Another possibility is that they show the captcha inside webview? That's what I intend to do in the v4

hardeep3 commented 2 months ago

Another possibility is that they show the captcha inside webview? That's what I intend to do in the v4

Need help here. Did you create a v4 including phone auth? I have phone auth working on mobile and web and just need to add it to Windows desktop app. My requirements is to use phone auth only. Thanks!