在应用程序中的越狱设备上安装应用程序

发布于 2024-11-30 09:08:50 字数 273 浏览 4 评论 0原文

我有苹果开发者证书。我正在尝试将我的应用程序安装在我的越狱 iPhone 上的 /Applications 中,以便我可以访问 SMS.db 数据库。我尝试了几种不同的变体,即不使用证书但使用 ldid 签名,以及使用我的 iOS App Store 分发证书签名。我的应用程序总是在启动时崩溃,并且似乎没有任何效果。如果我有 Apple 开发人员证书,将应用程序放入 /Applications 的最简单方法是什么?我还需要进行 ldid 签名吗?我在 iPhone 4 上使用 XCode4、SDK 4.3 和 iOS 4.1。

I have an Apple developer certificate. I'm trying to install my application in the /Applications on my jailbroken iPhone so I can access the SMS.db database. I've tried several different variations of using no certificate but signing with ldid, and signing with my iOS App Store distribution certificate. My app always crashes on launch and nothing seems to work. If I have an Apple developer certificate, what's the easiest way to get the app into /Applications? Do I still have to do the ldid signing? I'm using XCode4, SDK 4.3 and iOS 4.1 on an iPhone 4.

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

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

发布评论

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

评论(1

醉梦枕江山 2024-12-07 09:08:50

我为自己的应用程序做了一些研究,该应用程序需要访问越狱设备上的整个文件系统。您无法通过将 .ipa 文件安装到 /Applications 的正常方式来安装应用程序。

您的崩溃很可能与沙箱有关,因此它看起来像这样:

Jun  2 15:16:10 unknown sandboxd[31] <Notice>: BlueTool(145) deny file-read-metadata /private/var/mobile

Process:         BlueTool [145]
Path:            /usr/sbin/BlueTool
Load Address:    0x7f000
Identifier:      BlueTool
Version:         ??? (???)
Code Type:       ARM (Native)
Parent Process:  BTServer [88]

Date/Time:       2012-06-02 15:16:10.275 -0500
OS Version:      iPhone OS 5.0.1 (9A405)
Report Version:  104

Backtrace:
0   libsystem_kernel.dylib          0x30604c0c stat + 12

我通过将 .ipa 包转换为 .deb 包并通过 dpkg 安装它来解决这个问题。这样您就可以创建任何您想要的布局。

解决方案的要点如下:

为 debian 打包程序创建要使用的布局:

mkdir ./layout
mkdir ./layout/Applications
mkdir ./layout/DEBIAN
chmod 0755 ./layout/DEBIAN

解压缩 .ipa 包:

unzip package.ipa -d ./layout/Applications/MyAppName.app/

创建布局文件:

cat > ./layout/DEBIAN/control <<EOF
Package: MyAppName
Name: MyAppName
Depends: mobilesubstrate, preferenceloader, libstatusbar
Version: 1.0-0
Architecture: iphoneos-arm
Description: MyAppName application
Maintainer: Me
Author: Me
Section: Tweaks
EOF

chmod 0755 ./layout/DEBIAN/control

制作 .deb 包:

<path-to-theos-bin>/dpkg-deb -b ./layout MyAppName.deb

显示我们刚刚构建的 .deb 包中的内容:

<path-to-theos-bin>/dpkg-deb -c ./layout MyAppName.deb

然后通过 ssh 部署:

scp MyAppName.deb root@<device-ip>:/var/tmp
ssh root@<device-ip> "dpkg -i /var/tmp/MyAppName.deb"
ssh root@<device-ip> "killall -9 \"SpringBoard\""

I did some research about this for my own app that needed access to the whole file system on the jailbroken device. You can't install your app by normal means of installing an .ipa file to /Applications.

Your crash is most likely related to sandboxing, so it would look something like this:

Jun  2 15:16:10 unknown sandboxd[31] <Notice>: BlueTool(145) deny file-read-metadata /private/var/mobile

Process:         BlueTool [145]
Path:            /usr/sbin/BlueTool
Load Address:    0x7f000
Identifier:      BlueTool
Version:         ??? (???)
Code Type:       ARM (Native)
Parent Process:  BTServer [88]

Date/Time:       2012-06-02 15:16:10.275 -0500
OS Version:      iPhone OS 5.0.1 (9A405)
Report Version:  104

Backtrace:
0   libsystem_kernel.dylib          0x30604c0c stat + 12

I solved this by converting my .ipa package to a .deb package and installing it via dpkg. This way you can create any layout you want.

Here's the gist of the solution:

Create layout for the debian packager to work with:

mkdir ./layout
mkdir ./layout/Applications
mkdir ./layout/DEBIAN
chmod 0755 ./layout/DEBIAN

Unzip the .ipa package:

unzip package.ipa -d ./layout/Applications/MyAppName.app/

Create layout file:

cat > ./layout/DEBIAN/control <<EOF
Package: MyAppName
Name: MyAppName
Depends: mobilesubstrate, preferenceloader, libstatusbar
Version: 1.0-0
Architecture: iphoneos-arm
Description: MyAppName application
Maintainer: Me
Author: Me
Section: Tweaks
EOF

chmod 0755 ./layout/DEBIAN/control

Make a .deb package:

<path-to-theos-bin>/dpkg-deb -b ./layout MyAppName.deb

Show what's inside of the .deb package we just built:

<path-to-theos-bin>/dpkg-deb -c ./layout MyAppName.deb

Then deploy via ssh:

scp MyAppName.deb root@<device-ip>:/var/tmp
ssh root@<device-ip> "dpkg -i /var/tmp/MyAppName.deb"
ssh root@<device-ip> "killall -9 \"SpringBoard\""
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文