自动删除 iPhone 应用程序

发布于 2024-08-11 07:03:25 字数 379 浏览 3 评论 0原文

我有一个 iPhone 应用程序,需要有一个自毁选项。这个应用程序将在敏感位置使用,并拥有一些除了 iPod 支架之外任何人都不知道的算法。

删除应用程序的最“完整”方式是什么?

我正在考虑如何将零写入 nib 文件。或实际的 application.app 但我相信这个文件夹是写保护和沙箱的。

有人有更好的方法来实现这一目标吗?

详细说明(摘自原发帖者的评论):

这是针对越狱的 iPhone 的。

这些设备将提供给军事人员,这种设备落入敌人手中是我最不担心的。它将有一个按钮,因此一旦应用程序写入零或更好,但由于“exe”上到处都是垃圾而损坏,应用程序将无法工作,并且需要使用我所提供的设备检查 iPod 闪存芯片。 100%知道错的人不会有

I have a iPhone app which needs to have a self destruct option. This app is going to be use on sensitive locations and holds some algorithms which are not to be known by anybody except the iPod Holder.

What would be the most "complete" way of deleting the app?

I was thinking of some how writing zeros to the nib file. or the actual application.app but I believe this folders are write protected and sandboxed.

Anybody have any ideas of better ways to achieve this?

