Win a copy of Java Persistence with Spring Data and Hibernate this week in the Spring forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Tim Cooke
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • Junilu Lacar
  • Rob Spoor
  • Jeanne Boyarsky
Saloon Keepers:
  • Stephan van Hulst
  • Carey Brown
  • Tim Holloway
  • Piet Souris
Bartenders:

How to implement security with App+database

 
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
In play store, I found an App I want to do the same security that the developer did there.
The App consists of 4 tabs the first and second is available to everyone after installing the App, but tab3 and tab4 is not available, when we click on tab3 there is a text for a just password, we need to contact the developer to pay fee and give him the password and the brand of the phone , then the tab3 and 4 will be activated.
The app brings information from a database for tab1 and tab3 and tab4
is anyone has an idea how to implement that like, can we use FirbaseStorage, or we need to use Mysql or other databases.

Note: If password used with different devices, it will not working.


1.jpg
[Thumbnail for 1.jpg]
2.jpg
[Thumbnail for 2.jpg]
 
Bartender
Posts: 7488
171
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Sounds like a standard use case for in-app billing.

can we use FirbaseStorage, or we need to use Mysql or other databases.


I don't see how the choice of a DB plays into this.

If password used with different devices, it will not working.


You might want to rethink that. The standard expectation on Android is that all apps work on all devices where a user is signed in with the same Google account. You would have to have a very good reason to break this expectation in order not to antagonize users.
 
Muhannd Dhahier
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
But I think with the Firebase DB I can't just use a password .I need username and password.

also, I noticed in this App the password will be working only on one device.I think the developer get IMEI number from the device that installs the App to prevent use the password with the different device, Is this against Google policy to get the IMEI and save it to chek later?
 
Tim Moores
Bartender
Posts: 7488
171
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

But I think with the Firebase DB I can't just use a password .I need username and password.


I think the easiest way to authenticate a user would be by tapping into their Google account: https://developers.google.com/identity/sign-in/android/sign-in. If you want to roll your own (which I wouldn't recommend), you could write a REST web service that handles authentication. That way it wouldn't matter what kind of DB is used.

also, I noticed in this App the password will be working only on one device.I think the developer get IMEI number from the device that installs the App to prevent use the password with the different device, Is this against Google policy to get the IMEI and save it to chek later?


Why do you want the password to work on a single device only, rather than for a single user? These days everyone has multiple devices, and being able to use just a single one would be an inconvenience that users will neither expect nor like.
 
Muhannd Dhahier
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Because of  when he buy the App, he will not able to share the password with the others
 
Tim Moores
Bartender
Posts: 7488
171
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
In that case, tapping into the Google account is even better, since people definitely will not share those credentials.

But either way, you're better off making user's life easier instead of antagonizing them.
 
Muhannd Dhahier
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I agree with you but most of the users don't have Gmail account, they want just used a password to login and chek the information, I wish that I can use the Google account or whatever email for credentials, but these are the requirement for this App.
 
See ya later boys, I think I'm in love. Oh wait, she's just a tiny ad:
The Low Tech Laboratory Movie Kickstarter is LIVE NOW!
https://www.kickstarter.com/projects/paulwheaton/low-tech
reply
    Bookmark Topic Watch Topic
  • New Topic