Re: [Dnsmasq-discuss] dnsmasq does not respect BOOTP's broadcast flag

2016-04-25 Thread Simon Kelley
What software is your PC running? The DHCP client is broken. Look at

https://www.ietf.org/rfc/rfc2131.txt paragraph 4.3.6

The DHCP requests your PC is sending have no server-ip option, no,
requested-ip option and the ciaddr field is zero. That combination
doesn't fit any of the columns in the table, so the request is invalid.

If the PC is just booting (or returning from sleep) then it should
probably be in INIT-REBOOT state, and should include a requested-ip
option. If it did, then dnsmasq would reply.



Cheers,

Simon.


On 05/04/16 11:18, 黎伟强 wrote:
> Here you are. 
> 
>> To: dnsmasq-discuss@lists.thekelleys.org.uk
>> From: si...@thekelleys.org.uk
>> Date: Mon, 4 Apr 2016 17:15:32 +0100
>> Subject: Re: [Dnsmasq-discuss] dnsmasq does not respect BOOTP's broadcast
>> flag
>>
> 
> Please could you post the actual packet capture for that capture,
> instead of a screenshot? I need to look at other parts of the packet
> which are not shown to understand what's going on.
> 
> (Save as... from the wireshark File menu should do the trick.)
> 
> 
> Cheers,
> 
> Simon.
> 
> On 01/04/16 03:38, 黎伟强 wrote:
>>>> Dear all,   I got a router using dnsmasq-2.66 for DHCP
>>>> services, and I encountered a bug that the dnsmasq server does not
>>>> respond to my PC's DHCPREQUEST( normally it should respond with a
>>>> DHCPNAK? ), so it takes an obvious long time to got a new IP for my
>>>> PC. So, is this really a bug or it is just something wrong with my 
>>>> PC(Works well with other DHCP server)?  At my first thought, I
>>>> think it should be a bug that has been solved, so I reviewed the 
>>>> latest(ver.2.75) dnsmasq source code, however, neither did it care 
>>>> about this flag.   I also attached a patch for this.
>>>>
>>>>
>>>>
>>>>
>>>> ___ Dnsmasq-discuss 
>>>> mailing list Dnsmasq-discuss@lists.thekelleys.org.uk 
>>>> http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
>>>>
>>
>> ___
>> Dnsmasq-discuss mailing list
>> Dnsmasq-discuss@lists.thekelleys.org.uk
>> http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
> 
> 




signature.asc
Description: OpenPGP digital signature
___
Dnsmasq-discuss mailing list
Dnsmasq-discuss@lists.thekelleys.org.uk
http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss


Re: [Dnsmasq-discuss] dnsmasq does not respect BOOTP's broadcast flag

2016-04-05 Thread 黎伟强
Here you are. 

