[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20100207141445.GA19744@kroah.com>
Date: Sun, 7 Feb 2010 06:14:45 -0800
From: Greg KH <greg@...ah.com>
To: wzt wzt <wzt.wzt@...il.com>
Cc: linux-kernel@...r.kernel.org, sds@...ho.nsa.gov, jmorris@...ei.org,
eparis@...isplace.org
Subject: Re: [PATCH] LSM: add static to security_ops variable
On Sun, Feb 07, 2010 at 07:24:44PM +0800, wzt wzt wrote:
> security_ops was declared as a global variable, so other drivers or
> kernel code can easily change its value, like:
>
> extern struct security_operations *security_ops;
> security_ops = NULL;
>
> then insmod this driver immediately, it will get an oops. Other evil
> drivers can aslo fake this variable as extern.
Evil drivers can do lots of things, if you can load a kernel module on
the system, all bets are off. Just making this a private variable does
not mean much.
What external module are you trying to keep from using this variable?
thanks,
greg k-h
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists