HTTP

From WikiMD's Wellness Encyclopedia

Error creating thumbnail:
Tim Berners-Lee CP 2
Error creating thumbnail:
Http request telnet ubuntu

Hypertext Transfer Protocol (HTTP) is an application-layer protocol for transmitting hypermedia documents, such as HTML. It was designed for communication between web browsers and web servers, but it can also be used for other purposes. HTTP follows a classical client-server model, with a client initiating a request to a server and the server responding to the request. The protocol is a stateless protocol, meaning that the server does not keep any data (state) between two requests. However, web applications can maintain state through the use of HTTP cookies, sessions, and other mechanisms.

Overview[edit | edit source]

HTTP functions as a request-response protocol in the client-server computing model. A web browser, for example, may be the client and an application running on a computer hosting a website may be the server. The client submits an HTTP request message to the server. The server, which provides resources such as HTML files and other content, or performs other functions on behalf of the client, returns a response message to the client. The response contains completion status information about the request and may also contain requested content in its message body.

HTTP Versions[edit | edit source]

There have been several versions of HTTP, evolving to improve performance and security:

  • HTTP/1.0: This version introduced the basic framework of HTTP/1.x, defining the GET, POST, and HEAD methods and the MIME-like mechanism for sending data.
  • HTTP/1.1: Improved efficiency by adding persistent connections, chunked transfer encoding, and more. It is widely used on the Internet.
  • HTTP/2: Released in 2015, it introduced a major revision with improvements in efficiency, security, and speed. It uses the same API as HTTP/1.x but supports multiplexing, header compression, and server push.
  • HTTP/3: The latest version, based on QUIC, an experimental transport layer network protocol developed by Google. HTTP/3 aims to improve upon issues that HTTP/2 has over TCP with features like reduced connection establishment time and improved congestion control.

Methods[edit | edit source]

HTTP defines a set of request methods to indicate the desired action to be performed for a given resource. Although they can also be nouns, these request methods are sometimes referred to as HTTP verbs. Each of them implements a different semantic, but some common features are shared by a group of them:

  • GET: Requests a representation of the specified resource. Requests using GET should only retrieve data.
  • HEAD: Asks for a response identical to that of a GET request, but without the response body.
  • POST: Used to submit an entity to the specified resource, often causing a change in state or side effects on the server.
  • PUT: Replaces all current representations of the target resource with the request payload.
  • DELETE: Removes the specified resource.
  • PATCH: Used to apply partial modifications to a resource.

Status Codes[edit | edit source]

HTTP response status codes indicate whether a specific HTTP request has been successfully completed. Responses are grouped in five classes:

  • Informational responses (100–199),
  • Successful responses (200–299),
  • Redirection messages (300–399),
  • Client error responses (400–499),
  • Server error responses (500–599).

Security[edit | edit source]

The security of HTTP has been a concern since its inception. Because it is often used to transmit sensitive information such as usernames, passwords, and credit card details, various security measures have been introduced:

  • HTTPS: An extension of HTTP, it uses the Secure Sockets Layer (SSL)/Transport Layer Security (TLS) protocols to encrypt the communication between the client and the server.
  • HTTP Strict Transport Security (HSTS): A web security policy mechanism that helps to protect websites against man-in-the-middle attacks such as protocol downgrade attacks and cookie hijacking.

See Also[edit | edit source]

WikiMD
Navigation: Wellness - Encyclopedia - Health topics - Disease Index‏‎ - Drugs - World Directory - Gray's Anatomy - Keto diet - Recipes

Search WikiMD

Ad.Tired of being Overweight? Try W8MD's physician weight loss program.
Semaglutide (Ozempic / Wegovy and Tirzepatide (Mounjaro / Zepbound) available.
Advertise on WikiMD

WikiMD's Wellness Encyclopedia

Let Food Be Thy Medicine
Medicine Thy Food - Hippocrates

WikiMD is not a substitute for professional medical advice. See full disclaimer.
Credits:Most images are courtesy of Wikimedia commons, and templates Wikipedia, licensed under CC BY SA or similar.

Contributors: Prab R. Tumpati, MD