node_modules/electron-osx-sign/sign.js
/**
 * This function returns a promise verifying the code sign of application bundle.
 * @function
 * @param {Object} opts - Options.
 * @returns {Promise} Promise resolving output.
 */
This function returns a promise verifying the code sign of application bundle.
@function
@param {Object} opts - Options.
@returns {Promise} Promise resolving output.
This function returns a promise verifying the code sign of application bundle . @function @param { Object } opts - Options . @returns { Promise } Promise resolving output .
function verifySignApplicationAsync (opts) {
  var compareVersion = require('compare-version')
  var osRelease = require('os').release()
  debuglog('Verifying application bundle with codesign...')
  var promise = execFileAsync('codesign', [
    '--verify',
    '--deep',
    '--verbose=2'
  ]
    .concat(compareVersion(osRelease, '15.0.0') >= 0 ? ['--strict'] : [], 
      [opts.app]))
  if (opts.platform === 'darwin' && opts['gatekeeper-assess'] !== false) {
    promise = promise
      .then(function () {
        debuglog('Verifying Gatekeeper acceptance for darwin platform...')
        return execFileAsync('spctl', [
          '--assess',
          '--type', 'execute',
          '--verbose',
          '--ignore-cache',
          '--no-cache',
          opts.app
        ])
      })
  }
  return promise
    .thenReturn()
}
function verifySignApplicationAsync ( opts ) { var compareVersion = require ( 'compare-version' ) var osRelease = require ( 'os' ) . release ( ) debuglog ( 'Verifying application bundle with codesign...' ) var promise = execFileAsync ( 'codesign' , [ '--verify' , '--deep' , '--verbose=2' ] . concat ( compareVersion ( osRelease , '15.0.0' ) >= 0 ? [ '--strict' ] : [ ] , [ opts . app ] ) ) if ( opts . platform === 'darwin' && opts [ 'gatekeeper-assess' ] !== false ) { promise = promise . then ( function ( ) { debuglog ( 'Verifying Gatekeeper acceptance for darwin platform...' ) return execFileAsync ( 'spctl' , [ '--assess' , '--type' , 'execute' , '--verbose' , '--ignore-cache' , '--no-cache' , opts . app ] ) } ) } return promise . thenReturn ( ) }
This function returns a promise verifying the code sign of application bundle.
This function returns a promise verifying the code sign of application bundle .
// Verify with codesign // Only pass strict flag in El Capitan and later // Additionally test Gatekeeper acceptance for darwin platform