# What is Cryptographic Hashing?

> Cryptographic hashing is a one-way function that maps arbitrary input to a fixed-length digest, designed so the input cannot be practically recovered from the digest and two different inputs cannot practically produce the same digest.

- Canonical URL: https://yellowcube.eu/glossary/cryptographic-hashing/
- Publisher: Yellow Cube
- Language: en
- Contact: hello@yellowcube.eu

## Content

The three essential properties are preimage resistance (a digest reveals nothing about its input), second-preimage resistance (no different input with the same digest can be found for a given input), and collision resistance (no two inputs with the same digest can be found at all). Algorithms such as MD5 and SHA-1 have failed these properties and must not be used where they matter.

Hashing appears throughout security: integrity checks and tamper evidence, digital signatures that sign digests rather than whole messages, content addressing, and — with deliberate extra work — password storage. Passwords need salted, computationally expensive functions such as dedicated password-hashing algorithms; a fast general-purpose hash is the wrong tool for that specific job.

### Key points

- **Integrity use:** A matching digest confirms that content has not changed since the digest was computed — provided the digest itself was obtained through a trusted channel.
- **Password storage:** Store salted, slow-hash digests rather than fast hashes; the salt defeats precomputed lookups and the cost slows brute-force guessing at scale.
- **Algorithm selection:** Use current approved families (SHA-2, SHA-3) and treat MD5 and SHA-1 as broken for security purposes — they remain acceptable only for non-adversarial checksums.
- **Important limitation:** A hash proves only that two inputs matched under one function at one time. It provides no confidentiality — the digest of a guessable input is trivially recovered by trying candidates — and a hash computed over an untrusted channel can be swapped along with the content it vouches for.

### Related terms

[Cryptography](<https://yellowcube.eu/glossary/cryptography/>) · [Digital signature](<https://yellowcube.eu/glossary/digital-signature/>) · [Message authentication code (MAC)](<https://yellowcube.eu/glossary/message-authentication-code/>) · [Login credentials](<https://yellowcube.eu/glossary/login-credentials/>) · [Data integrity](<https://yellowcube.eu/glossary/data-integrity/>)

### Sources

[NIST FIPS 180-4: Secure Hash Standard](https://nvlpubs.nist.gov/nistpubs/FIPS/NIST.FIPS.180-4.pdf) · [NIST glossary: Hash Function](https://csrc.nist.gov/glossary/term/hash_function) · [OWASP, Password Storage Cheat Sheet](https://cheatsheetseries.owasp.org/cheatsheets/Password_Storage_Cheat_Sheet.html)

## Attribution and scope

This Markdown representation is generated from the same approved content records as the canonical HTML page. Cite the canonical URL above when referencing this material. Product and service descriptions are informational; confirm project-specific requirements with Yellow Cube.

