summaryrefslogtreecommitdiff
path: root/dbus/dbus-sysdeps-unix.c
diff options
context:
space:
mode:
authorSimon McVittie <smcv@collabora.com>2018-01-15 20:05:05 +0000
committerSimon McVittie <smcv@collabora.com>2018-03-02 14:52:18 +0000
commitfbc2a447c4ef189567617aa1372e83141de40a68 (patch)
treee27513c12cadac071cad3f2a82e3a074f55bb7db /dbus/dbus-sysdeps-unix.c
parent395269e0bce3782b0b413fbad89bdb9337b8df9d (diff)
sysdeps: Document what _dbus_credentials_new_from_current_process has
It only has the most important credentials, not the full set. Signed-off-by: Simon McVittie <smcv@collabora.com> Reviewed-by: Philip Withnall <withnall@endlessm.com> Bug: https://bugs.freedesktop.org/show_bug.cgi?id=103737
Diffstat (limited to 'dbus/dbus-sysdeps-unix.c')
-rw-r--r--dbus/dbus-sysdeps-unix.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/dbus/dbus-sysdeps-unix.c b/dbus/dbus-sysdeps-unix.c
index f1764416..d2a331eb 100644
--- a/dbus/dbus-sysdeps-unix.c
+++ b/dbus/dbus-sysdeps-unix.c
@@ -2756,8 +2756,14 @@ _dbus_user_info_fill_uid (DBusUserInfo *info,
}
/**
- * Adds the credentials of the current process to the
- * passed-in credentials object.
+ * Adds the most important credentials of the current process
+ * (the uid and pid) to the passed-in credentials object.
+ *
+ * The group vector is not included because it is rarely needed.
+ * The Linux security label is not included because it is rarely
+ * needed, it requires reading /proc, and the LSM API doesn't actually
+ * guarantee that the string seen in /proc is comparable to the strings
+ * found in SO_PEERSEC results.
*
* @param credentials credentials to add to
* @returns #FALSE if no memory; does not properly roll back on failure, so only some credentials may have been added