LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Domain forwarder (https://www.linuxquestions.org/questions/linux-software-2/domain-forwarder-4175514772/)

MarHazK 08-14-2014 02:05 AM

Domain forwarder
 
My friend did the domain forwarder but couldnt ask him again since he's went missing almost 10+ years lol, wanting to ask him how he did it.

Domain forwarder I meant is like similar to "Virtual Host in Apache WebServer", but i'm not talking about any webserver, but im talking about with TCP/IP.

Let see if the case below:
In BIND9 authorized DNS (public domain, reachable through internet users), there are 3 authorized domains named server1.com, server2.com, server3.com, and A-recorded a same WAN IP address (ie. 12.34.45.56), but different LAN machine, but have open-port 21 server on each LAN machine.

Client-Side
int num = RANDOM(1,3)
if (num == 1) connect(server1.com,21)
if (num == 2) connect(server2.com,21)
if (num == 3) connect(server3.com,21)

WAN IP ADDR for server1.com = 12.34.45.56
WAN IP ADDR for server2.com = 12.34.45.56
WAN IP ADDR for server3.com = 12.34.45.56

LAN IP ADDR for server1.com's machine = 192.168.1.1
LAN IP ADDR for server2.com's machine = 192.168.1.2
LAN IP ADDR for server3.com's machine = 192.168.1.3

So I wanting this:

1) connect to server1.com (WANIP: 12.34.45.56:21), reach to machine A
1) connect to server2.com (WANIP: 12.34.45.56:21), reach to machine B
1) connect to server3.com (WANIP: 12.34.45.56:21), reach to machine C



Is it possible to do so since my friend did that work. I try to figure it how but dont know how even iptables wont works on that, i guess, because I've tried.

unSpawn 09-06-2014 04:25 AM

Quote:

Originally Posted by MarHazK (Post 5220840)
Is it possible to do

No, unfortunately it isn't: HTTP supports a "Host" header but FTP doesn't.


All times are GMT -5. The time now is 01:56 PM.