虽然教科书很多,但是通信协议等最原始的标准还是各种协议的spec
正好最近看了websocket HTTP Request-Response里一些值的含义和应用,查了下
供其他同学参考和自己memo

出处:http://tools.ietf.org/html/rfc6455#section-11.3.1

[size=1em]11.3.  Registration of New HTTP Header Fields[size=1em]11.3.1.  Sec-WebSocket-Key   This section describes a header field registered in the Permanent   Message Header Field Names registry [RFC3864].   Header field name      Sec-WebSocket-Key   Applicable protocol      http   Status      standard   Author/Change controller      IETF   Specification document(s)      RFC 6455   Related information      This header field is only used for WebSocket opening handshake.   The |Sec-WebSocket-Key| header field is used in the WebSocket opening   handshake.  It is sent from the client to the server to provide part   of the information used by the server to prove that it received a   valid WebSocket opening handshake.  This helps ensure that the server   does not accept connections from non-WebSocket clients (e.g., HTTP   clients) that are being abused to send data to unsuspecting WebSocket   servers.   The |Sec-WebSocket-Key| header field MUST NOT appear more than once   in an HTTP request.Fette & Melnikov             Standards Track                   [Page 57] RFC 6455                 The WebSocket Protocol            December 2011[size=1em]11.3.2.  Sec-WebSocket-Extensions   This section describes a header field for registration in the   Permanent Message Header Field Names registry [RFC3864].   Header field name      Sec-WebSocket-Extensions   Applicable protocol      http   Status      standard   Author/Change controller      IETF   Specification document(s)      RFC 6455   Related information      This header field is only used for WebSocket opening handshake.   The |Sec-WebSocket-Extensions| header field is used in the WebSocket   opening handshake.  It is initially sent from the client to the   server, and then subsequently sent from the server to the client, to   agree on a set of protocol-level extensions to use for the duration   of the connection.   The |Sec-WebSocket-Extensions| header field MAY appear multiple times   in an HTTP request (which is logically the same as a single   |Sec-WebSocket-Extensions| header field that contains all values.   However, the |Sec-WebSocket-Extensions| header field MUST NOT appear   more than once in an HTTP response.
共收到 4 条回复
WHUISS158 · #2 · 2014-4-14 20:32:58  回复 支持 反对
html5的websocket麼

点评

是的,新标准,很多浏览器还有代理还不能很少支持或者支持一部分功能  详情 回复 发表于 2014-4-14 21:02
admin · #3 · 2014-4-14 21:02:32  回复 支持 反对

是的,新标准,很多浏览器还有代理还不能完全支持全部功能比如IE10以上,chrome,firefox,safari才能用
只有firefox才支持basic或者digest认证等
还有rfc和draft76版本的区别等

点评

学长也是做前端开发的么  详情 回复 发表于 2014-4-15 00:04
WHUISS158 · #4 · 2014-4-15 00:04:59  回复 支持 反对
admin 发表于 2014-4-14 21:02
是的,新标准,很多浏览器还有代理还不能完全支持全部功能比如IE10以上,chrome,firefox,safari才能用
...

学长也是做前端开发的么

点评

最近做后端服务器,不做前端,前端只是用来做调试用罢了  详情 回复 发表于 2014-4-15 08:31
admin · #5 · 2014-4-15 08:31:56  回复 支持 反对
WHUISS158 发表于 2014-4-15 00:04
学长也是做前端开发的么

最近做后端服务器,不做前端,前端只是用来做调试用罢了
回帖
B Color Image Link Quote Code Smilies
Command + Enter
快速回复 返回顶部 返回列表