Skip to main content

One post tagged with "App审核"

View All Tags

· 15 min read

苹果的 ​​ITMS(iTunes Store)错误​​通常与应用程序或内容提交到 App Store 的过程相关,尤其是在使用 ​​Transporter​​、​ ​​App Store Connect API​​、altool 等工具时出现的问题。苹果对这些错误的定义和管理主要集中在确保开发者遵守技术规范和审核指南,同时提供工具和文档帮助开发者解决问题。

  • 在提交应用到 App Store Connect 时,苹果的自动化系统会执行预检,检测常见错误(如签名、元数据格式等),并直接返回错误代码和描述。
  • 开发者需根据错误提示修改后重新提交。

一、I​TMS 错误类型

ITMS 错误通常以 ITMS-XXXXX 格式编号(例如 ITMS-9000 等),涵盖以下常见类型:

  1. ​元数据错误​
    • 与应用名称、描述、截图、关键词等元数据相关的问题。
  2. ​二进制文件问题​
    • 构建版本(IPA 文件)的签名、架构或格式错误。
  3. ​合规性问题​
    • 违反 App Store 审核指南(如隐私政策缺失、使用私有 API、数据收集不合规等)。
  4. ​证书与配置文件错误​
    • 签名证书失效、设备权限配置错误。
  5. ​服务器或网络问题​
    • 苹果服务器故障或开发者网络不稳定导致的提交失败。

二、如何处理 ITMS 错误

1. ​​开发者支持渠道​

  • ​联系苹果技术支持​​:通过 App Store Connect 的「联系我们」提交问题。
  • ​开发者论坛​​:在 Apple Developer Forums 中搜索类似案例或提问。
  • ​Xcode 和 Transporter 日志​​:通过工具生成的详细日志定位问题根源。

2. ​​审核团队的反馈​

  • 如果应用通过预检但被审核团队拒绝,开发者会收到包含具体条款的邮件(如违反指南 4.3、5.1.1 等),需根据反馈修改并重新提交。

三、ITMS 错误:编译与二进制问题

ITMS-90668

​错误信息​

ERROR ITMS-90668: "Invalid Bundle Executable. The executable file contains incomplete bitcode."

​原因​
二进制文件未正确启用 Bitcode 或编译参数不完整。

​解决方式​

  1. 方案一:​​关闭 Bitcode​
    检查二进制文件是否开启 Bitcode:

    otool -arch arm64 -l ./MXFFI | grep __LLVM | wc -l
    • 结果为 0 表示 ENABLE_BITCODE = NO
    • 结果不为 0 表示 ENABLE_BITCODE = YES
  2. 方案二:​​强行移除 Bitcode 并重签名​

    # 移除 Bitcode 
    xcrun bitcode_strip Flutter.framework/Flutter -r -o Flutter.framework/Flutter
    # 重签名 Framework
    codesign -fs "证书名称" Flutter.framework
    # 重签名整个 App
    codesign -fs "证书名称" --entitlements ${appPath}/entitlements.plist ${appPath}

ITMS-90087

​错误信息​

ERROR ITMS-90087: "Unsupported Architectures. The executable contains unsupported architectures [x86_64,i386]."

​原因​
二进制包含模拟器架构(x86_64/i386)。

​解决方式​
添加构建脚本移除无效架构:

APP_PATH="${TARGET_BUILD_DIR}/${WRAPPER_NAME}" find "$APP_PATH" -name '*.framework' -exec lipo -remove x86_64 {} -output {} \;

ITMS-90209

​错误信息​

ERROR ITMS-90209: "Invalid Segment Alignment. The binary does not have proper segment alignment."

​原因​
二进制文件段对齐异常。

​解决方式​

  1. 升级 Xcode 至最新版本。
  2. 使用 lipo 重新编译第三方库。

ITMS-90125

​错误信息​

ERROR ITMS-90125: "The binary is invalid. The encryption info is missing or invalid."

​原因​
二进制文件加密信息缺失。

​解决方式​
确保未手动修改二进制加密标志,使用Xcode默认构建流程。


TMS-90048

​错误信息​

ITMS-90048: This bundle is invalid - Your archive contains paths that are not allowed: [._Symbols]

​原因​
提交给 App Store Connect 的归档文件 (.xcarchive) 里,包含了一个不允许存在的隐藏文件 ._Symbols。

macOS 15.4 的 APFS 文件系统在处理文件时,会为某些操作(如 rsync)自动生成以 ._ 开头的隐藏文件,用于存储 Finder 元数据或资源 fork。在 iOS 构建过程中,生成 Symbols 目录时,系统可能因文件操作触发元数据文件 ._Symbols 的创建

​解决方式​
解决方式一:构建后,解压 ipa,删除 ._Symbols 解决方式二:通过Xcode 里通过 Prodict > Archive 提交


ITMS-90426

​错误信息​

ITMS-90426: Invalid Swift Support - The SwiftSupport folder is missing. Rebuild your app using the current public (GM) version of Xcode and resubmit it.

​原因​

SwiftSupport 文件夹丢失

