• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 133
  • Last Modified:

Whats the use of master secret

Hi,
In SSL handshake a master secret is generated. I guess this secret is the same for both client and server.
where exactly is this used. Is it used to encrypt or decrypt data ?
client and server already exchange a cipher suite how is the cipher suite related to this master secret

Thanks
0
Rohit Bajaj
Asked:
Rohit Bajaj
  • 2
  • 2
1 Solution
 
Pawan KumarDatabase ExpertCommented:
Its main purpose is to keep data confidential. & data integrity - if someone or something, willingly or not, alters data in transit, then the receiver must be able to reliably detect it.
0
 
Rohit BajajAuthor Commented:
So when client sends some packet to server it encrypts the packet with master secret and same way server also encrypts with this same master secret and send the packet to client ?
Then where does the encryption that is sent in cypher suite comes into play ?
0
 
Pawan KumarDatabase ExpertCommented:
Read # number 5,7,8 &9. This should help.

1. The client sends a "Client hello" message to the server, along with the client's random value and supported cipher suites.

2. The server responds by sending a "Server hello" message to the client, along with the server's random value.

3. The server sends its certificate to the client for authentication and may request a certificate from the client. The server sends the "Server hello done" message.

4. If the server has requested a certificate from the client, the client sends it.

5. The client creates a random Pre-Master Secret and encrypts it with the public key from the server's certificate, sending the encrypted Pre-Master Secret to the server.

6. The server receives the Pre-Master Secret. The server and client each generate the Master Secret and session keys based on the Pre-Master Secret.

7. The client sends "Change cipher spec" notification to server to indicate that the client will start using the new session keys for hashing and encrypting messages. Client also sends "Client finished" message.

8. Server receives "Change cipher spec" and switches its record layer security state to symmetric encryption using the session keys. Server sends "Server finished" message to the client.

9. Client and server can now exchange application data over the secured channel they have established. All messages sent from client to server and from server to client are encrypted using session key.
0
 
Rohit BajajAuthor Commented:
Hi,
I still have some confusion. I understand that master secret is computed from pre-master secret and random values.
But as you mentioned that all messages from client to server and server to client are encrypted using session keys...

1) Both sides have same session keys ?
2) where is the master secret used here..... is it used to decrypt the messages whereas session keys are used to encrypt the messages ?
0

Featured Post

Evaluating UTMs? Here's what you need to know!

Evaluating a UTM appliance and vendor can prove to be an overwhelming exercise.  How can you make sure that you're getting the security that your organization needs without breaking the bank? Check out our UTM Buyer's Guide for more information on what you should be looking for!

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now