Английская Википедия:HTTP/2

Материал из Онлайн справочника
Перейти к навигацииПерейти к поиску

Шаблон:Short description Шаблон:Use mdy dates Шаблон:Infobox protocol

HTTP/2 (originally named HTTP/2.0) is a major revision of the HTTP network protocol used by the World Wide Web. It was derived from the earlier experimental SPDY protocol, originally developed by Google.[1][2] HTTP/2 was developed by the HTTP Working Group (also called httpbis, where "Шаблон:Linktext" means "twice") of the Internet Engineering Task Force (IETF).[3][4][5] HTTP/2 is the first new version of HTTP since HTTP/1.1, which was standardized in Шаблон:IETF RFC in 1997. The Working Group presented HTTP/2 to the Internet Engineering Steering Group (IESG) for consideration as a Proposed Standard in December 2014,[6][7] and IESG approved it to publish as Proposed Standard on February 17, 2015 (and was updated in February 2020 in regard to TLS 1.3).[8][9] The HTTP/2 specification was published as Шаблон:IETF RFC on May 14, 2015.[10]

The standardization effort was supported by Chrome, Opera, Firefox,[11] Internet Explorer 11, Safari, Amazon Silk, and Edge browsers.[12] Most major browsers had added HTTP/2 support by the end of 2015.[13] About 97% of web browsers used have the capability (and 100% of "tracked desktop" web browsers).[13] Шаблон:As of, 36% (after topping out at just over 50%) of the top 10 million websites support HTTP/2.[14]

Its successor is HTTP/3, a major revision that builds on the concepts established by HTTP/2.[2][15][13][16]

Goals

The working group charter mentions several goals and issues of concern:[4]

Differences from HTTP/1.1

The proposed changes do not require any changes to how existing web applications work, but new applications can take advantage of new features for increased speed.[17] HTTP/2 leaves all of HTTP/1.1's high-level semantics, such as methods, status codes, header fields, and URIs, the same. What is new is how the data is framed and transported between the client and the server.[17]

Websites that are efficient minimize the number of requests required to render an entire page by minifying (reducing the amount of code and packing smaller pieces of code into bundles, without reducing its ability to function) resources such as images and scripts. However, minification is not necessarily convenient nor efficient and may still require separate HTTP connections to get the page and the minified resources. HTTP/2 allows the server to "push" content, that is, to respond with data for more queries than the client requested. This allows the server to supply data it knows a web browser will need to render a web page, without waiting for the browser to examine the first response, and without the overhead of an additional request cycle.[18]

Additional performance improvements in the first draft of HTTP/2 (which was a copy of SPDY) come from multiplexing of requests and responses to avoid some of the head-of-line blocking problem in HTTP 1 (even when HTTP pipelining is used), header compression, and prioritization of requests.[19] However, as HTTP/2 runs on top of a single TCP connection there is still potential for head-of-line blocking to occur if TCP packets are lost or delayed in transmission.[20] HTTP/2 no longer supports HTTP/1.1's chunked transfer encoding mechanism, as it provides its own, more efficient, mechanisms for data streaming.[21]

History

Genesis in and later differences from SPDY

SPDY (pronounced like "speedy") was a previous HTTP-replacement protocol developed by a research project spearheaded by Google.[22] Primarily focused on reducing latency, SPDY uses the same TCP pipe but different protocols to accomplish this reduction. The basic changes made to HTTP/1.1 to create SPDY included "true request pipelining without FIFO restrictions, message framing mechanism to simplify client and server development, mandatory compression (including headers), priority scheduling, and even bi-directional communication".[23]

The HTTP Working Group considered Google's SPDY protocol, Microsoft's HTTP Speed+Mobility proposal (SPDY based),[22] and Network-Friendly HTTP Upgrade.[24] In July 2012, Facebook provided feedback on each of the proposals and recommended HTTP/2 be based on SPDY.[25] The initial draft of HTTP/2 was published in November 2012 and was based on a straight copy of SPDY.[26]

The biggest difference between HTTP/1.1 and SPDY was that each user action in SPDY is given a "stream ID", meaning there is a single TCP channel connecting the user to the server. SPDY split requests into either control or data, using a "simple to parse binary protocol with two types of frames".[23][27] SPDY showed evident improvement over HTTP, with a new page load speedup ranging from 11% to 47%.[28]

The development of HTTP/2 used SPDY as a jumping-off point. Among the many detailed differences between the protocols, the most notable is that HTTP/2 uses a fixed Huffman code-based header compression algorithm, instead of SPDY's dynamic stream-based compression. This helps to reduce the potential for compression oracle attacks on the protocol, such as the CRIME attack.[27]

On February 9, 2015, Google announced plans to remove support for SPDY in Chrome in favor of support for HTTP/2.[29] That took effect, starting with Chrome 51.[30][31]

Development milestones

