html tool

2023年4月24日星期一

转:Why is a public key called a key - isn't it a lock?

 参考:https://security.stackexchange.com/questions/87247/why-is-a-public-key-called-a-key-isnt-it-a-lock


问题:突然想到为什么是key 和key,而不是钥匙和锁呢?go了一下,发现真有人和自己一样的问题的

以下是自己认为可以说服我的:

36

I'm not sure what locks you have experience with, but deadbolt locks are commonly used to lock from the outside. Thus "Lock something in".

In this case, the analogy is that a "key" is something variable, and the "lock" is the algorithm. The lock remains the same, while the key can be changed. In public key cryptography the key used to lock is different from the key used to unlock


另外这个也感觉有道理

5

This 'problem' is often encountered by people who are just learning about cryptography and public / private key cryptography. So I understand your confusion.

The reason we call both a 'key' is because its cryptographic function is to be a cryptographic key which has nothing to do with common day keys and locks.

In many analogies for laymen the lock - key analogy is used and this is the source of your confusion. You think of the key as something to unlock with. While a cryptologist see a key as a hut of information to encrypt or decrypt a piece of information.

And to keep in your analogy, there are doors that have no handles and these doors you open and close with the key (so the key is used both for opening and closing the door, giving you access to what's inside it).

没有评论:

发表评论