To understand the difference between http and https request and response, you need to know what is http and what is htps separately with their key points.
What is Hypertext Transfer Protocol (HTTP) ?
- Hypertext transfer protocol (HTTP) is the mode of communication that is used in internet browsers where data transfers id to and fro between user and server.
- First a connection is established between web browser and the server, the n a request is generated to the server. The sends back a response with a “ok” message or result of the request.
- In HTTP there is not any authentication during its communication, therefore it is a unsecured. It always uses the port 80 of TCP(transmission control protocol).
- It can be easily accessible and can be hacked as it does not follow any encryption.
- It performs its application in application layer That helps in communication using shared protocols.
- Its is less expensive as compared to HTTPS as it does not have any security certificates. Also it does not use SSL for data overflow.
- It is very much user friendly as it has the ability to cache.
- It works smoothly in virtual hosts.
- In simple words HTTP it is a basic protocol that is used for data transfer.
- Perfomance wise HTTP is bit faster than HTTPS
- Example of http is ==> http://www.blogilism.com
What is Secured Hypertext Transfer Protocol (HTTPS) ?
- Secured Hypertext Transfer Protocol (HTTPS) is the secure mode of communication, where the data transfer happens with encryption.
- First the server sends a list of supported encryption methods to create connection. the client selects any of the method from that list. Then the exchange of certificates is done from both ends. Once connection is created, the encrypted informational transferred between the two. After the job (data transfer) is to be done the connection is closed.
- HTTPS use TCP(transmission control protocol) port number 443 for enabling data communication. It is default port.
- It is much secured as it uses encryption for communicating. HTTPS uses an encrypted format for data transfer.
- HTTPS performs all its operations in the transport layer(in which end to end data transfer take place).
- It follows SSL protocol wherein all the confidential information like passwords, username, credit card numbers etc. are transferred in secured and encrypted manner.
- In HTTPS, SSL differentiates the identity between a sender and a receiver. Thus starting and ending points are unique. SSL uses algorithms to encapsulate the data by hiding its original meaning.
- Its doesn’t allow cache thus many websites avoid using it.
- Its is more expensive than HTTP as encryption certificates cost high.
- It is slower as compared to HTTP as it uses encryption method used in SSL.
- HTTPS doesn’t work in virtual hosts.
- In simple words, HTTP is basically an http with a more secured approach.
- Examples of HTTPS is www.google.co.in