Archive for the ‘Cryptography’ Category
Wednesday, October 15th, 2008
CAPICOM, a COM-based wrapper for the CryptoAPI library, is deprecated and on its way out. However, Microsoft has no time line for phasing it out, nor have they provided sufficient documentation of alternatives.
Many CAPICOM pages contain a confusing, bright-red header along the lines of:
[The SignedCode object is available for ...
Posted in Authenticode, COM, Cryptography, Technology, Win32 | No Comments »
Saturday, October 4th, 2008
GnuPG, GNU Privacy Guard, is a free system for encrypting files, emails, etc. The GnuPG plugin for vim provides automatic encryption and decryption of files within vim. If you attempt to edit a GnuPG-encrypted file with vim, it will prompt you for the password, and re-encrypt the file ...
Posted in Cryptography, Technology, Win32 | No Comments »
Friday, September 12th, 2008
Obtain a Software Publisher Certificate
Your Certificate Authority will supply one of the following:
a Personal Information Exchange (.pfx) file
a Software Publisher Certificate (.spc), and a Private Key (.pvk) file
a CER-encoded X.509 Certificate (.cer), and a Private Key (.pvk) file
For the second and third case, these file must be converted to a ...
Posted in Cryptography, Technology | No Comments »
Thursday, September 11th, 2008
With CAPICOM deprecated, MSDN suggests using the mssign32.dll functions. There are two fundamental problems with this:
No example code whatsoever is provided.
No header file is provided.
Well, at least I can do something about #2. Here is a minimal version of a header file for mssign32.dll. It includes direct ...
Posted in Authenticode, Cryptography, Technology | No Comments »
Wednesday, May 21st, 2008
Key Generation
Generate a DSA key:
ssh-keygen -t dsa
This will generate an RFC 4716-formatted key file similar to the following:
-----BEGIN DSA PRIVATE KEY-----
MIIBuwIBAAKBgQDijfpmyXBZpnq8EhEhSxeJz7fNxIlWYD6t7bviDZMARh8mLCr2
bug2J1K+Rl4qoLQJ7zRGlytwQ2krTCmvVahOjy9m/QW5936rCyVS19PRdJMEEMSN
vLQaMtpKbnHp0z8Xs/X1CkDmxThOlvRVjiObdd0U9eELLoo5VHauVHmufwIVAO7j
l4bxgVXeX09WJcyOXAUauNXHAoGAF20ESXgTvbbdxDECa2tfTi/j1/+emNV/+zuR
aq6xms/K0piZhMlkK3BD9PgHhXfqZuRT/Z9b8ja3nR34H2KL3UInCNV6kSq6h+MD
MLJnNQG4wADLYw3p5Tzz/hUwtfqpZ/9e7FpBdgfooS274GgPKTG8BFRiudIztPpK
4GueicoCgYEAy8hllDrFzQUqFG0kMe8r3dOFDjMQHf6ITttmAiScwEPg+a5D++Sq
bj42vkKSNgaYHc+Z8QPgerPehIkBde6wx0ukq0a8IXy8F86IasXz3wzotPeJsdKi
mynQKzhSm9Jzbk/SK/yh5NGhJzz1VmHsg+ir/qReguMHfqDGCI4kSFYCFDJKXQ4h
MteJHSlu62RrGwInRBOh
-----END DSA PRIVATE KEY-----
An accompanying, OpenSSH-formatted public key file should also be generated under the same file name with a .pub suffix. It should appear similar to the following:
ssh-dss ...
Posted in Cryptography, Technology | No Comments »