|
|
|
@ -212,16 +212,15 @@ let provideNuGetExtraFiles path (bundle:Bundle) (pack:Package) = |
|
|
|
// SIGN |
|
|
|
|
|
|
|
let sign fingerprint timeserver files = |
|
|
|
files |
|
|
|
|> Seq.map (sprintf "\"%s\"") |
|
|
|
|> Seq.map (fun file -> sprintf """sign /v /fd sha256 /sha1 "%s" /tr "%s" /td sha256 %s""" fingerprint timeserver file) |
|
|
|
|> Seq.iter (fun arguments -> |
|
|
|
let result = |
|
|
|
ExecProcess (fun info -> |
|
|
|
info.FileName <- findToolInSubPath "signtool.exe" """C:\Program Files (x86)\Windows Kits\10\bin\x64""" |
|
|
|
info.Arguments <- arguments) TimeSpan.MaxValue |
|
|
|
if result <> 0 then |
|
|
|
failwithf "Error during SignTool call ") |
|
|
|
let fileArgs = files |> Seq.map (sprintf "\"%s\"") |> String.concat " " |
|
|
|
let optionsArgs = sprintf """/v /fd sha256 /sha1 "%s" /tr "%s" /td sha256""" fingerprint timeserver |
|
|
|
let arguments = sprintf """sign %s %s""" optionsArgs fileArgs |
|
|
|
let result = |
|
|
|
ExecProcess (fun info -> |
|
|
|
info.FileName <- findToolInSubPath "signtool.exe" """C:\Program Files (x86)\Windows Kits\10\bin\x64""" |
|
|
|
info.Arguments <- arguments) TimeSpan.MaxValue |
|
|
|
if result <> 0 then |
|
|
|
failwithf "Error during SignTool call " |
|
|
|
|
|
|
|
|
|
|
|
// ZIP |
|
|
|
|