From: Darrel Goeddel <dgoeddel@TrustedCS.com>
To: Stephen Smalley <sds@tycho.nsa.gov>
Cc: James Morris <jmorris@redhat.com>,
Steve G <linux_4ever@yahoo.com>,
selinux@tycho.nsa.gov
Subject: Re: Getting the real task name in avc messages
Date: Thu, 31 Mar 2005 09:21:06 -0600 [thread overview]
Message-ID: <424C1562.5060108@trustedcs.com> (raw)
In-Reply-To: <1112272239.11216.9.camel@moss-spartans.epoch.ncsc.mil>
Stephen Smalley wrote:
> On Wed, 2005-03-30 at 16:27 -0600, Darrel Goeddel wrote:
>>You could also just do:
>>
>> task_lock(current);
>> audit_log_format(ab, " comm=%s", current->comm);
>> task_unlock(current);
>>
>>This avoids an unnecessary copy since we have no use the data after the
>>audit_log_format call.
>
>
> Is this locking truly necessary when accessing current->comm (as opposed
> to accessing the comm of another task)? Can it be set by any other
> task? We don't presently hold the lock when accessing it in avc_audit.
>
>
I didn't not think so, but I wasn't 100% sure. I only did a quick glance before
and thought it best to be safe. Upon further investigation, it sure looks to be
fine without holding the task lock.
--
Darrel
--
This message was distributed to subscribers of the selinux mailing list.
If you no longer wish to subscribe, send mail to majordomo@tycho.nsa.gov with
the words "unsubscribe selinux" without quotes as the message.
next prev parent reply other threads:[~2005-03-31 15:21 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-03-30 19:53 Getting the real task name in avc messages Steve G
2005-03-30 20:41 ` Stephen Smalley
2005-03-30 21:09 ` Stephen Smalley
2005-03-30 20:50 ` James Morris
2005-03-30 22:04 ` James Morris
2005-03-30 22:27 ` Darrel Goeddel
2005-03-31 12:30 ` Stephen Smalley
2005-03-31 13:36 ` Stephen Smalley
2005-03-31 15:21 ` Darrel Goeddel [this message]
2005-03-31 15:20 ` Stephen Smalley
-- strict thread matches above, loose matches on Subject: below --
2005-03-30 21:02 Steve G
2005-03-30 21:14 ` Stephen Smalley
2005-03-31 14:53 Steve G
2005-03-31 15:00 ` Stephen Smalley
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=424C1562.5060108@trustedcs.com \
--to=dgoeddel@trustedcs.com \
--cc=jmorris@redhat.com \
--cc=linux_4ever@yahoo.com \
--cc=sds@tycho.nsa.gov \
--cc=selinux@tycho.nsa.gov \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.