美文网首页
iOS越狱:命令行工具学习

iOS越狱:命令行工具学习

作者: 船长_ | 来源:发表于2018-11-03 20:54 被阅读177次

制作一个简单的命令行工具,使用mac连接越狱手机后,可使用终端输出自己制作的命令

1.创建iOS项目TestCommandLine,删除一些无用的文件,如图

main.png

main函数写代码

#import <UIKit/UIKit.h>

int main(int argc, char * argv[]) {
    @autoreleasepool {
        // 使用NSLog左边会有一些打印时间等信息
        printf("text command Line\n");
        // 删除程序入口App启动方法
        return 0;
    }
}

2.选中真机设备,edit scheme ->run->release ->编译

build.jpeg

3.products ->右键show in finder ->找到 TestCommandLine.app->右键 show in finder->TestCommandLine

91372F53-7C85-46D0-9291-046ACEF4AF0A.png

4.使用iFunBox->文件系统->usr->bin,这个文件夹存放着终端命令.把TestCommandLine放到这个路径文件夹下

5.终端输入指令

TestCommandLine

输出

-sh: /usr/bin/TestCommandLine: Permission denied

6.添加权限

chmod +x /usr/bin/TestCommandLine

再次输入指令,输出

text command Line

并且输入Tes敲tab键会自动补全

使用file命令查看这个TestCommandLine

file TestCommandLine

输出

TestCommandLine: Mach-O universal binary with 2 architectures: [arm_v7:Mach-O executable arm_v7] [arm64:Mach-O 64-bit executable arm64]
TestCommandLine (for architecture armv7):   Mach-O executable arm_v7
TestCommandLine (for architecture arm64):   Mach-O 64-bit executable arm64

说明制作的这个TestCommandLine是一个可执行的Mach-O文件

相关文章

  • 十二、去掉腾讯视频的广告

    一、MJAppTools 【越狱-逆向】处理iOS APP信息的命令行工具https://github.com/C...

  • iOS越狱:命令行工具学习

    制作一个简单的命令行工具,使用mac连接越狱手机后,可使用终端输出自己制作的命令 1.创建iOS项目TestCom...

  • iPhone 越狱初试

    iPhone 越狱初试 越狱工具 太极越狱 适用于 iOS 8.1.3-8.4盘古越狱 for iOS 9.2 -...

  • 自由的安卓和受限的苹果

    最新的iOS12越狱发布了,我花了一小时越狱了我的iPad,愉快地用上了命令行和一些盗版工具。越过禁忌总是能让人有...

  • ios逆向

    #iOS-Jailbearking-Study ##iOS越狱学习 iOS越狱就是发现iOS设备硬件或者软件的漏洞...

  • iOS 逆向随笔 - theos

    theos是iOS最方便的越狱开发工具包,可以用来构建命令行程序。 下载和安装theos 下载 jtool 签名工...

  • iOS逆向之旅1--越狱iOS11.0.2

    越狱区别与越狱工具 完美越狱:手机重启后仍然是越狱环境。 不完美越狱:手机重启后需重新越狱。 pp助手,iOS9....

  • iOS 逆向之越狱SSH 和 SCP

    越狱准备: 1、设备: iphone6s Plus 系统 iOS10.2.12、越狱工具:爱思助手 越狱过程:爱思...

  • iOS越狱开发:hook(拦截)一个自己写的方法

    开发越狱插件需要先配置开发环境 Theos: iOS越狱插件开发工具本文主要搬运至:iOS逆向工程(手动HOOK自...

  • iOS 自定义命令行工具

    我们再越狱手机上能用很多工具,尤其是在终端上的一些操作。那么怎么实现一个在iOS终端的命令行工具呢? 比如我们将常...

网友评论

      本文标题:iOS越狱:命令行工具学习

      本文链接:https://www.haomeiwen.com/subject/obllxqtx.html