# 其他类型加密

## 培根密码¶

### 原理¶

a AAAAA g AABBA n ABBAA t BAABA
b AAAAB h AABBB o ABBAB u-v BAABB
c AAABA i-j ABAAA p ABBBA w BABAA
d AAABB k ABAAB q ABBBB x BABAB
e AABAA l ABABA r BAAAA y BABBA
f AABAB m ABABB s BAAAB z BABBB

To encode a message each letter of the plaintext is replaced by a group of five of the letters 'A' or 'B'.

• 只有两种字符
• 每一段的长度为 5
• 加密内容会有特殊的字体之分，亦或者大小写之分。

## 栅栏密码¶

### 原理¶

明文：THERE IS A CIPHER


THEREISACIPHER


TH ER EI SA CI PH ER


TEESCPE
HRIAIHR


TEESCPEHRIAIHR


THEREIS ACIPHER


TAHCEIRPEHIESR


## 曲路密码¶

### 原理¶

明文：The quick brown fox jumps over the lazy dog


密文：gesfc inpho dtmwu qoury zejre hbxva lookT


## 01248 密码¶

• 只有 0，1，2，4，8

### 例子¶

8842101220480224404014224202480122

88421 8+8+4+2+1=23 W
122 1+2+2=5 E
48 4+8=12 L
2244 2+2+4+4=12 L
4 4 D
142242 1+4+2+2+4+2=15 O
248 2+4+8=14 N
122 1+2+2=5 E

## JSFuck¶

### 原理¶

JSFuck 可以只用 6 个字符 []()!+ 来编写 JavaScript 程序。比如我们想用 JSFuck 来实现 alert(1) 代码如下

[][(![]+[])[+[[+[]]]]+([][[]]+[])[+[[!+[]+!+[]+!+[]+!+[]+!+[]]]]+(![]+[])[+[[!+[]+!+[]]]]+(!![]+[])[+[[+[]]]]+(!![]+[])[+[[!+[]+!+[]+!+[]]]]+(!![]+[])[+[[+!+[]]]]][([][(![]+[])[+[[+[]]]]+([][[]]+[])[+[[!+[]+!+[]+!+[]+!+[]+!+[]]]]+(![]+[])[+[[!+[]+!+[]]]]+(!![]+[])[+[[+[]]]]+(!![]+[])[+[[!+[]+!+[]+!+[]]]]+(!![]+[])[+[[+!+[]]]]]+[])[+[[!+[]+!+[]+!+[]]]]+([][(![]+[])[+[[+[]]]]+([][[]]+[])[+[[!+[]+!+[]+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+(![]+[])[+[[!+[]+!+[]]]]+(!![]+[])[+[[+[]]]]+(!![]+[])[+[[!+[]+!+[]+!+[]]]]+(!![]+[])[+[[+!+[]]]]]+[])[+[[+!+[]]]+[[!+[]+!+[]+!+[]+!+[]+!+[]+!+[]]]])()


false       =>  ![]
true        =>  !![]
undefined   =>  [][[]]
NaN         =>  +[![]]
0           =>  +[]
1           =>  +!+[]
2           =>  !+[]+!+[]
10          =>  [+!+[]]+[+[]]
Array       =>  []
Number      =>  +[]
String      =>  []+[]
Boolean     =>  ![]
Function    =>  []["filter"]
eval        =>  []["filter"]["constructor"]( CODE )()
window      =>  []["filter"]["constructor"]("return this")()


## BrainFuck¶

### 原理¶

Brainfuck，是一种极小化的计算机语言，它是由 Urban Müller 在 1993 年创建的。我们举一个例子，如果我们想要一个在屏幕上打印Hello World！，那么对应的程序如下。对于其中的原理，感兴趣的可以自行网上搜索。

++++++++++[>+++++++>++++++++++>+++>+<<<<-]
>++.>+.+++++++..+++.>++.<<+++++++++++++++.
>.+++.------.--------.>+.>.


## 键盘密码¶

### 2017年xman选拔赛——一二三，木头人¶

23731263111628163518122316391715262121

23-x

73-m

12-a

63-n

11-q

xman{hintisenough}


• 实验吧 奇怪的短信