From: Peng Haitao <penght@cn.fujitsu.com>
To: Steve Grubb <sgrubb@redhat.com>
Cc: audit-list <linux-audit@redhat.com>
Subject: [PATCH] Fix a bug of parsing "acct=" in function parse_user()
Date: Thu, 28 Aug 2008 18:40:01 +0800 [thread overview]
Message-ID: <48B68081.2020200@cn.fujitsu.com> (raw)
Hello steve,
The value of "acct=" which is not in double quotation, cannot be right gotten.
The log is:
type=USER_CHAUTHTOK msg=audit(1167580800.033:178653): user pid=23192 uid=0 auid=0 subj=root:system_r:unconfined_t:s0-s0:c0.c1023 msg='op=adding user acct=aulog exe="/usr/sbin/useradd" (hostname=?, addr=?, terminal=pts/6 res=success)'
Signed-off-by: Peng Haitao <penght@cn.fujitsu.com>
---
src/ausearch-parse.c | 3 +--
1 files changed, 1 insertions(+), 2 deletions(-)
diff --git a/src/ausearch-parse.c b/src/ausearch-parse.c
index d9c305a..b80b984 100644
--- a/src/ausearch-parse.c
+++ b/src/ausearch-parse.c
@@ -791,13 +791,12 @@ static int parse_user(const lnode *n, search_items *s)
*term = saved;
} else {
/* Handle legacy accts */
- char *end = term;
+ char *end = ptr;
int legacy = 0;
while (*end != ' ') {
if (!isxdigit(*end)) {
legacy = 1;
- break;
}
end++;
}
--
1.5.3
--
Regards
Peng Haitao
next reply other threads:[~2008-08-28 10:40 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-08-28 10:40 Peng Haitao [this message]
2008-08-28 19:16 ` [PATCH] Fix a bug of parsing "acct=" in function parse_user() Steve Grubb
2008-08-28 19:34 ` 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=48B68081.2020200@cn.fujitsu.com \
--to=penght@cn.fujitsu.com \
--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