Create and Add a Free Certificate for Your Application

Helpful script writing tricks and HowTo's
User avatar
Posts: 473
Joined: 05 Apr 2016, 14:18
Location: İstanbul

Create and Add a Free Certificate for Your Application

19 Apr 2020, 11:08

It is useful to create certificates to gain the trust of antiviruses and prove that the software is yours. When they whitelist your certificate, you now receive fewer false positives. It may also be useful for some Antiviruses that think of Autohotkey applications as viruses.

In order to perform these operations, you must have an operating system of Windows 8.1 and above.

Creating the Certificate:

Open the PowerShell window and edit the following codes according to your own order: (PowerShell can be found by searching in the Start Menu)

Enter Your Website Name:

Code: Select all

$cert = New-SelfSignedCertificate -DnsName -Type CodeSigning -CertStoreLocation Cert:\CurrentUser\My
Enter the password for the certificate in the required field:

Code: Select all

$CertPassword = ConvertTo-SecureString -String "Your_Password" -Force –AsPlainText
Enter this command to export the certificate in Pfx format:

Code: Select all

Export-PfxCertificate -Cert "cert:\CurrentUser\My\$($cert.Thumbprint)" -FilePath "D:\Certs\Your_Cert_Name.pfx" -Password $CertPassword
The result is as follows. A certificate has been created on path "D: \ Certs".
PowerShell.png (73.51 KiB) Viewed 532 times

Add Certificate to Application:

Let's download and run the DigiCert App, a free app.

The certificate will be displayed on the CodeSigning Tab. (If there is a different situation, add the certificate by using the "import" button on the right.)

Add the certificate by following the steps in the image in order.
DigiCert.png (73.5 KiB) Viewed 532 times


Now you can right click on the certified application, open its properties and check the certificate.
EndCert.PNG (37.16 KiB) Viewed 532 times
Resources: (In Turkish Language)
Posts: 1237
Joined: 22 Jan 2017, 19:37

Re: Create and Add a Free Certificate for Your Application

19 Apr 2020, 11:18

@hasantr, very nice and extremely useful, thank you!

Return to “Tutorials”

Who is online

Users browsing this forum: No registered users and 14 guests