Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I've configured Windows Firewall in Windows 7 to block all traffic on the public interface, except to certain IP addresses, as described here: http://superuser.com/a/456326/112560 The problem is, this blocks the DHCP client and I cannot get an IP address from a DHCP server. If I add an exception for the DHCP server by excluding its IP from the blocked IP range (same as for the VPN server) that allows ipconfig /renew to work once I have an IP address, but if I release the IP address I cannot get another one unless I disable that firewall rule. I suspect this is because the DHCP DISCOVER client broadcast is still being blocked, so it cannot find the DHCP server. How do allow the DHCP client and connections to specific IPs, while blocking everything else?

share|improve this question

1 Answer 1

up vote 1 down vote accepted

In the Windows Firewall, blocked connections take precedence over allowed connections. There is an option to overrule that, but it is not available for outbound rules. Hence, to allow DHCP client broadcasts, you will have to exclude them from the rule suggested in this answer, assuming this firewall rule is indeed responsible for breaking your DHCP setup.

DHCP clients use the remote UDP port 67 for IPv4 and 547 for IPv6. If you are using the IP-based instead of port-based solution, exclude the broadcast address 255.255.255.255.

share|improve this answer
1  
Thanks! Ending the blocked range at 255.255.255.254 (rather than 255.255.255.255) did the trick. I still had to exclude the actual DHCP server as well. –  E M Mar 12 '13 at 15:30

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.