# 公开密钥加密

（重定向自公钥密码学

In the Diffie–Hellman key exchange scheme, each party generates a public/private key pair and distributes the public key. After obtaining an authentic copy of each other's public keys, Alice and Bob can compute a shared secret offline. The shared secret can be used, for instance, as the key for a symmetric cipher.
Keypair

## 过程

1. A用公钥对明文进行加密形成密文 ${\displaystyle c(x)}$ ，然后传输密文；
2. B收到密文，用私钥对密文进行解密 ${\displaystyle d(c(x))}$ ,得到要通信的明文${\displaystyle x}$

B向A发送信息反之。

## 参考文献

1. ^ Publishing a new idea. Merkle個人網站. [2010-12-08].