Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

This project is archived and is in readonly mode.

Wrong parsing paremeters with a semilocon ( ; ) char

#4227

When I post some parameter to any controller in my app ( rails 2.3.5 ) something like this:

name=Alexander;Cabezas

I get this:

{"html"=>"Alexander", "Cabezas"=>nil}

Apparently, it isn't parsing well the parameters with semicolon character on it.

Any thoughts?

Reported by Alexander C · March 19th, 2010 @ 12:08 AM

State: invalid
Milestone: 3.0.2
Assigned to: Yehuda Katz (wycats) Yehuda Katz (wycats)
Importance: Low

Activity

  1. Yehuda Katz (wycats)
    Yehuda Katz (wycats)
    • State changed from new to invalid
    • Tag changed from rails 2.3.5 parameter parsing bug to rack
    • Assigned user set to Yehuda Katz (wycats)
    • Milestone cleared.

    This is an issue with Rack's parameter parsing. While it's legal for them to treat ; as a separator, it's probably a poor choice:

    The problem is in rack/utils.rb:29

    DEFAULT_SEP = /[&;] */n
    

    March 29th, 2010 @ 07:03 AM

  2. Andrew White
    Andrew White

    Whether it's a poor choice is open for debate but it is a W3C recommendation that the semicolon is supported as a parameter separator:

    http://www.w3.org/TR/html4/appendix/notes.html#h-B.2.2

    March 29th, 2010 @ 10:20 AM

  3. Jeremy Kemper
    Jeremy Kemper
    • Milestone set to 3.0.2
    • Importance changed from to Low

    October 15th, 2010 @ 11:01 PM