Wrong SHA1 is calculated

2017-05-15 Thread Martin Puppe
Hello, I am debugging a problem with SHA1 checksums. I have found the following handy one-liner on Stack Overflow [^1], which serves well as a minimal example: ``` perl -MDigest::SHA1=sha1_hex -le "print sha1_hex <>" secure.txt ``` The problem is, that the result is simply not correct. Doing

Re: Wrong SHA1 is calculated

2017-05-15 Thread sisyphus1
From: Martin Puppe Sent: Monday, May 15, 2017 8:39 PM To: win32-vanilla@perl.org Subject: Wrong SHA1 is calculated Hello, I am debugging a problem with SHA1 checksums. I have found the following handy one-liner on Stack Overflow [^1], which serves well as a minimal example: perl

Re: Wrong SHA1 is calculated

2017-05-15 Thread sisyphus1
-Original Message- From: Christian Millour Sent: Tuesday, May 16, 2017 9:14 AM To: win32-vanilla@perl.org Subject: Re: Wrong SHA1 is calculated Le 15/05/2017 à 16:30, sisyph...@optusnet.com.au a écrit : Unfortunately, I don't know how to get that binmode() into the one-liner's angle

Re: Wrong SHA1 is calculated

2017-05-15 Thread Christian Millour
Le 15/05/2017 à 16:30, sisyph...@optusnet.com.au a écrit : Unfortunately, I don't know how to get that binmode() into the one-liner's angle brackets :-( you might consider playing with the PERLIO environment variable : $ perl -E "print qq{hello\nworld\n}" > secure.txt $ od -c secure.txt