iOS 数据保护和安全文件

标签 ios encryption data-protection

我正在构建一个应用程序,我需要在其中以加密格式存储数据。我在 Capabilities 下启用了 Data Protection 并在将数据写入磁盘时添加了 completeFileProtectionUntilFirstUserAuthentication 选项。 (我需要从后台获取访问它)

一切正常,但当我从 Xcode 下载应用程序容器时,我可以看到明文 (plist) 的数据。

自从我解锁手机后打开应用程序后,这是应该的吗?有什么方法可以验证数据实际上是否已加密?

最佳答案

没有办法实际验证这一点,因为当它在实际设备上时,所有内容都在磁盘上加密(只要设备设置了设备密码)。他们使用从处理器和内存芯片级别开始一直到文件和部分文件级别的加密 key 层。

从 Xcode 将应用程序包下载到 Mac 计算机与在 iOS 设备上运行应用程序包不同。

NSFileProtectionCompleteUntilFirstUserAuthentication 是 iOS 7 的默认安全设置,因此没有理由明确设置它。

This is the default class for all third-party app data not otherwise assigned to a Data Protection class.

更多信息来自 Apple 的白皮书(第 16 页):https://www.apple.com/business/docs/iOS_Security_Guide.pdf

关于iOS 数据保护和安全文件,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/46323589/

相关文章:

ios - UISlider 无法正确处理 .touchUpInside 事件

ios - 如何让 UITextView 键盘不会通过点击而关闭_Swift

ios - Web 内容不适合 webview 的框架?

asp.net - EncryptByKey 与 EncryptByPassPhrase?

iphone - 保护 Coredata 对象的安全

azure - 不使用 TLS 加密将 AMQP 遥测发送到 Azure 事件中心

google-analytics - 禁用 iframe 分析

c# - 防止用户在 C# 中打印/保存 PDF 文件

iphone - 使用 OpenGL 在 iPad 上从整数数据集中绘制图像数据

asp.net-core - 多 pod 的数据保护 key 轮换策略是什么?