Verhoeff algorithm using dihedral group D5 for superior error detection. Detects ALL single-digit errors and ALL adjacent transposition errors, unlike Luhn. Invented by Dutch mathematician Jacobus Verhoeff in 1969.
| Property | Value |
|---|---|
| Category | Checksums |
| Sub-category | Check Digit |
| Security status | 🎓 Educational Only |
| Complexity | Intermediate |
| Inventor | Jacobus Verhoeff |
| Year | 1969 |
| Origin | 🇳🇱 Netherlands |
| Source | algorithms/checksum/verhoeff.js |
Status: 🎓 Educational Only
No vulnerabilities are recorded for this implementation.
3 vectors ship with this algorithm and run in the test suite. Byte values are hexadecimal.
Vector 1 — Rosetta Code test vector 236
| Field | Value |
|---|---|
input |
323336 |
expected |
03 |
Vector 2 — Rosetta Code test vector 12345
| Field | Value |
|---|---|
input |
3132333435 |
expected |
01 |
Vector 3 — Rosetta Code test vector 123456789012
| Field | Value |
|---|---|
input |
313233343536373839303132 |
expected |
00 |