Allow cose signing of windows installers
@@ -634,6 +634,24 @@ class Platform
ProcessHelper.runCommand("",nsis+"/makensis.exe", ["/NOCD", scriptName] );
Log.verbose("Wrote " + name);
+
+ if (project.certificate!=null)
+ {
+ var signtool = project.getDef("SIGNTOOL");
+ if (signtool==null || signtool=="")
+ {
+ Log.verbose("SIGNTOOL variale not found, assuming signtool.exe");
+ signtool = "signtool.exe";
+ }
+ var pfxPath = project.certificate.path;
+ var certificatePwd = project.certificate.password;
+
+
+ var signParams = ["sign", "/fd", "SHA256", "/a", "/f", pfxPath, "/p", certificatePwd,
+ "/t", "http://timestamp.digicert.com", name];
+ ProcessHelper.runCommand("",signtool,signParams);
+ Log.verbose("signed installer");
+ }
}
else
Log.error("Unknown deployment protocol, use: 'script:', 'adb:', 'nsis:' or 'dir:'");
