Hey Guys,
Where is NSDefaults stored on iphone? Is it a good practice to store UserName and password in NSDefaults?
Thanks
Hey Guys,
Where is NSDefaults stored on iphone? Is it a good practice to store UserName and password in NSDefaults?
Thanks
All you really need to know is that the data is saved, is backed up and is available between restarts.
It is not, however, secure. You shouldn't really use it for storing passwords or anything else that's likely to be sensitive. Lots of apps do this anyway, even some big names, but it's certainly not good practice. The keychain can be used when you need something more secure, though it's not as easy to use as NSUserDefaults
.