dumb auditdeny question
Hi!
I wanted to get rid of the following message:
avc: denied { create } for pid=400 exe=/usr/bin/vim
scontext=kernel_u:kernel_r:kernel_d tcontext=kernel_u:object_r:tcb_t tclass=file
so I have the following in my policy:
auditdeny kernel_d tcb_t:{ file lnk_file sock_file fifo_file chr_file }
{ ioctl append rename create };But I still get the message.
What did I do wrong?
Signature · 7 lines
GNU GPL: csak tiszta forrásból -- This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.
Quoted 6 lines · Magosányi Árpád
I wanted to get rid of the following message:
avc: denied { create } for pid=400 exe=/usr/bin/vim
scontext=kernel_u:kernel_r:kernel_d tcontext=kernel_u:object_r:tcb_t tclass=file
Quoted 7 lines
so I have the following in my policy:
auditdeny
kernel_dtcb_t:{ filelnk_filesock_filefifo_filechr_file}{ ioctl append rename create };But I still get the message.
What did I do wrong?
Change the "auditdeny" to "dontaudit".
What you are saying with the auditdeny line is "audit a denial of these operations" { ioctl, append, rename, create }. dontaudit means don't audit what you have listed.
Use of auditdeny tends to cause confusion, so use dontaudit instead :)
faye
Signature · 9 lines
Faye Coker [email protected] -- This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.
Quoted 8 lines · Magosányi Árpád
Hi!
I wanted to get rid of the following message:
avc: denied { create } for pid=400 exe=/usr/bin/vim
scontext=kernel_u:kernel_r:kernel_d tcontext=kernel_u:object_r:tcb_t tclass=file
Quoted 9 lines
so I have the following in my policy:
auditdeny
kernel_dtcb_t:{ filelnk_filesock_filefifo_filechr_file}{ ioctl append rename create };But I still get the message.
What did I do wrong?
You want to use the "dontaudit" command. Auditdeny says to generate a message only when permission was denied on the specified access. So you probably want:
dontaudit kernel_d tcb_t:{ file lnk_file sock_file fifo_file chr_file }
{ ioctl append rename create };It's not a dumb question; the auditdeny keyword is confusing. That's one reason the dontaudit syntax was introduced. I believe in the base (NSA) policy there are no uses of auditdeny.
David
__________________________________
David Caplan 410 290 1411 x105
[email protected]
Tresys Technology, LLC
8840 Stanford Blvd., Suite 2100
Columbia, MD 21045
--
This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.