Elaboration (Taken from original poster's comments):

This is for a jailbroken iPhone.

These devices are going to be provided to military personnel this device falling into enemy hands would be the least of my concerns. It's going to have a button so wipe the app once the app is written to zero or better yet corrupted with garbage all over the "exe" the app has no way of working and it would require inspection of the iPod flash chip with equipment that i 100% know the wrong people wont have

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(8

牵强ㄟ 2024-08-18 07:03:26

如果您在应用程序中公开存储包含此算法的代码,那么在您运行“擦除”过程之前,没有什么可以阻止“错误的人”越狱设备并复制设备的完整文件结构。

此外,如果您正在与美国政府客户打交道,我怀疑他们是否会批准购买越狱设备,因为此类设备的供应商有 声称越狱是非法的。无论这在法庭上是否成立,政府在这些问题上往往持保守态度,宁可谨慎行事。因为苹果是一家美国大公司,也是政府的供应商,所以我不认为政府采购人员会站在越狱者一边。

我的建议是对应用程序捆绑包中的文件中的特定算法进行加密,并要求该应用程序的用户使用正确的(困难的)密码将该文件解密到内存中。这样,即使“坏人”获得了应用程序的访问权限,他们也不会拥有访问这些算法所需的一切,并且必须暴力破解加密部分的密码。这可以在标准的、未越狱的设备上完成。

美国陆军正在在战场上推出 iPod,上面装有自定义应用程序,所以我'我确信您不是第一个面临这一挑战的人。如果这项工作是通过国防部 SBIR 拨款(或类似拨款)资助的,您甚至可以联系您的签约官员,看看他们是否可以让您与适当机构的人员取得联系,他们可能会为您提供帮助解决这个问题(或者甚至确定这是否是一个问题)。

If you are openly storing the code that contains this algorithm within your application, there's nothing stopping the "wrong people" from jailbreaking the device and copying the complete file structure of the device before you run your "wipe" process.

Additionally, if you are dealing with a U.S. Government customer, I doubt that they will approve of the purchase of a jailbroken device, given that the vendor of such a device has claimed that jailbreaking is illegal. Whether or not this will hold up in court, the government tends to be conservative in these matters and err on the side of caution. Because Apple is a large U.S. company and a vendor to the government, I wouldn't expect the government procurers to take the jailbreakers' side in this.

My recommendation would be to encrypt the particular algorithms within a file in your application's bundle, and require the user of this application to decrypt this file into memory with the correct (difficult) password. That way, even if the "bad guys" were to gain access to the application, they wouldn't have everything they need to access these algorithms and would have to brute-force the password on the encrypted portion. This could be done on a standard, non-jailbroken device.

The U.S. Army is rolling out iPods in the field, with custom applications on them, so I'm sure that you're not the first person facing this challenge. If this work is being funded through a Department of Defense SBIR grant (or similar), you may even be able to contact your contracting officer and see if they can put you in touch with people at the appropriate agency who may be able to help you out with this (or even determine if it an issue to begin with).

荒人说梦 2024-08-18 07:03:26

我要大胆地说,你可能不想使用 iPhone 来运行这种类型的应用程序。在 iPhone 和跳板中对这种确切类型的操作有有意的限制。如果您正在做一些非常敏感的事情,以至于不能落入未经授权的手中,我的建议是使用不同的、更可定制/可控的平台。

I'm going to go out on a limb here and say you may not want to use the iphone for this type of app. There are intentional limitations to this exact type of action on the iphone and in springboard. If you are doing something so sensitive that it can't fall into unauthorized hands my recommendation would be to use a different and more customizable/controllable platform.

乜一 2024-08-18 07:03:26

除非您使用越狱设备工作,否则您可能会在这里遇到问题。

即使你能找到一种自动删除应用程序的方法,你仍然面临着这些算法落入坏人之手的风险 - 一旦设备落入某人手中,你基本上会遇到与苹果越狱相同的问题在别人手中,只需要适当的动机就可以访问数据。

保护算法安全的唯一方法是将数据传递到远程服务器并获取结果。安全漏洞的可能性仍然存在,但要低得多。

Unless you're working from a jailbroken device, you're probably going to run into problems here.

Even if you can find a way to automatically delete the app, you're still running the risk of those algorithms getting into the wrong hands - you would essentially be running into the same problems that Apple has with jailbreaking - once the device is in someone else's hands, it only takes the proper amount of motivation for the data to be accessed.

The only way to secure your algorithms is to pass the data to a remote server and get the results. There's still a possibility of a security breach, but it's much, much lower.

靖瑶 2024-08-18 07:03:26

我不知道这效果如何,但您可以将算法存储为应用程序包中的文件,可能使用脚本语言或其他语言从该文件运行算法,然后根据需要删除该文件。

I don't know how well this would work, but you could store the algorithm as a file inside the application bundle, run the algorithm from that file possibly using a scripting language or something, and delete that file if you need to.

天荒地未老 2024-08-18 07:03:26

这些文件夹是沙盒的,但您的应用程序位于其中。在我越狱的 iPhone 上,我看到所有权限都归移动设备所有,所以我看不出有什么理由不能用零覆盖所有文件,然后删除它们。

The folders are sandboxed, but your application is in there. On my jailbroken iPhone I see that all the permissions are owned by mobile so I don't see any reason why you can't just overwrite all the files with zeroes and then delete them.

岛徒 2024-08-18 07:03:26

应用程序包实际上是只读的,也许您应该将某些信息以加密形式存储在网络上的某个位置。

The application bundle is effectively read-only, perhaps you should store some of the information in an encrypted form somewhere on a network.

哥,最终变帅啦 2024-08-18 07:03:26

即使您找到了一种方法来覆盖闪存中的应用程序,您实际上也不会删除该应用程序。闪存芯片使用磨损均衡算法来减少对相同块的写入,因此当您写出时它们通常会被写入新的内存块,而不是之前使用的同一块,因此您实际上并没有删除任何内容。数据仍然可以从闪存芯片恢复(由专业人士)。

另一种选择是分离出算法的参数,使算法不再敏感(或至少不可用),并在文件中提供加密的参数。然后通过网络向授权用户提供密钥,并且不要将该密钥存储到闪存中,仅存储到 RAM 中。他们每次启动应用程序时都需要获取密钥。仅将密钥提供给授权用户。当然,您还需要使用另一个密钥对该密钥进行加密,以便通过网络传输...有一些系统可以执行此操作,不要发明自己的系统,无论如何,您都需要加密专家来执行此操作正确的。

Even if you find a way to write over the app in the flash memory, you really aren't erasing the app. Flash memory chips use wear leveling algorithms to reduce writes to the same blocks and so when you write out zeroes they are typically written to a new block of memory and not to the same block used before, so you really aren't erasing anything. The data can still be recovered from the flash chip (by a pro).

Another option is to separate out the parameters of the algorithm so that the algorithm is no longer sensitive (or at least not usable) and provide the parameters encrypted in a file. Then provide the key to authorized users via the network and don't store that key into flash, only RAM. They would need to get the key every time they start the app. Only give the key to authorized users. Of course, you'll also need to encrypt that key for transmission over the network with another key... There are systems for doing this, don't invent your own, in any case you'll need a crypto expert to do this right.

把人绕傻吧 2024-08-18 07:03:26

我将使用内置加密来存储数据,并使用用户必须输入的密钥来解密。如果没有密钥,则数据 blob 是否从设备中恢复也没有关系。

I would use the built in encryption to store the data, with a key the user has to enter to decrypt it. Without the key it doesn't matter if the data blob is recovered from the device.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文