Software /
code /
prosody
Comparison
net/httpserver.lua @ 3540:bc139431830b
Monster whitespace commit (beware the whitespace monster).
author | Waqas Hussain <waqas20@gmail.com> |
---|---|
date | Sat, 16 Oct 2010 23:00:42 +0500 |
parent | 3497:e9159b325e33 |
child | 3757:e8be634e217a |
comparison
equal
deleted
inserted
replaced
3539:8bbd965267b2 | 3540:bc139431830b |
---|---|
29 module "httpserver" | 29 module "httpserver" |
30 | 30 |
31 local default_handler; | 31 local default_handler; |
32 | 32 |
33 local function expectbody(reqt) | 33 local function expectbody(reqt) |
34 return reqt.method == "POST"; | 34 return reqt.method == "POST"; |
35 end | 35 end |
36 | 36 |
37 local function send_response(request, response) | 37 local function send_response(request, response) |
38 -- Write status line | 38 -- Write status line |
39 local resp; | 39 local resp; |
210 ssl.mode = "server"; | 210 ssl.mode = "server"; |
211 ssl.protocol = "sslv23"; | 211 ssl.protocol = "sslv23"; |
212 ssl.options = "no_sslv2"; | 212 ssl.options = "no_sslv2"; |
213 end | 213 end |
214 | 214 |
215 new{ port = port, interface = interface, | 215 new{ port = port, interface = interface, |
216 base = base, handler = handle_request, | 216 base = base, handler = handle_request, |
217 ssl = ssl, type = (ssl and "ssl") or "tcp" }; | 217 ssl = ssl, type = (ssl and "ssl") or "tcp" }; |
218 end | 218 end |
219 end | 219 end |
220 | 220 |
221 _M.request_reader = request_reader; | 221 _M.request_reader = request_reader; |