diff options
Diffstat (limited to 'doc/http.html')
-rw-r--r-- | doc/http.html | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/doc/http.html b/doc/http.html index a274aef..66282a4 100644 --- a/doc/http.html +++ b/doc/http.html | |||
@@ -45,8 +45,7 @@ namespace offers full support for the client side of the HTTP | |||
45 | protocol (i.e., | 45 | protocol (i.e., |
46 | the facilities that would be used by a web-browser implementation). The | 46 | the facilities that would be used by a web-browser implementation). The |
47 | implementation conforms to the HTTP/1.1 standard, | 47 | implementation conforms to the HTTP/1.1 standard, |
48 | <a href="http://www.cs.princeton.edu/~diego/rfc/rfc2616.txt">RFC | 48 | <a href="http://www.ietf.org/rfc/rfc2616.txt">RFC 2616</a>. |
49 | 2616</a>. | ||
50 | </p> | 49 | </p> |
51 | 50 | ||
52 | <p> | 51 | <p> |
@@ -67,8 +66,7 @@ local http = require("socket.http") | |||
67 | 66 | ||
68 | <p> | 67 | <p> |
69 | URLs must conform to | 68 | URLs must conform to |
70 | <a href="http://www.cs.princeton.edu/~diego/rfc/rfc1738.txt">RFC | 69 | <a href="http://www.ietf.org/rfc/rfc1738.txt">RFC 1738</a>, |
71 | 1738</a>, | ||
72 | that is, an URL is a string in the form: | 70 | that is, an URL is a string in the form: |
73 | </p> | 71 | </p> |
74 | 72 | ||
@@ -199,8 +197,7 @@ it usually returns a message body (a web page informing the | |||
199 | URL was not found or some other useless page). To make sure the | 197 | URL was not found or some other useless page). To make sure the |
200 | operation was successful, check the returned status <tt>code</tt>. For | 198 | operation was successful, check the returned status <tt>code</tt>. For |
201 | a list of the possible values and their meanings, refer to <a | 199 | a list of the possible values and their meanings, refer to <a |
202 | href="http://www.cs.princeton.edu/~diego/rfc/rfc2616.txt">RFC | 200 | href="http://www.ietf.org/rfc/rfc2616.txt">RFC 2616</a>. |
203 | 2616</a>. | ||
204 | </p> | 201 | </p> |
205 | 202 | ||
206 | <p class=description> | 203 | <p class=description> |
@@ -278,7 +275,7 @@ download and return status "401 Authentication Required". | |||
278 | The HTTP/1.1 standard defines two authentication methods: the Basic | 275 | The HTTP/1.1 standard defines two authentication methods: the Basic |
279 | Authentication Scheme and the Digest Authentication Scheme, both | 276 | Authentication Scheme and the Digest Authentication Scheme, both |
280 | explained in detail in | 277 | explained in detail in |
281 | <a href="http://www.cs.princeton.edu/~diego/rfc/rfc2068.txt">RFC 2068</a>. | 278 | <a href="http://www.ietf.org/rfc/rfc2068.txt">RFC 2068</a>. |
282 | </p> | 279 | </p> |
283 | 280 | ||
284 | <p class=note>The Basic Authentication Scheme sends | 281 | <p class=note>The Basic Authentication Scheme sends |
@@ -304,7 +301,7 @@ b, c, h = http.request("http://fulano:silva@www.example.com/private/index.html") | |||
304 | -- the request directly. | 301 | -- the request directly. |
305 | r, c = http.request { | 302 | r, c = http.request { |
306 | url = "http://www.example.com/private/index.html", | 303 | url = "http://www.example.com/private/index.html", |
307 | headers = { authentication = "Basic " .. (mime.b64("fulano:silva")) } | 304 | headers = { authorization = "Basic " .. (mime.b64("fulano:silva")) } |
308 | } | 305 | } |
309 | </pre> | 306 | </pre> |
310 | 307 | ||