Re: normalizing a URI with ..'s in it ?

2003-07-24 Thread Michael Becke
On Thursday, July 24, 2003, at 06:19 AM, Marcus Crafter wrote: From a users perspective it would be great if the method explicitly notified the user if this kind of input was invalid - but if that's inconsistent with current behaviour across the client I'd be happy with it being in the javadocs :

Re: normalizing a URI with ..'s in it ?

2003-07-24 Thread Michael Becke
I am not positive how this process is being worked out by I would suggest sending a message to [EMAIL PROTECTED] or to Ron Fielding. Mike On Thursday, July 24, 2003, at 06:16 AM, Mike Moran wrote: Michael Becke wrote: On Wednesday, July 23, 2003, at 06:18 PM, Mike Moran wrote: [Oleg agreed] Rig

Re: normalizing a URI with ..'s in it ?

2003-07-24 Thread Marcus Crafter
Hi All, Thanks for everyone's feedback on the subject. Much appreciated. >From a users perspective it would be great if the method explicitly notified the user if this kind of input was invalid - but if that's inconsistent with current behaviour across the client I'd be happy with it being in

Re: normalizing a URI with ..'s in it ?

2003-07-24 Thread Mike Moran
Michael Becke wrote: On Wednesday, July 23, 2003, at 06:18 PM, Mike Moran wrote: [Oleg agreed] Right. Out of interest, which set of test cases does the URI class use, the ones from rfc2396 or rfc2396bis? The tests are from rfc2396bis. This is verging rapidly off-topic, but I was wondering if yo

Re: normalizing a URI with ..'s in it ?

2003-07-23 Thread Michael Becke
On Wednesday, July 23, 2003, at 06:18 PM, Mike Moran wrote: [Oleg agreed] Right. Out of interest, which set of test cases does the URI class use, the ones from rfc2396 or rfc2396bis? The tests are from rfc2396bis. I would agree. Doesn't this mean that normalize() should thrown an exception if it

Re: normalizing a URI with ..'s in it ?

2003-07-23 Thread Mike Moran
On Wednesday, Jul 23, 2003, at 20:37 Europe/London, Michael Becke wrote: Mike Moran wrote: Btw, I presume this is the algorithm given in section 5.2 of http://www.apache.org/~fielding/uri/rev-2002/ rfc2396bis.html#absolutize? If so, this is just a draft (draft-fielding-uri-rfc2396bis-03.txt)

Re: normalizing a URI with ..'s in it ?

2003-07-23 Thread Oleg Kalnichevski
> Yes, this is the algorithm. We decided to upgrade to ensure that URI > parsing was consistent across Apache. I think this was at the request > of Roy Fielding. Oleg, is that correct? > This is correct. Oleg - To unsubs

Re: normalizing a URI with ..'s in it ?

2003-07-23 Thread Michael Becke
Mike Moran wrote: Btw, I presume this is the algorithm given in section 5.2 of http://www.apache.org/~fielding/uri/rev-2002/rfc2396bis.html#absolutize? If so, this is just a draft (draft-fielding-uri-rfc2396bis-03.txt). It does actually differ from rfc2396 in how it handles abnormal URLs (thou

Re: normalizing a URI with ..'s in it ?

2003-07-23 Thread Mike Moran
Michael Becke wrote: Though I agree this seems a little strange I am not sure it's a bug. URI.normalize() is using the algorithm defined at which corresponds to the latest update(I believe) to rfc2396. [ removed algorithm ] Btw, I pre

Re: normalizing a URI with ..'s in it ?

2003-07-23 Thread Michael Becke
2, 3 and 4 are ignored # rule 5 is applied once and "/relative/../" is replaced with "/" buffer = "my/../another/relative" # rule 6 is applied once and "my/../" is replaced with "/" buffer = "/another/relative" And we're done. Per

Re: normalizing a URI with ..'s in it ?

2003-07-23 Thread Ortwin Glück
Sounds like a bug to me. normalize should not change the absolute/relative type of an URL. Odi Marcus Crafter wrote: Hi All, Hope all is well. I have a question to do with normalizing a URI with ..'s in it. If I execute the following code: URI u = new URI("my/relative/../../anothe

normalizing a URI with ..'s in it ?

2003-07-23 Thread Marcus Crafter
Hi All, Hope all is well. I have a question to do with normalizing a URI with ..'s in it. If I execute the following code: URI u = new URI("my/relative/../../another/relative"); u.normalize(); u.getURI(); should the URI now be /another/relative or 'another/relative'