Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8318063

[macos] jpackage should do a codesign verify of application bundles

XMLWordPrintable

    • x86_64
    • os_x

      ADDITIONAL SYSTEM INFORMATION :
      macOS Ventura 13.5.2

      openjdk version "20" 2023-03-21
      OpenJDK Runtime Environment (build 20+36-2344)
      OpenJDK 64-Bit Server VM (build 20+36-2344, mixed mode, sharing)


      A DESCRIPTION OF THE PROBLEM :
      It could be useful for OS/X application builds if a codesign verify were done against completed application bundles.

      This could catch signing errors and allow failing of the build. In either application testing or in deployment.

      If for some reason it wouldn't be desirable to do it every run it could be done as informational on verbose jpackage runs. Allowing problem determination in the event something is incorrect.

      Example:
      codesign -v --verbose=4 outputdir/HalfPipe.app
      outputdir/HalfPipe.app: valid on disk
      outputdir/HalfPipe.app: satisfies its Designated Requirement

      codesign -v --verbose=4 QuantumJava.app
      QuantumJava.app: code has no resources but signature indicates they must be present

      ./qcapp.sh
      touch QuantumJava.app/Contents/app/qcqpp.jar
      codesign -v --verbose=4 QuantumJava.app
      QuantumJava.app: a sealed resource is missing or invalid
      file added: /Users/mjh/Documents/physics/quantumjava/QuantumJava.app/Contents/app/qcqpp.jar


            almatvee Alexander Matveev
            webbuggrp Webbug Group
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: