In classic cryptography, a cipher works on individual letters or bits. Substituting numbers (or pictures or symbols) for letters would be a cipher. Like a=1,b=2, c=3 etc. or a=z, b=y, c=x So anyone who has ever done an acrostic puzzle or used a decoder ring has solved a cipher.
In the Beale Legend, there are 3 ciphers of a type that could fall into several categories. It’s a polyalphabetic substitution cipher because more than one number can represent a letter of the alphabet. and a one pad cipher because the key is used just once. To come up with the cipher, Beale took the Declaration of independence (the key document) and numbered the words. To put his message into cipher, he took each letter of his message and substituted a number corresponding to the word that started with that letter.
Each word was numbered from 1 to 1322. It began:
When(1) in(2) the(3) course(4) of(5) human(6) events(7) it(8) becomes(9) necessary(10) for(11) one(12) people(13) to(14) dissolve(15) the(16) political(17) bands(18) which(19) have(20) connected(21) them(22) with(23) another(24) and(25) to(26) assume(27) among(28) the(29) powers(30) of(31) the(32) earth(33) the(34) separate(35) and(36) equal(37) station(38) to(39) which(40) the(41) laws(42)
To code your message, you match your letters to the first letter of any word, then substitute the number for the letter. Like if I wanted to code help, I could write it:
h e l p
Beale used the Declaration of Independence, but the key document could be anything—a book, a letter. Find the right key document, and anybody could decode them. Without it, they’re unbreakable—even with the most powerful computers.
Which is why the Beale Ciphers have remained unbroken for nearly 200 years.