X-Git-Url: https://git.archive.openwrt.org/?p=project%2Fluci.git;a=blobdiff_plain;f=libs%2Fhttp%2Fluasrc%2Fhttp%2Fprotocol.lua;h=d8ef09f7ae36ebf6326d3777c3472835c921828a;hp=e0c15015b28890330406210cc22d47d52a7aff80;hb=b33943a6e8596c1ddfc1b771a995d3cf21e81cd6;hpb=0ba0030745c3c23a3343484341575e127fb483f3 diff --git a/libs/http/luasrc/http/protocol.lua b/libs/http/luasrc/http/protocol.lua index e0c15015b..d8ef09f7a 100644 --- a/libs/http/luasrc/http/protocol.lua +++ b/libs/http/luasrc/http/protocol.lua @@ -248,7 +248,7 @@ process_states['headers'] = function( msg, chunk ) if chunk ~= nil then -- Look for a valid header format - local hdr, val = chunk:match( "^([A-Z][A-Za-z0-9%-_]+): +(.+)$" ) + local hdr, val = chunk:match( "^([A-Za-z][A-Za-z0-9%-_]+): +(.+)$" ) if type(hdr) == "string" and hdr:len() > 0 and type(val) == "string" and val:len() > 0 @@ -673,6 +673,7 @@ end -- @class table statusmsg = { [200] = "OK", + [206] = "Partial Content", [301] = "Moved Permanently", [302] = "Found", [304] = "Not Modified", @@ -680,8 +681,10 @@ statusmsg = { [403] = "Forbidden", [404] = "Not Found", [405] = "Method Not Allowed", + [408] = "Request Time-out", [411] = "Length Required", [412] = "Precondition Failed", + [416] = "Requested range not satisfiable", [500] = "Internal Server Error", [503] = "Server Unavailable", }