Cypherは、Hexcellsの作者Matthew Brown氏が2018年2月にリリースした暗号解読ゲームです。
このゲームの舞台は、3Dで表現された暗号の博物館です。博物館の内部には「暗号の歴史」「著名な人物や書物」「マニアックな雑学」などが題材となった様々な暗号が記されていますので、自身の知識やネット検索などを駆使してすべての暗号を解き明かしましょう。
SCIEn CEISK NOWlE DgeiS PowEr ↓ 00001 00000 00010 01110 01101 ↓ B A C O N
A. BACON
TUTTMO WSIHIN OSMRNE PIEEUZ LXSESZ ↓ TWOPL USSIX TIMES THREE MINUS ONEZZ ↓ TWO PLUS SIX TIMES THREE MINUS ONE ↓ 2 + 6 * 3 - 1 ↓ 19
A. NINETEEN
ヒント
GTP = THE、GTHG = THAT
『吸血鬼ドラキュラ』(Dracula)
THSWQD THZ RBXP GWXP HG XL ZWRNBRHK UTPQ WQ KBQZBQ HAVING HAD SOME TIME AT MY DISPOSAL WHEN IN LONDON W THZ SWRWGPZ GTP IOWGWRT XMRPMX HQZ XHZP RPHOFT I HAD VISITED THE BRITISH MUSEUM AND MADE SEARCH HXBQD GTP IBBVR HQZ XHNR WQ GTP KWIOHOL OPDHOZWQD AMONG THE BOOKS AND MAPS IN THE LIBRARY REGARDING GOHQRLKSHQWH WG THZ RGOMFV XP GTHG RBXP ABOPVQBUKPZDP TRANSYLVANIA IT HAD STRUCK ME THAT SOME FOREKNOWLEDGE BA GTP FBMQGOL FBMKZ THOZKL AHWK GB THSP RBXP OF THE COUNTRY COULD HARDLY FAIL TO HAVE SOME WXNBOGHQFP WQ ZPHKWQD UWGT H QBIKPXHQ BA GTHG FBMQGOL IMPORTANCE IN DEALING WITH A NOBLEMAN OF THAT COUNTRY
A. TRANSYLVANIA
『フランケンシュタイン』(Frankenstein)
LGGK VHZXJ RP VJJCEVO CK ZMX MGEXO C SCLDGEXJXS SOON AFTER MY ARRIVAL IN THE HOVEL I DISCOVERED LGRX IVIXJL CK ZMX IGDQXZ GH ZMX SJXLL UMCDM C MVS SOME PAPERS IN THE POCKET OF THE DRESS WHICH I HAD ZVQXK HJGR PGBJ OVWGJVZGJP. VZ HCJLZ C MVS TAKEN FROM YOUR LABORATORY. AT FIRST I HAD KXNOXDZXS ZMXR, WBZ KGU ZMVZ C UVL VWOX ZG SXDCIMXJ NEGLECTED THEM, BUT NOW THAT I WAS ABLE TO DECIPHER ZMX DMVJVDZXJL CK UMCDM ZMXP UXJX UJCZZXK, C THE CHARACTERS IN WHICH THEY WERE WRITTEN, I WXNVK ZG LZBSP ZMXR UCZM SCOCNXKDX. BEGAN TO STUDY THEM WITH DILIGENCE.
A. LABORATORY
『オレンジの種五つ - シャーロック・ホームズの冒険』(The Five Orange Pips - the Adventures of Sherlock Holmes)
A. LONESTAR
『宝島』(Treasure Island)
AJLP NYRJZJF DEAR LIVESEY LZ Y AS GSK QGSM MEJKEJP FSV LPJ LK KEJ ELNN SP ZKYNN YG NSGASG AS I DO NOT KNOW WHETHER YOU ARE AT THE HALL OR STILL IN LONDON Y ZJGA KEYZ YG ASVWNJ KS WSKE CNLUJZ I SEND THIS IN DOUBLE TO BOTH PLACES KEJ ZEYC YZ WSVOEK LGA HYKKJA THE SHIP IS BOUGHT AND FITTED ZEJ NYJZ LK LGUESP PJLAF HSP ZJL SHE LIES AT ANCHOR READY FOR SEA FSV GJRJP YTLOYGJA L ZMJJKJP ZUESSGJP YOU NEVER IMAGINED A SWEETER SCHOONER L UEYNA TYOEK ZLYN EJP A CHILD MIGHT SAIL HER KMS EVGAPJA KSGZ TWO HUNDRED TONS GLTJ EYZCLGYSNL NAME HISPANIOLA
A. HISPANIOLA
"Vigenere Square" の使い方
行[A-Z] = キー、列[a-z] = 平文
Ciphertext:ZTVGLKDBGLRUHABTUOZ Key :FLASHFLASHFLASHFLAS ↓ Plaintext :thu...
A. THUNDERANDLIGHTNING
まずはキーを求め、それから平文を求める。
Ciphertext:JCW Plaintext :the ↓ Key :PUR
"Vigenere Square" を用いて平文を求める。
Ciphertext:JCWSVLIVLVGSJJFJCWCVL Key :PURPURPURPURPURPURPUR ↓ Plaintext :thecatsatflatonthemat (the cat sat flat on the mat)
A. MAT
『踊る人形 - シャーロック・ホームズの帰還』(The Adventure of the Dancing Men - the Return of Sherlock Holmes)
L AFLUI WOYW P ADU FHSN BVS WV NDZQ DU FRBP LU YQ PLWLPHZRLUE DUB SYMIPRDIJH TYQUCU ZYLK FRSKHZ I THINK THAT I CAN HELP YOU TO PASS AN HOUR IN AN INTERESTING AND PROFITABLE MANNER SAID HOLMES BUHULUE KPQ FOYLY SS AM WOC WHZOL DRAWING HIS CHAIR UP TO THE TABLE G DT DDPPOF DDTGOPYU DGWO YOS DRYKV VD VLAULR ZYGWPLJZ I AM FAIRLY FAMILIAR WITH ALL FORMS OF SECRET WRITINGS YQK YP TWVLJI AFH HSWOMU VD D APLMJLUE PVLRNPDWF XWMQ AFH ZSEQCFA AND AM MYSELF THE AUTHOR OF A TRIFLING MONOGRAPH UPON THE SUBJECT GQ DFLJF L HLDSWCL MQL FXUBULB DUB VPVWF QHWYUHRH JGSOCUZ IN WHICH I ANALYZE ONE HUNDRED AND SIXTY SEPARATE CIPHERS ZXA G FVLILQV AFDA RKPQ LZ CQAGULJB UCZ AM PL BUT I CONFESS THAT THIS IS ENTIRELY NEW TO ME
A. MONOGRAPH
The first disc rotates on every press, when it reaches a notch in the wheel it will cause the next disc to rotate and so the second will eventually cause the third disc to rotate.
―― 05 MECHANISED CRYPTOGRAPHY
■ 1文字目 [Z]
Input/Output: ABCDEFGHIJKLMNOPQRSTUVWXYZ Scrambler I: BCDEFGHIJKLMNOPQRSTUVWXYZA WYGADFPVZBECKMTHXSLRINQOJU Reflector: ABCDEFGHIJKLMNOPQRSTUVWXYZ YRUHQSLDPXNGOKMIEBFZCWVJAT
平文の1文字目:U
■ 2文字目 [Y]
1文字目を処理したため、Scrambler Iが1つ回転していることに注意。
Input/Output: ABCDEFGHIJKLMNOPQRSTUVWXYZ Scrambler I: CDEFGHIJKLMNOPQRSTUVWXYZAB YGADFPVZBECKMTHXSLRINQOJUW Reflector: ABCDEFGHIJKLMNOPQRSTUVWXYZ YRUHQSLDPXNGOKMIEBFZCWVJAT
平文の2文字目:L
■ 3文字目以降
残りの3文字も同様に処理。
A. ULTRA(元ネタはおそらくこれ)
ENIGMAは5-1と同じだが、Scrambler Iの開始位置が不明。
暗号の右側に書かれている「INTEL」により、平文がXV(ローマ数字の15)で始まることが確定。ここからScrambler Iの開始位置を特定する。
Ciphertext:QHSGUWIG Plaintext :XV?????? 「Q」を変換すると「X」となるScrambler Iの位置を特定する。
Scrambler Iの開始位置が判明した状態のENIGMA
Input/Output: ABCDEFGHIJKLMNOPQRSTUVWXYZ Scrambler I: FGHIJKLMNOPQRSTUVWXYZABCDE DFPVZBECKMTHXSLRINQOJUWYGA Reflector: ABCDEFGHIJKLMNOPQRSTUVWXYZ YRUHQSLDPXNGOKMIEBFZCWVJAT
A. XVPURPLE
ENIGMAが5-1、5-2よりも複雑化。Scramblerが計3枚となったものの、暗号文が短いために回転するのは1枚目のScrambler IIだけ。
すべての要件を反映したENIGMA
Input/Output: BACDNFHGIJKQMEOPLRZTYVWXUS Scrambler II: ABCDEFGHIJKLMNOPQRSTUVWXYZ AJPCZWRLFBDKOTYUQGENHXMIVS Scrambler I: EFGHIJKLMNOPQRSTUVWXYZABCD ADFPVZBECKMTHXSLRINQOJUWYG Scrambler III: BCDEFGHIJKLMNOPQRSTUVWXYZA AGBPCSDQEUFVNZHYIXJWLRKOMT Reflector: ABCDEFGHIJKLMNOPQRSTUVWXYZ YRUHQSLDPXNGOKMIEBFZCWVJAT
A. BLITZKRIEG
1. 列D、E、F、Hを下方向へ回転
A B C D E F G H --------------- 2 1 3 1 2 5 7 2 --------------- 0 1 1 0 0 0 1 0 0 1 1 0 1 0 0 1 0 1 1 1 0 1 0 0 0 1 1 1 0 1 1 1 0 1 1 0 1 0 0 1 0 1 1 1 0 0 1 1 0 1 1 0 0 1 0 1
2. バイナリ値をアスキー変換
0110 0010 → 98 → b 0110 1001 → 105 → i 0111 0100 → 116 → t 0111 0111 → 119 → w 0110 1001 → 105 → i 0111 0011 → 115 → s 0110 0101 → 101 → e
A. BITWISE
■ [IMG]
FE,01,00,01 FE,FE,FE,00 FE,FF,FE,00 00,FF,01,01
値がほぼ二値化(00、FF)されているので、白黒に色分けをしてみる。
□■■■ □□□■ □□□■ ■□■■ ↓ .J
■ Image Steganography
1111 1110,0000 0001,0000 0000,0000 0001 1111 1110,1111 1110,1111 1110,0000 0000 1111 1110,1111 1111,1111 1110,0000 0000 0000 0000,1111 1111,0000 0001,0000 0001
Image Steganographyの手法としてLSBを利用した文字の埋め込みがあるため、すべてのLSBを抜き出して並べ替えてみる
1111 1110,0000 0001,0000 0000,0000 0001 1111 1110,1111 1110,1111 1110,0000 0000 1111 1110,1111 1111,1111 1110,0000 0000 0000 0000,1111 1111,0000 0001,0000 0001 ↓ 0101 0000 0100 0111 ↓ 0101 0000 → 80 → P 0100 0111 → 71 → G
A. .JPG
■ Key [YS]
1. Arrange text and key into 4x4 blocks.(4✕4形式に並べ替え)
text [1001 0111 1011 0101] key[YS] [0101 1001 0101 0011] ↓ 1001 0101 0111 1001 1011 0101 0101 0011
2. Swap columns 1/2 and 3/4 of each block.(各ブロックごとに列を入れ替え:1 ↔ 2、3 ↔ 4)
1234 1234 ---- ---- 0110 1010 1011 0110 0111 1010 1010 0011
3. Substitute (XOR) text block using key block.(各行のXORを計算)
a|0110 1010 b|1011 0110 c|0111 1010 d|1010 0011 a b c d 0110 1011 0111 1010 1010 0110 1010 0011 ↓ 1100 1101 1101 1001 ↓ 1100 1101 1101 1001
4. Shift rows of text block +0,+1,+2,+3.(各行を右方向へ回転)
回転させるビット数:a = 0、b = 1、c = 2、d = 3 a|1100 b|1101 c|1101 d|1001 ↓ a|1100 b|1110 c|0111 d|0011
Phase #1の結果:1100 1110 0111 0011
■ Key [BX]
1. Arrange text and key into 4x4 blocks.
textはPhase #1の結果を用いる text [1100 1110 0111 0011] key[BX] [0100 0010 0101 1000] ↓ 1100 0100 1110 0010 0111 0101 0011 1000
0100 0110 → 70 → F 0100 1110 → 78 → N
A. FN
A. NUCLEUS
A. RAINBOW
J: 10 S: 11 N: 16 U: 17 E: 24 M: 25 M:1416 V:5832 ↓ JSNUEMMV
"JSNUEMMV" をキーとして、"Vigenere Square" を用いて平文を求める。
Ciphertext:QTZDQRBCKEWGJV Key :JSNUEMMVJSNUEM
A. GALILEOGALILEI
MANY years ago, I contracted an intimacy with a Mr. William Legrand. He was of an ancient Huguenot family, and had once been wealthy; but a series of misfortunes had reduced him to want. To avoid the mortification consequent upon his disasters, he left New Orleans, the city of his forefathers, and took up his residence at Sullivan's Island, near Charleston, South Carolina.
This Island is a very singular one. It consists of little else than the sea sand, and is about three miles long. Its breadth at no point exceeds a quarter of a mile.
―― Edgar Allan Poe "The Gold-Bug" (1843)
n番目の単語を抜き出し、頭文字を並べる。
03:ago 31:reduced 04:I 06:an 68:very 15:of 12:Legrand 33:to 90:point 22:once 56:residence 35:To ↓ ARIAVOLTPORT
A. OVALPORTRAIT
加算の例:E + G → 5 + 7 = 12 → つまり E + G = L
E E(5) + G(7) = L(12) G A G(7) + B(2) + D(4) + E(5) = R(18) E(5) + G(7) + C(3) + G(7) = V(22) E(5) + G(7) + C(3) + E(5) = T(20) E D(4) + G(7) + C(3) = N(14) ↓ ELGARVTEN
A. DORABELLA
A. COMPASS
1. shift(4)
50203795740025510578343272 ↓ 32725020379574002551057834
2. mod(19), add(3)
32 % 19 + 3 = 16 72 % 19 + 3 = 18 50 % 19 + 3 = 15 20 % 19 + 3 = 4 37 % 19 + 3 = 21 95 % 19 + 3 = 3 74 % 19 + 3 = 20 00 % 19 + 3 = 3 25 % 19 + 3 = 9 51 % 19 + 3 = 16 05 % 19 + 3 = 8 78 % 19 + 3 = 5 34 % 19 + 3 = 18
3. アルファベット化(1 → A, 26 → Z)
16 = P 18 = R 15 = O 4 = D 21 = U 3 = C 20 = T 3 = C 9 = I 16 = P 8 = H 5 = E 18 = R
A. PRODUCTCIPHER
A. THEENEMYKNOWSTHESYSTEM
下段
3、6は、重なったアルファベット 1. Cloth 2. Ram 3. YP 4. TO 5. Gold 6. LYP 7. Helmet 8. I 9. Cyprus 10. Sword
A. CRYPTOGLYPHICS
CO QY LS GY LZ ON ET IM EP AD FK QX AQ RY BN FW QA TH EG RE AT CI PH ER IL = ?? SQ = ?? CS = ?? KF = HT FK = TH AQ = RE QY = ET KC = ?? CO = ON GY = EP 並べると下記のようになる ?? ?? ?? HT TH RE ET ?? ON EP THREEやONEが含まれているため、数字の並びだと想定して補完 ??? EIGHT THREE TWO ONE ???の候補は次の3通り ONE TWO SIX
A. 68321
PASSWORD IS CT C = CYTOSINE T = THYMINE
A. CYTOSINETHYMINE
A. TETRAGRAMATICUS