> To: dnsmasq-discuss@lists.thekelleys.org.uk
> From: si...@thekelleys.org.uk
> Date: Mon, 4 Apr 2016 17:15:32 +0100
> Subject: Re: [Dnsmasq-discuss] dnsmasq does not respect BOOTP's broadcast 
> flag
> 
> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA256
> 
> 
> Please could you post the actual packet capture for that capture,
> instead of a screenshot? I need to look at other parts of the packet
> which are not shown to understand what's going on.
> 
> (Save as... from the wireshark File menu should do the trick.)
> 
> 
> Cheers,
> 
> Simon.
> 
> On 01/04/16 03:38, 黎伟强 wrote:
> > Dear all,   I got a router using dnsmasq-2.66 for DHCP
> > services, and I encountered a bug that the dnsmasq server does not
> > respond to my PC's DHCPREQUEST( normally it should respond with a
> > DHCPNAK? ), so it takes an obvious long time to got a new IP for my
> > PC. So, is this really a bug or it is just something wrong with my 
> > PC(Works well with other DHCP server)?  At my first thought, I
> > think it should be a bug that has been solved, so I reviewed the 
> > latest(ver.2.75) dnsmasq source code, however, neither did it care 
> > about this flag.   I also attached a patch for this.
> > 
> > 
> > 
> > 
> > ___ Dnsmasq-discuss 
> > mailing list Dnsmasq-discuss@lists.thekelleys.org.uk 
> > http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
> > 
> -BEGIN PGP SIGNATURE-
> Version: GnuPG v2.0.22 (GNU/Linux)
> 
> iQIcBAEBCAAGBQJXApMkAAoJEBXN2mrhkTWiD4EP/31oX7HXVtMhDCt18Fo6klbu
> wrD4GysARnuj3NdFSQv/aEkoJ/ZZYH8g/ChPZSLNRhXd+0EuzhNGC14LnfgM7bUg
> tbbhq3iT99uATuiH20UyXUVrsKwI89xa7Mr4S0VRDt2IZlXtQwEgRnaMfQcgr407
> mgU4Uv6Jtpy6SBurYzRt0C897H0YFYwLryqWE5M6hJuhctlC0CcQPkb7vjBuoteM
> m0idx+oBYLzmKblbZyuxZa5JsN3T4Duk46+UTTppMwljjWvwORuCRfkq0gAFlKB+
> n9OwzKcqFfRix3zw7OP06c1ZVhUgw0O4pbX5/tzjU9f2GJ+rIcAk2xNHUBeDOHqf
> H/TGcGReGt2vybZ6+GpM4IoKUGWhqC3AzeMzYWGraYupfbkaebHqe+tiWNknIi0s
> Z+GYpUmAkRE4w+K062ldDqqueG47SIdBLKXTv0vcGmnXDFvafJcQuvr6VQrAjCIt
> fC86YR77TRgvfuG8E75lpVjJGNahvBhZid8z5S8oi7HdZb3OPVtXbbOPRJ+96kTb
> D4tyRTvupjWiM/29lxqOHFPtuM5MKLVGXlVql6jdMyZr51qdH/rxrHlGCuXLMU6T
> V1offYG8epjrI3aLUv0eOV4xf+UJ11RSBIofQQORM8U+pfVlSjJh5FUHipJAjkH6
> FoxjOxt6R1dEXbulVq5Y
> =1gD8
> -END PGP SIGNATURE-
> 
> ___
> Dnsmasq-discuss mailing list
> Dnsmasq-discuss@lists.thekelleys.org.uk
> http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
  

BOOTP-broadcast.pcap
Description: Binary data
___
Dnsmasq-discuss mailing list
Dnsmasq-discuss@lists.thekelleys.org.uk
http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss


Re: [Dnsmasq-discuss] dnsmasq does not respect BOOTP's broadcast flag

2016-04-04 Thread Simon Kelley
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256


Please could you post the actual packet capture for that capture,
instead of a screenshot? I need to look at other parts of the packet
which are not shown to understand what's going on.

(Save as... from the wireshark File menu should do the trick.)


Cheers,

Simon.

On 01/04/16 03:38, 黎伟强 wrote:
> Dear all,   I got a router using dnsmasq-2.66 for DHCP
> services, and I encountered a bug that the dnsmasq server does not
> respond to my PC's DHCPREQUEST( normally it should respond with a
> DHCPNAK? ), so it takes an obvious long time to got a new IP for my
> PC. So, is this really a bug or it is just something wrong with my 
> PC(Works well with other DHCP server)?  At my first thought, I
> think it should be a bug that has been solved, so I reviewed the 
> latest(ver.2.75) dnsmasq source code, however, neither did it care 
> about this flag.   I also attached a patch for this.
> 
> 
> 
> 
> ___ Dnsmasq-discuss 
> mailing list Dnsmasq-discuss@lists.thekelleys.org.uk 
> http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
> 
-BEGIN PGP SIGNATURE-
Version: GnuPG v2.0.22 (GNU/Linux)

