Tool to decrypt/encrypt with SHA1 (Secure Hash Algorithm) with 40 characters (in hexadecimal) often used in cryptography.
SHA-1 - dCode
Tag(s) : Hashing Function, Modern Cryptography
dCode is free and its tools are a valuable help in games, maths, geocaching, puzzles and problems to solve every day!
A suggestion ? a feedback ? a bug ? an idea ? Write to dCode!
SHA-1 (for Secure Hash Algorithm 1) is a cryptographic hashing algorithm developed by the NSA that transforms a variable-size data entry into a fixed 160-bit fingerprint (40 hexadecimal characters). This fingerprint is designed to be unique and deterministic: the same entry will always produce the same hash, this ensures the integrity of the initial data (a file or a message).
The SHA-1 algorithm takes a string of data and runs it through several processing steps (bit additions, chunking, logical operations, and rotations). The algorithm uses non linear functions, here are the 3 main ones:
$$ C(x,y,z) = (x \wedge y) \vee (\lnot x \wedge z) \\ P(x,y,z) = x \oplus y \oplus z \\ M(x,y,z) = (x \wedge y) \vee (x \wedge z) $$
With $ x,y,z $ portions of string to encode or fixed values among 0x67452301, 0xEFCDAB89, 0x98BADCFE, 0x10325476, 0xC3D2E1F0 (and others)
These operations are designed so that any change in the input results in a significant change in the fingerprint, making it difficult to predict the outcome.
Example: dCode is encrypted with the footprint 15fc6eed5ed024bfb86c4130f998dde437f528ee
As encryption is a hashing based on nonlinear functions, there is no decryption method. This means that to retrieve the password corresponding to a sha-1 hash, there is no choice but to try all possible passwords!
Technically, this operation would take several thousand years, even on the most powerful computers in the world. However, the list of passwords used in real life is more restricted, and it becomes possible to precalculate the most likely fingerprints.
dCode uses its word databases (10 million potential passwords) to speed up this processing. However, if the password is rare, or combined with salting, it will probably not be found.
The hash is composed of exactly 40 hexadecimal characters among 0123456789abcdef.
More rarely the hash is stored as a 20-byte binary string.
The database search can be complicated by inserting a salt to the word. The salt is usually a prefix or a suffix. Indeed, if it is already difficult but possible to precalculate the fingerprints of all the words, it becomes even more difficult to precalculate with all possible prefixes and suffixes.
Example: SHA1(dCode) = 15fc6eed5ed024bfb86c4130f998dde437f528ee but SHA1(dCodeSUFFIX) = 9b63fcb31388acee8879018244a3d107033890f1
Another (not recommended) variant is DOUBLE SHA1, that consists in applying SHA1 twice (the first time on the original string, then the second time on the computed hash).
A rainbow table is a database of words with all the pre-computed hashes and stored in order to accelerate and be able to parallelize the calculations of fingerprints.
List of magic SHA-1 hashes:
String | MD5(String) |
---|---|
aa3OFF9m | 0e36977786278517984959260394024281014729 |
aaK1STfY | 0e76658526655756207688271159624026011393 |
aaO8zKZF | 0e89257456677279068558073954252716165668 |
aaroZmOk | 0e66507019969427134894567494305185566735 |
Bonus magic SHA-1 like string that can also be evaluated at 0: 0e00000000000000000000081614617300000000 or 0e00000000000000000000721902017120000000
The SHA-1 algorithm was widely used before security flaws limited its use in contexts requiring high security.
In 2017, a team of researchers from Google and CWI Amsterdam publicly demonstrated a practical SHA-1 collision, named SHAttered here
These flaws allow an attacker to create two different messages with the same hash, bypassing the integrity guarantees offered by the hash function.
More robust algorithms such as SHA-256 or SHA-3 are now recommended.
SHA1 stands for Secure Hash Algorithm (version 1)
SHA1 was proposed by the National Security Agency in 1995.
dCode retains ownership of the "SHA-1" source code. Except explicit open source licence (indicated Creative Commons / free), the "SHA-1" algorithm, the applet or snippet (converter, solver, encryption / decryption, encoding / decoding, ciphering / deciphering, breaker, translator), or the "SHA-1" functions (calculate, convert, solve, decrypt / encrypt, decipher / cipher, decode / encode, translate) written in any informatic language (Python, Java, PHP, C#, Javascript, Matlab, etc.) and all data download, script, or API access for "SHA-1" are not public, same for offline use on PC, mobile, tablet, iPhone or Android app!
Reminder : dCode is free to use.
The copy-paste of the page "SHA-1" or any of its results, is allowed (even for commercial purposes) as long as you credit dCode!
Exporting results as a .csv or .txt file is free by clicking on the export icon
Cite as source (bibliography):
SHA-1 on dCode.fr [online website], retrieved on 2025-02-26,