How to Verify Software Before Deployment
Verify that a release artifact is authentic, unchanged, tested and approved before it reaches production. This guide covers code signatures, certificate trust, artifact hashes, security checks and automated release controls.
Verifying software before deployment helps ensure that the release artifact is authentic, has not been unexpectedly modified, and meets the technical and security requirements for its target environment. For signed software, this includes checking the digital signature, certificate chain, timestamp and publisher identity. It can also involve validating artifact hashes, running security tests and confirming that the file being deployed is the same one that passed release approval.
A successful build does not automatically mean software is ready for deployment. An executable may have an invalid signature, a package may have changed after signing, or a release pipeline may accidentally promote a different artifact from the one that was tested.
The safest approach is to treat verification as a required release gate. Build and test the software, finalize the artifact, sign it where required, verify the signature and integrity, and deploy only the approved artifact.
This guide explains how to verify software before deployment across common platforms and automated release workflows.
What Does Software Verification Before Deployment Mean?
Software verification before deployment is the process of checking that a release meets defined integrity, authenticity, security and operational requirements before it is promoted to production or distributed to users.
For code-signed software, verification helps establish whether the signature is valid under the selected verification policy and whether the signed content has changed. Certificate validation helps assess the signer's identity and trust chain. Additional checks establish whether the artifact passed testing and matches the approved release.
Verification generally covers five areas:
Signature validity
Does the digital signature verify against the artifact?
Publisher and certificate trust
Is the signing identity expected, and is the certificate chain acceptable under the applicable policy?
Artifact integrity
Does the artifact match the expected file or release hash?
Security and quality
Has the release passed required tests, scans and approvals?
Deployment consistency
Will the system deploy the exact artifact that was verified?
These checks complement one another. A valid signature does not prove that software is free of vulnerabilities, and a matching hash does not by itself establish who produced the artifact.
Software Verification Workflow Before Deployment
Identify the release artifact
Confirm the version, file format, build identifier and intended deployment target.
Run tests and security checks
Complete required functional tests, dependency checks and vulnerability scans.
Verify the signature
Check the digital signature and ensure the expected publisher identity is present.
Validate integrity and trust
Inspect the certificate chain, timestamp and expected artifact hash.
Approve the release
Apply release policies and block promotion if a mandatory check fails.
Deploy the verified artifact
Promote the same artifact that passed verification, without rebuilding or modifying it.
The exact checks depend on the software format and deployment environment. A Windows executable, macOS application, Java archive and Linux package may require different signature verification tools and trust policies.
Step 1: Confirm the Artifact Being Verified
Before running verification commands, establish exactly which file is being considered for release.
Record its filename, version, build identifier, source revision and intended deployment environment. If the release contains multiple files, identify which components require their own signatures and which package or installer will be distributed.
Check that:
- The artifact came from the expected build pipeline.
- The build completed successfully.
- The release version and package metadata are correct.
- All required changes were completed before signing.
- The file being verified is the one intended for deployment.
This step prevents a common release mistake: verifying one file and deploying another.
Step 2: Verify the Code Signature
The verification command depends on the platform and file type.
Verify a Windows executable
Microsoft SignTool can verify an Authenticode signature using the default Authenticode policy:
signtool verify /pa /v "MyApplication.exe"Review the output for a successful verification result and inspect the certificate and timestamp details.
The /pa option selects the default Authenticode verification policy, and /v provides verbose output. Drivers and other specialized artifacts may require a different verification policy or additional checks.
If verification fails, investigate the exact error rather than assuming that the certificate is defective. The file may have changed after signing, the certificate chain may be untrusted, or the signing process may have used an unsuitable identity.
Verify a macOS application
Use Apple's code signing tools to inspect an application bundle:
codesign --verify --deep --strict --verbose=2 "/Applications/MyApp.app"Review the command output and investigate any invalid or missing signatures. The --deep option can help with diagnostic checks, but it is not a replacement for correctly signing nested components.
Basic signature verification is separate from Gatekeeper assessment and notarization. Applications distributed under workflows requiring notarization should undergo those checks as well.
Verify a Java JAR archive
Use jarsigner to check the signatures in a Java archive:
jarsigner -verify -verbose -certs application.jarInspect the output for verification failures, unsigned entries and certificate warnings. Also check whether the signing certificate is trusted under the security policy of the target Java runtime.
A JAR that verifies cryptographically may still encounter trust or algorithm restrictions in a particular environment.
When command output is ambiguous, How to Verify a Code Signature provides a broader validation workflow, while How to Verify a Code Signature From the Command Line covers verification from a terminal or build script.
Step 3: Validate the Certificate and Publisher Identity
A successful signature check should be followed by a review of the signing identity and applicable trust requirements.
Confirm that:
- The publisher name matches the expected organization or developer.
- The certificate is appropriate for code signing.
- The certificate chain leads to a trusted root under the target system's policy.
- Certificate validity and revocation status meet the applicable requirements.
- The timestamp is present and valid when required by the release policy.
- The signature uses algorithms accepted by the target platform.
A certificate can be technically valid but belong to an unexpected publisher. Conversely, an unfamiliar publisher name does not automatically mean the signature is invalid. Compare the identity with the release record and the publisher information approved for that product.
Check the timestamp
A trusted timestamp can help establish when a signature was created. This can be important when a signing certificate expires, although the final validation result depends on the timestamp, revocation status and applicable policy.
Do not treat the presence of a timestamp alone as proof that the entire artifact is trustworthy. Verify the signature and certificate chain as well.
A timestamp helps establish when the signature was created, which can matter when a signing certificate expires; How to Timestamp Signed Software explains the timestamping step and its validation requirements.
Step 4: Verify Artifact Integrity With a Hash
A cryptographic hash provides a compact fingerprint of a file. Comparing the hash of a candidate artifact with a hash recorded by a trusted build or release process helps establish whether the file has changed.
For example, calculate a SHA-256 hash on Windows:
Get-FileHash "MyApplication.exe" -Algorithm SHA256On Linux or macOS, use:
sha256sum MyApplicationOn macOS, shasum is also available:
shasum -a 256 MyApplicationCompare the result with the hash recorded for the approved release artifact.
Important: The reference hash must come from a trusted source. Calculating a hash and then comparing it with another value obtained from the same untrusted location does not establish authenticity.
Hash verification and signature verification serve different purposes:
| Check | What it establishes | What it does not establish alone |
|---|---|---|
| Digital signature verification | Whether the signature validates for the signed content under the selected policy | Whether the software is vulnerability free |
| Certificate validation | Whether the signing identity and chain meet applicable trust rules | Whether the publisher's software is safe |
| SHA-256 hash comparison | Whether a file matches a trusted reference hash | Who created the file |
| Security scanning | Whether selected tools detect known or suspected security issues | That no vulnerabilities exist |
Use these checks together where appropriate.
Step 5: Test the Software and Its Dependencies
Code signing does not replace software quality assurance. Before deployment, run the tests required for the application's risk level and release policy.
Common checks include:
- Functional and regression tests.
- Dependency and software composition analysis.
- Static application security testing where applicable.
- Malware scanning of release artifacts.
- Configuration and secrets checks.
- Compatibility tests for supported operating systems and runtime versions.
- Installation, upgrade and rollback tests.
- Runtime smoke tests in a representative environment.
For installers, test the actual installation and uninstallation process. For application packages, verify that required files and dependencies are present. For containerized software, validate the image and its associated supply chain controls using the mechanisms appropriate to that environment.
A signed release can still contain vulnerable code, a compromised dependency or an unsafe configuration. Verification should therefore include both authenticity checks and the security controls required by your team.
Step 6: Verify Software Packages and Installers
If a release contains an installer and an application, verify the relevant artifacts individually.
For example, a Windows release might contain:
MyApplication.exe, the main executable.MyInstaller.msi, the installer package.- Supporting DLL files.
- Update utilities or additional executables.
The installer signature does not automatically sign every executable it contains. Similarly, signing an executable does not establish that the installer packaging or installation process is correct.
For macOS, verify the application bundle and any separately signed installer package using the relevant Apple tools. For Java, verify the signed JAR archive and check the certificate trust configuration of the intended runtime.
See How to Sign Software Packages and Installers for the signing side of this process.
Step 7: Enforce Verification in the Deployment Pipeline
Manual checks are useful during development, but production releases should enforce verification automatically wherever practical.
A secure deployment pipeline should fail closed when a mandatory signature, integrity or release policy check fails. It should not continue to deployment simply because the build succeeded.
Build and test
Produce the release artifact and complete required quality checks.
Sign the release
Use the approved signing identity and protected key infrastructure.
Verify the artifact
Check the signature, publisher, timestamp and expected hash.
Evaluate release policy
Confirm required approvals, security results and release conditions.
Promote and deploy
Deploy the exact verified artifact and retain release evidence.
Follow these practices when implementing the pipeline:
Promote the same artifact. Build once and promote the verified artifact through the release stages when your deployment architecture permits. If a later operation changes signed content, repeat the required signing and verification steps.
Protect signing credentials. Restrict signing access to authorized release jobs and identities. Keep private key material out of source code, ordinary build artifacts and unprotected variables.
Retain verification evidence. Record the artifact hash, build identifier, signature verification result, release approval and deployment outcome.
Block failed releases. Make signature and integrity verification mandatory checks when required by your release policy. Investigate failures before allowing deployment to proceed.
Related guides:
A repeatable release workflow connects signing to release approvals, while the CI/CD signing guide covers the pipeline implementation, and the software release process guide explains how to integrate signing into release stages.
Common Software Verification Failures
| Problem | Likely cause | Recommended action |
|---|---|---|
| Signature verification fails | Artifact was modified, signature is damaged or signing was incorrect | Inspect the exact artifact and repeat verification |
| Publisher is unexpected | Wrong signing identity or an unapproved release | Compare the certificate identity with the approved publisher |
| Certificate chain is untrusted | Missing intermediate certificate or unsuitable trust configuration | Inspect the chain and target system's trust store |
| Timestamp validation fails | Timestamp is missing, invalid or cannot be trusted | Inspect timestamp details and the applicable certificate policy |
| Hash does not match | Wrong artifact, post-build modification or incorrect reference hash | Trace the artifact to its build and obtain the trusted reference hash |
| Application is blocked despite a valid signature | Platform policy, reputation or notarization requirement | Check the relevant operating system's acceptance requirements |
| CI/CD verification fails | Environment, permissions, trust store or tool configuration differs | Compare the pipeline with a known working environment |
| Software passes verification but fails at runtime | Dependency, configuration, compatibility or application defect | Run installation and runtime tests in a representative environment |
When verification fails, the error can point to a changed artifact, certificate trust issue or signing configuration problem; How to Troubleshoot Code Signing Errors covers those common failure modes.
Pre-Deployment Software Verification Checklist
Frequently Asked Questions
What should be verified before deploying software?
Is code signature verification enough for production deployment?
Should software be verified before or after deployment?
Can I verify software without knowing the publisher?
What happens if the software signature is valid but the hash is different?
Should every deployment use code signing?
Choose a code signing certificate for your release
Certificate requirements vary by platform, publisher identity and distribution method. Compare available code signing options before selecting the signing identity for your release process.
Read the certificate buying guideExplore available code signing certificates
Review certificate options for your software distribution needs and confirm which signing identity aligns with your platform and publisher requirements.
View all certificates