I tested the regex with 1.8.7, 1.9.2, and JRuby 1.6.1.  All seem to hang and show the same behavior you see with REE.  Seems to be an issue with Ruby's regex engine on all distros.  FWIW, out of curiosity I ran the same regex in Perl, which handled it quickly and correctly.

Chris

On Tue, Jul 12, 2011 at 7:28 PM, John Nunemaker <nunemaker@gmail.com> wrote:
Posted the REE issue to the REE google group as well:
https://groups.google.com/forum/#!topic/emm-ruby/EBkMfFpk40A

The regex used on line 61 in rack/backports/uri/common.rb causes REE to hang for certain strings. I only know because it happened in production over and over the past week and today, with help, I was finally able to track it down.

Not sure if this is really an issue with Rack or just with REE, but it will affect anyone using Rack 1.3.0 and REE so I thought I would mention it here as well.