​解决方式​

  1. Build Settings -> Always Embed Swift Standard Libraries 设置成 YES
  2. 重新打包,然后解压 ipa 检查是否包含 SwiftSupport 文件夹

四、ITMS 错误:版本与配置问题

ITMS-90060

​错误信息​

ERROR ITMS-90060: "Invalid CFBundleShortVersionString '1.2.2.1'. Must be a period-separated list of three non-negative integers."

​原因​
版本号格式不符合三段式要求。

​解决方式​
检查所有依赖库的 CFBundleShortVersionString,修改为三段式(如 1.2.2)。


ITMS-90062

​错误信息​

"This bundle is invalid. The value for key CFBundleShortVersionString [...] must contain a higher version"

​原因​
提交版本号低于已审核版本。

​解决方式​
确保 CFBundleShortVersionStringCFBundleVersion 均高于最近审核通过版本。


ITMS-90725

​错误信息​

ITMS-90725: SDK Version Issue - This app was built with the iOS 15.5 SDK. All iOS apps submitted to the App Store must be built with the iOS 16.1 SDK or later, included in Xcode 14.1 or later."

​解决方式​
升级 Xcode 至 14.1 或更高版本,使用 iOS 16.1+ SDK 重新编译。


ITMS-90098

​错误信息​

The bundle identifier contains disallowed characters

​解决方式​
检查并修改 Bundle Identifier,确保其不包含不允许的字符


ITMS-90186

​错误信息​

Invalid Pre-Release Train. The train version is closed for new build submissions

*​原因​

该版本的预发布列车已关闭,无法提交新的构建版本

​解决方式​
检查 App Store Connect 中的版本设置,确保提交的版本号正确


五、ITMS 错误:隐私与权限问题

ITMS-91053、ITMS-91056、ITMS-91061

​错误信息​

ITMS-91053: Missing API declaration - Your app’s code in the “Runner” file references one or more APIs that require reasons, including the following API categories: NSPrivacyAccessedAPICategoryDiskSpace. While no action is required at this time, starting May 1, 2024, when you upload a new app or app update, you must include a NSPrivacyAccessedAPITypes array in your app’s privacy manifest to provide approved reasons for these APIs used by your app’s code. For more details about this policy, including a list of required reason APIs and approved reasons for usage, visit: https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_use_of_required_reason_api.

ITMS-91056: Invalid privacy manifest - The PrivacyInfo.xcprivacy file from the following path is invalid: "PrivacyInfo.xcprivacy". Keys and values in your app's privacy manifests must be valid. For more details about privacy manifest files, visit: https://developer.apple.com/documentation/bundleresources/privacy_manifest_files.

ITMS-91061: Missing privacy manifest - Your app includes “Frameworks/X.framework/X”, which includes X, an SDK that was identified in the documentation as a commonly used third-party SDK. If a new app includes a commonly used third-party SDK, or an app update adds a new commonly used third-party SDK, the SDK must include a privacy manifest file. Please contact the provider of the SDK that includes this file to get an updated SDK version with a privacy manifest. For more details about this policy, including a list of SDKs that are required to include signatures and manifests, visit: https://developer.apple.com/support/third-party-SDK-requirements.

​原因​
2024.2.29 日 Apple 发布了《关于 App Store 提交的隐私更新》,明确要求 新上架或更新的APP 必须包含 「PrivacyInfo.xcprivacy」 隐私清单文件,否则可能被拒审,部分第三方SDK若以二进制形式集成,还需附带签名。

开发者需要给 SDK 创建 PrivacyInfo.xcprivacy 隐私清单文件。

  • NSPrivacyAccessedAPICategoryFileTimestamp
  • NSPrivacyAccessedAPICategoryUserDefaults
  • NSPrivacyAccessedAPICategoryDiskSpace
  • NSPrivacyAccessedAPICategoryUserDefaults

​解决方式​

手动创建 PrivacyInfo.xcprivacy(根据你的情况修改)

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>NSPrivacyTracking</key>
<false/>
<key>NSPrivacyCollectedDataTypes</key>
<array/>
<key>NSPrivacyAccessedAPITypes</key>
<array>
<dict>
<key>NSPrivacyAccessedAPIType</key>
<string>NSPrivacyAccessedAPICategoryUserDefaults</string>
<key>NSPrivacyAccessedAPITypeReasons</key>
<array>
<string>CA92.1</string>
</array>
</dict>
<dict>
<key>NSPrivacyAccessedAPIType</key>
<string>NSPrivacyAccessedAPICategoryFileTimestamp</string>
<key>NSPrivacyAccessedAPITypeReasons</key>
<array>
<string>C617.1</string>
</array>
</dict>
</array>
</dict>
</plist>

第三方SDK较多,可以考虑使用自动修复脚本:

App Store隐私清单分析器:


ITMS-91061

​错误信息​

ITMS-91061: "Missing privacy manifest. Third-party SDK must include a privacy manifest."

​解决方式​
联系第三方 SDK 提供商获取包含隐私清单的更新版本。


ITMS-90683

​错误信息​

