JSGI: PATH_INFO/SCRIPT_NAME url-decoded?

2 views
Skip to first unread message

Kevin Dangoor

unread,
Sep 22, 2009, 11:51:22 AM9/22/09
to comm...@googlegroups.com
http://twitter.com/ianbicking/status/4166279789

"Did you know Jack and Rack don't even indicated if PATH_INFO/SCRIPT_NAME are url-decoded? They don't feel like real specs to me"

Kevin

--
Kevin Dangoor

work: http://labs.mozilla.com/
email: k...@blazingthings.com
blog: http://www.BlueSkyOnMars.com

Dean Landolt

unread,
Sep 22, 2009, 12:14:27 PM9/22/09
to comm...@googlegroups.com
On Tue, Sep 22, 2009 at 11:51 AM, Kevin Dangoor <kdan...@mozilla.com> wrote:
http://twitter.com/ianbicking/status/4166279789

"Did you know Jack and Rack don't even indicated if PATH_INFO/SCRIPT_NAME are url-decoded? They don't feel like real specs to me"

Woah there! Sure WSGI specified this -- they just got it totally wrong [1] :)

[1] http://www.wsgi.org/wsgi/WSGI_2.0#decoding-script-name-path-info -- originally added by Ian Bicking 01-24-2008

Unless someone beats me to it, I'll start compiling the comments from the few big JSGI threads into Level0/A and Level1/A proposals, with Level0/A being as close as possible to current JSGI while addressing any remaining problems, and Level1/A being the greatest hits from the many request object suggestions while remaining compatible with Level0/A-compliant middleware.

Tom Robinson

unread,
Sep 22, 2009, 2:59:03 PM9/22/09
to comm...@googlegroups.com
Yeah we've decided to specify that it should not be decoded, but I
guess it hasn't made it onto the public spec page yet.

Dean Landolt

unread,
Sep 22, 2009, 3:22:50 PM9/22/09
to comm...@googlegroups.com
On Tue, Sep 22, 2009 at 2:59 PM, Tom Robinson <tlrob...@gmail.com> wrote:

Yeah we've decided to specify that it should not be decoded, but I
guess it hasn't made it onto the public spec page yet.

Though Ash pointed out to me that CGI specifies PATH_INFO as decoded. WSGI proposed solution is a RAW_* set of keys for those variables that MUST be decoded. I'm finishing up a JSGI/Level0/A proposal that suggests env.pathInfo and env.scriptName MUST be decoded (per CGI and WSGI2.0) and an env.raw.pathInfo and env.raw.scriptName.

Also, it sounded like you were +0 on mixedCasing CGI vars as long as the names themselves remained the same. Is that still the case?
Reply all
Reply to author
Forward
0 new messages