Trithemius 密码编码器

The Trithemius cipher progressively shifts each letter by an incrementing value, starting at 0 for the first letter, 1 for the second, and so on through the alphabet. Invented by Johannes Trithemius in 1508, it is the earliest polyalphabetic cipher and the direct predecessor to the Vigenère cipher. Use this free online tool to encode and decode messages with the Trithemius progressive shift cipher.

结果
0 字符
Options:Preserve Case
Start Shift:

什么是特里特米乌斯密码?

特里特米乌斯密码(Trithemius Cipher)是已知最早的多表替换密码,由德国本笃会修道院院长约翰内斯·特里特米乌斯(Johannes Trithemius)发明,于1508年收录于其著作 Polygraphiae libri sex 中。该密码对每个字母使用逐步递增的偏移量——第一个字母偏移0,第二个偏移1,第三个偏移2,以此类推。

与对每个字母使用固定偏移量的凯撒密码不同,特里特米乌斯密码在每个位置使用不同的偏移量。这使得简单的频率分析更难奏效,但由于偏移模式(0, 1, 2, 3...)是固定且公开的,无需任何密钥——任何知道该方法的人都可以解密任何消息。

该密码的持久重要性并非在于其安全性,而在于它所引入的概念:在单条消息中使用多个替换字母表,以及tabula recta(方形字母表),这个26×26的参考网格成为后来所有多表密码的标准工具,包括维吉尼亚密码

什么是 Tabula Recta?

tabula recta(拉丁语,意为"直表"或"正表")是特里特米乌斯发明的一个26×26字母网格。每行都比上一行多移一位:

  • 第0行:A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
  • 第1行:B C D E F G H I J K L M N O P Q R S T U V W X Y Z A
  • 第2行:C D E F G H I J K L M N O P Q R S T U V W X Y Z A B
  • ……依此类推,直到第25行

使用 tabula recta 加密字母时,在顶行(列标题)找到明文字母,然后向下读到与当前偏移值对应的行,该交叉点处的字母即为密文。

tabula recta 成为多表密码学的基石。维吉尼亚密码使用同一张表,但根据重复关键词而非固定递进序列来选择行。波塔密码使用只有13个不同字母表的修改版本。

特里特米乌斯密码公式

加密: C = (P + i) mod 26

解密: P = (C - i + 26) mod 26

其中:

  • P 是明文字母的位置(A=0, B=1, ..., Z=25)
  • C 是密文字母的位置
  • i 是字母在消息中的索引(从0开始)

示例: 加密"HELLO"

位置 (i)字母偏移计算结果
0H (7)0(7 + 0) mod 26 = 7H
1E (4)1(4 + 1) mod 26 = 5F
2L (11)2(11 + 2) mod 26 = 13N
3L (11)3(11 + 3) mod 26 = 14O
4O (14)4(14 + 4) mod 26 = 18S

"HELLO"加密结果为"HFNOS"。每个字母使用 tabula recta 中对应的行。

如何使用本特里特米乌斯密码工具

  1. 在输入框中输入消息
  2. 选择加密或解密模式
  3. 即时查看结果——递进偏移会自动应用
  4. 探索 tabula recta 可视化,查看每个字母对应哪一行
  5. 一键复制输出

无需输入密钥,因为特里特米乌斯密码始终使用相同的偏移序列(0, 1, 2, 3...)。这既是其定义特征,也是其主要弱点。

约翰内斯·特里特米乌斯:密码学之父

约翰内斯·特里特米乌斯(1462—1516),原名 Johann Heidenberg,是德国本笃会修道院院长,对密码学做出了奠基性贡献。其主要著作包括:

  • Polygraphiae libri sex(1508年)——第一本关于密码学的印刷书籍,包含 tabula recta 和递进偏移密码
  • Steganographia(约1499年撰写,1606年出版)——一部伪装成天使魔法论著的隐写术专著,曾被列入天主教会的禁书目录

特里特米乌斯被广泛认为是现代密码学创始人之一。他的 tabula recta 影响了此后所有主要的多表密码,从乔瓦尼·巴蒂斯塔·贝拉索的关键词密码(1553年)到后来被误归于布莱兹·德·维吉尼亚的系统。

特里特米乌斯密码与相关密码对比

特性特里特米乌斯维吉尼亚凯撒波塔
类型多表替换多表替换单表替换多表替换
密钥无(递进)重复关键词单个数字重复关键词
使用 tabula recta是(发明者)修改版
偏移范围0-25(递进)0-25(关键词决定)固定 0-250-12(13个字母表)
安全性极低中等极低中等
自反性

特里特米乌斯密码处于多表密码演进的起点:它引入了 tabula recta 和多种替换字母表的概念,后来的密码通过添加秘密关键词对其进行了改进。

安全性分析

特里特米乌斯密码并不安全。由于使用固定且公开的偏移模式且无密钥:

  • 无密钥保密性——任何知道该密码系统的人都可以立即解密任何消息
  • 可预测的模式——偏移序列(0, 1, 2, 3...)永不改变
  • 模式分析——即使不了解该系统,规律性递进也很容易被统计检测
  • 无抗暴力破解能力——由于没有密钥,无需暴力破解

