Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save iMaz1n/e85283df0cc4ea42805ed86ea33672ec to your computer and use it in GitHub Desktop.
Save iMaz1n/e85283df0cc4ea42805ed86ea33672ec to your computer and use it in GitHub Desktop.
install ipa using command line

iOS FileStructure

  • listing iPod touch 5th disk stats
iPod-touch:/ root# df -h
Filesystem      Size  Used Avail Use% Mounted on
/dev/disk0s1s1  2.2G  1.6G  540M  76% /
devfs            27K   27K     0 100% /dev
/dev/disk0s1s2   28G  5.7G   22G  21% /private/var
/dev/disk1      223M   63M  160M  29% /Developer

install ipa using command line

  • using ideviceinstaller which can be installed using brew install ideviceinstaller
# list installed app on the connected device
# it also lists the identifier of the installed packages
ideviceinstaller -l

# install ipa
ideviceinstaller -i <your-package.ipa>

# uninstall app
ideviceinstaller -U <your-app-id>

ipa package analysis

ipa is essentially a zip file.

ipa file root structures

  • iTunes Artwork--a PNG app icon for showing in iTunes and the App Store.
  • iTunesMetadata.plist—Contains copyright information, release date, purchase date, name of the developer and company who created it, etc.
  • /Payload/Application.app

To repack the ipa, simple select the three files and folder listed above and right click and select compress. The Archive.zip you get can be install using ideviceinstaller. You can also rename the file name you wanted.

You can also use script.

cd <the-directory-that-store-the-three-files-and-folder>
zip -0 -y -r out.ipa .
#or use
zip -0  --symlinks --recurse-paths out.ipa .
# the `out.ipa` is the result

What in the Payload

  • _CodeSignature/CodeResources—-configuration file for app in the Payload resources, which is a xml configuration file. It includes two keys—files and rules. It can be thought as an index for files in the app.
  • PkgInfo--It belongs to files in CodeResources config. The contents of the PkgInfo file are the 4-byte package type followed by the 4-byte signature of your application. It comes from OS X and is not required by iOS. For more info, please refer to here.
  • *.nib—-compiled views
  • *.strings—-apple binary property list for storing localizable strings
  • embedded.mobileprovision--embeded provisioning profile
  • *.lproj--for localization usage
  • Info.plist--contains info about where to launch application, MinimumOSVersion, etc.

Reference

Jailbreaking iOS Device

Jailbreaking iPod Touch 5th with iOS 8.3 with Mac OS X 10.10

  • Download PP Jailbreak 2 at here
  • Connect your device, disable your Find-My-iPhone and lockscreen passcode, turn airplane mode on
  • Open PP Jailbreak 2 and follow the instruction

Interest package for Jailbreak Device

  • activator--customizing gesture
  • OpenSSH--for remote ssh login
  • open--for open apps with remote ssh login
  • netcat
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment