Chinaunix首页 | 论坛 | 博客
  • 博客访问: 1764901
  • 博文数量: 184
  • 博客积分: 10122
  • 博客等级: 上将
  • 技术积分: 5566
  • 用 户 组: 普通用户
  • 注册时间: 2005-12-08 12:32
文章存档

2011年(1)

2008年(183)

我的朋友

分类: 系统运维

2008-03-16 23:22:25

Fielding, et al.            Standards Track                     [Page 1]

RFC 2616 HTTP/1.1 June 1999


Table of Contents

1 Introduction ...................................................7            介绍
1.1 Purpose......................................................7                目的
1.2 Requirements .................................................8                要求
1.3 Terminology ..................................................8                术语
1.4 Overall Operation ...........................................12                全部的操作类型
2 Notational Conventions and Generic Grammar ....................14            符号表示和通用语法    
2.1 Augmented BNF ...............................................14                增强的 BNF 语言
2.2 Basic Rules .................................................15                基本规则
3 Protocol Parameters ...........................................17            协议参数
3.1 HTTP Version ................................................17                HTTP 版本
3.2 Uniform Resource Identifiers ................................18                URI(统一资源标识符)
3.2.1 General Syntax ...........................................19                    一般语法
3.2.2 http URL .................................................19                    http URL
3.2.3 URI Comparison ...........................................20                    URI 比较
3.3 Date/Time Formats ...........................................20                日期/时间格式
3.3.1 Full Date ................................................20                    完整日期
3.3.2 Delta Seconds ............................................21                    Delta Seconds
3.4 Character Sets ..............................................21                字符集
3.4.1 Missing Charset ..........................................22                    Missing Charset
3.5 Content Codings .............................................23                内容编码    
3.6 Transfer Codings ............................................24                传输编码
3.6.1 Chunked Transfer Coding ..................................25                    分块传输编码
3.7 Media Types .................................................26                媒体类型
3.7.1 Canonicalization and Text Defaults .......................27                    Canonicalization and Text Defaults
3.7.2 Multipart Types ..........................................27                    Multipart Types
3.8 Product Tokens ..............................................28                产品 Token
3.9 Quality Values ..............................................29                品质值
3.10 Language Tags ...............................................29                语言标记
3.11 Entity Tags .................................................30                Entity 标记
3.12 Range Units .................................................30                范围单位
4 HTTP Message ..................................................31             HTTP 消息   
4.1 Message Types ...............................................31                消息类型
4.2 Message Headers .............................................31                消息头
4.3 Message Body ................................................32                消息主体
4.4 Message Length ..............................................33                消息长度
4.5 General Header Fields .......................................34                常用的 Header 字段
5 Request .......................................................35             请求   
5.1 Request-Line ................................................35                Request 字符串
5.1.1 Method ...................................................36                    Method
5.1.2 Request-URI ..............................................36                    Request-URI
5.2 The Resource Identified by a Request ........................38                一个请求所标识的资源
5.3 Request Header Fields .......................................38             响应   
6 Response ......................................................39             状态行
6.1 Status-Line .................................................39                状态代码和原因解释
6.1.1 Status Code and Reason Phrase ............................39                响应消息中的 header
6.2 Response Header Fields ......................................41



Fielding, et al. Standards Track [Page 2]

RFC 2616 HTTP/1.1 June 1999


