Review your favorite Linux distribution.
Go Back > Forums > Linux Forums > Linux - Networking
User Name
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.


  Search this Thread
Old 01-17-2007, 05:00 PM   #1
Registered: Oct 2003
Posts: 35

Rep: Reputation: 15
Block all users and allow certain Mac Address

Hey guys,

I am running vsftpd on SUSE 10.1, and i want to block all the incoming connections to the FTP, and allow only connections with certain MAC Address.

I'll do it with iptables?
How can i succeed it?

I read some threads but i found only how to restrict one user via MAC ADDRESS.

Thanks in advanced!!
Old 01-17-2007, 06:07 PM   #2
Registered: Aug 2003
Location: Indiana
Distribution: fc6 sles9 & 10 kubuntu ubuntu-server
Posts: 240
Blog Entries: 2

Rep: Reputation: 30
It would be the opposite of what you found. Drop all incoming ftp connections accept for the one from the given mac address:

iptables -A INPUT -p tcp --destination-port 22 -m mac --mac-source
12:34:ab:cd:56:78 -j ACCEPT

iptables -A INPUT -p tcp --destination-port 22 -j DROP
Old 01-18-2007, 05:31 AM   #3
Registered: Oct 2003
Posts: 35

Original Poster
Rep: Reputation: 15

I use the command
iptables -A INPUT -p tcp --destination-port 21 -j DROP

but still i am accepting connections.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
by using iptables block mac address to restric user to access internet Farrukh Fida Linux - Networking 3 10-09-2006 08:59 AM
block mac address Ammad Linux - General 1 09-11-2005 02:00 PM
DESPERATE : Iptables block users by MAC address. ranjan303 Linux - Security 28 03-29-2005 02:15 AM
how to get ip address, broadcast address, mac address of a machine sumeshstar Programming 2 03-12-2005 05:33 AM
DHCP Server MAC Address found, IP address not assigned wmburke Linux - Wireless Networking 17 11-17-2004 11:33 AM > Forums > Linux Forums > Linux - Networking

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

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration