Interesting: Life in a post-database world: using crypto to avoid DB writes.
For some security related operations, you only need smart use of HMAC, and no temporary database entries.
Thanks for the Jan Wildeboer referral to this.
–jeroen
Posted by jpluimers on 2015/11/05
Interesting: Life in a post-database world: using crypto to avoid DB writes.
For some security related operations, you only need smart use of HMAC, and no temporary database entries.
Thanks for the Jan Wildeboer referral to this.
–jeroen
Posted in Development, Hashing, Power User, Security, Software Development | Leave a Comment »
Posted by jpluimers on 2015/09/11
Over time this has become a must have: HTTPS Everywhere | Electronic Frontier Foundation developed by EFF and TOR.
Too bad many sites still do not work correctly with it.
This is especially true for places or networks where HTTP (or even worse HTTPS) is going through a MitM layer, for instance many mobile providers do this by injecting tracking bits to your traffic:
–jeroen
Posted in https, Power User, Security | Leave a Comment »
Posted by jpluimers on 2015/07/27
Dumping any kind of certificate file gives you access to more details than the Windows UI usually shows you.
This is especially handy when checking out errors or issues (which can be very difficult to track down).
For binary PFX files, the certutil and openssl commands come in very handy:
Some options to view PFX file details:Open a command prompt and type: certutil -dump Install OpenSSL and use the commands to view the details, such as: openssl pkcs12 -info -in unverified.
OpenSSL is a separate download (from my OpenSSL category of articles, see Some command-line tips for OpenSSL and file format pfx, p12, cer, crt, key, etc. conversion of certificates, keys) to get it.
CertUtil now ships with Windows by default (it wasn’t in the Windows XP era, I’m not sure about Windows Server 2003).
Here is the CertUtil help for dumping certificate information;
Dump certificate file information CertUtil [Options] [-dump] [File] Options: [-f] [-silent] [-split] [-p Password] [-t Timeout]
Note:
- the [-v] option is not listed, but does work; it will give a more verbose dump.
- [-dump] also works other certificate file extensions like .p7b files.
Here is the OpenSSL help for dumping pkcs12 information:
openssl pkcs12 [-export] [-chain] [-inkey filename] [-certfile filename] [-name name] [-caname name] [-in filename] [-out filename] [-noout] [-nomacver] [-nocerts] [-clcerts] [-cacerts] [-nokeys] [-info] [-des | -des3 | -idea | -aes128 | -aes192 | -aes256 | -camellia128 | -camellia192 | -camellia256 | -nodes] [-noiter] [-maciter | -nomaciter | -nomac] [-twopass] [-descert] [-certpbe cipher] [-keypbe cipher] [-macalg digest] [-keyex] [-keysig] [-password arg] [-passin arg] [-passout arg] [-rand files] [-CAfile file] [-CApath dir] [-CSP name]
The pkcs12 command allows PKCS#12 files sometimes referred to as PFX files to be created and parsed. PKCS#12 files are used by several programs including Netscape, MSIE and MS Outlook.
There are a lot of options the meaning of some depends of whether a PKCS#12 file is being created or parsed. By default a PKCS#12 file is parsed. A PKCS#12 file can be created by using the -export option see below.
-in filenameThis specifies filename of the PKCS#12 file to be parsed. Standard input is used by default.
…
-infooutput additional information about the PKCS#12 file structure, algorithms used and iteration counts.
and the OpenSSL help for dumping pkcs7 information:
openssl pkcs7 [-inform PEM|DER] [-outform PEM|DER] [-in filename] [-out filename] [-print_certs] [-text] [-noout] [-engine id]
The pkcs7 command processes PKCS#7 files in DER or PEM format.
-inform DER|PEM; This specifies the input format. DER format is DER encoded PKCS#7 v1.5 structure.PEM the default is a base64 encoded version of the DER form with header and footer lines.
…
-print_certs; prints out any certificates or CRLs contained in the file. They are preceded by their subject and issuer names in one line format.
-text; prints out certificates details in full rather than just subject and issuer names.
…
Notes:
- do not forget the -inform DER option to specify a binary .p7b file.
- the -text option gives you more verbose information
–jeroen
via:
Posted in CertUtil, OpenSSL, PKI, Power User, Public Key Cryptography, Security, Windows | Leave a Comment »
Posted by jpluimers on 2015/07/07
Interesting reads:
–jeroen
Posted in Communications Development, Development, https, Internet protocol suite, LifeHacker, Power User, Security, TCP, TLS | Leave a Comment »
Posted by jpluimers on 2015/06/01
They days of SHA-1 are quickly coming to an end. Chrome has already marked SHA-1 signed TLS/SSL certificates for having an expiration > 2015-12-31 as insecure for a few weeks now. They promised to sunset SHA-1 about 9 months ago.
So if you haven’t done so, upgrade your HTTPS (and HTTP/2 which defaults to TLS) certificates to SHA-2. A great site of help here is SHAAAAAAAAAAAAA | Check your site for weak SHA-1 certificates. It is open source at GitHub.
You’ve less than 6 months now.
More in dept-reading (especially the comments by Ryan Sleevi): Chrome 42 (next stable) will mark SHA-1 signed certs with a validation date >2015 as insecure!.
–jeroen
PS: if you really need to do the balancing act, you technically can serve old certificates to SHA-2 incompatible clients while serving more secure certificates to modern clients. But it’s a risk, so you might as well tell these old clients they’re out.
Posted in https, Power User, Public Key Cryptography, Security, TLS | Leave a Comment »
Posted by jpluimers on 2015/05/28
A while ago, I was fighting a corporate web proxy playing Man-in-the-Middle on all https sessions.
Though playing MitM on your employees is a debatable thing to do (especially without informing the employees, and illegal in certain countries, I had to get a GIT connection to the outside world working.
This helped tracking it down: GIT_CURL_VERBOSE “unable to get local issuer certificate”.
What I finally did was this:
"%ProgramFiles%\Git\bin\curl-ca-bundle.crt""%ProgramFiles(x86)%\Git\bin\curl-ca-bundle.crt""%ProgramFiles%\Mercurial\cacert.pem""%ProgramFiles(x86)%\Mercurial\cacert.pem"–jeroen
PS: These were the failures I was getting:
Posted in *nix, cURL, Development, DVCS - Distributed Version Control, git, PKI, Power User, Security, Source Code Management | Leave a Comment »
Posted by jpluimers on 2015/03/16
Hmm, I missed this earlier. So: watch your TLS stack (OpenSSL and others), then
Patch soon and be careful.
After that read A Few Thoughts on Cryptographic Engineering: Attack of the week: FREAK (or ‘factoring the NSA for fun and profit’).
Thanks Kristian Köhntopp for sharing.
–jeroen
Posted in OpenSSL, Power User, Security | Leave a Comment »
Posted by jpluimers on 2015/03/10
Stuff I found out myself:
Some links I found useful: Read the rest of this entry »
Posted in Delphi, Development, OpenSSL, Power User, Security, Software Development | 3 Comments »
Posted by jpluimers on 2015/03/05
If you are running OpenSSL as a regular user, or cannot perform “RunAs Administrator”, and you get this error message:
unable to write 'random state'
then make sure you have set your environment variables correctly before running OpenSSL:
RANDFILE=%LOCALAPPDATA%\.rnd
A full batch file front-end for OpenSSL.exe is this one:
Posted in Batch-Files, Development, OpenSSL, Power User, Scripting, Security, Software Development, Windows | Leave a Comment »