diff options
| -rw-r--r-- | ChangeLog | 5 | ||||
| -rw-r--r-- | lib/webrick/httputils.rb | 2 |
2 files changed, 6 insertions, 1 deletions
@@ -1,3 +1,8 @@ +Wed Jun 17 07:44:27 2009 NARUSE, Yui <naruse@ruby-lang.org> + + * lib/webrick/httputils.rb (parse_form_data): escape boundary of + multipart/form-data when embed in regexp. + Tue Jun 16 22:23:00 2009 Nobuyoshi Nakada <nobu@ruby-lang.org> * io.c (rb_io_open), math.c (domain_check), object.c (boot_defclass): diff --git a/lib/webrick/httputils.rb b/lib/webrick/httputils.rb index 976d3e915e..c5e847fcb2 100644 --- a/lib/webrick/httputils.rb +++ b/lib/webrick/httputils.rb @@ -304,7 +304,7 @@ module WEBrick module_function :parse_query def parse_form_data(io, boundary) - boundary_regexp = /\A--#{boundary}(--)?#{CRLF}\z/ + boundary_regexp = /\A--#{Regexp.quote(boundary)}(--)?#{CRLF}\z/ form_data = Hash.new return form_data unless io data = nil |
