What are the ways to store user details in encrypted form in database?


I’m a mobile app developer developing an app that gets input from users like mobile number, email id, and user name. I’m a bit confused about how to select the encryption method like Symmetric or Asymmetric and how to transmit the data from the app to the server.

Since I’m developing an app that will get user information like Mobile number, user name, and password. The App will share the user name and mobile number for other users to discover that person. In that way how should I encrypt the data (Mobile number and username) to store it in the database and how to decrypt it later in the App. I’ll hash the password so no worries in storing the password. The only thing is username and Mobile number.

  • What encryption method should I want to use for this scenario?
  • Which algorithm should I choose Symmetric or Asymmetric algorithm?
  • How to store the encryption key safe in the app?