I have an application where the user can log in but i don't want the user to enter his credentials every time he wants to use the application. 1 time would be sufficient but how(and whats the best way) to save 2 strings that i can revive by starting the application.
Asked
Active
Viewed 1,131 times
0
-
See this thread as well: [http://stackoverflow.com/questions/523627/storing-passwords-in-iphone-applications/524144#524144](http://stackoverflow.com/questions/523627/storing-passwords-in-iphone-applications/524144#524144) – August Feb 12 '09 at 21:10
1 Answers
12
The iPhone has a keychain API just like OS X. Or you could just store them using NSUserDefaults which would be easier but less secure.

Stephen Darlington
- 51,577
- 12
- 107
- 152
-
1Please don't store them using NSUserDefaults, you wouldn't want too expose passwords of your users when they for example lose their iPhone. – Georg Schölly Feb 06 '09 at 17:20
-