密码与编码 Mathematics

14 个科学问题 · 数学 Mathematics

本页目录

RSA公钥密码依赖什么数学困难性?

What mathematical hardness does RSA public-key cryptography rely on?

RSA基于大整数分解困难:公开乘积n=pq,私钥依赖其素因子。已知没有高效算法对大n分解,因此可安全地用公钥加密、私钥解密。
RSA relies on the hardness of factoring large integers: publish n=pq, keep its prime factors secret. No efficient factoring algorithm is known for large n, so public encryption and private decryption stay secure.
难度 专业 · 适合 高中(15-18) CC BY 4.0 · 已核验 · Verified 2026-08-23 · 2 条独立证据
来源 · Source

吴军,《数学之美》第3版,人民邮电出版社,2020

Wu Jun, Beauty of Mathematics, 3rd ed., Posts & Telecom Press, 2020

#RSA #大数分解 #公钥密码

Diffie-Hellman怎样让两人在公开信道上协商出共享秘密?

How does Diffie-Hellman let two parties agree on a secret over a public channel?

双方各自选私钥,公开交换g^a、g^b(模p),再各自用对方的公值算出g^(ab),而窃听者只能看到g^a、g^b,想恢复g^(ab)需解离散对数。
Each picks a private key and publicly exchanges g^a, g^b (mod p), then both compute g^(ab); an eavesdropper sees only g^a, g^b and would need to solve a discrete log to recover the shared secret.
难度 专业 · 适合 高中(15-18) CC BY 4.0 · 已核验 · Verified 2026-08-23 · 2 条独立证据
来源 · Source

吴军,《数学之美》第3版,人民邮电出版社,2020

Wu Jun, Beauty of Mathematics, 3rd ed., Posts & Telecom Press, 2020

#DiffieHellman #密钥交换 #离散对数

汉明码怎样用少量冗余位发现并纠正一位错误?

How does a Hamming code use few parity bits to detect and correct a single error?

汉明码把校验位放在2的幂次位置,使每个数据位参与若干奇偶校验。出错时各校验方程的结果拼成出错位的位置编号,从而定位并翻转修正。
Hamming codes place parity bits at powers of two so each data bit participates in several checks. The combined parity results form the position of the erroneous bit, locating and correcting it.
难度 专业 · 适合 高中(15-18) CC BY 4.0 · 已核验 · Verified 2026-08-23 · 2 条独立证据
来源 · Source

吴军,《数学之美》第3版,人民邮电出版社,2020

Wu Jun, Beauty of Mathematics, 3rd ed., Posts & Telecom Press, 2020

#汉明码 #纠错 #奇偶校验

数字签名怎样证明消息确实来自某人且未被篡改?

How does a digital signature prove a message is from someone and unaltered?

发送者用私钥对消息哈希签名,任何人可用其公钥验证:能验证通过,说明签名者持有私钥且内容未变。它类似手写签名但可数学验证。
The sender signs a hash of the message with a private key; anyone verifies with the public key. Successful verification proves the signer held the private key and the content is unchanged.
难度 专业 · 适合 高中(15-18) CC BY 4.0 · 已核验 · Verified 2026-08-23 · 2 条独立证据
来源 · Source

吴军,《数学之美》第3版,人民邮电出版社,2020

Wu Jun, Beauty of Mathematics, 3rd ed., Posts & Telecom Press, 2020

#数字签名 #公钥 #哈希

什么是完美保密,它有什么代价?

What is perfect secrecy, and what is its cost?

香农定义:密文不泄露任何明文信息(条件分布等于先验)。一次性密码本可达此标准,但代价是密钥必须与明文等长且仅用一次,难以分发。
Shannon defined perfect secrecy as ciphertext revealing nothing about plaintext. The one-time pad achieves it, but at the cost of a key as long as the message, used once and hard to distribute.
难度 专业 · 适合 高中(15-18) CC BY 4.0 · 已核验 · Verified 2026-08-23 · 2 条独立证据
来源 · Source

吴军,《数学之美》第3版,人民邮电出版社,2020

Wu Jun, Beauty of Mathematics, 3rd ed., Posts & Telecom Press, 2020

#完美保密 #香农 #信息论

什么是离散对数问题,它在密码中有什么用?

What is the discrete logarithm problem, and what is it used for in cryptography?

给定g、模p和h=g^x mod p,求x就是离散对数问题,目前没有高效算法。它是Diffie-Hellman密钥交换和许多数字签名的数学基础。
Given g, prime p, and h=g^x mod p, finding x is the discrete log problem, for which no efficient algorithm is known. It underlies Diffie-Hellman key exchange and many digital signatures.
难度 专业 · 适合 高中(15-18) CC BY 4.0 · 已核验 · Verified 2026-08-23 · 2 条独立证据
来源 · Source

吴军,《数学之美》第3版,人民邮电出版社,2020

Wu Jun, Beauty of Mathematics, 3rd ed., Posts & Telecom Press, 2020

#离散对数 #模幂 #密钥交换

二战中的恩尼格玛机是如何加密的,图灵等人怎样破解?

How did the WWII Enigma machine encrypt, and how did Turing and others break it?

恩尼格玛用可转动的转子对字母做复杂替换,每天更换接线设置。盟军利用已知明文片段(如天气报告)和机电炸弹机穷举转子位置而破译。
Enigma used rotors for complex substitution with daily key settings. The Allies exploited known plaintext fragments (e.g., weather reports) and electromechanical bombes to brute-force rotor positions.
难度 进阶 · 适合 大众 CC BY 4.0 · 已核验 · Verified 2026-08-23 · 2 条独立证据
来源 · Source

