Created
March 14, 2024 17:23
-
-
Save unitycoder/3e61459c367d0273b49b83fcf49c17e2 to your computer and use it in GitHub Desktop.
Revisions
-
unitycoder revised this gist
Mar 14, 2024 . 1 changed file with 3 additions and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,3 +1,4 @@ ``` // https://forum.unity.com/threads/codesign-a-windows-build.1558505/ $password = ConvertTo-SecureString -String \"#{password}\" -Force -AsPlainText @@ -6,4 +7,5 @@ $subject_name = (Get-PfxData -FilePath "$filePath" -Password $password | Select- $subject_name = $subject_name -replace 'CN=', '' Import-PfxCertificate -FilePath $filePath -CertStoreLocation Cert:\\LocalMachine\\My -Password $password & signtool.exe sign /a /sm /n $subject_name /fd SHA256 "$fileToSign" ``` -
unitycoder created this gist
Mar 14, 2024 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,9 @@ // https://forum.unity.com/threads/codesign-a-windows-build.1558505/ $password = ConvertTo-SecureString -String \"#{password}\" -Force -AsPlainText $subject_name = (Get-PfxData -FilePath "$filePath" -Password $password | Select-Object -ExpandProperty EndEntityCertificates | Select-Object -ExpandProperty SubjectName).Name $subject_name = $subject_name -replace 'CN=', '' Import-PfxCertificate -FilePath $filePath -CertStoreLocation Cert:\\LocalMachine\\My -Password $password & signtool.exe sign /a /sm /n $subject_name /fd SHA256 "$fileToSign"