diff --git a/nselib/http.lua b/nselib/http.lua index f9dbd3498..c40ab474c 100644 --- a/nselib/http.lua +++ b/nselib/http.lua @@ -778,8 +778,10 @@ parse_set_cookie = function (s) -- Loop over the attributes. while s:sub(pos, pos) == ";" do - pos = pos + 1 - pos = skip_space(s, pos) + -- Skip over empty attributes + repeat + pos = skip_space(s, pos + 1) + until s:sub(pos, pos) ~= ";" if pos > #s then break end