iQIcBAEBCAAGBQJXApMkAAoJEBXN2mrhkTWiD4EP/31oX7HXVtMhDCt18Fo6klbu
wrD4GysARnuj3NdFSQv/aEkoJ/ZZYH8g/ChPZSLNRhXd+0EuzhNGC14LnfgM7bUg
tbbhq3iT99uATuiH20UyXUVrsKwI89xa7Mr4S0VRDt2IZlXtQwEgRnaMfQcgr407
mgU4Uv6Jtpy6SBurYzRt0C897H0YFYwLryqWE5M6hJuhctlC0CcQPkb7vjBuoteM
m0idx+oBYLzmKblbZyuxZa5JsN3T4Duk46+UTTppMwljjWvwORuCRfkq0gAFlKB+
n9OwzKcqFfRix3zw7OP06c1ZVhUgw0O4pbX5/tzjU9f2GJ+rIcAk2xNHUBeDOHqf
H/TGcGReGt2vybZ6+GpM4IoKUGWhqC3AzeMzYWGraYupfbkaebHqe+tiWNknIi0s
Z+GYpUmAkRE4w+K062ldDqqueG47SIdBLKXTv0vcGmnXDFvafJcQuvr6VQrAjCIt
fC86YR77TRgvfuG8E75lpVjJGNahvBhZid8z5S8oi7HdZb3OPVtXbbOPRJ+96kTb
D4tyRTvupjWiM/29lxqOHFPtuM5MKLVGXlVql6jdMyZr51qdH/rxrHlGCuXLMU6T
V1offYG8epjrI3aLUv0eOV4xf+UJ11RSBIofQQORM8U+pfVlSjJh5FUHipJAjkH6
FoxjOxt6R1dEXbulVq5Y
=1gD8
-END PGP SIGNATURE-

___
Dnsmasq-discuss mailing list
Dnsmasq-discuss@lists.thekelleys.org.uk
http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss


Re: [Dnsmasq-discuss] dnsmasq does not respect BOOTP's broadcast flag

2016-04-02 Thread 黎伟强
  As the source code indicates, my patch will work only when the 
authoritative option is checked. 


