/lists.whatwg.org/pipermail/whatwg-whatwg.org/2010-April/025757.html

https://github.com/whatwg/whatwg.org · HTML · 113 lines · 85 code · 21 blank · 7 comment · 0 complexity · 3ef099fc7b57396f3c87a0ed53c21da8 MD5 · raw file

  1. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
  2. <HTML>
  3. <HEAD>
  4. <TITLE> [whatwg] some comments on establish a WebSocket connection
  5. </TITLE>
  6. <LINK REL="Index" HREF="index.html" >
  7. <LINK REL="made" HREF="mailto:whatwg%40lists.whatwg.org?Subject=Re%3A%20%5Bwhatwg%5D%20some%20comments%20on%20establish%20a%20WebSocket%20connection&In-Reply-To=%3Cop.vag4qdijidj3kv%40simon-pieterss-macbook.local%3E">
  8. <META NAME="robots" CONTENT="index,nofollow">
  9. <META http-equiv="Content-Type" content="text/html; charset=us-ascii">
  10. <LINK REL="Previous" HREF="025759.html">
  11. <LINK REL="Next" HREF="025760.html">
  12. </HEAD>
  13. <BODY BGCOLOR="#ffffff">
  14. <H1>[whatwg] some comments on establish a WebSocket connection</H1>
  15. <!--htdig_noindex-->
  16. <B>Simon Pieters</B>
  17. <A HREF="mailto:whatwg%40lists.whatwg.org?Subject=Re%3A%20%5Bwhatwg%5D%20some%20comments%20on%20establish%20a%20WebSocket%20connection&In-Reply-To=%3Cop.vag4qdijidj3kv%40simon-pieterss-macbook.local%3E"
  18. TITLE="[whatwg] some comments on establish a WebSocket connection">simonp at opera.com
  19. </A><BR>
  20. <I>Thu Apr 1 02:04:51 PDT 2010</I>
  21. <P><UL>
  22. <LI>Previous message: <A HREF="025759.html">[whatwg] WebSocket bufferedAmount includes overhead or not
  23. </A></li>
  24. <LI>Next message: <A HREF="025760.html">[whatwg] Character encoding of document.open()ed documents
  25. </A></li>
  26. <LI> <B>Messages sorted by:</B>
  27. <a href="date.html#25757">[ date ]</a>
  28. <a href="thread.html#25757">[ thread ]</a>
  29. <a href="subject.html#25757">[ subject ]</a>
  30. <a href="author.html#25757">[ author ]</a>
  31. </LI>
  32. </UL>
  33. <HR>
  34. <!--/htdig_noindex-->
  35. <!--beginarticle-->
  36. <PRE>The establish a WebSocket connection algorithm says:
  37. [[
  38. 35. ...
  39. &#8618;If the byte is 0x20 (ASCII space)
  40. Ignore the byte and move on to the next step.
  41. Otherwise
  42. Treat the byte as described by the list in the next step, then move on to
  43. that next step for real.
  44. Note: This skips past a space character after the colon, if necessary.
  45. 36. Read a byte from the server.
  46. If the connection closes before this byte is received, then fail the
  47. WebSocket connection and abort these steps.
  48. Otherwise, handle the byte as described in the appropriate entry below:
  49. &#8618;If the byte is 0x0D (ASCII CR)
  50. Move on to the next step.
  51. ]]
  52. Consider the case when the server gives a colon followed by CR. My reading
  53. is that step 36 will be run twice:
  54. Upon receiving the CR in step 35, &quot;Treat the byte as described by the list
  55. in the next step&quot; which is &quot;Move on to the next step.&quot; (i.e. step 37),
  56. &quot;then move on to that next step for real.&quot; (i.e. step 36).
  57. Step 41 says:
  58. [[
  59. If the entry's name is &quot;set-cookie&quot; or &quot;set-cookie2&quot; or another
  60. cookie-related field name
  61. If the relevant specification is supported by the user agent, handle the
  62. cookie as defined by the appropriate specification, with the resource
  63. being the one with the host host, the port port, the path (and possibly
  64. query parameters) resource name, and the scheme http if secure is false
  65. and https if secure is true. [COOKIES]
  66. ]]
  67. What should be done if the relevant specification is not supported?
  68. --
  69. Simon Pieters
  70. Opera Software
  71. </PRE>
  72. <!--endarticle-->
  73. <!--htdig_noindex-->
  74. <HR>
  75. <P><UL>
  76. <!--threads-->
  77. <LI>Previous message: <A HREF="025759.html">[whatwg] WebSocket bufferedAmount includes overhead or not
  78. </A></li>
  79. <LI>Next message: <A HREF="025760.html">[whatwg] Character encoding of document.open()ed documents
  80. </A></li>
  81. <LI> <B>Messages sorted by:</B>
  82. <a href="date.html#25757">[ date ]</a>
  83. <a href="thread.html#25757">[ thread ]</a>
  84. <a href="subject.html#25757">[ subject ]</a>
  85. <a href="author.html#25757">[ author ]</a>
  86. </LI>
  87. </UL>
  88. <hr>
  89. <a href="http://lists.whatwg.org/listinfo.cgi/whatwg-whatwg.org">More information about the whatwg
  90. mailing list</a><br>
  91. <!--/htdig_noindex-->
  92. </body></html>