Overview
| Artifact ID: | 75a56fd2056e2bfa2ca5aee042b6ec2e5d127468 |
|---|---|
| Ticket: | 921072ffffffffffffffffffffffffffffffffff
Regexp misparses some URL |
| User & Date: | nobody on 2004-03-22 15:35:40 |
Changes
- assignee changed to: "hobbs"
- cmimetype changed to: "text/plain"
- comment changed to:
A URL of the form http://foo.com/@bar.com/url.ext is misparsed with the host being bar.com instead of foo.com. The problem is an attempt to parse [email protected] type URL This code is where it happens: set exp {^(([^:]*)://)?([^@]+@)?([^/:]+)(:([0-9]+))?(/.*)?$} if {![regexp -nocase $exp $url x prefix proto user host y port srvurl]} { This modification (adding a / to the unrecognzed characters as part of a "name@" field) solves the problem. set exp {^(([^:]*)://)?([^@/]+@)?([^/:]+)(:([0-9]+))?(/.*)?$} if {![regexp -nocase $exp $url x prefix proto user host y port srvurl]} { Submitted by [email protected]
- foundin changed to: "obsolete: 8.4.6"
- priority changed to: "5 Medium"
- resolution changed to: "None"
- status changed to: "Open"
- submitter changed to: "nobody"
- subsystem changed to: "29. http Package"
- title changed to: "Regexp misparses some URL"
- type changed to: "Bug"