简体   繁体   English

当应用程序被沙盒化时,为什么 Apple 建议将密码、机密和密钥存储在 iOS Keychain 中?

[英]Why does Apple recommend to store passwords, secrets, and keys in iOS Keychain when apps are sandboxed?

I am struggling to understand the benefit of using iOS keychain to store application passwords, secrets, and keys.我很难理解使用 iOS 钥匙串存储应用程序密码、机密和密钥的好处。 It's the recommended way to "handle" this data but I am not seeing the benefit from a security perspective.这是“处理”这些数据的推荐方法,但从安全角度来看,我没有看到好处。

First, apple claims the keychain prevents other applications from accessing the sensitive data in keychain.首先,苹果声称钥匙串可以防止其他应用程序访问钥匙串中的敏感数据。 The application sandbox design already prevents this, so I don't understand why storing in keychain would be necessary.应用程序沙箱设计已经阻止了这种情况,所以我不明白为什么需要存储在钥匙串中。 Second, apple claims the data is stored "encrypted" in the iOS keychain and once can specify lock/access controls for each keychain item.其次,苹果声称数据“加密”存储在 iOS 钥匙串中,并且一次可以为每个钥匙串项目指定锁定/访问控制。 If a user "roots" the device (jailbreaks the phone), there are tools out there that can access the entire data in the iOS keychain, rendering the keychain encryption and access controls useless.如果用户“root”了设备(越狱手机),则有一些工具可以访问 iOS 钥匙串中的全部数据,从而使钥匙串加密和访问控制变得无用。

It sounds like to me all the iOS keychain does is add extra overhead, from a security perspective Apple's application sandboxing and application code signing should be enough to protect sensitive application data.在我看来,iOS 钥匙串所做的一切只是增加了额外的开销,从安全角度来看,Apple 的应用程序沙箱和应用程序代码签名应该足以保护敏感的应用程序数据。 We should be able to simply store sensitive data on an iOS app's file system or in code, and rely on Apple's app sandboxing and code signing.我们应该能够简单地将敏感数据存储在 iOS 应用程序的文件系统或代码中,并依赖 Apple 的应用程序沙箱和代码签名。 Am I missing something?我错过了什么吗?

您错过的一件事是即使应用程序被删除,存储的数据仍将保留在钥匙串中,因此可以在用户重新安装应用程序的情况下检索它,这与应用程序文件系统上的数据不同,当应用程序运行时会丢失已移除。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 iOS Keychain 数据是否被沙盒化了? - Is iOS Keychain data sandboxed? 我可以在iOS钥匙串中为一个用户存储/检索多个密码吗? - Can I store/ retrieve multiple passwords in the iOS keychain for a single user? 如何使用iOS钥匙串存储多个用户名和密码? - How can I store multiple usernames and passwords with the iOS keychain? Apple是否会修改提交到App Store的应用程序上的iOS应用程序可执行文件? - Does Apple modify iOS application executables on apps submitted to the App Store? Apple 是否接受应用商店中带有静态链接 OpenSSL 的 iOS 应用? - Does Apple accept iOS apps with statically linked OpenSSL in the app store? 苹果为何建议将枚举类型定义为NSInteger? - Why does Apple recommend defining enumeration types as NSInteger? iOS应用中使用的API密钥和机密 - 存储它们的位置? - API keys and secrets used in iOS app - where to store them? MDM是否会干扰iOS应用之间的钥匙串共享? - Does MDM interfere with keychain sharing between iOS apps? ios IDFV存储在钥匙串中 - ios IDFV store in Keychain iOS App Store提交:Apple是否使用经过验证的Facebook帐户测试Facebook应用程序? - iOS App Store Submission: Does Apple Test Facebook Apps with verified Facebook Accounts?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM