WEBrick: prevent response splitting and header injection
authorYusuke Endoh <mame@ruby-lang.org>
Tue, 1 Oct 2019 03:29:18 +0000 (12:29 +0900)
committerUtkarsh Gupta <utkarsh@debian.org>
Thu, 1 Oct 2020 13:24:55 +0000 (14:24 +0100)
commitf503a30b333a6e43bde61f9234ed7b500326cf93
tree2aab4d5221a35e66d4b011256def41f954d7f051
parent07f6aa866e0399fcdc6045d3f55626c517313622
WEBrick: prevent response splitting and header injection

Origin: https://github.com/ruby/ruby/commit/3ce238b5f9795581eb84114dcfbdf4aa086bfecc
Bug-Debian-Security: https://security-tracker.debian.org/tracker/CVE-2019-16254

This is a follow up to d9d4a28f1cdd05a0e8dabb36d747d40bbcc30f16.
The commit prevented CRLR, but did not address an isolated CR or an
isolated LF.

Co-Authored-By: NARUSE, Yui <naruse@airemix.jp>
[Salvatore Bonaccorso: Backport to 2.3.3:
 - Context changes in test/webrick/test_httpresponse.rb
]

Gbp-Pq: Name WEBrick-prevent-response-splitting-and-header-inject.patch
lib/webrick/httpresponse.rb
test/webrick/test_httpresponse.rb