notarization: ".pkg could not be extracted."

Hi, after a software update of our previously successfully notarizated installion .pkg we now receive a cryptic notarization issue refusing the entire .pkg:

{
  "logFormatVersion": 1,
  "jobId": "5cff2d71-7228-4fb4-a39d-329084cd2713",
  "status": "Invalid",
  "statusSummary": "Archive contains critical validation errors",
  "statusCode": 4000,
  "archiveFilename": "my_installer.pkg.zip",
  "uploadDate": "2024-12-04T23:17:14.016Z",
  "sha256": "2f26d0376506abe130ac904d7cb0d0cd5428666624428da9f44da7756352844f",
  "ticketContents": null,
  "issues": [
    {
      "severity": "error",
      "code": null,
      "path": "my_installer.pkg.zip",
      "message": "Package my_installer.pkg.zip has no signed executables or bundles. No tickets can be generated.",
      "docUrl": null,
      "architecture": null
    },
    {
      "severity": "warning",
      "code": null,
      "path": "my_installer.pkg.zip/my_installer.pkg",
      "message": "The contents of the package at my_installer.pkg.zip/my_installer.pkg could not be extracted.",
      "docUrl": null,
      "architecture": null
    }
  ]
}

What could be the reason for that? We've also submitted the .pkg (not zipped) with the same result. We build it on different macOS versions, including Sonoma 14.7 with latest developer tools installed, without any change in outcome.

But when extracting it via the undocumented:

pkgutil --expand-full

and .zipping the raw contents (without re-packaging it as .pkg) and sending it again, notarization succeeds for all components.

However the installation for the .pkg still fails with the notarization dialog. I was under the assumption that it is sufficient to notarize the .pkg contents but this does not seem to be true, or?

Any hints or help is highly appreciated, Thanks!

Answered by hagen in 817519022

I found the issue: a line choice was missing for a given choice element. Now the thing is that productbuild does not complain as well as it never returns an error value once the distribution.xml has passed checks for formal xml correctness. The notarization issue is cryptic enough to let me spend days on investigation. And it's certainly not my first .pkg installer... Thanks anyways!

I suspect that this has something to do with the way that your installer package is created. In Packaging Mac software for distribution there’s a trivial example of how to create a package for an app. If you do that and then submit the package, what happens?

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Thanks Quinn,

yes, the example works, as well as our countless other installer projects. Also the previous .pkg submission prior to the latest content update succeeds. The updated installer .pkg itself can be installed without any issues in the installer .log.

Accepted Answer

I found the issue: a line choice was missing for a given choice element. Now the thing is that productbuild does not complain as well as it never returns an error value once the distribution.xml has passed checks for formal xml correctness. The notarization issue is cryptic enough to let me spend days on investigation. And it's certainly not my first .pkg installer... Thanks anyways!

notarization: ".pkg could not be extracted."
 
 
Q