0

I'm trying to configure an openwrt router so that I get two wan IP addresses by dhcp - one for the router itself and one for a DMZ host. I followed the DMZ howto. It appears that the host on the DMZ interface sends a request for a IP but does not receive one. Config files are here.

0

WANs are usually point-to-point connections. In this way, they are not going to assign two IP addresses to a router. Instead, a local LAN is configured for DMZ and externally connections are masked as if they were coming from/to the router IP.

This forwarding is what is achieved for port 80 with the following lines of howto:

# Make 192.168.2.2:80 publicly accessible
config 'redirect'
   option '_name' 'http'
   option 'src' 'wan'
   option 'proto' 'tcp'
   option 'src_dport' '80'
   option 'dest_ip' '192.168.2.2'

I think you can get a fully transparent DMZ if you remove lines with proto and src_dport, then your DMZ server would look to the external networks as having the IP of the router.

  • Thanks a lot for your answer. I will ask you a clarifying question because your example is not related to what is needed and I'd like to be sure we're talking about the same thing. Are you saying that using a router and one or more hosts one cannot emulate a switch whose ports are as follows: port 0: connected to Network X; port 1, port 2, etc.: hosts 1,2, etc. with addresses in Network X? – vkamenen Jun 11 '15 at 11:20
  • By definition, a router connects two networks. The router has one IP address on each network and hosts must configure that network IP as its gateway IP. DMZs are usually used to split networks. However home routers used to name masquerading function as DMZ and I think this leads to confusion. In summary, a router (used as a router) can not emulate a switch connecting two different networks (that is neither a switch). Nevertheless, I use a home DSL router as a switch: just with default setup (all ports same network) disabling DSL WAN connection and disabling DHCP. – arauzo Jun 12 '15 at 23:13
  • Thanks for your answer. I mistakenly used the term DMZ then – vkamenen Jun 12 '15 at 23:17
  • I think you should close the question by selecting this answer or edit question to reformulate it. I think what you wanted was a router acting as a bridge between networks (something tecnically difficult) and a network provider assigning you two IPs (which is more a negotiation thing than something technically solvable). – arauzo Jun 15 '15 at 8:50

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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