> From: weiqiang...@hotmail.com
> Subject: Re: [Dnsmasq-discuss] dnsmasq does not respect BOOTP's broadcast flag
> Date: Fri, 1 Apr 2016 13:32:44 +0800
> To: albert.arib...@free.fr
> CC: dnsmasq-discuss@lists.thekelleys.org.uk
> 
> Yeah, I've read the manual and that option is checked. It just won't work.
> 
> Sent from my iPhone
> 
> > 在 2016年4月1日,13:24,Albert ARIBAUD  写道:
> > 
> > Hello,
> > 
> > Le Fri, 1 Apr 2016 02:38:30 +
> > 黎伟强  a écrit:
> > 
> >> Dear all,   I got a router using dnsmasq-2.66 for DHCP services,
> >> and I encountered a bug that the dnsmasq server does not respond to
> >> my PC's DHCPREQUEST( normally it should respond with a DHCPNAK? ), so
> >> it takes an obvious long time to got a new IP for my
> >> PC.
> >> 
> >> So, is this really a bug or it is just
> >> something wrong with my PC(Works well with other DHCP server)?  At my
> >> first thought, I think it should be a bug that has been solved, so I
> >> reviewed the latest(ver.2.75) dnsmasq source code, however, neither
> >> did it care about this flag.
> >> 
> >>  I also attached a patch for this.
> > 
> > Are you sure that this is BOOTP related?
> > 
> > As long as dnsmasq is configured to *not* be authoritative, it will
> > *not* respond with NAKs to requests (as these NAKs might interfere with
> > another, authoritative, server's positive answers).
> > 
> > Existing option -K (or --dhcp-authoritative in long form) will tell
> > dnsmasq that it is indeed the only DHCP server around and therefore
> > authoritative, and as such, it will then emit NAKs for bad requests
> > (see 'man dnsmasq' for details).
> > 
> > Can you try without your patch and with -K option?
> > 
> > Amicalement,
> > -- 
> > Albert.
  ___
Dnsmasq-discuss mailing list
Dnsmasq-discuss@lists.thekelleys.org.uk
http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss


Re: [Dnsmasq-discuss] dnsmasq does not respect BOOTP's broadcast flag

2016-04-01 Thread 黎伟强
Thanks for the reply.I've read the post, but unfortunately, not the same thing. 
The post's key point is that the DHCP server offer the DHCP offer with unicast 
is set(since the client requested), but the firewall of Win7 just reject it. My 
problem is that dnsmasq just silently ignored my request. 

From: all...@live.cn
To: dnsmasq-discuss@lists.thekelleys.org.uk
Date: Fri, 1 Apr 2016 13:21:35 +0800
Subject: Re: [Dnsmasq-discuss] dnsmasq does not respect BOOTP's broadcast flag




Greetings.

I don't quite understand the broadcast flag, however I did encounter the 
"taking a very long time to obtain an IP" problem.

I'm on Windows 10. Router has dnsmasq 2.75.

During Windows booting process, its firewall would deny any unicast packet from 
outside its own subnet, that including DHCP. Windows would try to request DHCP, 
then deny the reply, a few times.

Solution is asking Windows to request a DHCP reply via broadcast: 
http://sysadministrivia.blogspot.jp/2011/04/dhcp-broadcast-flag-problem-with-dhcp.html

Wish this help.


五月
2016.4

From: weiqiang...@hotmail.com
To: dnsmasq-discuss@lists.thekelleys.org.uk
Date: Fri, 1 Apr 2016 02:38:30 +
Subject: [Dnsmasq-discuss] dnsmasq does not respect BOOTP's broadcast flag




Dear all,   I got a router using dnsmasq-2.66 for DHCP services, and I 
encountered a bug that the dnsmasq server does not respond to my PC's 
DHCPREQUEST( normally it should respond with a DHCPNAK? ), so it takes an 
obvious long time to got a new IP for my PC.  So, is this 
really a bug or it is just something wrong with my PC(Works well with other 
DHCP server)?  At my first thought, I think it should be a bug that has been 
solved, so I reviewed the latest(ver.2.75) dnsmasq source code, however, 
neither did it care about this flag.   I also attached a patch for this.
   

___
Dnsmasq-discuss mailing list
Dnsmasq-discuss@lists.thekelleys.org.uk
http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss 
  

___
Dnsmasq-discuss mailing list
Dnsmasq-discuss@lists.thekelleys.org.uk
http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss 
  ___
Dnsmasq-discuss mailing list
Dnsmasq-discuss@lists.thekelleys.org.uk
http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss


Re: [Dnsmasq-discuss] dnsmasq does not respect BOOTP's broadcast flag

2016-03-31 Thread 黎伟强
Yeah, I've read the manual and that option is checked. It just won't work.

Sent from my iPhone

> 在 2016年4月1日,13:24,Albert ARIBAUD  写道:
> 
> Hello,
> 
> Le Fri, 1 Apr 2016 02:38:30 +
> 黎伟强  a écrit:
> 
>> Dear all,   I got a router using dnsmasq-2.66 for DHCP services,
>> and I encountered a bug that the dnsmasq server does not respond to
>> my PC's DHCPREQUEST( normally it should respond with a DHCPNAK? ), so
>> it takes an obvious long time to got a new IP for my
>> PC.
>> 
>> So, is this really a bug or it is just
>> something wrong with my PC(Works well with other DHCP server)?  At my
>> first thought, I think it should be a bug that has been solved, so I
>> reviewed the latest(ver.2.75) dnsmasq source code, however, neither
>> did it care about this flag.
>> 
>>  I also attached a patch for this.
> 
> Are you sure that this is BOOTP related?
> 
> As long as dnsmasq is configured to *not* be authoritative, it will
> *not* respond with NAKs to requests (as these NAKs might interfere with
> another, authoritative, server's positive answers).
> 
> Existing option -K (or --dhcp-authoritative in long form) will tell
> dnsmasq that it is indeed the only DHCP server around and therefore
> authoritative, and as such, it will then emit NAKs for bad requests
> (see 'man dnsmasq' for details).
> 
> Can you try without your patch and with -K option?
> 
> Amicalement,
> -- 
> Albert.
___
Dnsmasq-discuss mailing list
Dnsmasq-discuss@lists.thekelleys.org.uk
http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss


Re: [Dnsmasq-discuss] dnsmasq does not respect BOOTP's broadcast flag

2016-03-31 Thread 五月
Greetings.

I don't quite understand the broadcast flag, however I did encounter the 
"taking a very long time to obtain an IP" problem.

I'm on Windows 10. Router has dnsmasq 2.75.

During Windows booting process, its firewall would deny any unicast packet from 
outside its own subnet, that including DHCP. Windows would try to request DHCP, 
then deny the reply, a few times.

Solution is asking Windows to request a DHCP reply via broadcast: 
http://sysadministrivia.blogspot.jp/2011/04/dhcp-broadcast-flag-problem-with-dhcp.html

Wish this help.


五月
2016.4

From: weiqiang...@hotmail.com
To: dnsmasq-discuss@lists.thekelleys.org.uk
Date: Fri, 1 Apr 2016 02:38:30 +0000
Subject: [Dnsmasq-discuss] dnsmasq does not respect BOOTP's broadcast flag




Dear all,   I got a router using dnsmasq-2.66 for DHCP services, and I 
encountered a bug that the dnsmasq server does not respond to my PC's 
DHCPREQUEST( normally it should respond with a DHCPNAK? ), so it takes an 
obvious long time to got a new IP for my PC.  So, is this 
really a bug or it is just something wrong with my PC(Works well with other 
DHCP server)?  At my first thought, I think it should be a bug that has been 
solved, so I reviewed the latest(ver.2.75) dnsmasq source code, however, 
neither did it care about this flag.   I also attached a patch for this.
   

___
Dnsmasq-discuss mailing list
Dnsmasq-discuss@lists.thekelleys.org.uk
http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss 
  ___
Dnsmasq-discuss mailing list
Dnsmasq-discuss@lists.thekelleys.org.uk
http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss


Re: [Dnsmasq-discuss] dnsmasq does not respect BOOTP's broadcast flag

2016-03-31 Thread Albert ARIBAUD
Hello,

Le Fri, 1 Apr 2016 02:38:30 +
黎伟强  a écrit:

> Dear all,   I got a router using dnsmasq-2.66 for DHCP services,
> and I encountered a bug that the dnsmasq server does not respond to
> my PC's DHCPREQUEST( normally it should respond with a DHCPNAK? ), so
> it takes an obvious long time to got a new IP for my
> PC.
>
>  So, is this really a bug or it is just
> something wrong with my PC(Works well with other DHCP server)?  At my
> first thought, I think it should be a bug that has been solved, so I
> reviewed the latest(ver.2.75) dnsmasq source code, however, neither
> did it care about this flag.
> 
>   I also attached a patch for this. 

Are you sure that this is BOOTP related?

As long as dnsmasq is configured to *not* be authoritative, it will
*not* respond with NAKs to requests (as these NAKs might interfere with
another, authoritative, server's positive answers).

Existing option -K (or --dhcp-authoritative in long form) will tell
dnsmasq that it is indeed the only DHCP server around and therefore
authoritative, and as such, it will then emit NAKs for bad requests
(see 'man dnsmasq' for details).

Can you try without your patch and with -K option?

Amicalement,
-- 
Albert.

___
Dnsmasq-discuss mailing list
Dnsmasq-discuss@lists.thekelleys.org.uk
http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss


[Dnsmasq-discuss] dnsmasq does not respect BOOTP's broadcast flag

2016-03-31 Thread 黎伟强
Dear all,   I got a router using dnsmasq-2.66 for DHCP services, and I 
encountered a bug that the dnsmasq server does not respond to my PC's 
DHCPREQUEST( normally it should respond with a DHCPNAK? ), so it takes an 
obvious long time to got a new IP for my PC.  So, is this 
really a bug or it is just something wrong with my PC(Works well with other 
DHCP server)?  At my first thought, I think it should be a bug that has been 
solved, so I reviewed the latest(ver.2.75) dnsmasq source code, however, 
neither did it care about this flag.   I also attached a patch for this.
   

120-respect_bootp_unicast_flags.patch
Description: Binary data
___
Dnsmasq-discuss mailing list
Dnsmasq-discuss@lists.thekelleys.org.uk
http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss