Digest-Sha

Digest::SHA(3p) Perl Programmers Reference Guide Digest::SHA(3p)

Digest-Sha

Digest::SHA(3p) Perl Programmers Reference Guide Digest::SHA(3p) # Digest::SHA(3p) Perl Programmers Reference Guide Digest::SHA(3p) NNAAMMEE # Digest::SHA - Perl extension for SHA-1/224/256/384/512 SSYYNNOOPPSSIISS # In programs: # Functional interface use Digest::SHA qw(sha1 sha1_hex sha1_base64 ...); $digest = sha1($data); $digest = sha1_hex($data); $digest = sha1_base64($data); $digest = sha256($data); $digest = sha384_hex($data); $digest = sha512_base64($data); # Object-oriented use Digest::SHA; $sha = Digest::SHA->new($alg); $sha->add($data); # feed data into stream $sha->addfile(*F); $sha->addfile($filename); $sha->add_bits($bits); $sha->add_bits($data, $nbits); $sha_copy = $sha->clone; # make copy of digest object $state = $sha->getstate; # save current state to string $sha->putstate($state); # restore previous $state $digest = $sha->digest; # compute digest $digest = $sha->hexdigest; $digest = $sha->b64digest; From the command line: $ shasum files $ shasum --help SSYYNNOOPPSSIISS ((HHMMAACC--SSHHAA)) # # Functional interface only use Digest::SHA qw(hmac_sha1 hmac_sha1_hex . ...