Rate this article: 



(1 votes, average: 5.00)






This article will simplify the process of generating a Comodo Code Signing Certificate and its public-private key pair for use in Google Cloud Key Management Service (Google Cloud KMS).
Technical Users: Follow our guide on how to generate the CSR and download the key attestation in Google Cloud.
It’s hard to set up a Google Cloud KMS account with a code signing key if you don’t have a certificate! While this step may be a no-brainer for more experienced developers, it’s an important step to mention for our newer dev readers who may not be as familiar with code signing certificates.
The good news is that you can get a Comodo Code Signing Certificate without breaking the bank. This is because we offer discounts of up to 14% on top of our already discounted prices via coupons for code signing certificates, email signing certificates, and SSL/TLS certificates.
Ready to start signing your software and other executables in the cloud? You can with a Comodo Code Signing Certificate + Google Cloud KMS.
Shop Code Signing CertificatesWhen purchasing a Comodo Code Signing Certificate for cloud code signing from ComodoSSLstore.com, you’ll need to select the preferred certificate delivery method. Code signing certificate keys must be securely generated and stored on FIPS-compliant secure hardware devices such as USB tokens and physical and cloud-based hardware security modules (HSMs).
Get a Comodo Code Signing CertificateTo select Google Cloud KMS when purchasing a certificate from ComodoSSLstore.com, you can make the selection on the certificate’s product page. Using the drop-down menu, select Install on Existing HSM and complete the checkout process.
Once your order is complete, you’ll be guided through the certificate generation process on CertificateGeneration.com that we’ll go over in Step Five.
If you wish to use an existing Google Cloud KMS key ring, jump to Step Three. Otherwise, you’ll need to set up a new key ring following the directions provided by Google Cloud KMS. (NOTE: This set up process will require using an authorized Cloud KMS Admin account.)
Code signing certificates must be generated and stored on secure hardware. This means that if you’re using a hardware security module (HSM), then you must provide attestation documentation to the certification authority (CA).
To collect your key attestation files:
Next, you’ll need to generate a certificate signing request using the key you just generated. There are several different ways you can generate the CSR.
For this tutorial we’ll walk you through doing it with OpenSSL on Linux (Ubuntu).
13. Set the environment variable to point to your key file. You can do this using a modified version of the command: export GOOGLE_APPLICATION_CREDENTIALS=”/root/gckms_auth.json” (Be sure to replace the JSON file’s example location path with the real one.)
You’ve now configured OpenSSL to use Google KMS as a PKCS #11 provider. If you need to troubleshoot your connection to Google KMS:
14. You can now generate the CSR. Do this using a modified version of the following command that reflects your specific variables: openssl req -new -subj ‘/CN=Your Company Name, LLC/’ -sha256 -engine pkcs11 -keyform engine -key pkcs11:object=your_key_name > code_signing_request.csr
When you purchase a certificate from ComodoSSLstore.com, you’ll be directed to a certificate enrollment wizard on CertificateGeneration.com. You’ll need the attestation documentation for this step (i.e., the .zip file you downloaded earlier in Step Three).
To complete the CSR submission process, log into your account on ComodoSSLstore.com and access your orders in the dashboard and choose the option to generate a certificate. This will take you to CertificateGeneration.com page. Here, you’ll be asked to do the following:
It’s in step #4 of this process (as shown in the screenshot below) that you’ll need to do the following:
Once your identity has been verified and all T’s are crossed and I’s are dotted, the CA will issue your certificate.
That’s it! You can now start adding your digital signature to executables in the cloud using your code signing key that’s securely stored in Google KMS.