7 Entity ........................................................42            实体
7.1 Entity Header Fields ........................................42                实体 Header 字段
7.2 Entity Body .................................................43                实体主体
7.2.1 Type .....................................................43                    类型
7.2.2 Entity Length ............................................43                    实体长度
8 Connections ...................................................44            连接    
8.1 Persistent Connections ......................................44                永久连接
8.1.1 Purpose ..................................................44                    目的
8.1.2 Overall Operation ........................................45                    全部操作
8.1.3 Proxy Servers ............................................46                    代理服务器    
8.1.4 Practical Considerations .................................46                    实际考虑
8.2 Message Transmission Requirements ...........................47                消息传输需求
8.2.1 Persistent Connections and Flow Control ..................47                    永久连接和流控
8.2.2 Monitoring Connections for Error Status Messages .........48                    通过错误状态消息监控连接
8.2.3 Use of the 100 (Continue) Status .........................48                    100 状态的使用
8.2.4 Client Behavior if Server Prematurely Closes Connection ..50                    客户端行为(如果服务器过早关闭连接)
9 Method Definitions ............................................51                消息定义
9.1 Safe and Idempotent Methods .................................51                    安全和有效的方法
9.1.1 Safe Methods .............................................51                        安全的方法
9.1.2 Idempotent Methods .......................................51                        有效的方法
9.2 OPTIONS .....................................................52                    选项
9.3 GET .........................................................53                    GET 方法
9.4 HEAD ........................................................54                    HEAD 方法
9.5 POST ........................................................54                    POST 方法
9.6 PUT .........................................................55                    PUT 方法
9.7 DELETE ......................................................56                    DELETE 方法
9.8 TRACE .......................................................56                    TRACE 方法
9.9 CONNECT .....................................................57                    CONNECT 方法
10 Status Code Definitions ......................................57               状态代码定义 
10.1 Informational 1xx ...........................................57                    信息 (1xx)
10.1.1 100 Continue .............................................58                        继续(100)
10.1.2 101 Switching Protocols ..................................58                        切换协议(101)
10.2 Successful 2xx ..............................................58                    成功(2xx)
10.2.1 200 OK ...................................................58                        OK(200)
10.2.2 201 Created ..............................................59                        已建立(202)
10.2.3 202 Accepted .............................................59                        已接受(202)
10.2.4 203 Non-Authoritative Information ........................59                        非权威信息(203)
10.2.5 204 No Content ...........................................60                        缺少内容(204)
10.2.6 205 Reset Content ........................................60                        内容重置(205)
10.2.7 206 Partial Content ......................................60                        部分内容(206)
10.3 Redirection 3xx .............................................61                    重定向(3xx)
10.3.1 300 Multiple Choices .....................................61                        多个选择(300)
10.3.2 301 Moved Permanently ....................................62                        永久移动(301)
10.3.3 302 Found ................................................62                        发现(302)
10.3.4 303 See Other ............................................63                        看其他(303)
10.3.5 304 Not Modified .........................................63                        未修改(304)
10.3.6 305 Use Proxy ............................................64                        使用代理(305)
10.3.7 306 (Unused) .............................................64                        保留(306)



Fielding, et al. Standards Track [Page 3]

RFC 2616 HTTP/1.1 June 1999


10.3.8 307 Temporary Redirect ...................................65                        临时移动(307)
10.4 Client Error 4xx ............................................65                    客户机错误(4xx)
10.4.1 400 Bad Request .........................................65                        无效请求 (400)
10.4.2 401 Unauthorized ........................................66                        认证失败(401)    
10.4.3 402 Payment Required ....................................66                        Payment required(402)    
10.4.4 403 Forbidden ...........................................66                        禁止访问(403)
10.4.5 404 Not Found ...........................................66                        文件不存在(404)
10.4.6 405 Method Not Allowed ..................................66                        方法被禁止(405)
10.4.7 406 Not Acceptable ......................................67                        不接受(406)
10.4.8 407 Proxy Authentication Required .......................67                        代理要求认证(407)
10.4.9 408 Request Timeout .....................................67                        请求超时(408)
10.4.10 409 Conflict ............................................67                        冲突(409)
10.4.11 410 Gone ................................................68                        页面被删除(410)
10.4.12 411 Length Required .....................................68                        需要指定长度(411)
10.4.13 412 Precondition Failed .................................68                        Precondition failed(412)
10.4.14 413 Request Entity Too Large ............................69                        请求实体太长(413)
10.4.15 414 Request-URI Too Long ................................69                        Request-URI 太长(414)
10.4.16 415 Unsupported Media Type ..............................69                        不被支持的媒体类型(415)
10.4.17 416 Requested Range Not Satisfiable .....................69                        请求的方位不安全(416)
10.4.18 417 Expectation Failed ..................................70                        Expectation failed(417)
10.5 Server Error 5xx ............................................70                    服务器错误(5xx)
10.5.1 500 Internal Server Error ................................70                        内部错误(500)
10.5.2 501 Not Implemented ......................................70                        功能未实现(501)
10.5.3 502 Bad Gateway ..........................................70                        网关错误(502)
10.5.4 503 Service Unavailable ..................................70                        服务不可用(503)
10.5.5 504 Gateway Timeout ......................................71                        网关连接超时(504)
10.5.6 505 HTTP Version Not Supported ...........................71                        HTTP 版本不支持(505)
11 Access Authentication ........................................71                访问认证                    
12 Content Negotiation ..........................................71                内容协商     

