Wixsharp: Certificate password can be null

Created on 5 Jun 2018  路  9Comments  路  Source: oleg-shilo/wixsharp

Hi Oleg,
with commit 281567b38eb9b7176a8cb0fe7e15aeeb19943b83 an ArgumentNullException is thrown using the following code:

project.DigitalSignature = new DigitalSignature()
{
    UseCertificateStore = true,
    PfxFilePath = "My certificate name",
    OptionalArguments = "/a /s MY /fd sha256 /tr \"http://sha256timestamp.ws.symantec.com/sha256/timestamp\"",
    Description = "My description"
};

The password variable can be null.
https://github.com/oleg-shilo/wixsharp/blob/90111a5fce95fc76649f1ae473ea50eeb21ca6a8/Source/src/WixSharp/CommonTasks.cs#L215

Done / Released bug

Most helpful comment

Should be OK now

Install-Package WixSharp -Version 1.6.5.3-HotFix 

All 9 comments

You are absolutely right. I was not aware that password is optional.

Do you need a HotFix release or you prefer to wait for the normal release?

I am hitting the same issue, tried to solve it with password=string.Empty but for some reason it does not work.
So yes, I personally would appreciate a HotFix NuGet....

Thanks

I can wait for the normal release.
For now I downgraded to version 1.6.5.0 where the digital signature works correctly.

Done:

Install-Package WixSharp -Version 1.6.5.2-HotFix 

PM> Install-Package WixSharp -Version 1.6.5.2-HotFix

Attempting to gather dependency information for package 'WixSharp.1.6.5.2-HotFix'
Gathering dependency information took 951,9 ms
Attempting to resolve dependencies for package 'WixSharp.1.6.5.2-HotFix' with DependencyBehavior 'Lowest'
_Install-Package : Unable to find a version of 'WixSharp.bin' that is compatible with 'WixSharp 1.6.5.2-HotFix constraint: WixSharp.bin (>= 1.6.5.2)'._
At line:1 char:1

  • Install-Package WixSharp -Version 1.6.5.2-HotFix
  • ~~~~~~~~~~~~

    • CategoryInfo : NotSpecified: (:) [Install-Package], Exception

    • FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand

Give it another try. May be NuGet was not ready yet. The package is there: https://www.nuget.org/packages/WixSharp/1.6.5.2-HotFix

image

yes but shouldn't the dependency in WixSharp.nuspec also point to 1.6.5.2-HotFix instead of this?

    <dependencies>
        <dependency id="WixSharp.bin" version="1.6.5.2" />
    </dependencies>

edit: since WixSharp.bin 1.6.5.2 does not actually exists (only WixSharp.bin 1.6.5.2-Hotfix, as the error message states)

:( Yes . My mistake.
Incrementing the version now...

Should be OK now

Install-Package WixSharp -Version 1.6.5.3-HotFix 
Was this page helpful?
0 / 5 - 0 ratings

Related issues

UweKeim picture UweKeim  路  5Comments

kain64 picture kain64  路  4Comments

meytes picture meytes  路  5Comments

mattias-symphony picture mattias-symphony  路  3Comments

ju2pom picture ju2pom  路  5Comments