作者sean72 (.)
看板Network
标题Fw: [问题] Certificate 凭证
时间Sat Aug 3 13:07:25 2013
※ [本文转录自 Web_Design 看板 #1H_8_-WV ]
作者: sean72 (.) 看板: Web_Design
标题: [问题] Certificate 凭证
时间: Sat Aug 3 13:07:08 2013
最近在网路上看了certificate的内容
但是不是很了解
因为本身在写python程式 所以也就参考了他上面的说明
我逐字阅读还是有不懂得地方 我将我的问题贴在文章的前头
希望有人能帮忙回答 谢谢
自己整理的结论:
所以凭证里面包含的东西有
a. subject的名称以及subject的公钥
b. issuer里面的资讯: 谁是subject,以及凭证里面subject的公钥是否正确
整串短文看完,我还是不清楚这个东西如何运作
我知道certificate是由第三方公司例如verisign所认证签发
所以如果当我登入某家银行的网站
那麽我的电脑就是subject,银行的主机就是issuer这样吗?
那麽当我连接到银行主机的时候,这个certificate是什麽时候飞进我和银行之间?
certificate是银行寄给我的吗?
如果是,银行寄给我凭证,我打开凭证,使用里面我(subject)的那把公钥,
去解开我私钥加密的讯息?
那银行一开始怎麽会有我的公钥?
难道我的公钥大家都可以任意取得? Verisign如何取得我的电脑名称以及公钥资讯?自己整理的结论:
所以凭证里面包含的东西有
a. subject的名称以及subject的公钥
b. issuer里面的资讯: 谁是subject,以及凭证里面subject的公钥是否正确
整串短文看完,我还是不清楚这个东西如何运作
我知道certificate是由第三方公司例如Verisign所认证签发
所以如果当我登入某家银行的网站
那麽我的电脑就是subject,银行的主机就是issuer这样吗?
那麽当我连接到银行主机的时候,这个certificate是什麽时候飞进我和银行之间?
certificate是银行寄给我的吗?
如果是,银行寄给我凭证,我打开凭证,使用里面我(subject)的那把公钥,
去解开我私钥加密的讯息?
那银行一开始怎麽会有我的公钥?
难道我的公钥大家都可以任意取得? Verisign如何取得我的电脑名称以及公钥资讯?
http://docs.python.org/3.3/library/ssl.html#certificates
Certificates in general are part of a public-key / private-key system.
In this system, each principal, (which may be a machine, or a person, or an
organization) is assigned a unique two-part encryption key. One part of the
key is public, and is called the public key; the other part is kept secret,
and is called the private key. The two parts are related, in that if you
encrypt a message with one of the parts, you can decrypt it with the other
part, and only with the other part.
每台机器都会有一把"公钥" 一把"私钥",如果你用其中一把钥匙去加密,就得用另
外一把相对应的钥匙去解密
(但是他没说要用"哪一把"去加密,不过从下文推断 应该是用私钥加密公钥解密
但是说不定也能反其道而行?)
A certificate contains information about two principals.
"凭证"包含两台机器的讯息
It contains the name of a subject, and the subject’s public key.
凭证包含了某台机器(subject)的名称以及他的公钥
It also contains a statement by a second principal, the issuer, that the
subject is who he claims to be, and that this is indeed the subject’s public
key.
另一台机器(issuer)有下面两个资讯:
1.谁是subject,
2.以及凭证里面subject的公钥是否正确
凭证除了上述subject以及subjet公钥以外,另外也包含issuer里面的这份资讯
The issuer’s statement is signed with the issuer’s private key, which only
the issuer knows.
Issuer的资讯被issuer的私钥加密过了
However, anyone can verify the issuer’s statement by finding the issuer’s
public key, decrypting the statement with it, and comparing it to the other
information in the certificate.
只要有issuer公钥的人,都可以用issuer的公钥去解密issuer的资讯,去验证,然後比较
凭证里面有关issuer的资讯以及issuer本身的资讯
--
※ 发信站: 批踢踢实业坊(ptt.cc)
◆ From: 172.249.127.149
※ 发信站: 批踢踢实业坊(ptt.cc)
※ 转录者: sean72 (172.249.127.149), 时间: 08/03/2013 13:07:25