openssl自签发证书以及ssl原理简介(二)
2015-07-20 16:45
330 查看
本节接着分析ssl原理。
本来想分析rsa握手和dh握手的不同,无奈dh实验不成功,这里仅仅根据抓包分析rsa握手过程。
参考抓包我们来分析一下rsa ssl握手过程。
首先client 发送client hello message,其中包含client random以及client之后的加密组件。
接着server发送server random,选定的server cipher suite 以及公钥证书并请求客户端的证书。
4000
接着client发送自己的公钥证书certificate。生成premaster secret (ClientkeyExchange)并且使用server的公钥证书加密发送给server。验证server的证书后ChangeCipherSpec表示下次通信使用堆成密钥。
这样server端收到后解密也可以得到premaster。permaster,client random, server random 构成session key。并生成session Ticket.
另外,我这里抓包是双向认证,cloudflare得rsa认证图是单向认证。
参考链接很有价值。
参考:
https://blog.cloudflare.com/keyless-ssl-the-nitty-gritty-technical-details/ http://blog.csdn.net/fw0124/article/details/40875629 http://blog.csdn.net/fw0124/article/details/40983787 http://blog.chinaunix.net/uid-10167808-id-3451290.html http://www.fenesky.com/blog/2014/07/25/how-session-secret.html http://program-think.blogspot.com/2014/11/https-ssl-tls-2.html http://segmentfault.com/a/1190000002554673 http://op.baidu.com/2015/04/https-s01a01/
本来想分析rsa握手和dh握手的不同,无奈dh实验不成功,这里仅仅根据抓包分析rsa握手过程。
参考抓包我们来分析一下rsa ssl握手过程。
首先client 发送client hello message,其中包含client random以及client之后的加密组件。
接着server发送server random,选定的server cipher suite 以及公钥证书并请求客户端的证书。
4000
接着client发送自己的公钥证书certificate。生成premaster secret (ClientkeyExchange)并且使用server的公钥证书加密发送给server。验证server的证书后ChangeCipherSpec表示下次通信使用堆成密钥。
这样server端收到后解密也可以得到premaster。permaster,client random, server random 构成session key。并生成session Ticket.
另外,我这里抓包是双向认证,cloudflare得rsa认证图是单向认证。
参考链接很有价值。
参考:
https://blog.cloudflare.com/keyless-ssl-the-nitty-gritty-technical-details/ http://blog.csdn.net/fw0124/article/details/40875629 http://blog.csdn.net/fw0124/article/details/40983787 http://blog.chinaunix.net/uid-10167808-id-3451290.html http://www.fenesky.com/blog/2014/07/25/how-session-secret.html http://program-think.blogspot.com/2014/11/https-ssl-tls-2.html http://segmentfault.com/a/1190000002554673 http://op.baidu.com/2015/04/https-s01a01/
相关文章推荐
- 【Linux-shell】shell脚本基础语法练习
- 密钥登陆Linux服务器
- OpenMesh 删除网格顶点
- 基于centos的mysql学习补充一
- Linux学习(1)——CLI:BASH命令
- Linux Screen命令详解
- 公司网站
- liunx安装nginx
- nginx+iis实现负载均衡
- linux下jdk的安装
- 嵌入式Linux串口输出可疑乱码
- linux SSH rsa认证方式登录需理清的问题
- opencv源码分析:cvCreateTreeCascadeClassifier
- Linux企业运维高效技巧心得及分享
- linux关于bashrc与profile的区别
- sgu 199 beautiful people(nlog 的LIS并输出路径)
- CopyOnWriteArrayList详解
- linux下面关于makefile使用的笔记。
- bash shell脚本常用功能
- Linux上 使用zip命令打包 目录(递归)