Sunday, November 29, 2015

Check binary file certificate

Certificates of binary files (executables or dynamic libraries) on Windows can be checked using available tool (signtool.exe) or by developing code using API procedures.

1. The utility signtool.exe is used to sign binaries, but it also allows overview of certificate information. Usage is described at location https://msdn.microsoft.com/en-us/library/windows/desktop/aa388171%28v=vs.85%29.aspx

2. WinVerifyTrust API gives information if file is signed and certificate is valid or not. Usage is described here: https://msdn.microsoft.com/en-us/library/aa388208%28v=vs.85%29.aspx.

3. Crypto API gives more information, similar to results of signtool.exe. Possible usage is described at https://support.microsoft.com/en-us/kb/323809.

No comments: