Reputation: 3697
I am developing an app that requires a user to register and log in. Currently to date I have been storing their userID (retrieved from an API), username and hashed password (plus a few other bits of information) in user defaults however after doing some research on security, users are able to modify these defaults as they are stored in a text file.
My concern is that I would not want a user to change the userID and access other users information. What would be the best way to secure the data in the app?
All information is retrieved from an online API and I am not using Core Data.
I have looked in to Keychain but would this be overkill to store userID?
Upvotes: 0
Views: 1175
Reputation: 11143
The keychain would not be overkill, that kind of thing is what it's for.
Really though it sounds like a bad security problem in your API. If the user can login and can then access the data of every other user via the API and then if they fiddle with some values, that's no good.
Upvotes: 1