[AppArmor 38/45] AppArmor: Module and LSM hooks

2007-10-26 Thread jjohansen
Module parameters, LSM hooks, initialization and teardown. Signed-off-by: John Johansen <[EMAIL PROTECTED]> Signed-off-by: Andreas Gruenbacher <[EMAIL PROTECTED]> --- security/apparmor/lsm.c | 816 1 file changed, 816 insertions(+) --- /dev/null

Re: [AppArmor 38/45] AppArmor: Module and LSM hooks

2007-06-12 Thread Andreas Gruenbacher
On Monday 11 June 2007 16:33, Stephen Smalley wrote: >From a userland perspective, audit and inotify allow you to specify > watches on pathnames, and those watches trigger actions by the audit and > inotify subsystems when those files are accessed. The kernel mechanism > however is inode-based, no

Re: [AppArmor 38/45] AppArmor: Module and LSM hooks

2007-06-12 Thread Serge E. Hallyn
Quoting Karl MacMillan ([EMAIL PROTECTED]): > On Tue, 2007-06-12 at 10:34 -0500, Serge E. Hallyn wrote: > > Quoting Stephen Smalley ([EMAIL PROTECTED]): > > [...] > > > > > > > If we added support for named type transitions to SELinux, as proposed > > > earlier by Kyle Moffett during this discus

Re: [AppArmor 38/45] AppArmor: Module and LSM hooks

2007-06-12 Thread Karl MacMillan
On Tue, 2007-06-12 at 10:34 -0500, Serge E. Hallyn wrote: > Quoting Stephen Smalley ([EMAIL PROTECTED]): [...] > > > > If we added support for named type transitions to SELinux, as proposed > > earlier by Kyle Moffett during this discussion, wouldn't that address > > that issue without needing a

Re: [AppArmor 38/45] AppArmor: Module and LSM hooks

2007-06-12 Thread Serge E. Hallyn
Quoting Stephen Smalley ([EMAIL PROTECTED]): > On Mon, 2007-06-11 at 14:02 -0500, Serge E. Hallyn wrote: > > Quoting Andreas Gruenbacher ([EMAIL PROTECTED]): > > > On Monday 11 June 2007 16:33, Stephen Smalley wrote: > > > > On Mon, 2007-06-11 at 01:10 +0200, Andreas Gruenbacher wrote: > > > > > On

Re: [AppArmor 38/45] AppArmor: Module and LSM hooks

2007-06-12 Thread Stephen Smalley
On Mon, 2007-06-11 at 17:55 +0200, Andreas Gruenbacher wrote: > On Monday 11 June 2007 16:33, Stephen Smalley wrote: > > On Mon, 2007-06-11 at 01:10 +0200, Andreas Gruenbacher wrote: > > > On Wednesday 06 June 2007 15:09, Stephen Smalley wrote: > > > > On Mon, 2007-06-04 at 16:30 +0200, Andreas Gru

Re: [AppArmor 38/45] AppArmor: Module and LSM hooks

2007-06-12 Thread Pavel Machek
Hi! > > > > How will kernel work with very long paths? I'd suspect some problems, > > > > if path is 1MB long and I attempt to print it in /proc > > > > somewhere. > > > > > > Pathnames are only used for informational purposes in the kernel, except > > > in AppArmor of course. /proc only uses pa

Re: [AppArmor 38/45] AppArmor: Module and LSM hooks

2007-06-12 Thread Stephen Smalley
On Mon, 2007-06-11 at 14:02 -0500, Serge E. Hallyn wrote: > Quoting Andreas Gruenbacher ([EMAIL PROTECTED]): > > On Monday 11 June 2007 16:33, Stephen Smalley wrote: > > > On Mon, 2007-06-11 at 01:10 +0200, Andreas Gruenbacher wrote: > > > > On Wednesday 06 June 2007 15:09, Stephen Smalley wrote: >

Re: [AppArmor 38/45] AppArmor: Module and LSM hooks

2007-06-11 Thread Serge E. Hallyn
Quoting Andreas Gruenbacher ([EMAIL PROTECTED]): > On Monday 11 June 2007 16:33, Stephen Smalley wrote: > > On Mon, 2007-06-11 at 01:10 +0200, Andreas Gruenbacher wrote: > > > On Wednesday 06 June 2007 15:09, Stephen Smalley wrote: > > > > On Mon, 2007-06-04 at 16:30 +0200, Andreas Gruenbacher wrot

Re: [AppArmor 38/45] AppArmor: Module and LSM hooks

2007-06-11 Thread Andreas Gruenbacher
On Monday 11 June 2007 16:33, Stephen Smalley wrote: > On Mon, 2007-06-11 at 01:10 +0200, Andreas Gruenbacher wrote: > > On Wednesday 06 June 2007 15:09, Stephen Smalley wrote: > > > On Mon, 2007-06-04 at 16:30 +0200, Andreas Gruenbacher wrote: > > > > On Monday 04 June 2007 15:12, Pavel Machek wro

Re: [AppArmor 38/45] AppArmor: Module and LSM hooks

2007-06-11 Thread Stephen Smalley
On Mon, 2007-06-11 at 01:10 +0200, Andreas Gruenbacher wrote: > On Wednesday 06 June 2007 15:09, Stephen Smalley wrote: > > On Mon, 2007-06-04 at 16:30 +0200, Andreas Gruenbacher wrote: > > > On Monday 04 June 2007 15:12, Pavel Machek wrote: > > > > How will kernel work with very long paths? I'd su

Re: [AppArmor 38/45] AppArmor: Module and LSM hooks

