简体   繁体   English

应用程序更新后,我放入钥匙串的值可以保存吗?

[英]Values that I Put in Keychain Can Be Saved After app is updated?

I have an application in app-store. 我在app-store中有一个应用程序。 In My Application I use keychain to save some values(for example: name & surname) as crypted. 在我的应用程序中,我使用keychain将一些值(例如:name&surname)保存为crypted。 If I use xCode to update my app , there is no problem about values. 如果我使用xCode更新我的应用程序,则值没有问题。 They are all saved in keychain as I want. 它们都按照我的意愿保存在钥匙串中。 But If I put new version into the app-store and updated my app with the version that is in appstore, My values are all gone :( Does iOS remove the values in keychain if app is updated ? 但是,如果我将新版本放入应用程序商店并使用appstore中的版本更新我的应用程序,我的价值观全部消失:(如果应用程序更新,iOS会删除钥匙串中的值吗?

Note : On iPhone, Keychain rights depend on the provisioning profile used to sign your application. 注意 :在iPhone上,Keychain权限取决于用于签署应用程序的provisioning profile Be sure to consistently use the same provisioning profile across different versions of your application. 确保在不同版本的应用程序中始终使用same provisioning profile

Check for more information Keychain Services Programming Guide 检查更多信息Keychain Services Programming Guide

The app's keychain shall not be removed or altered by any means during an update. 在更新期间,不得以任何方式删除或更改应用程序的钥匙串。 If you experience this, you must be doing something wrong (see Joachim's questions above). 如果您遇到这种情况,您必须做错事(参见上面的Joachim的问题)。

(Actually deleting the app did not remove its keychain in iOS 4.x, which should normally not happen. I haven't checked whether this was improved with later iOS versions, though.) (实际上删除应用程序并没有删除iOS 4.x中的钥匙串,这通常不应该发生。但我没有检查这是否在以后的iOS版本中有所改进。)

Besides, the keychain is not part of the application's filesystem, therefore an update shall not affect its contents. 此外,钥匙串不是应用程序文件系统的一部分,因此更新不应影响其内容。 The keychain belongs to a central, secure database (actually it is a special sqlite3 DB). 钥匙串属于中央安全数据库(实际上它是一个特殊的sqlite3数据库)。 For more details check out the "Keychain Data Protection" chapter in Apple's iOS Security document: http://www.apple.com/ipad/business/docs/iOS_Security_Oct12.pdf . 有关更多详细信息,请查看Apple iOS安全文档中的“Keychain Data Protection”一章: http//www.apple.com/ipad/business/docs/iOS_Security_Oct12.pdf

As a conclusion: your app's keychain shall remain unchanged after an app update. 结论是:应用更新后,您应用的钥匙串应保持不变。

Simple answer is NO. 简单的答案是否定的。 Your data stored in KeyChain is not removed when your app will be updated. 当您的应用更新时,不会删除存储在KeyChain中的数据。 You can get data from KeyChain using it's key-value pair. 您可以使用KeyChain的键值对从KeyChain获取数据。

Hope, this simple answer can help you. 希望,这个简单的答案可以帮到你。

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

相关问题 我们可以从共享同一应用程序组的应用程序启用钥匙串共享之前访问保存的钥匙串项目吗? - Can we access keychain items that are saved before enabling keychain sharing from app sharing same app group? iOS用户如何在卸载应用程序后删除钥匙串 - How can a iOS user remove keychain after uninstalling app 如果分发证书已更新,iphone app update 可以访问钥匙串吗? - Can iphone app update access the keychain if the distribution certificate has been updated? 我可以访问iPhone上的钥匙串吗? - Can I access the keychain on the iPhone? 更新的应用已保存了原始数据 - Updated app has saved the original data 我可以使用MonoTouch访问iPhone上的钥匙串吗? - Can I access the keychain on the iPhone with MonoTouch? 拒绝钥匙串访问后,应用程序无法在iPhone上运行 - App won't run on iPhone after denying keychain access 如何在应用程序转移到新帐户后解决钥匙串访问警告 - How to solve keychain access warning after app transfer to new account 如何将Keychain共享功能添加到我的App ID? - How do I add the Keychain sharing feature to my App ID? 我可以在iOS钥匙串中为一个用户存储/检索多个密码吗? - Can I store/ retrieve multiple passwords in the iOS keychain for a single user?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM