summaryrefslogtreecommitdiff
path: root/man/sd_bus_creds_get_pid.xml
diff options
context:
space:
mode:
authorMartin Pitt <martin.pitt@ubuntu.com>2014-11-20 15:28:12 +0100
committerMartin Pitt <martin.pitt@ubuntu.com>2014-11-20 15:28:12 +0100
commit5eef597e931b0428bb984dc2bf0736d032a9198c (patch)
treec24d24d36d083e227a6ba3c1b5ae5c40ae822cb2 /man/sd_bus_creds_get_pid.xml
parente842803ae5f3f162fa51f30787c3b2423e3826cf (diff)
downloadsystemd-5eef597e931b0428bb984dc2bf0736d032a9198c.tar.gz
Imported Upstream version 217
Diffstat (limited to 'man/sd_bus_creds_get_pid.xml')
-rw-r--r--man/sd_bus_creds_get_pid.xml102
1 files changed, 58 insertions, 44 deletions
diff --git a/man/sd_bus_creds_get_pid.xml b/man/sd_bus_creds_get_pid.xml
index f84fbae35c..23763bd6ae 100644
--- a/man/sd_bus_creds_get_pid.xml
+++ b/man/sd_bus_creds_get_pid.xml
@@ -67,6 +67,7 @@ along with systemd; If not, see <http://www.gnu.org/licenses/>.
<refname>sd_bus_creds_get_audit_login_uid</refname>
<refname>sd_bus_creds_get_unique_name</refname>
<refname>sd_bus_creds_get_well_known_names</refname>
+ <refname>sd_bus_creds_get_connection_name</refname>
<refpurpose>Retrieve fields from a credentials object</refpurpose>
</refnamediv>
@@ -219,6 +220,12 @@ along with systemd; If not, see <http://www.gnu.org/licenses/>.
<paramdef>char ***<parameter>name</parameter></paramdef>
</funcprototype>
+ <funcprototype>
+ <funcdef>int <function>sd_bus_creds_get_connection_name</function></funcdef>
+ <paramdef>sd_bus_creds *<parameter>c</parameter></paramdef>
+ <paramdef>const char **<parameter>name</parameter></paramdef>
+ </funcprototype>
+
</funcsynopsis>
</refsynopsisdiv>
@@ -230,77 +237,77 @@ along with systemd; If not, see <http://www.gnu.org/licenses/>.
<citerefentry><refentrytitle>sd_bus_creds_new_from_pid</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
in which case it will describe the specified process, or it may be
created by
- <citerefentry><refentrytitle>sd_bus_get_peer_creds</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+ <citerefentry><refentrytitle>sd_bus_get_owner_creds</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
in which case it will describe the process at the other endpoint
of a connection.
</para>
- <para><function>sd_bus_creds_get_pid</function> will retrieve the
+ <para><function>sd_bus_creds_get_pid()</function> will retrieve the
PID (process identifier).</para>
- <para><function>sd_bus_creds_get_pid_starttime</function> will
+ <para><function>sd_bus_creds_get_pid_starttime()</function> will
retrieve the time since the start of the epoch in microseconds
since the process was started.</para>
- <para><function>sd_bus_creds_get_tid</function> will retrieve the
+ <para><function>sd_bus_creds_get_tid()</function> will retrieve the
TID (thread identifier).</para>
- <para><function>sd_bus_creds_get_uid</function> will retrieve the
+ <para><function>sd_bus_creds_get_uid()</function> will retrieve the
numeric UID (user identifier).</para>
- <para><function>sd_bus_creds_get_gid</function> will retrieve the
+ <para><function>sd_bus_creds_get_gid()</function> will retrieve the
numeric GID (group identifier).</para>
- <para><function>sd_bus_creds_get_comm</function> will retrieve the
+ <para><function>sd_bus_creds_get_comm()</function> will retrieve the
comm field (truncated name of the executable, as stored in
<filename>/proc/<replaceable>pid</replaceable>/comm</filename>).
</para>
- <para><function>sd_bus_creds_get_tid_comm</function> will retrieve
+ <para><function>sd_bus_creds_get_tid_comm()</function> will retrieve
the comm field of the thread (as stored in
<filename>/proc/<replaceable>pid</replaceable>/task/<replaceable>tid</replaceable>/comm</filename>).
</para>
- <para><function>sd_bus_creds_get_exe</function> will retrieve the
+ <para><function>sd_bus_creds_get_exe()</function> will retrieve the
path to the program (as stored in the
<filename>/proc/<replaceable>pid</replaceable>/exe</filename>
link, but with <literal> (deleted)</literal> suffix removed).
</para>
- <para><function>sd_bus_creds_get_cmdline</function> will retrieve
+ <para><function>sd_bus_creds_get_cmdline()</function> will retrieve
an array of command-line arguments (as stored in
<filename>/proc/<replaceable>pid</replaceable>/cmdline</filename>).
</para>
- <para><function>sd_bus_creds_get_cgroup</function> will retrieve
+ <para><function>sd_bus_creds_get_cgroup()</function> will retrieve
the cgroup path. See <ulink
url="https://www.kernel.org/doc/Documentation/cgroups/cgroups.txt">cgroups.txt</ulink>.
</para>
- <para><function>sd_bus_creds_get_unit</function> will retrieve the
+ <para><function>sd_bus_creds_get_unit()</function> will retrieve the
systemd unit name (in the system instance of systemd) that the
process is part of. See
<citerefentry><refentrytitle>systemd.unit</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
</para>
- <para><function>sd_bus_creds_get_user_unit</function> will
+ <para><function>sd_bus_creds_get_user_unit()</function> will
retrieve the systemd unit name (in the user instance of systemd)
that the process is part of. See
<citerefentry><refentrytitle>systemd.unit</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
</para>
- <para><function>sd_bus_creds_get_slice</function> will retrieve
+ <para><function>sd_bus_creds_get_slice()</function> will retrieve
the systemd slice (a unit in the system instance of systemd) that
the process is part of. See
<citerefentry><refentrytitle>systemd.slice</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
</para>
- <para><function>sd_bus_creds_get_session</function> will retrieve
+ <para><function>sd_bus_creds_get_session()</function> will retrieve
the logind session that the process is part of. See
<citerefentry><refentrytitle>systemd-logind.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>.
</para>
- <para><function>sd_bus_creds_get_owner_uid</function> will retrieve
+ <para><function>sd_bus_creds_get_owner_uid()</function> will retrieve
the numeric UID (user identifier) of the user who owns the slice
that the process is part of. See
<citerefentry><refentrytitle>systemd.slice</refentrytitle><manvolnum>5</manvolnum></citerefentry>
@@ -308,50 +315,57 @@ along with systemd; If not, see <http://www.gnu.org/licenses/>.
<citerefentry><refentrytitle>systemd-user-sessions.service</refentrytitle><manvolnum>8</manvolnum></citerefentry> -->.
</para>
- <para><function>sd_bus_creds_has_effective_cap</function> will
+ <para><function>sd_bus_creds_has_effective_cap()</function> will
check whether the capability specified by
<parameter>capability</parameter> was set in the effective
capabilities mask. A positive return value means that is was
set, zero means that it was not set, and a negative return
value signifies an error. See
- <citerefentry><refentrytitle>capabilities</refentrytitle><manvolnum>7</manvolnum></citerefentry>
+ <citerefentry project='man-pages'><refentrytitle>capabilities</refentrytitle><manvolnum>7</manvolnum></citerefentry>
and <varname>Capabilities=</varname> and
<varname>CapabilityBoundingSet=</varname> settings in
<citerefentry><refentrytitle>systemd.exec</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
</para>
- <para><function>sd_bus_creds_has_permitted_cap</function> is
- similar to <function>sd_bus_creds_has_effective_cap</function>,
+ <para><function>sd_bus_creds_has_permitted_cap()</function> is
+ similar to <function>sd_bus_creds_has_effective_cap()</function>,
but will check the permitted capabilities mask.</para>
- <para><function>sd_bus_creds_has_inheritable_cap</function> is
- similar to <function>sd_bus_creds_has_effective_cap</function>,
+ <para><function>sd_bus_creds_has_inheritable_cap()</function> is
+ similar to <function>sd_bus_creds_has_effective_cap()</function>,
but will check the inheritable capabilities mask.</para>
- <para><function>sd_bus_creds_has_bounding_cap</function> is
- similar to <function>sd_bus_creds_has_effective_cap</function>,
+ <para><function>sd_bus_creds_has_bounding_cap()</function> is
+ similar to <function>sd_bus_creds_has_effective_cap()</function>,
but will check the bounding capabilities mask.</para>
- <para><function>sd_bus_creds_get_selinux_context</function> will
+ <para><function>sd_bus_creds_get_selinux_context()</function> will
retrieve the SELinux security context (label) of the process.</para>
- <para><function>sd_bus_creds_get_audit_session_id</function> will
+ <para><function>sd_bus_creds_get_audit_session_id()</function> will
retrieve the audit session identifier of the process.</para>
- <para><function>sd_bus_creds_get_audit_login_uid</function> will
+ <para><function>sd_bus_creds_get_audit_login_uid()</function> will
retrieve the audit user login identifier (the identifier of the
user who is "responsible" for the session).</para>
- <para><function>sd_bus_creds_get_unique_name</function> will
+ <para><function>sd_bus_creds_get_unique_name()</function> will
retrieve the D-Bus unique name. See <ulink
url="http://dbus.freedesktop.org/doc/dbus-specification.html#message-protocol-names-bus">The
D-Bus specification</ulink>.</para>
- <para><function>sd_bus_creds_get_well_known_names</function> will
+ <para><function>sd_bus_creds_get_well_known_names()</function> will
retrieve the set of D-Bus well-known names. See <ulink
url="http://dbus.freedesktop.org/doc/dbus-specification.html#message-protocol-names-bus">The
D-Bus specification</ulink>.</para>
+ <para><function>sd_bus_creds_get_connection_name()</function> will
+ retrieve a descriptive name of the bus connection of the
+ peer. This name is useful to discern multiple bus connections by
+ the same peer, and may be altered by the peer with the
+ <citerefentry><refentrytitle>sd_bus_set_name()</refentrytitle><manvolnum>3</manvolnum></citerefentry>
+ call.</para>
+
<para>All functions that take a <parameter>const
char**</parameter> parameter will store the answer there as an
address of a NUL-terminated string. It will be valid as long as
@@ -381,7 +395,7 @@ along with systemd; If not, see <http://www.gnu.org/licenses/>.
<variablelist>
<varlistentry>
- <term><varname>-ENODATA</varname></term>
+ <term><constant>-ENODATA</constant></term>
<listitem><para>Given field is not available in
<parameter>c</parameter>.</para>
@@ -389,36 +403,36 @@ along with systemd; If not, see <http://www.gnu.org/licenses/>.
</varlistentry>
<varlistentry>
- <term><varname>-ENOENT</varname></term>
+ <term><constant>-ENOENT</constant></term>
<listitem><para>Given field is not specified for the sender.
- This will be returned by <function>sd_bus_get_unit</function>,
- <function>sd_bus_get_user_unit</function>,
- <function>sd_bus_get_slice</function>,
- <function>sd_bus_get_session</function>, and
- <function>sd_bus_get_owner_uid</function> if the sender is not
+ This will be returned by <function>sd_bus_get_unit()</function>,
+ <function>sd_bus_get_user_unit()</function>,
+ <function>sd_bus_get_slice()</function>,
+ <function>sd_bus_get_session()</function>, and
+ <function>sd_bus_get_name_creds_uid()</function> if the sender is not
part of a systemd system unit, systemd user unit, systemd
slice, logind session, or a systemd user session.</para>
</listitem>
</varlistentry>
<varlistentry>
- <term><varname>-ENXIO</varname></term>
+ <term><constant>-ENXIO</constant></term>
- <listitem><para>An error occured in parsing cgroup paths.
+ <listitem><para>An error occurred in parsing cgroup paths.
<filename>libsystemd</filename> might be out of sync with
the running systemd version.</para></listitem>
</varlistentry>
<varlistentry>
- <term><varname>-EINVAL</varname></term>
+ <term><constant>-EINVAL</constant></term>
<listitem><para>Specified pointer parameter is <constant>NULL</constant>.
</para></listitem>
</varlistentry>
<varlistentry>
- <term><varname>-ENOMEM</varname></term>
+ <term><constant>-ENOMEM</constant></term>
<listitem><para>Memory allocation failed.</para></listitem>
</varlistentry>
@@ -431,7 +445,7 @@ along with systemd; If not, see <http://www.gnu.org/licenses/>.
<para><function>sd_bus_open_user()</function> and other functions
described here are available as a shared library, which can be
compiled and linked to with the
- <constant>libsystemd</constant> <citerefentry><refentrytitle>pkg-config</refentrytitle><manvolnum>1</manvolnum></citerefentry>
+ <constant>libsystemd</constant> <citerefentry project='die-net'><refentrytitle>pkg-config</refentrytitle><manvolnum>1</manvolnum></citerefentry>
file.</para>
</refsect1>
@@ -441,11 +455,11 @@ along with systemd; If not, see <http://www.gnu.org/licenses/>.
<para>
<citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
<citerefentry><refentrytitle>sd-bus</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
- <citerefentry><refentrytitle>credentials</refentrytitle><manvolnum>7</manvolnum></citerefentry>,
<citerefentry><refentrytitle>fork</refentrytitle><manvolnum>2</manvolnum></citerefentry>,
<citerefentry><refentrytitle>execve</refentrytitle><manvolnum>2</manvolnum></citerefentry>,
- <citerefentry><refentrytitle>free</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
- <citerefentry><refentrytitle>proc</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
+ <citerefentry project='man-pages'><refentrytitle>credentials</refentrytitle><manvolnum>7</manvolnum></citerefentry>,
+ <citerefentry project='man-pages'><refentrytitle>free</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+ <citerefentry project='man-pages'><refentrytitle>proc</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
<citerefentry><refentrytitle>systemd.journald-fields</refentrytitle><manvolnum>7</manvolnum></citerefentry>
</para>
</refsect1>