该密码今天仅用于教育和历史研究。对于实际消息安全,基于关键词的密码(如维吉尼亚阿尔伯蒂密码)至少提供依赖密钥的变换。

常见问题

tabula recta 是什么?谁发明的?

tabula recta 是一个26×26的字母网格,每行比上一行多移一位字母。由约翰内斯·特里特米乌斯发明,于1508年出版。tabula recta 成为维吉尼亚密码和许多其他多表系统的标准参考表,是密码学史上最重要的工具之一。

特里特米乌斯密码与维吉尼亚密码有何不同?

特里特米乌斯密码使用固定的递进偏移序列(0, 1, 2, 3...),没有密钥;而维吉尼亚密码使用重复的关键词来确定偏移量。两者都使用 tabula recta 进行加密,但维吉尼亚密码的关键词使其更难破解,因为偏移模式并非公开。

特里特米乌斯密码安全吗?

不安全。由于没有密钥且偏移模式始终为 0, 1, 2, 3...,任何知道该系统的人都可以立即解密任何消息。它在1508年因引入多表替换而具有开创性意义,但今天仅用于教育目的。

约翰内斯·特里特米乌斯是谁?

约翰内斯·特里特米乌斯(1462—1516)是德国本笃会修道院院长、历史学家和密码学家。他撰写了 Polygraphiae libri sex(第一本关于密码学的印刷书籍)和 Steganographia(隐蔽通信的先驱著作)。他发明的 tabula recta 为所有后续多表密码奠定了基础。

如何解密特里特米乌斯密码?

从每个密文字母中减去其位置索引:第一个字母减0,第二个减1,第三个减2,以此类推。例如,"HFNOS"解密为"HELLO",因为 H-0=H, F-1=E, N-2=L, O-3=L, S-4=O。我们的解码工具可自动完成此操作。

什么是 Steganographia?

Steganographia 由约翰内斯·特里特米乌斯于约1499年撰写,1606年遗作出版。该书伪装成天使魔法论著,实际上包含秘密通信方法,包括早期的隐写技术和密码系统。它曾被列入天主教会的禁书目录,直到现代学者揭示了其真正的密码学内容。

相关工具与资源

Frequently Asked Questions About Trithemius Cipher

What is the Trithemius cipher?

The Trithemius cipher is a polyalphabetic substitution cipher that uses a progressively increasing shift value for each letter. The first letter is shifted by 0, the second by 1, the third by 2, and so on. Published in 1508 in "Polygraphiae libri sex," it was the first known polyalphabetic cipher and laid the foundation for more advanced ciphers like the Vigenère.

How does the Trithemius cipher work?

Each letter in the plaintext is shifted forward in the alphabet by its position index. The first letter (position 0) stays the same, the second letter (position 1) shifts by 1, the third shifts by 2, and so on. For example, "HELLO" becomes "HFNOS" because H+0=H, E+1=F, L+2=N, L+3=O, O+4=S. The shift wraps around after Z back to A using modular arithmetic.

Who was Johannes Trithemius?

Johannes Trithemius (1462-1516) was a German Benedictine abbot, lexicographer, historian, and cryptographer. He authored "Polygraphiae libri sex" in 1508, the first printed book on cryptography, and "Steganographia," a treatise on steganography and cryptography disguised as a work on magic. His tabula recta became a cornerstone tool in polyalphabetic cipher design.

What is the relationship between Trithemius and Vigenere?

The Trithemius cipher is the direct ancestor of the Vigenère cipher. Trithemius introduced the tabula recta and the concept of using multiple cipher alphabets. Giovan Battista Bellaso and later Blaise de Vigenère extended this idea by using a secret keyword to select which row of the tabula recta to use for each letter, rather than the fixed progressive pattern that Trithemius used.

Is the Trithemius cipher secure?

No, the Trithemius cipher is not secure. Because it uses no secret key and always applies the same predictable shift pattern (0, 1, 2, 3...), anyone who knows the method can instantly decrypt any message. It is vulnerable to both brute force and pattern analysis. It was groundbreaking in the 16th century for introducing polyalphabetic substitution, but it is used today only for education and historical study.

What is the tabula recta?

The tabula recta ("straight table" or "right table") is a 26x26 grid of letters invented by Trithemius. Each row is the alphabet shifted by one more position than the row above it. Row 0 is ABCDEFG..., row 1 is BCDEFGH..., and so on. To encrypt a letter, you find its column in the grid and read the letter at the intersection with the row corresponding to the current shift value. It became the standard reference table for the Vigenère cipher and many other polyalphabetic ciphers.

How do you decrypt a Trithemius cipher?

To decrypt, reverse the shift for each letter position. Subtract 0 from the first letter, 1 from the second, 2 from the third, and so on. If the result goes below A, wrap around to the end of the alphabet using modular arithmetic. For example, the ciphertext "HFNOS" decrypts to "HELLO" because H-0=H, F-1=E, N-2=L, O-3=L, S-4=O. Our free online tool performs this decryption automatically.