Linode Forum
Linode Community Forums
 FAQFAQ    SearchSearch    MembersMembers      Register Register 
 LoginLogin [ Anonymous ] 
Post new topic  Reply to topic
Author Message
 Post subject: iptables --cmd-owner
PostPosted: Tue Dec 19, 2006 12:58 pm 
Offline
Linode Staff
User avatar

Joined: Tue Apr 15, 2003 10:32 pm
Posts: 246
Location: NJ, USA
One of our customers is experiencing some problems using iptables in CentOS4. I wanted to put this out to the community to see if anyone could offer some help: (IP masked to protect the innocent)

Quote:
I am running the new 2.6.18-linode25 kernel and I am still having difficulties using the iptables owner match under CentOS 4. This exact syntax works fine on a real CentOS 4 machine with a current CentOS kernel.

It appears that this problem is specifically related to the --cmd-owner part of the owner match. The last two outputs leave the rest of the iptables command the same, but only uses one of the owner match parameters. See below.

[root@ ~]# iptables -A OUTPUT -s 64.62.231.x -o eth0 -p tcp -m tcp -m multiport --dports 21,80,443 -m state --state NEW -m owner --uid-owner xxx --cmd-owner yyy -j ACCEPT
iptables: Invalid argument
[root@ ~]# iptables -A OUTPUT -s 64.62.231.x -o eth0 -p tcp -m tcp -m state --state NEW -m owner --uid-owner xxx --cmd-owner yyy -j ACCEPT
iptables: Invalid argument
[root@ ~]# iptables -A OUTPUT -s 64.62.231.x -o eth0 -p tcp -m tcp -m multiport --dports 21,80,443 -m state --state NEW -m owner --cmd-owner yyy -j ACCEPT
iptables: Invalid argument
[root@ ~]# iptables -A OUTPUT -s 64.62.231.x -o eth0 -p tcp -m tcp -m multiport --dports 21,80,443 -m state --state NEW -m owner --uid-owner xxx -j ACCEPT
[root@ ~]#


So, --cmd-owner is failing, and I haven't been able to figure out what kernel patch (or config option) enables this feature. It looks like the iptables userspace app has support for this feature already.

Has anyone successfully used --cmd-owner iptables rules, or can point out some syntax problem?

Thanks,
--Tom


Top
   
 Post subject:
PostPosted: Wed Jan 10, 2007 3:14 am 
Offline
Senior Member

Joined: Sat Dec 04, 2004 5:36 pm
Posts: 145
Do you see something like this?
Code:
% gzcat /proc/config.gz | grep -i owner
CONFIG_IP_NF_MATCH_OWNER=y
CONFIG_IP6_NF_MATCH_OWNER=y


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic


Who is online

Users browsing this forum: No registered users and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
RSS

Powered by phpBB® Forum Software © phpBB Group