mirror of
https://github.com/ninenines/cowboy.git
synced 2025-07-14 04:10:24 +00:00
Fix cowboy_req:filter_cookies missing valid cookies
When 3 or more cookies were sent the extra cookies were not found because the binary:split on ";" stopped at the first occurrence.
This commit is contained in:
parent
8e121d138c
commit
36f42a5e8b
2 changed files with 2 additions and 2 deletions
|
@ -324,7 +324,7 @@ filter_then_parse_cookies(Config) ->
|
|||
[{<<"cookie">>, "bad name=strawberry"}], Config),
|
||||
<<"[{<<\"cake\">>,<<\"strawberry\">>}]">>
|
||||
= do_get_body("/filter_then_parse_cookies",
|
||||
[{<<"cookie">>, "bad name=strawberry; cake=strawberry"}], Config),
|
||||
[{<<"cookie">>, "bad name=strawberry; another bad name=strawberry; cake=strawberry"}], Config),
|
||||
<<"[]">>
|
||||
= do_get_body("/filter_then_parse_cookies",
|
||||
[{<<"cookie">>, "Blocked by http://www.example.com/upgrade-to-remove"}], Config),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue