@@ -57923,13 +57923,19 @@ async function ImportCredentials() {
5792357923 const developerIdApplicationCertificateBase64 = core.getInput('developer-id-application-certificate');
5792457924 if (developerIdApplicationCertificateBase64) {
5792557925 const developerIdApplicationCertificatePassword = core.getInput('developer-id-application-certificate-password');
57926+ if (!developerIdApplicationCertificatePassword) {
57927+ throw new Error('developer-id-application-certificate-password is required when developer-id-application-certificate is provided!');
57928+ }
5792657929 core.info('Importing developer id application certificate...');
5792757930 await importCertificate(keychainPath, tempCredential, developerIdApplicationCertificateBase64.trim(), developerIdApplicationCertificatePassword.trim());
5792857931 installedCertificates = true;
5792957932 }
5793057933 const developerIdInstallerCertificateBase64 = core.getInput('developer-id-installer-certificate');
5793157934 if (developerIdInstallerCertificateBase64) {
5793257935 const developerIdInstallerCertificatePassword = core.getInput('developer-id-installer-certificate-password');
57936+ if (!developerIdInstallerCertificatePassword) {
57937+ throw new Error('developer-id-installer-certificate-password is required when developer-id-installer-certificate is provided!');
57938+ }
5793357939 core.info('Importing developer id installer certificate...');
5793457940 await importCertificate(keychainPath, tempCredential, developerIdInstallerCertificateBase64.trim(), developerIdInstallerCertificatePassword.trim());
5793557941 installedCertificates = true;
@@ -58021,14 +58027,9 @@ async function importCertificate(keychainPath, tempCredential, certificateBase64
5802158027 const certArgs = [
5802258028 'import', certificatePath,
5802358029 '-k', keychainPath,
58030+ '-P', certificatePassword,
5802458031 '-A', '-t', 'cert', '-f', 'pkcs12'
5802558032 ];
58026- if (certificatePassword && certificatePassword.length > 0) {
58027- certArgs.push('-P', certificatePassword);
58028- }
58029- else {
58030- certArgs.push('-P', '');
58031- }
5803258033 await exec.exec(security, certArgs);
5803358034 const partitionList = 'apple-tool:,apple:,codesign:';
5803458035 if (core.isDebug()) {
0 commit comments