Permalink
Browse files

[skip ci] Setup code signing

  • Loading branch information...
nopara73 committed Oct 22, 2018
1 parent 80dcfb8 commit a909b9718a116d94dc908886a6ce98dcfaceb5f0
Showing with 16 additions and 2 deletions.
  1. +16 −2 WalletWasabi.Packager/Program.cs
@@ -18,9 +18,11 @@ private static void Main(string[] args)
// 1. Publish with Packager.
// 2. Build WIX project with Release and x64 configuration.
// 3. Sign with Packager.
bool doPublish = true;
bool doSign = false;
var doPublish = true;
var doSign = false;
var pfxPassword = "dontcommit";
string pfxPath = "C:\\digicert.pfx";
string packagerProjectDirectory = Path.GetFullPath(Path.Combine(AppContext.BaseDirectory, "..\\..\\..\\"));
string solutionDirectory = Path.GetFullPath(Path.Combine(packagerProjectDirectory, "..\\"));
string guiProjectDirectory = Path.GetFullPath(Path.Combine(solutionDirectory, "WalletWasabi.Gui\\"));
@@ -203,6 +205,17 @@ private static void Main(string[] args)
var msiFileName = Path.GetFileName(msiPath);
var newMsiPath = Path.Combine(binDistDirectory, msiFileName);
File.Move(msiPath, newMsiPath);
// Sign code with digicert.
var psiSigntool = new ProcessStartInfo
{
FileName = "cmd",
RedirectStandardInput = true,
WorkingDirectory = binDistDirectory
};
var signToolProcess = Process.Start(psiSigntool);
signToolProcess.StandardInput.WriteLine($"signtool sign /d \"Wasabi Wallet\" /f \"{pfxPath}\" /p {pfxPassword} /t http://timestamp.digicert.com /a \"{newMsiPath}\" && exit");
signToolProcess.WaitForExit();
}
else if (target.StartsWith("linux", StringComparison.OrdinalIgnoreCase))
{
@@ -283,6 +296,7 @@ private static void Main(string[] args)
}
IoHelpers.OpenFolderInFileExplorer(binDistDirectory);
return; // No need for readkey here.
}
Console.WriteLine();

0 comments on commit a909b97

Please sign in to comment.