Date Milestone[4]
December 20, 2007[32][33] First HTTP/1.1 Revision Internet Draft
January 23, 2008[34] First HTTP Security Properties Internet Draft
Early 2012[35] Call for Proposals for HTTP 2.0
October 14 – November 25, 2012[36][37] Working Group Last Call for HTTP/1.1 Revision
November 28, 2012[38][39] First WG draft of HTTP 2.0, based upon draft-mbelshe-httpbis-spdy-00
Held/Eliminated Working Group Last Call for HTTP Security Properties
September 2013[40][41] Submit HTTP/1.1 Revision to IESG for consideration as a Proposed Standard
February 12, 2014[42] IESG approved HTTP/1.1 Revision to publish as a Proposed Standard
June 6, 2014[32][43] Publish HTTP/1.1 Revision as Шаблон:IETF RFC
August 1, 2014 – September 1, 2014[7][44] Working Group Last call for HTTP/2
December 16, 2014[6] Submit HTTP/2 to IESG for consideration as a Proposed Standard
December 31, 2014 – January 14, 2015[45] IETF Last Call for HTTP/2
January 22, 2015[46] IESG telechat to review HTTP/2 as Proposed Standard
February 17, 2015[8] IESG approved HTTP/2 to publish as Proposed Standard
May 14, 2015[47] Publish HTTP/2 as Шаблон:IETF RFC
February 2020 Шаблон:IETF RFC: HTTP/2 with TLS 1.3

Encryption

HTTP/2 is defined both for HTTP URIs (i.e. without TLS encryption, a configuration which is abbreviated in Шаблон:Strong) and for HTTPS URIs (over TLS using ALPN extension[48] where TLS 1.2 or newer is required, a configuration which is abbreviated in Шаблон:Strong).

Although the standard itself does not require usage of encryption,[49] all major client implementations (Firefox,[50] Chrome, Safari, Opera, IE, Edge) have stated that they will only support HTTP/2 over TLS, which makes encryption de facto mandatory.[51]

Criticisms

Development process

The FreeBSD and Varnish developer Poul-Henning Kamp asserts that the standard was prepared on an unrealistically short schedule, ruling out any basis for the new HTTP/2 other than the SPDY protocol and resulting in other missed opportunities for improvement. Kamp criticizes the protocol itself for being inconsistent and having needless, overwhelming complexity. He also states that the protocol violates the protocol layering principle, for example by duplicating flow control that belongs in the transport layer (TCP). He also suggested that the new protocol should have removed HTTP Cookies, introducing a breaking change.[52]

Encryption

Initially, some membersШаблон:Who of the Working Group tried to introduce an encryption requirement in the protocol. This faced criticism.

Critics stated that encryption has non-negligible computing costs and that many HTTP applications actually have no need for encryption and their providers have no desire to spend additional resources on it. Encryption proponents have stated that this encryption overhead is negligible in practice.[53] Poul-Henning Kamp has criticized the IETF for hastily standardizing Google's SPDY prototype as HTTP/2 due to political considerations.[52][54][55] The criticism of the agenda of mandatory encryption within the existing certificate framework is not new, nor is it unique to members of the open-source communityШаблон:Snd a Cisco employee stated in 2013 that the present certificate model is not compatible with small devices like routers, because the present model requires not only annual enrollment and remission of non-trivial fees for each certificate, but must be continually repeated on an annual basis.[56] In the end the Working Group did not reach consensus over the mandatory encryption,[49] although most client implementations require it, which makes encryption a de facto requirement.

The HTTP/2 protocol also faced criticism for not supporting opportunistic encryption, a measure against passive monitoring similar to the STARTTLS mechanism that has long been available in other Internet protocols like SMTP. Critics have stated that the HTTP/2 proposal goes in violation of IETF's own Шаблон:IETF RFC "Pervasive Monitoring Is an Attack", which also has a status of Best Current Practice 188.[57] RFC7258/BCP188 mandates that passive monitoring be considered as an attack, and protocols designed by IETF should take steps to protect against passive monitoring (for example, through the use of opportunistic encryption). A number of specifications for opportunistic encryption of HTTP/2 have been provided,[58][59][60] of which draft-nottingham-http2-encryption was adopted as an official work item of the working group, leading to the publication of Шаблон:IETF RFC in May 2017.

TCP head-of-line blocking

Although the design of HTTP/2 effectively addresses the HTTP-transaction-level head-of-line blocking problem by allowing multiple concurrent HTTP transactions, all those transactions are multiplexed over a single TCP connection, meaning that any packet-level head-of-line blocking of the TCP stream simultaneously blocks all transactions being accessed via that connection. This head-of-line blocking in HTTP/2 is now widely regarded as a design flaw, and much of the effort behind QUIC and HTTP/3 has been devoted to reduce head-of-line blocking issues.[61][62]

Server-side support

Шаблон:Main

Server software

The following web servers support HTTP/2:

