WRT54G - Sveasoft firmware - URL redirect
I would like the router to act like a simple reverse proxy, as follows, and wonder if iptables or some other utility can do this:
http:///case1 is sent to address X on the LAN side http:///case2 is sent to address Y on the LAN sidethat is, the incoming HTTP on the WAN's IP is identical, only the URL differs. Example: Making an IP Webcam visible on the internet, where the camera's built-in web server is on some LAN address and I need to use port 80 for it and some other web server. Port-forwarding to something other than 80 would not work if the client is behind a blocking firewall on his side. Maybe this also involves port triggering. Or maybe it's not prudent to ask a router to do this. I have just one WAN IP address. ANSWER: You can try to use the builtin URL filter. Add the following to rc_startup:
iptables -t nat -I PREROUTING -p tcp --dport 80 -m webstr --url [URL] -j DNAT --to [IP]