12.1 Server-driven Negotiation ...................................72                    服务器端驱动的协商
12.2 Agent-driven Negotiation ....................................73                    浏览器驱动的协商
12.3 Transparent Negotiation .....................................74                    透明协商
13 Caching in HTTP ..............................................74                HTTP 缓存    
13.1.1 Cache Correctness ........................................75                    缓存(内容)的正确性
13.1.2 Warnings .................................................76                    警告
13.1.3 Cache-control Mechanisms .................................77                    缓存控制方案
13.1.4 Explicit User Agent Warnings .............................78                    明确指定 User Agent 告警
13.1.5 Exceptions to the Rules and Warnings .....................78                    例外的规则和告警
13.1.6 Client-controlled Behavior ...............................79                    客户端控制的行为
13.2 Expiration Model ............................................79                超时模型
13.2.1 Server-Specified Expiration ..............................79                    服务器相关的超时
13.2.2 Heuristic Expiration .....................................80                    启发式超时
13.2.3 Age Calculations .........................................80                    缓存内容有效期计算    
13.2.4 Expiration Calculations ..................................83                    超时计算
13.2.5 Disambiguating Expiration Values .........................84                    Disambiguating Expiration Values    
13.2.6 Disambiguating Multiple Responses ........................84                    Disambiguating Multiple Responses
13.3 Validation Model ............................................85                有效模型
13.3.1 Last-Modified Dates ......................................86                    最后修改日期



Fielding, et al. Standards Track [Page 4]

RFC 2616 HTTP/1.1 June 1999


13.3.2 Entity Tag Cache Validators ..............................86                    实体标记缓存
13.3.3 Weak and Strong Validators ...............................86                    Weak and Strong validators
13.3.4 Rules for When to Use Entity Tags and Last-Modified Dates.89                    何时使用实体标记和最后修改日期的规则
13.3.5 Non-validating Conditionals ..............................90                    Non-validating 条件
13.4 Response Cacheability .......................................91                响应缓存    
13.5 Constructing Responses From Caches ..........................92                使用缓存构建响应
13.5.1 End-to-end and Hop-by-hop Headers ........................92                    端到端和 hop-by-hop headers
13.5.2 Non-modifiable Headers ...................................92                    Non-modifiable headers
13.5.3 Combining Headers ........................................94                    组合 header
13.5.4 Combining Byte Ranges ....................................95                    组合 Byte ranges
13.6 Caching Negotiated Responses ................................95                缓存协商响应
13.7 Shared and Non-Shared Caches ................................96                共享和非共享缓存    
13.8 Errors or Incomplete Response Cache Behavior ................97                错误和不完全响应缓存行为
13.9 Side Effects of GET and HEAD ................................97                GET、HEAD 的副作用
13.10 Invalidation After Updates or Deletions ...................97                更新或者删除后的 invalidation
13.11 Write-Through Mandatory ...................................98                强制 Write-through
13.12 Cache Replacement .........................................99                缓存替换
13.13 History Lists .............................................99                历史列表
14 Header Field Definitions ....................................100            header 字段定义
14.1 Accept .....................................................100                Accept
14.2 Accept-Charset .............................................102                Accept-Charset
14.3 Accept-Encoding ............................................102                Accept-Encoding
14.4 Accept-Language ............................................104                Accept-Language
14.5 Accept-Ranges ..............................................105                Accept-Range
14.6 Age ........................................................106                Age
14.7 Allow ......................................................106                Allow
14.8 Authorization ..............................................107                Authorization
14.9 Cache-Control ..............................................108                Cache-Control
14.9.1 What is Cacheable .......................................109                    什么是可缓存的
14.9.2 What May be Stored by Caches ............................110                    那些应该被缓存
14.9.3 Modifications of the Basic Expiration Mechanism .........111                    基础超时方案的修改
14.9.4 Cache Revalidation and Reload Controls ..................113                    缓存 revalidation 和 reload 控制
14.9.5 No-Transform Directive ..................................115                    No-Transform 指令
14.9.6 Cache Control Extensions ................................116                    缓存控制扩展
14.10 Connection ...............................................117                连接
14.11 Content-Encoding .........................................118                Content-Encoding
14.12 Content-Language .........................................118                Content-Language
14.13 Content-Length ...........................................119                Content-Language    
14.14 Content-Location .........................................120                Content-Location
14.15 Content-MD5 ..............................................121                Content-MD5
14.16 Content-Range ............................................122                Content-Range
14.17 Content-Type .............................................124                Content-Type
14.18 Date .....................................................124                Date
14.18.1 Clockless Origin Server Operation ......................125                    无时钟的原始服务器操作
14.19 ETag .....................................................126                ETag
14.20 Expect ...................................................126                Expect
14.21 Expires ..................................................127                Expires
14.22 From .....................................................128                From



Fielding, et al. Standards Track [Page 5]

