From 3ab5be34767e6ad85392a212e93632c0c4f22a8e Mon Sep 17 00:00:00 2001 From: shyouhei Date: Sat, 14 Feb 2009 19:17:52 +0000 Subject: merge revision(s) 20246: * lib/webrick/httprequest.rb (WEBrick::HTTPRequest#read_request_line): use non-greedy match for path retrieval to avoid huge recursion for insanely long path. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_7@22311 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 6 ++++++ lib/webrick/httprequest.rb | 2 +- version.h | 8 ++++---- 3 files changed, 11 insertions(+), 5 deletions(-) diff --git a/ChangeLog b/ChangeLog index febab9e135..8bfda55558 100644 --- a/ChangeLog +++ b/ChangeLog @@ -3,6 +3,12 @@ Fri Feb 13 19:18:42 2009 Nobuyoshi Nakada * lib/logger.rb (ProgName): fixed for svn, based on a patch from Nobuhiro IMAI at [ruby-dev:37108]. +Sun Feb 15 04:17:40 2009 Yukihiro Matsumoto + + * lib/webrick/httprequest.rb (WEBrick::HTTPRequest#read_request_line): + use non-greedy match for path retrieval to avoid huge recursion + for insanely long path. + Fri Feb 13 19:04:54 2009 Keiju Ishitsuka * shell/command-processor.rb: undefined method `top_level_test' in diff --git a/lib/webrick/httprequest.rb b/lib/webrick/httprequest.rb index 1d32293a27..4021259072 100644 --- a/lib/webrick/httprequest.rb +++ b/lib/webrick/httprequest.rb @@ -225,7 +225,7 @@ module WEBrick @request_line = read_line(socket) if socket @request_time = Time.now raise HTTPStatus::EOFError unless @request_line - if /^(\S+)\s+(\S+)(?:\s+HTTP\/(\d+\.\d+))?\r?\n/mo =~ @request_line + if /^(\S+)\s+(\S+?)(?:\s+HTTP\/(\d+\.\d+))?\r?\n/mo =~ @request_line @request_method = $1 @unparsed_uri = $2 @http_version = HTTPVersion.new($3 ? $3 : "0.9") diff --git a/version.h b/version.h index 4b4babb75f..bda68d50fc 100644 --- a/version.h +++ b/version.h @@ -1,15 +1,15 @@ #define RUBY_VERSION "1.8.7" -#define RUBY_RELEASE_DATE "2009-02-13" +#define RUBY_RELEASE_DATE "2009-02-15" #define RUBY_VERSION_CODE 187 -#define RUBY_RELEASE_CODE 20090213 -#define RUBY_PATCHLEVEL 116 +#define RUBY_RELEASE_CODE 20090215 +#define RUBY_PATCHLEVEL 117 #define RUBY_VERSION_MAJOR 1 #define RUBY_VERSION_MINOR 8 #define RUBY_VERSION_TEENY 7 #define RUBY_RELEASE_YEAR 2009 #define RUBY_RELEASE_MONTH 2 -#define RUBY_RELEASE_DAY 13 +#define RUBY_RELEASE_DAY 15 #ifdef RUBY_EXTERN RUBY_EXTERN const char ruby_version[]; -- cgit v1.2.3