On Sun, Nov 01, 2015 at 08:52:19PM +0100, Mildis wrote:
> Understood.
>
> Here the corrected patch.
Great, I've applied it, thanks. Please don't forget to update the doc,
I'm pretty sure the address format is mentionned there.
Thanks,
Willy
Understood.
Here the corrected patch.
--
Mildis
Le 2015-11-01 18:43, Willy Tarreau a écrit :
Hi,
On Tue, Oct 27, 2015 at 05:56:41PM +0100, Mildis wrote:
Hi,
I???ve reworked the patch.
No warnings whatsoever, wether using GCC or LLVM.
checkpatch is OK, no warnings either.
Buffers are secured
Hi,
On Tue, Oct 27, 2015 at 05:56:41PM +0100, Mildis wrote:
> Hi,
>
> I???ve reworked the patch.
> No warnings whatsoever, wether using GCC or LLVM.
> checkpatch is OK, no warnings either.
> Buffers are secured and all loops exit naturally or with an index I???ve
> checked against off-by-one.
O
Hi,
I’ve reworked the patch.
No warnings whatsoever, wether using GCC or LLVM.
checkpatch is OK, no warnings either.
Buffers are secured and all loops exit naturally or with an index I’ve
checked against off-by-one.
I’ve made a custom loop to remove the brackets : I found it easier than
to do
Hi,
On Thu, Oct 22, 2015 at 08:26:01PM +0200, Mildis wrote:
> Hi Willy,
>
> Here are two patches, rebased on current HEAD.
> The first allows IPv6 with square brackets, the second parses colon to
> look for a port.
OK thanks.
> The logic is meant to be backward compatible with current behavior
Hi Willy,
Here are two patches, rebased on current HEAD.
The first allows IPv6 with square brackets, the second parses colon to
look for a port.
The logic is meant to be backward compatible with current behavior : as
you suggested, starting from the end, it looks for either a colon or a
closin
Hi again,
Let’s go step by step.
Here is a first patch which allows square-brackets literals.
It does not change the port parser, just remove the brackets in str2ip2.
It expects the IP address to be either plain or surrounded with square
brackets, thus if first and last chars are not respective
On Tue, Oct 13, 2015 at 08:10:03PM +0200, Mildis wrote:
>
> Le 2015-10-10 15:49, Willy Tarreau a écrit :
> >Hi,
>
> >@@ -856,11 +883,28 @@ struct sockaddr_storage *str2sa_range(const char
> >*str, int *low, int *high, char
> > else { /* IPv4 and IPv6 */
> > int use_fqdn = 0;
> >
>
Le 2015-10-10 15:49, Willy Tarreau a écrit :
Hi,
@@ -856,11 +883,28 @@ struct sockaddr_storage *str2sa_range(const char
*str, int *low, int *high, char
else { /* IPv4 and IPv6 */
int use_fqdn = 0;
- port1 = strrchr(str2, ':');
- if (port1)
On Sat, Oct 10, 2015 at 05:02:08PM +0200, Mildis wrote:
> Aw, man !
> My C skills are so rusted :)
>
> I???ll look at your comments and correct all this.
Thanks.
> BTW, a bit off-topic : have you looked at a code-review server like
> gerrit ?
No but quite frankly I don't believe a single minut
Aw, man !
My C skills are so rusted :)
I’ll look at your comments and correct all this.
BTW, a bit off-topic : have you looked at a code-review server like
gerrit ?
Quite useful for multi-round patchset submission like this one.
--
Mildis
Le 2015-10-10 15:49, Willy Tarreau a écrit :
Hi,
On
Hi,
On Sat, Oct 10, 2015 at 01:50:46PM +0200, Mildis wrote:
> Here is a working patch for IPv6 literal with square brackets.
> Tested with :
> "2001:db8::1234:5678",
> "2001:db8::1234:5678:",
> "2001:db8::1234:5678:80",
> "2001:db8::1234:5678:80:",
> "::",
> ":::",
> ":::80",
> "[2001:db8::1234:56
Here is a working patch for IPv6 literal with square brackets.
Tested with :
"2001:db8::1234:5678",
"2001:db8::1234:5678:",
"2001:db8::1234:5678:80",
"2001:db8::1234:5678:80:",
"::",
":::",
":::80",
"[2001:db8::1234:5678]",
"[2001:db8::1234:5678]:",
"[2001:db8::1234:5678]:80",
"[::]",
"[::]:",
"[:
Thanks for your feedback.
I think it need improvement as I currently replace the closing bracket
with a null directly in the string. Working on a copy and leave the
original string as-is should be better.
Plus adding some logic here and there to match all cases ...
I’ll work on this asap.
Mild
Hi Mildis,
>> And regarding "2001:db8::1234", you can't forbit it simply because you
>> don't know if 1234 is a port or not in this context, as you have
>> reported.
>
> Sure. In this very specific case 1234 can’t be a port as 2001:db8:: is
> then a subnet.
For the record: you can't know that, u
On Tue, Oct 06, 2015 at 05:57:09PM +0200, Mildis wrote:
> >And regarding "2001:db8::1234", you can't forbit it simply because you
> >don't know if 1234 is a port or not in this context, as you have
> >reported.
>
> Sure. In this very specific case 1234 can???t be a port as 2001:db8:: is
> then a
Le 2015-10-06 17:47, Willy Tarreau a écrit :
Hi,
You must not forbid "[2001:db8::1234]:" otherwise people will not adopt
the square brackets notation. Some of them probably already do things
like
this :
server srv1 $IP_SRV1:$PORT_SRV1
And fill the respective environment variables with e
Hi,
On Tue, Oct 06, 2015 at 05:34:07PM +0200, Mildis wrote:
> Hi Willy,
>
> My bad : in the doc, I didn???t get the « add a colon without a port to
> end an address » trick.
> That???s why I was lost at first.
> The doc obviously says ???[:[port]]??? making the port optional
> and an ending col
Hi Willy,
My bad : in the doc, I didn’t get the « add a colon without a port to
end an address » trick.
That’s why I was lost at first.
The doc obviously says ‘[:[port]]’ making the port optional and
an ending colon valid but it looks like a typo to me as ending an IPv6
address with a colon i
On Mon, Oct 05, 2015 at 06:42:52PM +0200, Mildis wrote:
> Le 2015-10-05 18:07, David du Colombier a écrit :
> >>It looks like IPv6 parsing may lead to errors.
> >>The logic cannot distinguish from ???2001:db8::1234:80??? as :
> >>- a plain IPv6 address 2001:db8::1234:80
> >>- IPv6 2001:db8::1234 on
Le 2015-10-05 18:07, David du Colombier a écrit :
It looks like IPv6 parsing may lead to errors.
The logic cannot distinguish from ‘2001:db8::1234:80’ as :
- a plain IPv6 address 2001:db8::1234:80
- IPv6 2001:db8::1234 on port 80
As far I remember, to prevent this confusion, we made the final
c
> It looks like IPv6 parsing may lead to errors.
> The logic cannot distinguish from ‘2001:db8::1234:80’ as :
> - a plain IPv6 address 2001:db8::1234:80
> - IPv6 2001:db8::1234 on port 80
As far I remember, to prevent this confusion, we made the final
colon mandatory on IPv6 addresses. This way, a
Hi list,
It looks like IPv6 parsing may lead to errors.
The logic cannot distinguish from ‘2001:db8::1234:80’ as :
- a plain IPv6 address 2001:db8::1234:80
- IPv6 2001:db8::1234 on port 80
It always default to the latter, considering any valid word made only of
digits as a port.
(see https://g
23 matches
Mail list logo