How do I access the filesystem outside of the sandbox on a jailbroken iOS device?

巧了我就是萌 提交于 2019-12-11 03:21:43

问题


I'm going to develop a simple app for jailbroken iOS devices. I would like to access the filesystem of the device outside of the app's sandbox and move some files (from a directory to another, for example).

How can I do this using Xcode 3.1 or 4, compatible with OS version 3.1.3?


回答1:


Just use NSFileManager. On a jailbroken device, it gives you full access to the filesystem—just give it the paths you want to mess with. You can get the contents of a directory with its -contentsOfDirectoryAtPath:error: method and move files around with -moveItemAtPath:toPath:error:.



来源:https://stackoverflow.com/questions/7095421/how-do-i-access-the-filesystem-outside-of-the-sandbox-on-a-jailbroken-ios-device

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!