公開密鑰加密


公開密鑰加密 (简体)

Free Web Hosting with Website Builder
A big random number is used to make a public-key pair.
Anyone can encrypt using the public key, but only the holder of the private key can decrypt. Secrecy depends on the secrecy of the private key.
Using a private key to encrypt (thus signing) a message; anyone can check the signature using the public key. Validity depends on private key security.
By combining your own private key with the other users public key you can calculate a shared secret that only the two of you know. The shared secret can be used as the key for a symmetric cipher.

公開密鑰加密也稱為非對稱密鑰加密,該加密演算法使用兩個不同的密鑰:加密密鑰和解密密鑰。前者公開,又稱公開密鑰,簡稱公鑰。後者保密,又稱私有密鑰,簡稱私鑰。這兩個密鑰是數學相關的,用某用戶加密密鑰加密後所得的信息只能用該用戶的解密密鑰才能解密。RSA演算法(由發明者Rivest,Shmir和Adleman姓氏首字母縮寫而來)是著名的公開密鑰加密演算法。

公鑰加密的另一用途是身份驗證:用私鑰加密的信息,可以用公鑰拷貝對其解密,接收者由此可知這條信息確實來自於擁有私鑰的某人。

公鑰的形式就是數字證書

優點

與對稱密鑰加密相比,優點在於無需共享的通用密鑰,解密的私鑰不發往任何用戶。即使公鑰在網上被截獲,如果沒有與其匹配的私鑰,也無法解密,所截獲的公鑰是沒有任何用處的。

過程

Asymmetric encryption system

假設兩個用戶A,B進行通信,公鑰為c,私鑰為d,明文為x.

1:A用公鑰對明文進行加密形成密文c(x),然後傳輸密文;

2:B收到密文,用私鑰對密文進行解密d(c(x)),得到要通信的明文x。







Why are we here?
All text is available under the terms of the GNU Free Documentation License
This page is cache of Wikipedia. History