Re: [PATCH 3/3] audit: drop audit_cmd_lock in AUDIT_USER family of cases

2013-12-08 Thread Toshiyuki Okajima
, > @@ -729,6 +730,7 @@ static int audit_receive_msg(struct sk_buff *skb, struct > nlmsghdr *nlh) > } > audit_set_pid(ab, NETLINK_CB(skb).portid); > audit_log_end(ab); > + mutex_lock(_cmd_mutex); > } > brea

Re: [PATCH 3/3] audit: drop audit_cmd_lock in AUDIT_USER family of cases

2013-12-08 Thread Toshiyuki Okajima
) } audit_set_pid(ab, NETLINK_CB(skb).portid); audit_log_end(ab); + mutex_lock(audit_cmd_mutex); } break; case AUDIT_ADD_RULE: -- 1.7.1 -- Toshiyuki Okajima toshi.okaj...@jp.fujitsu.com

[RESEND][BUG][PATCH V3] audit: audit_log_start running on auditd should not stop

2013-12-04 Thread Toshiyuki Okajima
not stop. You can see the deadlock with the following reproducer: # auditctl -a exit,always -S all # reboot Signed-off-by: Toshiyuki Okajima Reviewed-by: gaof...@cn.fujitsu.com --- kernel/audit.c | 14 -- 1 files changed, 8 insertions(+), 6 deletions(-) diff --git a/kernel/audit.c b

[RESEND][BUG][PATCH V3] audit: audit_log_start running on auditd should not stop

2013-12-04 Thread Toshiyuki Okajima
not stop. You can see the deadlock with the following reproducer: # auditctl -a exit,always -S all # reboot Signed-off-by: Toshiyuki Okajima toshi.okaj...@jp.fujitsu.com Reviewed-by: gaof...@cn.fujitsu.com --- kernel/audit.c | 14 -- 1 files changed, 8 insertions(+), 6 deletions(-) diff

Re: [BUG][PATCH] audit: audit_log_start running on auditd should not stop

2013-10-28 Thread Toshiyuki Okajima
Hi. (2013/10/26 0:12), Eric Paris wrote: > On Fri, 2013-10-25 at 10:36 +0900, Toshiyuki Okajima wrote: > >> systemd

Re: [BUG][PATCH] audit: audit_log_start running on auditd should not stop

2013-10-28 Thread Toshiyuki Okajima
Hi. (2013/10/26 0:12), Eric Paris wrote: On Fri, 2013-10-25 at 10:36 +0900, Toshiyuki Okajima wrote: systemd|auditd

Re: [BUG][PATCH] audit: audit_log_start running on auditd should not stop

2013-10-24 Thread Toshiyuki Okajima
Hi. Thanks for your interest. (2013/10/24 4:55), Richard Guy Briggs wrote: > On Tue, Oct 15, 2013 at 02:30:34PM +0800, Gao feng wrote: >> Hi Toshiyuki-san, > > Toshiuki and Gao, > >> On 10/15/2013 12:43 PM, Toshiyuki Okajima wrote: >>> The backlog cannot

Re: [BUG][PATCH] audit: audit_log_start running on auditd should not stop

2013-10-24 Thread Toshiyuki Okajima
Hi. Thanks for your interest. (2013/10/24 4:55), Richard Guy Briggs wrote: On Tue, Oct 15, 2013 at 02:30:34PM +0800, Gao feng wrote: Hi Toshiyuki-san, Toshiuki and Gao, On 10/15/2013 12:43 PM, Toshiyuki Okajima wrote: The backlog cannot be consumed when audit_log_start is running

[BUG][PATCH V3] audit: audit_log_start running on auditd should not stop

2013-10-15 Thread Toshiyuki Okajima
. So, audit_log_start running on auditd should not stop. You can see the deadlock with the following reproducer: # auditctl -a exit,always -S all # reboot Signed-off-by: Toshiyuki Okajima Cc: gaof...@cn.fujitsu.com --- kernel/audit.c | 14 -- 1 files changed, 8 insertions(+), 6

Re: [BUG][PATCH] audit: audit_log_start running on auditd should not stop

2013-10-15 Thread Toshiyuki Okajima
Hi Gao-san, (2013/10/15 15:30), Gao feng wrote: > Hi Toshiyuki-san, > On 10/15/2013 12:43 PM, Toshiyuki Okajima wrote: >> The backlog cannot be consumed when audit_log_start is running on auditd >> even if audit_log_start calls wait_for_auditd to consume it. >> The situati

