public inbox for linux-audit@redhat.com
 help / color / mirror / Atom feed
From: "zhangxiliang" <zhangxiliang@cn.fujitsu.com>
To: 'Steve Grubb' <sgrubb@redhat.com>, dwmw2@infradead.org
Cc: linux-audit@redhat.com
Subject: A question about the directory watch in audit_tree.c in kernel
Date: Tue, 20 May 2008 09:11:43 +0800	[thread overview]
Message-ID: <001701c8ba16$77c11ad0$2e8da70a@fnste3fa5f55c4> (raw)

HI,
        When I use "auditctl -w /home" to watch a directory, nothing about the 
directory changed can be output.

       I found the "audit tree handle_event" in audit_tree.c in kernel. It 
implements as follows:

       static void handle_event(struct inotify_watch *watch, u32 wd, u32 mask,
                         u32 cookie, const char *dname, struct inode *inode)
{
	struct audit_chunk *chunk = container_of(watch, struct audit_chunk, watch);

	if (mask & IN_IGNORED) {
		evict_chunk(chunk);
		put_inotify_watch(watch);
	}
}

        In "handle_event", the mask can be "IN_MOVED_FROM", "IN_MOVED_TO", 
"IN_DELETE_SELF", "IN_IGNORED" and so on.
        Why it only deals with the mask  " IN_IGNORED" and ignores the other 
mask?

--
Regards
Zhang Xiliang
--------------------------------------------------
Zhang Xiliang
Development Dept.I
Nanjing Fujitsu Nanda Software Tech. Co., Ltd.(FNST) 8/F., Civil Defense 
Building, No.189 Guangzhou Road, Nanjing, 210029, China
TEL: +86+25-86630566-838
COINS: 79955-838
FAX: +86+25-83317685
MAIL: zhangxiliang@cn.fujitsu.com
--------------------------------------------------
This communication is for use by the intended recipient(s) only and may 
contain information that is privileged, confidential and exempt from 
disclosure under applicable law. If you are not an intended recipient of this 
communication, you are hereby notified that any dissemination, distribution or 
copying hereof is strictly prohibited.  If you have received this 
communication in error, please notify me by reply e-mail, permanently delete 
this communication from your system, and destroy any hard copies you may have 
printed.

             reply	other threads:[~2008-05-20  1:11 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-05-20  1:11 zhangxiliang [this message]
2008-05-20 12:06 ` A question about the directory watch in audit_tree.c in kernel Kevin Boyce
2008-05-20 12:41   ` Steve Grubb
2008-05-21  1:47   ` zhangxiliang
2008-05-21 15:03     ` Steve Grubb
2008-05-22 12:28       ` LC Bruzenak
2008-05-22 13:09         ` Steve Grubb

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='001701c8ba16$77c11ad0$2e8da70a@fnste3fa5f55c4' \
    --to=zhangxiliang@cn.fujitsu.com \
    --cc=dwmw2@infradead.org \
    --cc=linux-audit@redhat.com \
    --cc=sgrubb@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox