Reference Blog: The difference between HTTP and HTTPS
the difference between HTTP and HTTPS
First, HTTP and the HTTPS The basic concepts and differences
- HTTP:
- Is the most widely used network protocol, is a client and server-side request and response Standard (TCP), used to transfer from the WWW server hypertext to the local browser Transfer protocol, it can make the browser more efficient, so that network transmission reduced.
- the data transmitted by the HTTP protocol is unencrypted, which is plaintext, so it is very insecure to use the HTTP protocol to transmit private information .
- HTTPS(full name:Hypertext Transfer Protocol over Secure Socket Layer)
- A security- targeted HTTP channel, the Http+ssl protocol.
- Main functions:
- Encrypted transfer: establish an information security channel to ensure the security of data transmission (encryption of communication between browser and server)
- identity authentication: confirm the authenticity of the website (relying on the certificate to verify the identity of the server)
- Advantages:
- Use HTTPS The protocol authenticates the user and the server, ensuring that the data is sent to the correct client and server;
- HTTPS The agreement is made by ssl+http protocol constructs a network protocol that can be encrypted, transmitted, and authenticated. http Protocol security, which prevents data from being stolen, changed, and ensures data integrity during transmission.
- HTTPS Is the safest solution under the current architecture, though not completely secure, but it dramatically increases the cost of a man-in-the-middle attack.
- Google used to the years 8 month to adjust the search engine algorithm, and said that "compared to the equivalent HTTP website, using HTTPS encrypted sites will be ranked higher in search results. "
- Disadvantages:
- H TTPs The protocol handshake phase is time-consuming and will extend the page load times by nearly 50% 10% to 20% power consumption;
- HTTPS connection cache is less than HTTP Efficient, increase data overhead and power consumption, and even existing security measures will be affected;
- SSL certificates require money, the more powerful the higher the cost of the certificate, personal sites, small sites are not necessary generally not used.
- S SL certificates typically require binding ip cannot be in the same ip bind multiple domain names, ipv4 Resources cannot support this consumption.
- H TTPs The encryption range of the protocol is also limited, in hacker attacks, denial of service attacks, Server hijacking has little effect. Most critical, ssl Certificate of credit chain system is not secure, especially in some countries can control the ca root certificate in the case of an intermediate man attack as feasible.
- Difference:
- The HTTPS protocol requires a certificate to be applied to the CA, generally with less free certificates, and therefore a certain fee.
- HTTP is a Hypertext Transfer Protocol, and information is transmitted in plaintext;
- HTTPS is an SSL encrypted transport protocol with security.
- http and HTTPS use a completely different connection, the same port, the former is 80, the latter is 443.
- HTTP connection is very simple, is stateless;
- HTTPS protocol is a network protocol built by Ssl+http protocol which can encrypt transmission and authentication, which is more secure than HTTP protocol .
Second, HTTPS encryption, decryption, verification process
- customer make With https url access web server, required with web " Span style= "font-family: Microsoft Jacob Black; Background-color:white "> server established ssl connection.
- Web When the server receives a client request, it sends a copy of the Web site's certificate information (the certificate contains the public key) to the client.
- the client's browser and Web Server starts negotiation SSL The security level of the connection, which is the level of information encryption.
- The client's browser establishes a session key based on both agreed security levels, and then encrypts the session key using the Web site's public key and transmits it to the Web site.
- Web The server decrypts the session key with its own private key.
- Web The server uses the session key to encrypt communication with the client.
HTTP vs HTTPS