On Wed, 3 Sep 2003, Hrvoje Niksic wrote:

> Mauro Tortonesi <[EMAIL PROTECTED]> writes:
>
> >> Can you show me an example of a URL that failed to parse?
> >
> > the problem was not with false negatives, but with false positives
> > instead. URLs like:
> >
> > http://[2001.23]/
> > ftp://[dead:beef:dead:beef:dead:beef:dead:beef:dead:beef:dead:beef:dead:beef:..2]
> > were considered valid IPv6 addresses. this is clearly wrong and not
> > RFC 2732 compliant.
>
> Ah, now I see what you mean.  I don't quite agree with the idea of URL
> parsing code containing knowledge of IPv6 (or any other!) addresses,
> but since rfc2732 accepted it, I guess I'll go with it.

yes, i agree. it is really ugly to add some layer-3 knowledge to URL
parsing. but we cannot do anything about it.


> Please mail the patch to wget-patches; I'll apply it.

ok. i'll do it.


> If you have patches for Wget's configure.in to work with Autoconf
> 2.5x, I'll gladly accept those, too.

this will be a little more work. thanks to the adoption of automake i have
made many changes to configure.ac and it is now by far simpler than it
used to be. so, i'll have to make some changes before i'll be able to
submit the patch. expect it not before tomorrow.


> > moreover, the code was not efficient, as the loop was not stopped
> > when an invalid char was encontered.
>
> You have got to be joking -- AFAIR the loop was simply looking for
> ']', which is much more efficient than full parsing of the address
> which you implement!

yes, you're right. i hadn't consider the overhead of all the new checks,
most of all the strchr(xdigits, ch) statement.


> Either way, the URLs with "[...]" addresses are still extremely rare,
> so performance is not affected either way.

yes, you're right. they are extremely rare, but they are also very
important for testing IPv6-enabled services.

-- 
Aequam memento rebus in arduis servare mentem...

Mauro Tortonesi                 [EMAIL PROTECTED]
                                [EMAIL PROTECTED]
                                [EMAIL PROTECTED]
Deep Space 6 - IPv6 with Linux  http://www.deepspace6.net
Ferrara Linux User Group        http://www.ferrara.linux.it


Reply via email to