SD_BUS_SET_DESCRIPTION - Online Linux Manual PageSection : 3
Updated :
Source : systemd 250
Note : sd_bus_set_description

NAMEsd_bus_set_description, sd_bus_get_description, sd_bus_set_anonymous, sd_bus_is_anonymous, sd_bus_set_trusted, sd_bus_is_trusted, sd_bus_set_allow_interactive_authorization, sd_bus_get_allow_interactive_authorization, sd_bus_get_scope, sd_bus_get_tid, sd_bus_get_unique_name − Set or query properties of a bus object

SYNOPSIS#include <systemd/sd−bus​.h>int sd_bus_set_description(sd_bus *bus, const char *description); int sd_bus_get_description(sd_bus *bus, const char **description); int sd_bus_set_anonymous(sd_bus *bus, int b); int sd_bus_is_anonymous(sd_bus *bus); int sd_bus_set_trusted(sd_bus *bus, int b); int sd_bus_is_trusted(sd_bus *bus); int sd_bus_set_allow_interactive_authorization(sd_bus *bus, int b); int sd_bus_get_allow_interactive_authorization(sd_bus *bus); int sd_bus_get_scope(sd_bus *bus, const char **scope); int sd_bus_get_tid(sd_bus *bus, pid_t *tid); int sd_bus_get_unique_name(sd_bus *bus, const char **unique);

DESCRIPTIONsd_bus_set_description() sets the description string that is used in logging to the specified string​. The string is copied internally and freed when the bus object is deallocated​. The description argument may be NULL, in which case the description is unset​. This function must be called before the bus is started​. sd_bus_get_description() returns a description string in description​. This string may have been previously set with sd_bus_set_description() or sd_bus_open_with_description(3) or similar​. If not set this way, a default string like "system" or "user" will be returned for the system or user buses, and −ENXIO otherwise​. sd_bus_set_anonymous() enables or disables "anonymous authentication", i​.e​. lack of authentication, of the bus peer​. This function must be called before the bus is started​. See the Authentication Mechanisms[1] section of the D−Bus specification for details​. sd_bus_is_anonymous() returns true if the bus connection allows anonymous authentication (in the sense described in previous paragraph)​. sd_bus_set_trusted() sets the "trusted" state on the bus object​. If true, all connections on the bus are trusted and access to all privileged and unprivileged methods is granted​. This function must be called before the bus is started​. sd_bus_is_trusted() returns true if the bus connection is trusted (in the sense described in previous paragraph)​. sd_bus_set_allow_interactive_authorization() enables or disables interactive authorization for method calls​. If true, messages are marked with the ALLOW_INTERACTIVE_AUTHORIZATION flag specified by the D−Bus[2] specification, informing the receiving side that the caller is prepared to wait for interactive authorization, which might take a considerable time to complete​. If this flag is set, the user may be queried for passwords or confirmation via polkit[3] or a similar framework​. sd_bus_get_allow_interactive_authorization() returns true if interactive authorization is allowed and false if not​. sd_bus_get_scope() stores the scope of the given bus object in scope​. The scope of the system bus is "system"​. The scope of a user session bus is "user"​. If the given bus object is not the system or a user session bus, sd_bus_get_scope() returns an error​. sd_bus_get_tid() stores the kernel thread id of the thread associated with the given bus object in tid​. If bus is a default bus object obtained by calling one of the functions of the sd_bus_default(3) family of functions, it stores the thread id of the thread the bus object was created in​. Otherwise, if the bus object is attached to an event loop, it stores the thread id of the thread the event loop object was created in​. If bus is not a default bus object and is not attached to an event loop, sd_bus_get_tid() returns an error​. sd_bus_get_unique_name() stores the unique name of the bus object on the bus in unique​. See The D−Bus specification[4] for more information on bus names​. Note that the caller does not own the string stored in unique and should not free it​.

RETURN VALUEOn success, these functions return a non−negative integer​. On failure, they return a negative errno−style error code​.

ErrorsReturned errors may indicate the following problems: −EINVAL An argument is invalid​. −ENOPKG The bus cannot be resolved​. −EPERM The bus has already been started​. −ECHILD The bus was created in a different process​. −ENOMEM Memory allocation failed​. −ENODATA The bus object passed to sd_bus_get_scope() was not a system or user session bus​. −ENXIO The bus object passed to sd_bus_get_tid() was not a default bus object and is not attached to an event loop​. The bus object passed to sd_bus_get_description() did not have a description​.

NOTESThese APIs are implemented as a shared library, which can be compiled and linked to with the libsystemd ​pkg-config(1) file​.

SEE ALSOsystemd(1), sd-bus(3), sd_bus_default_user(3), sd_bus_default_system(3), sd_bus_open_user(3), sd_bus_open_system(3)

NOTES 1. Authentication Mechanisms ­view-source:https://dbus.freedesktop.org/doc/dbus-specification.html#auth-mechanisms 2. D-Bus ­view-source:https://dbus.freedesktop.org/doc/dbus-specification.html 3. polkit ­https://www.freedesktop.org/wiki/Software/polkit 4. The D-Bus specification ­https://dbus.freedesktop.org/doc/dbus-specification.html#message-protocol-names-bus
0
Johanes Gumabo
Data Size   :   23,075 byte
man-sd_bus_get_description.3Build   :   2024-12-29, 07:25   :  
Visitor Screen   :   x
Visitor Counter ( page / site )   :   2 / 260,484
Visitor ID   :     :  
Visitor IP   :   3.137.159.163   :  
Visitor Provider   :   AMAZON-02   :  
Provider Position ( lat x lon )   :   39.962500 x -83.006100   :   x
Provider Accuracy Radius ( km )   :   1000   :  
Provider City   :   Columbus   :  
Provider Province   :   Ohio ,   :   ,
Provider Country   :   United States   :  
Provider Continent   :   North America   :  
Visitor Recorder   :   Version   :  
Visitor Recorder   :   Library   :  
Online Linux Manual Page   :   Version   :   Online Linux Manual Page - Fedora.40 - march=x86-64 - mtune=generic - 24.12.29
Online Linux Manual Page   :   Library   :   lib_c - 24.10.03 - march=x86-64 - mtune=generic - Fedora.40
Online Linux Manual Page   :   Library   :   lib_m - 24.10.03 - march=x86-64 - mtune=generic - Fedora.40
Data Base   :   Version   :   Online Linux Manual Page Database - 24.04.13 - march=x86-64 - mtune=generic - fedora-38
Data Base   :   Library   :   lib_c - 23.02.07 - march=x86-64 - mtune=generic - fedora.36

Very long time ago, I have the best tutor, Wenzel Svojanovsky . If someone knows the email address of Wenzel Svojanovsky , please send an email to johanes_gumabo@yahoo.co.id .
If error, please print screen and send to johanes_gumabo@yahoo.co.id
Under development. Support me via PayPal.