Re: [BUG][PATCH] audit: audit_log_start running on auditd should not stop

2013-10-15 Thread Toshiyuki Okajima
Hi Gao-san, (2013/10/15 15:30), Gao feng wrote: Hi Toshiyuki-san, On 10/15/2013 12:43 PM, Toshiyuki Okajima wrote: The backlog cannot be consumed when audit_log_start is running on auditd even if audit_log_start calls wait_for_auditd to consume it. The situation is a deadlock because only

[BUG][PATCH V3] audit: audit_log_start running on auditd should not stop

2013-10-15 Thread Toshiyuki Okajima
. So, audit_log_start running on auditd should not stop. You can see the deadlock with the following reproducer: # auditctl -a exit,always -S all # reboot Signed-off-by: Toshiyuki Okajima toshi.okaj...@jp.fujitsu.com Cc: gaof...@cn.fujitsu.com --- kernel/audit.c | 14 -- 1 files

[BUG][PATCH] audit: audit_log_start running on auditd should not stop

2013-10-14 Thread Toshiyuki Okajima
. So, audit_log_start running on auditd should not stop. You can see the deadlock with the following reproducer: # auditctl -a exit,always -S all # reboot Signed-off-by: Toshiyuki Okajima Cc: gaof...@cn.fujitsu.com --- kernel/audit.c |3 +++ 1 files changed, 3 insertions(+), 0 deletions

[BUG][PATCH] audit: audit_log_start running on auditd should not stop

2013-10-14 Thread Toshiyuki Okajima
. So, audit_log_start running on auditd should not stop. You can see the deadlock with the following reproducer: # auditctl -a exit,always -S all # reboot Signed-off-by: Toshiyuki Okajima toshi.okaj...@jp.fujitsu.com Cc: gaof...@cn.fujitsu.com --- kernel/audit.c |3 +++ 1 files changed, 3

Re: [BUG][PATCH][RFC] audit: hang up in audit_log_start executed on auditd

2013-10-11 Thread Toshiyuki Okajima (smtp-b.css)
Gao-san, (2013/10/11 18:33), Gao feng wrote: > On 10/11/2013 09:36 AM, Toshiyuki Okajima wrote: >> Hi. >> >> The following reproducer causes auditd daemon hang up. >> (But the hang up is released after the audit_backlog_wait_time passes.) >> # auditctl -

Re: [BUG][PATCH][RFC] audit: hang up in audit_log_start executed on auditd

2013-10-11 Thread Toshiyuki Okajima (smtp-b.css)
Gao-san, (2013/10/11 18:33), Gao feng wrote: On 10/11/2013 09:36 AM, Toshiyuki Okajima wrote: Hi. The following reproducer causes auditd daemon hang up. (But the hang up is released after the audit_backlog_wait_time passes.) # auditctl -a exit,always -S all # reboot I reproduced

[BUG][PATCH][RFC] audit: hang up in audit_log_start executed on auditd

2013-10-10 Thread Toshiyuki Okajima
n can execute the audit_log_start, and then it can cause a hang up because only auditd daemon can consume the backlog. So, audit_log_start executed by auditd daemon should not handle the backlog in case auditd daemon hangs up (while wait_for_auditd is calling). Signed-off-by: Toshiyuki Okajima

[BUG][PATCH][RFC] audit: hang up in audit_log_start executed on auditd

2013-10-10 Thread Toshiyuki Okajima
the audit_log_start, and then it can cause a hang up because only auditd daemon can consume the backlog. So, audit_log_start executed by auditd daemon should not handle the backlog in case auditd daemon hangs up (while wait_for_auditd is calling). Signed-off-by: Toshiyuki Okajima toshi.okaj

[BUG] Failed to open a file after setgid

2013-07-03 Thread Toshiyuki Okajima
Hi guys! I encountered that a file cannot be opened even if the process has a valid access authority for the file on linux-3.10. This problem is caused since the group list which getgroups() returns includes wrong ID as the group ID after setgid(). These groups include egid of the process

[BUG] Failed to open a file after setgid

2013-07-03 Thread Toshiyuki Okajima
Hi guys! I encountered that a file cannot be opened even if the process has a valid access authority for the file on linux-3.10. This problem is caused since the group list which getgroups() returns includes wrong ID as the group ID after setgid(). These groups include egid of the process