最新的macOS版本10.15.4声称代码签名对客户无效

问题描述 投票:1回答:1

好,所以我正在为macOS桌面应用程序使用代码签名和(已验证)公证。

我还通过下载并执行在macOS 10.15.3上测试自己的下载。 (例如,如果我忘记了对代码进行签名,那么我将无法运行我的可执行文件)

但是现在我有一个使用macOS 10.15.4的客户,他发送了显示以下错误的屏幕截图:

异常类型:EXC_Crach(Coode签名无效)

异常代码:0x0000000000000000,0x0000000000000000

例外说明:EXC_CORPSE_NOTIFY

终止原因:命名空间CODESIGNING,代码0x1

这里是我签名的相关部分

  codesign --force --options runtime --timestamp --entitlements "/Volumes/DiskW/projects-cool/myapp/osx/shrents/casc-dlv.plist" --sign "Example" "/Volumes/DiskW/projects-cool/myapp/osx/finaldist/myapp.app"

  codesign --display --entitlements :- "/Volumes/DiskW/projects-cool/myapp/osx/finaldist/myapp.app"

  /usr/bin/xcrun altool --notarize-app --primary-bundle-id "com.example.myapp" -u "[email protected]" -p "xxx" -t osx -f "/Volumes/DiskW/projects-cool/myapp/osx/finaldist/myapp.zip"

  /usr/bin/xcrun altool --notarization-info yyyy -u "[email protected]" -p "xxx"

  /usr/bin/xcrun stapler staple -v "/Volumes/DiskW/projects-cool/myapp/osx/finaldist/myapp.app"

casc-dlv.plist的内容:

<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>com.apple.security.cs.disable-library-validation</key>
    <true/>
</dict>
</plist>

Info.plist的内容

<?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>CFBundleDevelopmentRegion</key>
    <string>English</string>
    <key>CFBundleExecutable</key>
    <string>MyApp</string>
    <key>CFBundleName</key>
    <string>MA</string>
    <key>LSApplicationCategoryType</key>
    <string></string>
    <key>CFBundleIdentifier</key>
    <string>com.example.MyApp</string>
    <key>CFBundleInfoDictionaryVersion</key>
    <string>6.0</string>
    <key>CFBundlePackageType</key>
    <string>APPL</string>
    <key>CFBundleSignature</key>
    <string>a1wse</string>
    <key>CFBundleShortVersionString</key>
    <string>10.1.4</string>
    <key>CFBundleVersion</key>
    <string>10.1.4</string>
    <key>CFBundleIconFile</key>
    <string>MyApp.icns</string>
    <key>CSResourcesFileMapped</key>
    <true/>
    <key>NSRequiresAquaSystemAppearance</key>
    <true/>             
    <key>NSAppTransportSecurity</key>
    <dict>
      <key>NSAllowsArbitraryLoads</key>
      <true/>       
    </dict>
    <key>CFBundleDocumentTypes</key>
    <array>
        <dict>
            <key>CFBundleTypeRole</key>
            <string>Viewer</string>
            <key>CFBundleTypeExtensions</key>
            <array>
                <string>*</string>
            </array>
            <key>CFBundleTypeOSTypes</key>
            <array>
                <string>fold</string>
                <string>disk</string>
                <string>****</string>
            </array>
        </dict>
    </array>
    <key>NSHighResolutionCapable</key>
    <true/>
    <key>LSMinimumSystemVersion</key>
    <string>10.8</string>       
</dict>
</plist>

在我拥有的macOS中检查我的“钥匙串”:

  • “开发人员ID应用程序:示例(xyz)”

(无关紧要)

...

查看:https://developer.apple.com/account/resources/profiles/list

我只有几年前用于开发应用程序的配置文件已过期

xcode macos code-signing provisioning-profile lazarus
1个回答
0
投票

删除权利/ casc-dlv.plist似乎可以解决问题。

这是一个答案,因为它可以解决问题,但是我不会将此答案标记为正确的答案,因为在很多情况下,仅转储权利并不总是可能的。

© www.soinside.com 2019 - 2024. All rights reserved.