Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions docs/platforms/apple/guides/ios/size-analysis/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,10 @@ description: Upload iOS builds to Sentry for size analysis.

<Include name="size-analysis/app-thinning" />

### Binary Code Signature

<Include name="size-analysis/binary-code-signature" />

### App Store Connect File Sizes

<Include name="size-analysis/app-store-connect-file-sizes" />
Expand Down
19 changes: 19 additions & 0 deletions includes/size-analysis/binary-code-signature.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
Mach-O binaries contain code signature data within the `LC_CODE_SIGNATURE` load command which itself contains `SHA1` and/or `SHA256` hashes of every page block. This means the size of this data will scale linearly with the size of your binary.

By default Sentry calculates the size of this data as-is. You may notice differences when comparing against your app downloaded from the App Store. For example, Xcode 26 archives only codesign with `SHA256` hashes, but the App Store codesigns with both `SHA1` and `SHA256` hashes. In other words, App Store downloads of your app may be slightly larger than what's produced by Xcode. This App Store behavior is subject to change at any time.

If you'd like to compare the impact of this with your app, you can re-sign each binary before uploading to Sentry:

```bash
# Inspect the current code signature
codesign -dvvv '/path/to/your/binary'

# Re-sign with a new code signature
codesign --force \
--sign 'Apple Distribution: Your Team (team_id)' \
--digest-algorithm sha1 \
--digest-algorithm sha256 \
'/path/to/your/binary'
```

This will force both `SHA1` and `SHA256` hashes to be used.
Loading