"Missing Info.plist key. Your app's code references [...] but the Info.plist file does not contain [...]"

​原因​
访问敏感数据(如位置、相机)未提供隐私描述。

​解决方式​
Info.plist 中添加对应键值:

  • NSLocationWhenInUseUsageDescription
  • NSCameraUsageDescription

ITMS-90078​

​错误信息​

"Missing push notification entitlement [...] entitlements do not include the 'aps-environment' entitlement"

​原因​
应用包含APNs相关API但未声明推送通知权限

​解决方式​

  1. 在项目Capabilities中启用推送通知
  2. 检查第三方库是否隐式引用APNs API,使用nm或otool排查二进制文件中的符号引用

六、ITMS 错误:签名与描述文件问题

ITMS-9000

​错误信息​

ERROR ITMS-9000: "The binary you uploaded was invalid."

​原因​
描述文件(Provisioning Profiles )过期或被删除。

​解决方式​
重新生成并下载描述文件,使用有效文件重新打包。


ITMS-90165

​错误信息​

ERROR ITMS-90165: "Invalid Provisioning Profile Signature. The provisioning profile [...] is not valid"

原因

描述文件签名失效(苹果更新签名机制导致)

​解决方式​

  1. 重新编辑描述文件并下载。
  2. 删除旧文件后重新打包。

ITMS-90046

​错误信息​

ERROR ITMS-90046: "Invalid Code Signing Entitlements"

​原因​
代码签名权利无效,可能是描述文件有问题或 Bundle Identifier 命名不规范等

​解决方式​
检查描述文件是否正确配置,确保 Bundle Identifier 命名符合要求


ITMS-90535

​错误信息​

Invalid Code Signing Entitlements

​原因​
第三方 info.plist 文件中的 Bundle Identifier 或版本号等信息未正确配置

​解决方式​
修改第三方 info.plist 文件,添加正确的 Bundle Identifier、版本号等信息


七、ITMS 错误:界面与图标问题

ITMS-90809

​错误信息​

ERROR ITMS-90809: "Deprecated API Usage. UIWebView is no longer accepted."

​解决方式​
替换 UIWebViewWKWebView,重新编译。


ITMS-90022、ITMS-90025

​错误信息​

# ITMS-90022
Missing required icon file. The bundle does not contain an app icon for iPhone / iPod Touch of exactly '57x57' pixels, in.png format for iOS versions < 7.0
# ITMS-90025
Missing recommended icon file. The bundle does not contain an app icon for iPhone / iPod Touch of exactly '120x120' pixels, in.png format for iOS versions >= 7.0

​解决方式​
在 images.xcassets 的 AppIcon.appiconset 中添加相应尺寸的图标,并在 Contents.json 中进行配置


ITMS-90705

​错误信息​

Launch storyboard not found. Make sure you specify the launch storyboard filename without a filename extension for the key UILaunchStoryboardName in the Info.plist

原因

启动故事板未找到,Info.plist 中的 UILaunchStoryboardName 值不正确

​解决方式​
检查 Info.plist 中的 UILaunchStoryboardName 值,确保其与启动故事板文件名一致,且不包含扩展名


ITMS-90096

​原始错误信息​

Missing recommended icon file. The bundle does not contain an app icon for iPhone / iPod Touch of exactly '57x57' pixels, in.png format for iOS versions < 7.0

原因

应用缺少 LaunchImage 或其设置有问题

​解决方式​
添加相应尺寸的启动图片到项目根目录,并修改 info.plist 文件,或检查 LaunchScreen.storyboard 是否存在


八、ITMS 错误:其他常见问题

ITMS-90474 / ITMS-90475

​错误信息​

ERROR ITMS-90474: “Invalid Bundle. iPad Multitasking support requires these orientations: ‘UIInterfaceOrientationPortrait,UIInterfaceOrientationPortraitUpsideDown,UIInterfaceOrientationLandscapeLeft,UIInterfaceOrientationLandscapeRight’. Found ‘UIInterfaceOrientationLandscapeLeft,UIInterfaceOrientationLandscapeRight’ in bundle ‘...’.”

ERROR ITMS-90475: “Invalid Bundle. iPad Multitasking support requires launch story board in bundle ‘...”

原因 iPad 分屏适配,需要添加全屏声明

​解决方式​
Info.plist 中添加:

<key>UIRequiresFullScreen</key> <true/>


ITMS-90529

​错误信息​

ERROR ITMS-90529: "IInvalid package. Applications built with sdk 9.0 or later must be packaged as proper IPA files"

原因

打包方式不正确,未使用 .ipa 文件格式

​解决方式​
将编译后的 .app 放入 Payload 文件夹,压缩为 .ipa 文件。


ITMS-90983

​错误信息​

ERROR ITMS-90983: "Missing purpose string in Info.plist for media classification."

原因

iOS 16 及以上需要在 Info.plist 中添加媒体分类的目的字符串

​解决方式​
Info.plist 中添加媒体分类描述:

  • NSMediaLibraryUsageDescription
  • NSAppleMusicUsageDescription