All of lore.kernel.org
 help / color / mirror / Atom feed
* module owner does not work
@ 2010-03-01  9:33 Lentes, Bernd
  2010-03-01 11:06 ` Richard Horton
  0 siblings, 1 reply; 4+ messages in thread
From: Lentes, Bernd @ 2010-03-01  9:33 UTC (permalink / raw)
  To: 'netfilter@vger.kernel.org'

Hello,

I'd like to use the owner module to limit access to somes hosts just for some users. But it doesn't work.
My rule is:
iptables -I OUTPUT -d 0.0.0.0/0 -m owner --uid-owner 1000 -j REJECT
This is a very wide rule, just for testing purpose.

But uid 1000 is still able e.g. to send emails from the shell using mail.
I googeled already a lot, and found people saying the owner-module was canceled in Kernel 2.6.14, others saying that it still works in kernel 2.6.18. Some say it does not work with a SMP host. But i have the default kernel and only one CPU. Please help me, i'm running out of ideas.
I'm running SLES 10 SP3, kernel 2.6.16.60-0.59.1-default, iptables 1.3.5 .

Bernd

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: module owner does not work
  2010-03-01  9:33 module owner does not work Lentes, Bernd
@ 2010-03-01 11:06 ` Richard Horton
  2010-03-01 11:20   ` Pascal Hambourg
  0 siblings, 1 reply; 4+ messages in thread
From: Richard Horton @ 2010-03-01 11:06 UTC (permalink / raw)
  To: Lentes, Bernd; +Cc: netfilter@vger.kernel.org

On 1 March 2010 09:33, Lentes, Bernd <bernd.lentes@helmholtz-muenchen.de> wrote:
> Hello,
>
> I'd like to use the owner module to limit access to somes hosts just for some users. But it doesn't work.
> My rule is:
> iptables -I OUTPUT -d 0.0.0.0/0 -m owner --uid-owner 1000 -j REJECT
> This is a very wide rule, just for testing purpose.
>

Do pings still work?

If you have an MTA locally its probably not going out of the box as
the uid of the process which called mail but as the uid of the MTA...

-- 
Richard Horton
Users are like a virus: Each causing a thousand tiny crises until the
host finally dies.
http://www.solstans.co.uk - Solstans Japanese Bobtails and Norwegian Forest Cats
http://www.pbase.com/arimus - My online photogallery

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: module owner does not work
  2010-03-01 11:06 ` Richard Horton
@ 2010-03-01 11:20   ` Pascal Hambourg
  2010-03-01 17:03     ` AW: " Lentes, Bernd
  0 siblings, 1 reply; 4+ messages in thread
From: Pascal Hambourg @ 2010-03-01 11:20 UTC (permalink / raw)
  To: netfilter@vger.kernel.org

Hello,

Richard Horton a écrit :
> On 1 March 2010 09:33, Lentes, Bernd <bernd.lentes@helmholtz-muenchen.de> wrote:
>>
>> I'd like to use the owner module to limit access to somes hosts just
>> for some users. But it doesn't work.
>> My rule is:
>> iptables -I OUTPUT -d 0.0.0.0/0 -m owner --uid-owner 1000 -j REJECT
>> This is a very wide rule, just for testing purpose.
> 
> Do pings still work?

Probably, as ping runs with suid root. Better try with something like
telnet or netcat (nc).

>> But uid 1000 is still able e.g. to send emails from the shell using mail.
>
> If you have an MTA locally its probably not going out of the box as
> the uid of the process which called mail but as the uid of the MTA...

I agree.

>> I googeled already a lot, and found people saying the owner-module was
>> canceled in Kernel 2.6.14, others saying that it still works in kernel
>> 2.6.18. Some say it does not work with a SMP host. But i have the
>> default kernel and only one CPU.

AFAIK, only the --pid-owner, --sid-owner and --cmd-owner options are
broken on SMP and were removed in kernel 2.6.14. The 'owner' match,
--uid-owner and gid-owner options are still present and work.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* AW: module owner does not work
  2010-03-01 11:20   ` Pascal Hambourg
@ 2010-03-01 17:03     ` Lentes, Bernd
  0 siblings, 0 replies; 4+ messages in thread
From: Lentes, Bernd @ 2010-03-01 17:03 UTC (permalink / raw)
  To: netfilter@vger.kernel.org

Hi,

Pascal Hambourg wrote:

> Hello,
> 
> Richard Horton a écrit :
> > On 1 March 2010 09:33, Lentes, Bernd 
> <bernd.lentes@helmholtz-muenchen.de> wrote:
> >>

> > 
> > Do pings still work?
> 
> Probably, as ping runs with suid root. Better try with 
> something like telnet or netcat (nc).

I tried telnet, and it worked ! Thanks for your answer.

> 
> >> But uid 1000 is still able e.g. to send emails from the 
> shell using mail.
> >
> > If you have an MTA locally its probably not going out of the box as 
> > the uid of the process which called mail but as the uid of 
> the MTA...
> 
> I agree.
> 

I also agree.

Bernd

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2010-03-01 17:03 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-03-01  9:33 module owner does not work Lentes, Bernd
2010-03-01 11:06 ` Richard Horton
2010-03-01 11:20   ` Pascal Hambourg
2010-03-01 17:03     ` AW: " Lentes, Bernd

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.