RFC 2616 HTTP/1.1 June 1999


14.23 Host .....................................................128                Host
14.24 If-Match .................................................129                If-Match
14.25 If-Modified-Since ........................................130                If-Modified-Since
14.26 If-None-Match ............................................132                If-None-Match
14.27 If-Range .................................................133                If-Range
14.28 If-Unmodified-Since ......................................134                If-Unmodified-Since
14.29 Last-Modified ............................................134                Last-Modified
14.30 Location .................................................135                Location
14.31 Max-Forwards .............................................136                Max-Forwards
14.32 Pragma ...................................................136                Pragma
14.33 Proxy-Authenticate .......................................137                Proxy-Authenticate
14.34 Proxy-Authorization ......................................137                Proxy-Authorization
14.35 Range ....................................................138                Range
14.35.1 Byte Ranges ...........................................138                    Byte Ranges
14.35.2 Range Retrieval Requests ..............................139                    Range Retrieval Requests
14.36 Referer ..................................................140                Referer
14.37 Retry-After ..............................................141                Retry-After
14.38 Server ...................................................141                Server
14.39 TE .......................................................142                TE
14.40 Trailer ..................................................143                Trailer
14.41 Transfer-Encoding..........................................143                Transfer-Encoding
14.42 Upgrade ..................................................144                Upgrade
14.43 User-Agent ...............................................145                User-Agent
14.44 Vary .....................................................145                Vary
14.45 Via ......................................................146                Via    
14.46 Warning ..................................................148                Warning
14.47 WWW-Authenticate .........................................150                WWW-Authenticate
15 Security Considerations .......................................150            安全考虑                
15.1 Personal Information....................................151                个人信息
15.1.1 Abuse of Server Log Information .........................151                    服务器日志信息的安全
15.1.2 Transfer of Sensitive Information .......................151                    敏感信息的传输
15.1.3 Encoding Sensitive Information in URI's .................152                    URI 中的敏感信息的编码
15.1.4 Privacy Issues Connected to Accept Headers ..............152                    隐私问题
15.2 Attacks Based On File and Path Names .......................153                基于文件和路径名的攻击    
15.3 DNS Spoofing ...............................................154                DNS 欺骗
15.4 Location Headers and Spoofing ..............................154                Location header 和欺骗
15.5 Content-Disposition Issues .................................154                内容泄露问题    
15.6 Authentication Credentials and Idle Clients ................155                认证凭证和空闲客户
15.7 Proxies and Caching ........................................155                代理和缓存
15.7.1 Denial of Service Attacks on Proxies....................156                    针对代理的DoS 攻击
16 Acknowledgments .............................................156                感谢    
17 References ..................................................158                参考
18 Authors' Addresses ..........................................162                作者地址
19 Appendices ..................................................164                附录
19.1 Internet Media Type message/http and application/http ......164                    Internet 媒体类型(message/http 和 application/http)
19.2 Internet Media Type multipart/byteranges ...................165                    Internet 媒体类型 Multipart/byteranges
19.3 Tolerant Applications ......................................166                    Tolerant 应用
19.4 Differences Between HTTP Entities and RFC 2045 Entities ....167                    HTTP 实体和 RFC 2045 实体的区别



Fielding, et al. Standards Track [Page 6]

RFC 2616 HTTP/1.1 June 1999


19.4.1 MIME-Version ............................................167                        MIME 版本
19.4.2 Conversion to Canonical Form ............................167                        到 Canonical 格式的转换
19.4.3 Conversion of Date Formats ..............................168                        日志格式的转换
19.4.4 Introduction of Content-Encoding ........................168                        Content-Encoding 的介绍
19.4.5 No Content-Transfer-Encoding ............................168                        No Content-Transfer-Encoding    
19.4.6 Introduction of Transfer-Encoding .......................169                        Transfer-Encoding 的介绍
19.4.7 MHTML and Line Length Limitations .......................169                        MHTML 和每行长度的限制
19.5 Additional Features ........................................169                    其他的属性
19.5.1 Content-Disposition .....................................170                        Content0Dispostition
19.6 Compatibility with Previous Versions .......................170                    与上一个版本的兼容性
19.6.1 Changes from HTTP/1.0 ...................................171                        相比 HTTP/1.0 的改变
19.6.2 Compatibility with HTTP/1.0 Persistent Connections ......172                        兼容 HTTP/1.0 的永久连接
19.6.3 Changes from RFC 2068 ...................................172                        相比 RFC 2068 的改动
20 Index .......................................................175                    索引
21 Full Copyright Statement ....................................176




阅读(8941) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~