Solving Puzzle Caches: Ciphers
To read the previous post on Solving Puzzle Caches, go to http://bcaching.wordpress.com/2008/08/06/puzzles-part-2/.
There are many different types of ciphers from the simple to complex. Geocaching.com even uses a simple cipher for encrypting cache hints so that it is relatively easy to decode in the field. It is known as ROT-13 or the Caesar cipher with a shift of 13.
If you have a cipher on your hands, the first thing to do is determine what cipher you are dealing with. Hopefully the CO was kind enough to tell you or at least give you a hint. Most ciphers you will encounter on cache pages will be for letters only, so you will be deciphering into words. For example:
THE COORDINATES ARE NORTH FORTY DEGREES ZERO POINT FIVE THREE TWO WEST SEVENTY FIVE DEGREES TWO POINT FIVE ZERO TWO
can be encoded into a variety of somewhat simple forms using monoalphabetic substitution ciphers:
Caesar with a shift of 3: (A=D, B=E, C=F, D=G, and so on)
WKH FRRUGLQDWHV DUH QRUWK IRUWB GHJUHHV CHUR SRLQW ILYH WKUHH WZR ZHVW VHYHQWB ILYH GHJUHHV WZR SRLQW ILYH CHUR WZR
Caesar with a shift of 6: (A=G, B=H, C=I, D=J, and so on)
ZNK IUUXJOTGZKY GXK TUXZN LUXZE JKMXKKY FKXU VUOTZ LOBK ZNXKK ZCU CKYZ YKBKTZE LOBK JKMXKKY ZCU VUOTZ LOBK FKXU ZCU
Atbash cipher, where the letters are reversed: (A=Z, B=Y, C=X, D=W, …)
GSV XLLIWRMZGVH ZIV MLIGS ULIGB WVTIVVH AVIL KLRMG UREV GSIVV GDL DVHG HVEVMGB UREV WVTIVVH GDL KLRMG UREV AVIL GDL
Keyword ciphers are a little more complicated. They use a secret word or phrase that omits duplicates to come up with an alternately ordered alphabet. For example, if the secret phrase was LETS GO GEOCACHING, the translation key would be as follows:
“Geocaching” in the phrase changed to “cahin” to remove duplicate letters, then after the phrase all remaining letters are listed in order. The resulting cipher is:
RAG TJJPSHFLRGQ LPG FJPRA OJPRY SGCPGGQ ZGPJ KJHFR OHVG RAPGG RWJ WGQR QGVGFRY OHVG SGCPGGQ RWJ KJHFR OHVG ZGPJ RWJ
The PigPen or Masonic cipher is easy to spot. It uses a translation from letters into symbols:
which results in this:
What do you know?
If you know you’re dealing with a substitution cipher, but have no clue which one, you can always use the brute force method, and try a bunch of online tools to convert them. It can be more interesting to figure it out. If you expect to find numbers, write them out and look for repeating letters:
- THREE is a five letter word with two E’s. In the previous keyword cipher RAPGG is a possible candidate for “THREE”.
- SEVEN and SEVENTY repeats E in the 2nd and 4th positions. QGVGFRY repeats G in the 2nd 4th positions.
- COORDINATES is a relatively long 11 letter word that shows up surprisingly often in geocache ciphers and it has O repeated in the 2nd and 3rd positions so it can be easy to spot.
Once you determine a few of the letters this way it doesn’t take much more to decode the entire message.
The art and science of writing hidden messages in such a way that no one apart from the sender and intended recipient even realizes there is a hidden message.
Is there an excessive amount of text information on the cache page? Does some of it seem extraneous or not even make sense? It may be hiding the real message. Look for a hidden message in the first letter or last letter of each word, every other word, or every word at the beginning of a sentence
Geocache On! No one really trusts hints from iffy finders. Trust yourself. Maybe eat treats every rainy Sunday.
What?? The first letters of each word spells: Go North fifty meters.
In other cases, you may need to count the number of letters in each word or sentence, or each word in a sentence to get the numbers you need.
Messages can also be hidden inside images so that they’re not visible without some manipulation. Try inverting images, or “Local Equalization” or “Find Edges” filters if available. The trouble with these is that a photo editor is needed like Adobe Photoshop or Corel Photopaint. There are some free tools that don’t offer as many functions but still may be helpful:
- Paint.Net (for Windows) at http://www.getpaint.net/ along with the BoltBait plugin pack that includes a steganography tool!
- SplashUp (online tool) at http://www.splashup.com/splashup/
That’s easy, what else have you got?
Polyalphabetic substitution ciphers are those that have changing substitutions throughout the cipher. A might translate to C one time, and T the next.
The Vigenère cipher is a popular one that uses a repeating keyword or phrase along with “tabula recta”:
Using this table is relatively straightforward once you’ve done it once or twice. To Encode, setup your message and your key on two separate lines (as shown below). The key repeats when it gets to the end – until there is a letter from the key that matches up with ever letter from the message. Then you take each two matching letters from the message and key, starting with “T” and “L” in this case, and find where they intersect in the table. Locating T across the top, and L along the left side, they intersect in the middle with “E”.
THE COORDINATES ARE NORTH FORTY DEGREES ZERO POINT FIVE THREE TWO WEST SEVENTY FIVE DEGREES TWO POINT FIVE ZERO TWO LET SGOGEOCACHI NGL ETSGO GEOCA CHINGLE TSGO GEOCA CHIN GLETS GOG EOCA CHINGLE TSGO GEOCACH ING LETSG OGEO CACH ING ELX UUCXHWPAVLA NXP RHJZV LSFVY FLOEKPW SWXC VSWPT HPDR ZSVXW ZKU ASUT ULDRTEC YABS JIUTEGZ BJU ASBFZ TOZS BETV BJU THE COORDINATES ARE NORTH FORTY DEGREES ZERO POINT FIVE THREE TWO WEST SEVENTY FIVE DEGREES TWO POINT FIVE ZERO TWO
Decoding the cipher is a little different. Here you line up the key phrase over the cipher (you would have the 2nd and 3rd lines in the example above), starting with “L” and “E”. Locating the “L” along the left edge, then follow that line across into the table to find “E”. The letter at the top of the column the “E” is in is your next decoded letter, in this case “T”.
The AutoKey cipher (aka Autoclave) is similar except it uses a single letter or short phrase to start things off followed by the message itself:
THE COORDINATES ARE NORTH FORTY DEGREES ZERO POINT FIVE THREE TWO WEST SEVENTY FIVE DEGREES TWO POINT FIVE ZERO TWO MTH ECOORDINATE SAR ENORT HFORT YDEGREE SZER OPOIN TFIV ETHRE ETW OWES TSEVENT YFIV EDEGREE STW OPOIN TFIV EZER OTW FAL GQCFULVNTXW SRV RBFKA MTFKR BHKXVIW RDVF DDWVG YNDZ XAYVI XPK KAWL LWZZRGR DNDZ HHKXVIW LPK DDWVG YNDZ DDVF HPK
Polygraphic Ciphers like Playfair, and Trifid are even more complicated. They encode two or more letters at the same time using a keyword or phrase. The encoded messages are much more difficult to break without knowing the key. They are usually written as two letter tuples. Using the same message and keyword as before, we get this using Playfair:
sa cb av hk ja do st th ms kn ps fr hk sx bt su tw tg wg kh ka oj sd oz ts fy tw ts vc ec gs gt wl dl sr oz tb tl ms tg ex ak co dl jh wl wg kh ex av
and this using Trifid:
There is a lot of information online about these ciphers and more. Here are some links to tools, including online converters, as well as lots of details about how the ciphers work. If all else fails, try wikipedia or google.
There are many ways to hide instuctions or coordinates in geocache puzzles and hopefully this series helps introduce some of those techniques. Perhaps it will even inspire a few new puzzles!