吴军,《数学之美》第3版,人民邮电出版社,2020

Wu Jun, Beauty of Mathematics, 3rd ed., Posts & Telecom Press, 2020

#恩尼格玛 #转子 #二战密码

一次性密码本为什么理论上绝对安全?

Why is the one-time pad provably unbreakable in theory?

若密钥和明文等长、真正随机且只用一次,密文与任意明文等长且统计无关,攻击者无法区分。它要求密钥绝对保密且绝不重用。
With a key as long as the message, truly random and used only once, the ciphertext is statistically independent of any plaintext, so the attacker cannot tell them apart. The key must stay secret and never be reused.
难度 进阶 · 适合 大众 CC BY 4.0 · 已核验 · Verified 2026-08-23 · 2 条独立证据
来源 · Source

吴军,《数学之美》第3版,人民邮电出版社,2020

Wu Jun, Beauty of Mathematics, 3rd ed., Posts & Telecom Press, 2020

#一次性密码本 #完美保密 #随机

为什么异或(XOR)在加密中如此常用?

Why is XOR so common in cryptography?

异或的一个妙处是自身异或可逆:A⊕K再⊕K回到A。它与随机密钥异或可打乱比特,且计算极快、便于硬件实现。
XOR is self-inverse: (A⊕K)⊕K=A. XORing with a random key scrambles bits, is extremely fast, and is easy to implement in hardware.
难度 进阶 · 适合 大众 CC BY 4.0 · 已核验 · Verified 2026-08-23 · 2 条独立证据
来源 · Source

吴军,《数学之美》第3版,人民邮电出版社,2020

Wu Jun, Beauty of Mathematics, 3rd ed., Posts & Telecom Press, 2020

#异或 #比特运算 #对称加密

密码学哈希函数有什么特性,为什么不可逆?

What properties make a cryptographic hash function, and why is it one-way?

好的哈希把任意输入映射成固定长度指纹,具备确定性、抗碰撞(难找两个同输出)和单向性(由输出难反推输入)。它广泛用于签名与校验。
A good hash maps any input to a fixed-length fingerprint that is deterministic, collision-resistant, and one-way (hard to invert). It is widely used in signatures and integrity checks.
难度 进阶 · 适合 初中(12-15) CC BY 4.0 · 已核验 · Verified 2026-08-23 · 2 条独立证据
来源 · Source

吴军,《数学之美》第3版,人民邮电出版社,2020

Wu Jun, Beauty of Mathematics, 3rd ed., Posts & Telecom Press, 2020

#哈希 #单向函数 #数字指纹

凯撒密码是怎么加密的,为什么很容易破解?

How does the Caesar cipher encrypt, and why is it easy to break?

它把字母表整体平移固定位数(如A→D)。因为只有25种可能的位移,穷举或按字母频率分析都能迅速还原明文。
It shifts the alphabet by a fixed amount (e.g., A→D). With only 25 possible shifts, brute force or letter-frequency analysis recovers the plaintext quickly.
难度 进阶 · 适合 大众 CC BY 4.0 · 已核验 · Verified 2026-08-23 · 2 条独立证据
来源 · Source

吴军,《数学之美》第3版,人民邮电出版社,2020

Wu Jun, Beauty of Mathematics, 3rd ed., Posts & Telecom Press, 2020

#凯撒密码 #替换密码 #频率分析

二维码为什么被遮挡一部分仍能扫出来?

Why can a QR code still scan when partly covered?

二维码内置里德-所罗门纠错码,把数据编码成可冗余恢复的形式。即使部分模块污损,解码器也能靠冗余信息还原原始数据。
QR codes embed Reed-Solomon error correction, encoding data redundantly. Even if some modules are damaged, the decoder reconstructs the original from the redundant information.
难度 入门 · 适合 大众 CC BY 4.0 · 已核验 · Verified 2026-08-23 · 2 条独立证据
来源 · Source

吴军,《数学之美》第3版,人民邮电出版社,2020

Wu Jun, Beauty of Mathematics, 3rd ed., Posts & Telecom Press, 2020

#二维码 #纠错码 #里德所罗门

维吉尼亚密码相比凯撒密码强在哪里,又如何被攻破?

How is the Vigenère cipher stronger than Caesar, and how is it broken?

它用一段重复的关键词逐位平移,打破了单字母频率。但可用卡西斯基测试或重合指数找出周期,再对各分组做频率分析破解。
It shifts each letter by a repeating keyword, breaking simple letter frequencies. Yet Kasiski examination or index of coincidence reveals the period, after which each group is frequency-analyzed.
难度 入门 · 适合 大众 CC BY 4.0 · 已核验 · Verified 2026-08-23 · 2 条独立证据
来源 · Source

吴军,《数学之美》第3版,人民邮电出版社,2020

Wu Jun, Beauty of Mathematics, 3rd ed., Posts & Telecom Press, 2020

#维吉尼亚 #多表替换 #卡西斯基

字母频率分析为什么能破解古典替换密码?

Why does letter-frequency analysis break classical substitution ciphers?

自然语言字母出现频率稳定(英文e最常见),单表替换保留频率模式。统计密文字母频次并对照语言特征即可逐字还原。
Natural languages have stable letter frequencies (e in English is most common), and simple substitution preserves that pattern. Counting ciphertext frequencies against language stats recovers letters.
难度 入门 · 适合 大众 CC BY 4.0 · 已核验 · Verified 2026-08-23 · 2 条独立证据
来源 · Source

吴军,《数学之美》第3版,人民邮电出版社,2020

Wu Jun, Beauty of Mathematics, 3rd ed., Posts & Telecom Press, 2020

#频率分析 #替换密码 #密码学