Content delivery networks

  • Akamai was the first major CDN to support HTTP/2 and HTTP/2 Server Push.
  • Microsoft Azure supports HTTP/2.
  • PageCDN supports HTTP/2 out of the box and provides user-interface to setup HTTP/2 Server Push in CDN dashboard.[92]
  • CDN77 supports HTTP/2 using nginx (August 20, 2015).
  • Cloudflare supports HTTP/2 using nginx with SPDY as a fallback for browsers without support, whilst maintaining all security and performance services.[93] Cloudflare was the first major CDN to support HTTP/2 Server Push.[94]
  • AWS CloudFront supports HTTP/2[95] since September 7, 2016.
  • Fastly supports HTTP/2 including Server Push.[96]
  • Imperva Incapsula CDN supports HTTP/2.[97] The implementation includes support for WAF and DDoS mitigation features as well.
  • KeyCDN supports HTTP/2 using nginx (October 6, 2015). HTTP/2 Test is a test page to verify if your server supports HTTP/2.
  • Voxility supports HTTP/2 using nginx since July, 2016. The implementation comes in support for Cloud DDoS mitigation services.[98]
  • StackPath supports HTTP/2.

Implementations

See also

References

Шаблон:Reflist

External links

Шаблон:Web interfaces Шаблон:Web browsers

  1. Шаблон:Cite web
  2. 2,0 2,1 Шаблон:Cite news
  3. Шаблон:Cite news
  4. 4,0 4,1 4,2 Шаблон:Cite web
  5. Шаблон:Cite web
  6. 6,0 6,1 Шаблон:Cite web
  7. 7,0 7,1 Шаблон:Cite web
  8. 8,0 8,1 Шаблон:Cite mailing list
  9. Шаблон:Cite web
  10. Шаблон:Cite journal
  11. Шаблон:Cite web
  12. Шаблон:Cite web
  13. 13,0 13,1 13,2 Шаблон:Cite web
  14. Шаблон:Cite web
  15. Шаблон:Cite journal
  16. Шаблон:Cite web
  17. 17,0 17,1 Шаблон:Cite book
  18. Шаблон:Cite web
  19. Шаблон:Cite news
  20. Шаблон:Cite web
  21. Шаблон:Cite journal
  22. 22,0 22,1 Шаблон:Cite web
  23. 23,0 23,1 Шаблон:Cite web
  24. Шаблон:Cite news
  25. Шаблон:Cite web
  26. Шаблон:Cite web
  27. 27,0 27,1 Шаблон:Cite book
  28. Шаблон:Cite web
  29. Шаблон:Cite web
  30. Шаблон:Cite web
  31. Шаблон:Cite web
  32. 32,0 32,1 Шаблон:Cite web
  33. Шаблон:Cite web
  34. Шаблон:Cite web
  35. Шаблон:Cite web
  36. Шаблон:Cite web
  37. Шаблон:Cite web
  38. Шаблон:Cite web
  39. Шаблон:Cite web
  40. Шаблон:Cite web
  41. Шаблон:Cite web
  42. Шаблон:Cite mailing list
  43. Шаблон:Cite mailing list
  44. Шаблон:Cite web
  45. Шаблон:Cite web
  46. Шаблон:Cite web
  47. Шаблон:Cite mailing list
  48. Шаблон:Cite journal
  49. 49,0 49,1 Шаблон:Cite web
  50. Шаблон:Cite web
  51. Шаблон:Cite web
  52. 52,0 52,1 Шаблон:Cite journal
  53. Шаблон:Cite web
  54. Шаблон:Cite journal
  55. Шаблон:Cite mailing list
  56. Шаблон:Cite mailing list
  57. Шаблон:Cite mailing list
  58. Шаблон:Cite web
  59. Шаблон:Cite web
  60. Шаблон:Cite news
  61. Шаблон:Cite web
  62. Шаблон:Cite web
  63. Шаблон:Cite web
  64. Шаблон:Cite web
  65. Шаблон:Cite web
  66. Шаблон:Cite web
  67. Шаблон:Cite web
  68. Шаблон:Cite web
  69. Шаблон:Cite web
  70. Шаблон:Cite web
  71. Шаблон:Cite web
  72. Шаблон:Cite web
  73. Шаблон:Cite web
  74. Шаблон:Cite web
  75. Шаблон:Cite web
  76. Шаблон:Cite web
  77. Шаблон:Cite web
  78. Шаблон:Citation
  79. Шаблон:Cite web
  80. Шаблон:Cite web
  81. Шаблон:Cite web
  82. Шаблон:Cite web
  83. Шаблон:Cite web
  84. Шаблон:Cite web
  85. Шаблон:Cite web
  86. Шаблон:Cite web
  87. Шаблон:Cite news
  88. Шаблон:Cite web
  89. Шаблон:Cite web
  90. Шаблон:Cite web
  91. Шаблон:Cite web
  92. Шаблон:Cite web
  93. Шаблон:Cite web
  94. Шаблон:Cite web
  95. Шаблон:Cite web
  96. Шаблон:Cite web
  97. Шаблон:Cite web
  98. Шаблон:Cite web