Bypassing iPhone Code Signatures
【Bypassing iPhone Code Signatures】
Starting with the recent beta releases of the iPhoneOS, Apple has started requiring that all code on the device is signed. This is mostly to make it impossible for programs running through Apple's AppStore to download more software and run it (so no competition for AppStore).
iOS要求所有程序都必须签名。
In order to get around this (and thereby to install our own code onto the device) the iPhone Dev Team has patched the signature verification out of the kernel. However, another half of the codesign problem is that the binary contains a number of SHA1 verification hashes that are checked in numerous locations throughout the kernel. Patching this out is A) difficult (especially to track as Apple makes changes) and B) of marginal benefit as adding these hashes is easy. This means you do still have to at least pay lipservice to the code signature process. There are currently three viable options.
iPhone Dev Team已经把签名校验机制从内核中抽离出来。可是,对于SHA1的校验确无处不在,A)把所有这些校验机制抽离出来很困难(尤其是要跟得上苹果的变化),B)添加这些hashes很容易。
所以有以下3种方式可以用来帮助绕过这些SHA1校验:
1、Option #1: Self-Signing
使用苹果的签名工具codesign进行签名即可。
2、Option #2: Pseudo-Signing
codesign是macos平台上的工具,linux平台可以使用ldid。
3、Option #3: Disable Checks
关闭所有的校验。
【Entitlements】
Every executable also has an XML file (specifically an Objective-C Property List) that is signed into it that is its block of "entitlements". This area is read (I'm not certain by who, but I'd guess the kernel) to determine what seatbelt profile to apply to that process and what extra abilities it gets.
To dump or set the entitlements of a binary we can use ldid. Dumping uses -e and setting involves passing an argument to -S as you sign the file. You can also pass --entitlements to codesign.
ldid -e选项用于从bin中导出entitlements权限,-S选项用于签名,给-S添加参数的是一个entitlements文件。也可通过给codesign --entitlements选项来设置权限。如下:

【Entitlement实战】

Bypassing iPhone Code Signatures的更多相关文章
- [转]Bypassing iPhone Code Signatures
Source Link: http://www.saurik.com/id/8 Due to popular demand, I am putting some of the content I ha ...
- Code Sign error: Provisioning profile XXXX can't be found
[iphone]Code Sign error: Provisioning profile XXXX can't be found 如果你更新了profile,再编译iphone项目,发现下面的错误, ...
- iPhone较为基础的代码片段
Iphone代码片段导航 1.给UITableViewController添加ToolBar. self.navigationController.toolbarHidden = NO; //默认是隐 ...
- ipa重签名
为什么要研究重签名问题?将程序打包成ipa包后,ipa包中会包含Provisioning Profile和_CodeSignature等文件,里面包含了对整个ipa的签名信息. 一旦改动ipa中的不论 ...
- An iOS zero-click radio proximity exploit odyssey
NOTE: This specific issue was fixed before the launch of Privacy-Preserving Contact Tracing in iOS 1 ...
- github上所有大于800 star OC框架
https://github.com/XCGit/awesome-objc-frameworks#awesome-objc-frameworks awesome-objc-frameworks ID ...
- IOS常用加密GTMBase64
GTMDefines.h // // GTMDefines.h // // Copyright 2008 Google Inc. // // Licensed under the Apache Lic ...
- 验证Xcode真伪的方法,来自苹果官网
验证Xcode真伪的方法,来自苹果官网 Xcode的验证你的版本 2015年9月22日 注意:中文为有道翻译,看下验证方法即可. 我们最近将应用程序从应用程序商店,还建有Xcode的假冒 ...
- iOS使用MD5 - 字符串加密至MD5&获取文件MD5
iOS 字符串加密至MD5 + (NSString *) md5:(NSString *)str { unsigned ]; CC_MD5( cStr, strlen(cStr), result ); ...
随机推荐
- OneDrive网页版打不开的解决办法
发现OneDrive文件被误删了,想去网页版找回历史文件,发现网页版无法打开,而客户端是可以正常使用的,于是猜测是域名指向的主IP被封了,于是想通过客户端的IP访问 第一步,WireShark抓包 第 ...
- 解决pip安装太慢的问题
经常在使用Python的时候需要安装各种模块,而pip是很强大的模块安装工具,但是由于国外官方pypi经常被墙,导致不可用,所以我们最好是将自己使用的pip源更换一下,这样就能解决被墙导致的装不上库的 ...
- HashMap(HashSet)的实现
0. HashMap(TreeMAP).HashSet.HashTable 的关系 HashMap 的底层则维护着 Node<K, V>[] table; 一个一维数组用于快速访问(只在初 ...
- GitHub Blog创建以及本地管理
创建 注册GitHub账户 首页点击新建仓库 New repository repository name必须为 Owner.github.io EX:我的Owner下为pualus,那么就应为pua ...
- 【ES6】蛋疼
- HDU - 6129 :Just do it (杨辉三角)
There is a nonnegative integer sequence a 1...n a1...n of length n n . HazelFan wants to do a type ...
- model里面字段choices的values值的选择
代码如下: Model: class Person(models.Model): name = models.CharField(max_length=200) CATEGORY_CHOICES = ...
- 使用 key 登录时分开记录操作历史记录
线上服务器一般都是配置 key 登录,一个账号可以多个工作人员连接,操作命令历史却全部记录在一个文件中,当然后查看某条命令是谁执行的时候就不好查了.这时候我们就可以通过配置 histroy 相关环境变 ...
- PADS Logic 脚本的 Fields 一个对象记录
PADS Logic 脚本的 Fields 一个对象记录 PADS Laogic 有一个非常棒的脚本功能,可以导出所以元件. 我目前是把脚本绑定到 Ctrl+S 上,在保存时自动导出 txt 文件,方 ...
- module_param 用于动态开启/关闭 驱动打印信息
1.定义模块参数的方法: module_param(name, type, perm); 其中,name:表示参数的名字; type:表示参数的类型; perm:表示参数的访问权限 ...