I have a requirement in my web application, that I need to register a user with their phone number instead of email and password.
The system should take the input of the user's phone number and send an OTP SMS to that phone number. If the OTP matches, I need to create user.
I tried 2FA with asp.net identity, but it works only when the user is already registered and the phone number is updated in the user table.
Can someone kindly help me.
Thanks in Advance.
Tarak
You will have to use a paid sms link given by sms provider to send text to particular phone number.
For e.g - When a user register on your site , his/her number will be inserted in the database and an OTP will be created and inserted against that phone number , the link will be use to send OTP to the following phone number. So during login the user will be asked the otp and if the otp he/she got on mobile matches with the otp from database then the login would be successful. I don't think there is any method to send text to a phone number like that . You will have to use some paid sms provider link or something like that . I hope i have answered your question.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With