2007-06-10 Thread Andreas Gruenbacher
On Wednesday 06 June 2007 15:09, Stephen Smalley wrote: > On Mon, 2007-06-04 at 16:30 +0200, Andreas Gruenbacher wrote: > > On Monday 04 June 2007 15:12, Pavel Machek wrote: > > > How will kernel work with very long paths? I'd suspect some problems, > > > if path is 1MB long and I attempt to print

Re: [AppArmor 38/45] AppArmor: Module and LSM hooks

2007-06-09 Thread Andreas Gruenbacher
On Saturday 09 June 2007 14:58, Pavel Machek wrote: > > > How will kernel work with very long paths? I'd suspect some problems, > > > if path is 1MB long and I attempt to print it in /proc > > > somewhere. > > > > Pathnames are only used for informational purposes in the kernel, except > > in App

Re: [AppArmor 38/45] AppArmor: Module and LSM hooks

2007-06-09 Thread Pavel Machek
Hi! > > How will kernel work with very long paths? I'd suspect some problems, > > if path is 1MB long and I attempt to print it in /proc > > somewhere. > > Pathnames are only used for informational purposes in the kernel, except in > AppArmor of course. /proc only uses pathnames in a few places,

Re: [AppArmor 38/45] AppArmor: Module and LSM hooks

2007-06-06 Thread Stephen Smalley
On Mon, 2007-06-04 at 16:30 +0200, Andreas Gruenbacher wrote: > On Monday 04 June 2007 15:12, Pavel Machek wrote: > > How will kernel work with very long paths? I'd suspect some problems, > > if path is 1MB long and I attempt to print it in /proc > > somewhere. > > Pathnames are only used for info

Re: [AppArmor 38/45] AppArmor: Module and LSM hooks

2007-06-04 Thread Andreas Gruenbacher
On Monday 04 June 2007 15:12, Pavel Machek wrote: > How will kernel work with very long paths? I'd suspect some problems, > if path is 1MB long and I attempt to print it in /proc > somewhere. Pathnames are only used for informational purposes in the kernel, except in AppArmor of course. /proc onl

Re: [AppArmor 38/45] AppArmor: Module and LSM hooks

2007-06-04 Thread Pavel Machek
Hi! > > > You very well know that the vfs has a limit of PATH_MAX characters (4096) > > > for pathnames. This means that at most that many characters can be passed > > > at once. > > What users can do is something like this: > > chdir("some/long/path"); > chdir("some/even/longer/path"); >

Re: [AppArmor 38/45] AppArmor: Module and LSM hooks

2007-06-04 Thread Andreas Gruenbacher
On Monday 04 June 2007 13:35, Pavel Machek wrote: > On Mon 2007-06-04 13:25:30, Andreas Gruenbacher wrote: > > On Monday 04 June 2007 12:55, Pavel Machek wrote: > > > On Wed 2007-05-23 18:16:45, Andreas Gruenbacher wrote: > > > > On Tuesday 15 May 2007 11:14, Pavel Machek wrote: > > > > > Why is th

Re: [AppArmor 38/45] AppArmor: Module and LSM hooks

2007-06-04 Thread Pavel Machek
On Mon 2007-06-04 13:25:30, Andreas Gruenbacher wrote: > On Monday 04 June 2007 12:55, Pavel Machek wrote: > > On Wed 2007-05-23 18:16:45, Andreas Gruenbacher wrote: > > > On Tuesday 15 May 2007 11:14, Pavel Machek wrote: > > > > Why is this configurable? > > > > > > The maximum length of a pathnam

Re: [AppArmor 38/45] AppArmor: Module and LSM hooks

2007-06-04 Thread Andreas Gruenbacher
On Monday 04 June 2007 12:55, Pavel Machek wrote: > On Wed 2007-05-23 18:16:45, Andreas Gruenbacher wrote: > > On Tuesday 15 May 2007 11:14, Pavel Machek wrote: > > > Why is this configurable? > > > > The maximum length of a pathname is an arbitrary limit: we don't want to > > allocate arbitrary am

Re: [AppArmor 38/45] AppArmor: Module and LSM hooks

2007-06-04 Thread Pavel Machek
On Wed 2007-05-23 18:16:45, Andreas Gruenbacher wrote: > On Tuesday 15 May 2007 11:14, Pavel Machek wrote: > > Why is this configurable? > > The maximum length of a pathname is an arbitrary limit: we don't want to > allocate arbitrary amounts of of kernel memory for pathnames so we introduce >

Re: [AppArmor 38/45] AppArmor: Module and LSM hooks

2007-05-23 Thread Andreas Gruenbacher
On Tuesday 15 May 2007 11:14, Pavel Machek wrote: > Why is this configurable? The maximum length of a pathname is an arbitrary limit: we don't want to allocate arbitrary amounts of of kernel memory for pathnames so we introduce this limit and set it to a reasonable value. In the unlikely case t

Re: [AppArmor 38/45] AppArmor: Module and LSM hooks

2007-05-16 Thread Pavel Machek
> Module parameters, LSM hooks, initialization and teardown. > > Signed-off-by: John Johansen <[EMAIL PROTECTED]> > Signed-off-by: Andreas Gruenbacher <[EMAIL PROTECTED]> > +/* Maximum pathname length before accesses will start getting rejected */ > +unsigned int apparmor_path_max = 2 * PATH_MAX

[AppArmor 38/45] AppArmor: Module and LSM hooks

2007-05-14 Thread jjohansen
Module parameters, LSM hooks, initialization and teardown. Signed-off-by: John Johansen <[EMAIL PROTECTED]> Signed-off-by: Andreas Gruenbacher <[EMAIL PROTECTED]> Index: b/security/apparmor/lsm.c === --- /dev/null +++ b/security/appa