> For the complete documentation index, see [llms.txt](https://wiki.smhuda.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://wiki.smhuda.com/pentesting/application-security/mobile-security/ios/ios-reverse-engineering.md).

# iOS Reverse Engineering

{% embed url="<https://habr.com/en/post/595797>" %}

## `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
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://wiki.smhuda.com/pentesting/application-security/mobile-security/ios/ios-reverse-engineering.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
