【原文】
The Hypertext Transfer Protocol (HTTP) is a stateless application-level request/response protocol that uses extensible semantics and self-descriptive message payloads for flexible interaction with network-based hypertext information systems. This document is the first in a series of documents that collectively form the HTTP/1.1 specification:
- "Message Syntax and Routing" (this document)
- "Semantics and Content" [RFC7231]
- "Conditional Requests" [RFC7232]
- "Range Requests" [RFC7233]
- "Caching" [RFC7234]
- "Authentication" [RFC7235]
超文本傳輸協(xié)議(HTTP) 是無狀態(tài)的應(yīng)用層的傳輸/響應(yīng)協(xié)議,用來拓展語義和自描述消息有效載荷使其可以與基于網(wǎng)絡(luò)的超文本信息系統(tǒng)靈活交互。本文檔是 HTTP/1.1 系列文檔集合的第一部分:
- 消息語法與路由(本文檔)
- 語義和內(nèi)容
- 條件請求
- 范圍請求
- 緩存
- 認證
This HTTP/1.1 specification obsoletes RFC 2616 and RFC 2145 (on HTTP versioning). This specification also updates the use of CONNECT to establish a tunnel, previously defined in RFC 2817, and defines the "https" URI scheme that was described informally in RFC 2818.
該 HTTP/1.1 規(guī)范廢棄了 RFC 2616 和 RFC 2145(HTTP 版本)。該規(guī)范也更新了 CONNECT 建立隧道的使用,之前在 RFC 2817 定義, 和在 RFC 2818 的非正式描述定義 “https” URL 方案。
HTTP is a generic interface protocol for information systems. It is designed to hide the details of how a service is implemented by presenting a uniform interface to clients that is independent of the types of resources provided. Likewise, servers do not need to be aware of each client's purpose: an HTTP request can be considered in isolation rather than being associated with a specific type of client or a predetermined sequence of application steps. The result is a protocol that can be used effectively in many different contexts and for which implementations can evolve independently over time.
HTTP 是為信息系統(tǒng)打造的通用接口協(xié)議。它也被設(shè)計為將獨立類型的資源提供者通過呈現(xiàn)一個統(tǒng)一的接口給客戶端隱藏服務(wù)端的實現(xiàn)。同樣,服務(wù)端無需知道每個客戶端的目的:一個 HTTP 請求是獨立隔離的而不是與特定類型的客戶端所綁定或與應(yīng)用程序的執(zhí)行順序相關(guān)聯(lián)。這使協(xié)議可以在許多不同的場景應(yīng)用和隨著時間的推移進一步發(fā)展。
HTTP is also designed for use as an intermediation protocol for translating communication to and from non-HTTP information systems. HTTP proxies and gateways can provide access to alternative information services by translating their diverse protocols into a hypertext format that can be viewed and manipulated by clients in the same way as HTTP services.
HTTP 也被設(shè)計作為一個傳輸通信中介協(xié)議在非 HTTP 信息系統(tǒng)來往傳輸通信。HTTP 代理和網(wǎng)關(guān)可以通過把它們的多種協(xié)議翻譯成超文本格式從而提供訪問替代信息服務(wù),然后通過客戶端以相同的 HTTP 服務(wù)即可查看和操作。
One consequence of this flexibility is that the protocol cannot be defined in terms of what occurs behind the interface. Instead, we are limited to defining the syntax of communication, the intent of received communication, and the expected behavior of recipients. If the communication is considered in isolation, then successful actions ought to be reflected in corresponding changes to the observable interface provided by servers. However, since multiple clients might act in parallel and perhaps at cross-purposes, we cannot require that such changes be observable beyond the scope of a single response.
協(xié)議太靈活的一個后果是不能對接口背后發(fā)生的事情定義術(shù)語。不僅如此,我們限制定義通信的語法,接收通信的意圖,和收件人的預(yù)期行為。如果通信被單獨考慮,那么成功的動作應(yīng)該被反映在由服務(wù)器提供的可觀察接口的相應(yīng)變化中。然而,由于多個客戶端可能并行操作,并且可能會由交叉目的地,我們不能要求這些變化在單個響應(yīng)的范圍外可觀察。
This document describes the architectural elements that are used or referred to in HTTP, defines the "http" and "https" URI schemes, describes overall network operation and connection management, and defines HTTP message framing and forwarding requirements. Our goal is to define all of the mechanisms necessary for HTTP message handling that are independent of message semantics, thereby defining the complete set of requirements for message parsers and message forwarding intermediaries.
該文檔描述的架構(gòu)元素被 HTTP 使用或參考,定義了 “http” 和 “https” URL 結(jié)構(gòu),描述涵蓋整體網(wǎng)絡(luò)運算和連接管理,定義了 HTTP 消息結(jié)構(gòu)和轉(zhuǎn)發(fā)要求。我們的目標是為 HTTP 消息處理獨立的消息語義定義需要的所有機制,從而為消息解析和消息轉(zhuǎn)發(fā)中介定義了一整套完整的需求集合。