Skip to main content

Command-line hash utility

Project description

Gethash

PyPI PyPI - Python Version PyPI - Downloads PyPI - License code style: black

Gethash is a command-line hash utility.

Installation

$ pip install -U gethash

or (if you need legacy hash algorithms)

$ pip install -U "gethash[all]"

Note: Gethash requires Python 3.7 and later.

Usage

After installation, 9 commands are available:

  • crc32
  • md5
  • sha1
  • sha256
  • sha512
  • sha3-256
  • sha3-512
  • blake2b
  • blake2s

If you use [all], 3 additional commands are available:

  • md2
  • md4
  • ripemd160

Generate hash values

$ ls -l
total 296
-rw-r--r-- 1 User 197610  68074 Jun 27 10:43 001.zip
-rw-r--r-- 1 User 197610 126717 Jun 27 10:43 002.zip
-rw-r--r-- 1 User 197610 103064 Jun 27 10:44 003.zip

$ sha1 -s *.zip
7701133eb84b567362fbf1b9e3883d7620ee8ada *001.zip
0d6c6cb6908064139f419c1b528f99142a1f2a49 *002.zip
10e2c0d8aa85add2ba495393f7f7f0b0baaf34a6 *003.zip

$ ls -l
total 299
-rw-r--r-- 1 User 197610  68074 Jun 27 10:43 001.zip
-rw-r--r-- 1 User 197610     51 Jun 27 10:44 001.zip.sha1
-rw-r--r-- 1 User 197610 126717 Jun 27 10:43 002.zip
-rw-r--r-- 1 User 197610     51 Jun 27 10:44 002.zip.sha1
-rw-r--r-- 1 User 197610 103064 Jun 27 10:44 003.zip
-rw-r--r-- 1 User 197610     51 Jun 27 10:44 003.zip.sha1

Check hash values

$ cat *.sha1
7701133eb84b567362fbf1b9e3883d7620ee8ada *001.zip
0d6c6cb6908064139f419c1b528f99142a1f2a49 *002.zip
10e2c0d8aa85add2ba495393f7f7f0b0baaf34a6 *003.zip

$ sha1 -c *.sha1
[SUCCESS] 001.zip
[SUCCESS] 002.zip
[SUCCESS] 003.zip

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

gethash-4.7.tar.gz (15.7 kB view details)

Uploaded Source

Built Distribution

gethash-4.7-py3-none-any.whl (20.9 kB view details)

Uploaded Python 3

File details

Details for the file gethash-4.7.tar.gz.

File metadata

  • Download URL: gethash-4.7.tar.gz
  • Upload date:
  • Size: 15.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.6.0 importlib_metadata/4.8.2 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7

File hashes

Hashes for gethash-4.7.tar.gz
Algorithm Hash digest
SHA256 0db3b2b283113d1cc692a4d2f5fa638a1bb7e0e480a679f6d0afe6cd924d717c
MD5 76a3dd262c69ece6e31113259f04a810
BLAKE2b-256 c2abc8617e91d6c2f0bd016ef465786bd34550a360a9ff2291a300da861ae715

See more details on using hashes here.

File details

Details for the file gethash-4.7-py3-none-any.whl.

File metadata

  • Download URL: gethash-4.7-py3-none-any.whl
  • Upload date:
  • Size: 20.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.6.0 importlib_metadata/4.8.2 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7

File hashes

Hashes for gethash-4.7-py3-none-any.whl
Algorithm Hash digest
SHA256 8ffdb8ec11c261583f13f48e4530ae7756e520bd429e7ad57e81b0272a79f268
MD5 2609433f1cc737ea71cad3e666d49021
BLAKE2b-256 328eb9288873535d2d49d9f6bec593d44bbe2adfe89113375ef443a1cfdb1a0f

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page