Skip to contentSkip to conversation

problem using MAC address.

DISCUSSION ads nat 3 participants 5 messages Oct 27, 2004

lore
Share & tools
lore

ads nat

author
#0 lore raw

Hi,
I want block forwarding as follows :

"iptables -I INPUT 1 -i eth1 -p tcp -m tcp --dport 25 -m mac --mac-source 00:08:A1:53:BE:71 -d ! 10.0.0.2 -j DROP"

it does not work but when I try to do same thing with rule
"iptables -D FORWARD -i eth1 -p tcp -m tcp --dport 25 -s 192.168.0.42 -d ! 10.0.0.2 -j DROP"

Is there any sytax error.

Or Do I have to installed any additional module of iptables.
I am using Redhat 9.0 Linux.
Please guide me.

Thanks for support.

__________________________________
Do you Yahoo!?
Take Yahoo! Mail with you! Get it on your mobile phone.
http://mobile.yahoo.com/maildemo

#1 lore raw
Quoted 11 lines · ads nat

Hi,
I want block forwarding as follows :

"iptables -I INPUT 1 -i eth1 -p tcp -m tcp --dport 25 -m mac --mac-source 00:08:A1:53:BE:71 -d ! 10.0.0.2 -j DROP"

it does not work but when I try to do same thing with rule "iptables -D FORWARD -i eth1 -p tcp -m tcp --dport 25 -s 192.168.0.42 -d ! 10.0.0.2 -j DROP"

Quoted 9 lines

Is there any sytax error.

Or Do I have to installed any additional module of iptables.
I am using Redhat 9.0 Linux.
Please guide me.

Thanks for support.

Sorry, for the fulless answer.

You not need:
iptables -I INPUT 1 -i eth1 -p tcp --dport 25 -m mac --mac-source 00:08:A1:53:BE:71 -j DROP

You need:
iptables -A FORWARD -p tcp --dport 25 -m --mac-source 00:08:A1:53:BE:71 -j DROP

Signature · 3 lines
wbr, Logechnik Alexandr

In God we trust, but something else must have X.509 certificate
author
#2 lore raw

I want to allow access to -d 202.63.167.193 and deny to all other destination.
Solutins you have given will restrict access to port 25 at all destinations.

Thanks for support.

Quoted 34 lines · --- Logechnik Alexandr
Quoted 4 lines · ads nat

Hi,
I want block forwarding as follows :

"iptables -I INPUT 1 -i eth1 -p tcp -m tcp --dport

25

Quoted 1 line

-m mac --mac-source 00:08:A1:53:BE:71 -d ! 10.0.0.2

-j

Quoted 3 lines

DROP"

it does not work but when I try to do same thing

with

Quoted 2 lines

rule
"iptables -D FORWARD -i eth1 -p tcp -m tcp --dport

25

Quoted 11 lines

-s 192.168.0.42 -d ! 10.0.0.2 -j DROP"

Is there any sytax error.

Or Do I have to installed any additional module of iptables.
I am using Redhat 9.0 Linux.
Please guide me.

Thanks for support.

Sorry, for the fulless answer.

You not need:
iptables -I INPUT 1 -i eth1 -p tcp --dport 25 -m mac --mac-source
00:08:A1:53:BE:71 -j DROP

Quoted 13 lines

You need:
iptables -A FORWARD -p tcp --dport 25 -m
--mac-source 00:08:A1:53:BE:71
-j DROP

Signature · 4 lines
wbr, Logechnik Alexandr

In God we trust, but something 
else must have X.509 certificate

__________________________________
Do you Yahoo!?
Yahoo! Mail Address AutoComplete - You start. We finish.
http://promotions.yahoo.com/new_mail

#3 lore raw
In reply to ads nat
Quoted 23 lines · ads nat

Hi,
I want block forwarding as follows :

"iptables -I INPUT 1 -i eth1 -p tcp -m tcp --dport 25 -m mac --mac-source 00:08:A1:53:BE:71 -d ! 10.0.0.2 -j DROP"

it does not work but when I try to do same thing with rule "iptables -D FORWARD -i eth1 -p tcp -m tcp --dport 25 -s 192.168.0.42 -d ! 10.0.0.2 -j DROP"

Is there any sytax error.

Or Do I have to installed any additional module of iptables.
I am using Redhat 9.0 Linux.
Please guide me.

Thanks for support.

Quoted 8 lines

__________________________________
Do you Yahoo!?
Take Yahoo! Mail with you! Get it on your mobile phone.
http://mobile.yahoo.com/maildemo

You try delete some chain. You need:

"iptables -A FORWARD -i eth1 -p tcp -m tcp --dport 25 -s 192.168.0.42 -d ! 10.0.0.2 -j DROP"

Signature · 3 lines
wbr, Logechnik Alexandr

In God we trust, but something else must have X.509 certificate
#4 lore raw
In reply to ads nat
Quoted 6 lines · ads nat

Hi,
I want block forwarding as follows :

"iptables -I INPUT 1 -i eth1 -p tcp -m tcp --dport 25 -m mac --mac-source 00:08:A1:53:BE:71 -d ! 10.0.0.2 -j DROP"

if you're trying to block FORWARDING, why not try putting that rule in the FORWARD chain instead of the INPUT chain?

Quoted 4 lines

it does not work but when I try to do same thing with rule
"iptables -D FORWARD -i eth1 -p tcp -m tcp --dport 25 -s 192.168.0.42 -d ! 10.0.0.2 -j DROP"

that is a command that deletes a rule out of the FORWARD chain

Quoted 6 lines

Is there any sytax error.

Or Do I have to installed any additional module of iptables.
I am using Redhat 9.0 Linux.
Please guide me.

wanna clue us in as to what exactly you're trying to do?

-j

Signature · 1 line
Jason Opperisano <[email protected]>