HomeGlossaryCryptographic Hashing
Glossary

Cryptographic Hashing

Hashing turns any file, message or password into a short fixed-length value. Change one character of the input and the hash changes, so tampering shows.

Definition

What does cryptographic hashing mean?

Cryptographic hashing produces a fixed-length digest from an input so that a change to the input is detectable. An administrator can compare the hash of a downloaded file against a value published through a trusted channel.

Full guide: NIST password guidelines for a small business Service: IT Consulting

Hashing is a one-way calculation. NIST describes a hash algorithm as one that maps a message of arbitrary length to a fixed-length message digest: a one-page memo and a 40-gigabyte backup each produce a value of the same size. One NIST publication calls the result a fingerprint of the file or message, because it depends on the entire contents. There is no key and nothing to decrypt. You cannot run the calculation backward to get the file from its hash.

A hash function used for security has to resist three attacks, and NIST lists them for its approved algorithms. Collision resistance: it is computationally infeasible to find two different inputs with the same hash. Preimage resistance: given a hash, it is infeasible to find an input that produces it. Second preimage resistance: given one input, it is infeasible to find a second with the same hash. A function that fails any of these can still catch accidental corruption, but it can no longer prove that nobody swapped the file on purpose.

A business meets hashing in four places. Passwords: a well-built system does not store your password. NIST's digital identity guidelines say passwords shall be salted and hashed using a suitable password hashing scheme, so that each guess costs an attacker who has stolen the password file real effort. Downloads: vendors publish hash values so you can confirm an installer or firmware image is the one they released. Signatures: the certificates behind HTTPS, signed software and signed email work by signing a hash of the content. Security tools: antivirus and detection products recognize known malicious files by their hashes.

The algorithm matters, and it ages. NIST's approved hash algorithms are the SHA-2 family in FIPS 180-4, such as SHA-256, and the SHA-3 family in FIPS 202. SHA-1 is on the way out: NIST deprecated it in 2011, disallowed it for digital signatures at the end of 2013, and in December 2022 told federal agencies to move away from it for all applications as soon as possible, with validated cryptographic modules that still list SHA-1 as approved moving to the historical list after December 31, 2030. MD5 is not among NIST's approved algorithms. A small business does not choose these algorithms, but it does own old appliances and applications that still depend on retired ones.

Reviewed by Joel Baum, Founder. Last reviewed . Our editorial standards.

Hashing vs encryption: the difference

Encryption as defined in NIST's glossary: a cryptographic transformation of plaintext into ciphertext that conceals its meaning, reversible by decryption.
QuestionHashingEncryption
What is it for?Proving data has not changed, and checking a secret without storing itKeeping data confidential
Can it be reversed?No. There is no way to compute the input from the hashYes, by anyone holding the key
Does it use a key?No key. Password hashing adds a salt, which is not secretYes. Protecting the key is the whole problem
What does the output look like?A fixed-length value whatever the input sizeCiphertext about as large as the data
Where you meet itStored passwords, download verification, digital signatures, malware detectionDisk encryption on laptops, encrypted email, HTTPS connections, encrypted backups
What goes wrongRetired algorithms, unsalted or fast hashes for passwords, guessable inputsLost keys, keys stored beside the data, encryption switched off

Why it matters for a small business

Hashing is why a breach of a well-run website does not hand attackers your password, and why a breach of a badly run one does. It is also the check that tells you a firmware file or installer is the genuine article before it goes on every machine. The owner's part is to ask the right questions: does this application store passwords as salted hashes, do we verify what we install, and which old systems still rely on SHA-1 or MD5? One caution: hashing is not anonymization. A hashed Social Security number can be recovered by hashing every possible number and comparing, so hashed personal data still needs protecting.

Where this comes up in NetSys consulting work

Questions about hashing usually arrive inside a larger one: is this old application safe to keep, can this appliance still be trusted, what did the insurer's questionnaire mean? NetSys consulting answers with a written plan covering the current environment, workable options with costs, the dependencies and the order of work, and discovery includes a vulnerability scan so the roadmap starts from measured exposure. See IT Consulting Services for Small and Mid-Size Businesses.

If you want a quick read on where your business stands first, the free cybersecurity assessment asks seven questions and returns an instant score with next steps.

Worked Example

Checking a downloaded installer against its published hash

An administrator has downloaded a firmware image for the office firewall. Before it is installed, five minutes of checking confirms it is the file the vendor released.

  1. Get the published value from a trusted channel

    Copy the SHA-256 value from the vendor's own support site over HTTPS. A hash posted beside the file on a mirror, or sent in the same email as the download link, proves nothing: whoever altered the file could alter the hash.

  2. Compute the hash of the file you have

    On Windows, run Get-FileHash with the file path in PowerShell, which uses SHA-256 by default. On macOS or Linux, run shasum -a 256 followed by the file name. The command prints a string of 64 characters.

  3. Compare the whole value

    Paste both values side by side or let a script compare them. Checking the first and last few characters by eye is how mismatches get missed.

  4. Stop on a mismatch

    A different value means a corrupted download, the wrong file or tampering. Do not install it. Download again from the vendor, and if it still differs, contact the vendor's support.

  5. Record it

    Note the file name, version, hash and date in the change record. Next quarter, someone can confirm what was installed without guessing.

The check proves the file matches what the vendor published. It does not prove the vendor's file is free of flaws, which is what patching and vulnerability management are for.

Sources

Checked on December 2, 2026.

Common Questions

Cryptographic Hashing: FAQs

What is the difference between hashing and encryption?

Encryption is reversible and hashing is not. Encryption scrambles data so that only someone with the key can read it, and the key turns it back. Hashing produces a fixed-length value that cannot be turned back into the data, so it is used to prove something has not changed or to check a password without storing it. Encryption protects confidentiality; hashing protects integrity.

What is a password hash?

It is the value a system stores in place of your password. When you sign in, the system hashes what you typed and compares the result with the stored value. NIST's guidelines say passwords shall be salted and hashed with a suitable password hashing scheme, which takes a password, a salt and a cost factor, so that each guess against a stolen password file is expensive.

What is salting?

A salt is a non-secret value, different for each account, that is combined with the password before hashing. Two people with the same password then have different stored hashes, and an attacker cannot use one precomputed table of common passwords against a whole stolen file. Salting does not make a weak password strong; it removes the shortcut.

Is SHA-1 still safe to use?

Not for new work. NIST deprecated SHA-1 in 2011 and disallowed it for digital signatures at the end of 2013. Its December 2022 policy recommends that federal agencies move away from SHA-1 for all applications as soon as possible and use SHA-2 or SHA-3, and sets December 31, 2030 as the date after which validated cryptographic modules listing SHA-1 as approved become historical. Old devices that only support SHA-1 are candidates for replacement.

Can a hash be reversed?

Not by calculation. But if the input is guessable, an attacker can hash guesses until one matches, which is how weak passwords are recovered from stolen hash files. That is why password systems add a salt and a deliberately slow hashing scheme, and why hashing a short value such as a phone number or Social Security number does not hide it.

Free cybersecurity assessment

Seven questions on how your business would hold up.

The assessment covers downtime, phishing and ransomware and gives an instant score with next steps. For a decision about a specific system, such as an old application or appliance, NetSys IT consulting produces a written plan with options and costs.