Categoria
Hashing e crypto
Tutti gli strumenti e gli articoli di questa categoria, riuniti in un unico posto.
Strumenti
Generatore di hash (SHA-1/256/384/512)
Calcola digest SHA-1, SHA-256, SHA-384 e SHA-512 di qualsiasi testo, mostrati in hex e Base64, usando il Web Crypto nativo del browser. Gira interamente nel tuo browser.
Generatore di HMAC (SHA-256/384/512)
Calcola un HMAC con chiave su un messaggio usando la tua chiave segreta, mostrato in hex e Base64, tramite il Web Crypto nativo del browser. La stessa costruzione che il verificatore di JWT usa per HS256. La tua chiave non lascia mai il tuo browser.
Hash Preimage Finder
Watch a bounded, local brute-force search recover a weak hash input in seconds, or run out of keyspace on anything with real entropy. No wordlist, no table, just your browser. A demonstration of why fast, unsalted hashes fail.
Articoli
Hashing, cifratura e codifica: tre cose diverse
Tre operazioni costantemente confuse, separate nettamente da due domande: è reversibile e richiede una chiave?
LeggiHashing crittografico: SHA-256 e la famiglia SHA-2
Cosa garantisce una funzione di hash, le proprietà che la rendono crittografica e perché un digest non è cifratura.
LeggiScegliere un hash: MD5, SHA-1, SHA-2, SHA-3 e BLAKE
Quali funzioni di hash sono ancora sicure, quali sono compromesse, quali sono le loro dimensioni di output e come scegliere quella giusta.
LeggiCollisioni, resistenza alla preimmagine e il limite del compleanno
Le tre proprietà di sicurezza che un hash crittografico deve avere, perché le collisioni contano e la matematica del compleanno che fissa la forza reale.
LeggiMemorizzare le password: bcrypt, scrypt e Argon2
Perché un hash veloce come SHA-256 è lo strumento sbagliato per le password, e cosa fanno davvero il salting e i fattori di lavoro.
LeggiHMAC: hash con chiave per l'autenticazione dei messaggi
Perché un hash semplice prova l'integrità ma non l'autenticità, come una chiave segreta lo risolve e perché la struttura di HMAC conta.
LeggiPerché HMAC, e non hash(chiave + messaggio)
L'attacco di estensione di lunghezza che rompe l'hashing con chiave ingenuo, e la costruzione annidata che HMAC usa per sconfiggerlo.
LeggiAutenticare le richieste API con HMAC
Come un segreto condiviso e un hash permettono a un server di fidarsi di una richiesta che non ha visto fare, e come si inserisce la protezione dal replay.
LeggiVerificare un HMAC in modo sicuro: tempo costante e replay
Perché confrontare le firme con == fa trapelare un canale laterale temporale, e perché una firma valida da sola non ferma una richiesta ripetuta.
LeggiWhy Cryptographic Hashes Are One-Way
A cryptographic hash maps any input to a fixed-size digest and is designed so that recovering the input from the digest is infeasible. That property, preimage resistance, is why you cannot decrypt a hash. The only ways to reverse one are to look it up or to guess-and-check, both of which are search, not inversion.
LeggiBrute Force vs Lookup Tables: Two Ways to Reverse a Hash
Since a hash cannot be inverted, reversing one means searching, and there are two families. Precompute a giant table of input-to-hash pairs and look the hash up (what CrackStation does), or generate candidates on the fly and hash each until one matches (brute force). They trade storage for compute in opposite directions.
LeggiWhy Salting Defeats Precomputed Tables
A salt is a unique random value stored with each password hash and mixed in before hashing. It makes identical passwords hash differently, which destroys the economics of precomputed tables: an attacker would need a separate table for every salt. Salting is the specific defense that neutralizes lookup services and rainbow tables.
LeggiSlow KDFs: bcrypt, scrypt, and Argon2
Salting defeats precomputation but not a targeted guess-and-check attack; a fast hash still lets an attacker try billions of candidates per second. Slow key derivation functions fix that by making each guess deliberately expensive and tunable, cutting an attacker's rate by many orders of magnitude. These are what you should store passwords with.
LeggiKeyspace, Entropy, and Crack Time
Whether brute force can reverse a hash comes down to keyspace size versus the attacker's hashing rate. Keyspace grows exponentially with length and alphabet, so a few extra characters move a secret from cracked in seconds to infeasible for millennia. This is the arithmetic behind why length and randomness matter most.
LeggiChoosing a Password Hash
Storing passwords safely is a solved problem: use a purpose-built, salted, slow password hash, not a raw digest. This is a short decision guide, from the algorithm to pick to the parameters to set and the mistakes to avoid, aligned with OWASP and NIST guidance.
Leggi