RubySpec #3692
URI should escape or parse [ and ]
| Status: | Rejected | Start date: | 08/14/2010 | |
|---|---|---|---|---|
| Priority: | Normal | Due date: | ||
| Assignee: | - | % Done: | 0% |
|
| Category: | - | |||
| Target version: | - |
Description
This fails:
URI.parse( URI.escape("http://example.com/some[1].jpg") )
It raises URI::InvalidURIError
It should either parse or escape the brackets.
I know they are considered to be "unsafe". It doesn't matter. Some web pages use them and the Ruby libraries should be able to parse data in the field.
The alternative is to write additional escaping code anywhere one uses URI.escape because it is inadequate.
History
Updated by naruse (Yui NARUSE) almost 2 years ago
- Status changed from Open to Rejected
URI.escape is not for this use case. See also Bug #3457.