Keychain和NSUserDefault之间的区别? [英] Difference between Keychain and NSUserDefault?
问题描述
我是目标C
的新手,我创建了一个应用程序,因为我使用了 NSUserDefault
和 Keychain
用于存储我的用户名和密码。但我无法区分两者。请帮助区分两者。
I am new to objective C
, I have created one application in that I have used both NSUserDefault
and Keychain
to store my user name and password. But I cant differentiate both. Please help to differentiate the both.
谢谢。
推荐答案
钥匙串是一个加密容器,用于存放多个应用程序和安全服务的密码。 Apple Inc.在Mac OS和iOS中使用钥匙串作为密码管理系统。
A keychain is an encrypted container that holds passwords for multiple applications and secure services. Apple Inc. uses keychains as password management system in Mac OS and iOS.
NSUserDefaults 提供基于用户首选项自定义应用程序行为的方法。属于Cocoa和Cocoa Touch的Foundation框架。
NSUserDefaults Provides a way for application behavior customization based on user preferences. Belongs to the Foundation framework for Cocoa and Cocoa Touch.
我从 NSUserdefaults 和钥匙串
这篇关于Keychain和NSUserDefault之间的区别?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!