HTTPS Protocolo2021
HTTPS Protocolo2021
HTTP request
Amy Web server
HTTP response www.taobao.com
Page 2
Question
HTTP + SSL
Page 3
Outline
1. Secure socket layer (SSL)
2. A simplified version of SSL
3. Details in SSL
4. SSL certificate
Page 4
Secure socket layer (SSL)
Secure socket layer (SSL)
Originally specified in the 1990s by Netscape
The first widely used protocol for securing online transactions
A secure TCP protocol for HTTP and other applications
Encryption, integrity, and server and client authentication
Page 5
SSL in TCP/IP protocol suite
Application
program
SSL socket Application layer
Application
SSL sub layer
program
TCP socket TCP socket
TCP TCP
IP IP
Page 6
Outline
1. Secure socket layer (SSL)
2. A simplified version of SSL
3. Details in SSL
4. SSL certificate
Page 7
A simplified version of SSL
Bob
Amy a server with private
key, public key, and
certificate
Page 8
1. Handshake
Page 9
1. Handshake (continued)
Bob
Amy a server with private
key, public key, and
certificate
Create TCP
connection
Verify Bob
Calculate and
send MS
Get MS by decrypting
EMS with KA-
time time
Page 10
2. Key calculation
Amy and Bob both generate four keys (EA, MA, EB, MB)
from the master secret MS
Page 11
3. Data transfer
Page 12
3. Data transfer (continued)
data
data data
MAC MAC
fragment fragment
Page 13
3. Data transfer (continued)
Amy Bob
Page 14
3. Data transfer (continued)
Amy Bob
Page 15
SSL record
SSL record protocol
Encrypt with EX
NOT encrypt: type, version, length
type: a handshake message or application message,
SSL connection closure
version: SSL version
length: the receiver extracts SSL record from TCP byte stream
Page 16
Outline
1. Secure socket layer (SSL)
2. A simplified version of SSL
3. Details in SSL
4. SSL certificate
Page 17
SSL handshake
SSL handshake protocol
Page 18
SSL handshake (continued)
4. The client and the server calculate the Master Secret (MS) from
PMS, respectively, and then get two encryption keys and two
MAC secrets from MS. After this, all the messages between
client and server are encrypted and authenticated
e.g., An attacker eavesdrops and modifies the encryption algorithm list in Step 1
Page 19
Why to use the random nonce?
Page 20
SSL connection closure
Amy Bob
Page 21
Some implementations of SSL
OpenSSL (http://www.openssl.org/)
A free, open-source implementation of SSL
Apache-SSL (http://httpd.apache.org/docs/current/ssl/index.html)
A secure Webserver, based on Apache and OpenSSL
SSLeay (http://www.ssleay.org/)
A free implementation of Netscape’s Secure Socket Layer
Page 22
Outline
1. Secure socket layer (SSL)
2. A simplified version of SSL
3. Details in SSL
4. SSL certificate
Page 23
SSL certificate
Page 24
SSL certificate (continued)
Page 25
SSL certificate (continued)
Page 26
Summary
Page 27
Questions
Page 28
Thanks!
工科类 20 号
教师:唐晓岚
Page 29