From: stefanb@linux.vnet.ibm.com (Stefan Berger)
To: linux-security-module@vger.kernel.org
Subject: [PATCH] security: fix description of values returned by cap_inode_need_killpriv
Date: Wed, 26 Jul 2017 14:31:08 -0400 [thread overview]
Message-ID: <1501093868-30838-1-git-send-email-stefanb@linux.vnet.ibm.com> (raw)
cap_inode_need_killpriv returns 1 if security.capability exists,
0 otherwise. Fix the description of the return value to reflect this.
Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
---
security/commoncap.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/security/commoncap.c b/security/commoncap.c
index 7abebd7..92931f8 100644
--- a/security/commoncap.c
+++ b/security/commoncap.c
@@ -302,8 +302,7 @@ static inline void bprm_clear_caps(struct linux_binprm *bprm)
* affects the security markings on that inode, and if it is, should
* inode_killpriv() be invoked or the change rejected?
*
- * Returns 0 if granted; +ve if granted, but inode_killpriv() is required; and
- * -ve to deny the change.
+ * Returns 1 if security.capability has a value, 0 otherwise.
*/
int cap_inode_need_killpriv(struct dentry *dentry)
{
--
2.7.4
--
To unsubscribe from this list: send the line "unsubscribe linux-security-module" in
the body of a message to majordomo at vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
next reply other threads:[~2017-07-26 18:31 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-07-26 18:31 Stefan Berger [this message]
2017-07-26 23:07 ` [PATCH] security: fix description of values returned by cap_inode_need_killpriv Serge E. Hallyn
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=1501093868-30838-1-git-send-email-stefanb@linux.vnet.ibm.com \
--to=stefanb@linux.vnet.ibm.com \
--cc=linux-security-module@vger.kernel.org \
/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;
as well as URLs for NNTP newsgroup(s).