Sorry for taking so long in responsing; I was rambling in the forest for few days.
For the an other question in post #16: the "anywhere" and "anywhere" are the source and destination addresses. But as said earlier, that is not the whole truth; run with "iptables -v -L" to see more comprehensive listing (and "iptables -t nat -v -L").
For post #18:
ok, now I know how you have connected your cables. What I don't know, is why. Well, I do know that you are figuring out a problem in some other configuration, but I don't get the more concrete target.
As I tried to distinguish in post #6 (by using two concrete cases plus an open case "c"), the forwarding might mean many things. Forwarding can happen in ethernet level, routing level or protocol level and most of these can be done either with or without modifying actual "envelopes" of packages.
Back to the network description:
So, you have now in test setting #1:
Internet <- ->
{Some external IP} [cable router] {Internal IP 192.168.100.something}
<- subnet (A) 192.168.100.0/24, carried in a switch I ->*
*(A) {192.168.100.5/eth0} [linux box] {200.0.0.250/eth1} <- subnet (B) 200.0.0.0/24 carried in a same switch I -> (B) {200.0.0.254} [mail server]
*(A) {192.168.100.7} [test machine]
Are the following claims true:
1. You are allowed to set the test machine to have any settings you might ever want.
2. You are allowed to set the linux box to have any settings you might ever want.
3. You are allowed to set the mailserver to have any settings you might ever want.
About the objectives, what do you want to happen in following cases when you write:
a) testbox# telnet 192.168.100.5 25
b) testbox# telnet 192.168.100.7 25
c) testbox# telnet
www.linuxquestions.org 25
(or any other arbitrary netsite)
d) testbox# telnet
www.linuxquestions.org 80
(or any other arbitrary netsite)
e) testbox# telnet 200.0.0.0 25
f) linuxbox# telnet 200.0.0.0 25
g) Are these relevant questions at all? Are you trying to archive something else?
Some more general remarks.
* There is normally not much sense in connecting two nics to the same switch. It might be useful is some cases, though, eg. when your switch supports ethernet bonging/channeling so you can get double throughput, but only partially useful on routing.
* Why do you want to put the mailserver into it's own subnet in the first place? Wouldn't it be
so much easier to just let the mailserver be one of the citizens (like 192.168.100.27) and setup others in the lan to use it as their mailserver. No routing, no address translation, no fuss at all.