diff --git a/man/rules/meson.build b/man/rules/meson.build index 5dadd5fc6cb..9673ef8886f 100644 --- a/man/rules/meson.build +++ b/man/rules/meson.build @@ -242,6 +242,14 @@ manpages = [ 'sd_bus_request_name_async'], ''], ['sd_bus_set_connected_signal', '3', ['sd_bus_get_connected_signal'], ''], + ['sd_bus_set_description', + '3', + ['sd_bus_get_allow_interactive_authorization', + 'sd_bus_get_description', + 'sd_bus_set_allow_interactive_authorization', + 'sd_bus_set_anonymous', + 'sd_bus_set_trusted'], + ''], ['sd_bus_set_sender', '3', ['sd_bus_get_sender'], ''], ['sd_bus_set_watch_bind', '3', ['sd_bus_get_watch_bind'], ''], ['sd_bus_slot_set_destroy_callback', diff --git a/man/sd-bus.xml b/man/sd-bus.xml index a84af2b878e..8c7b60743c9 100644 --- a/man/sd-bus.xml +++ b/man/sd-bus.xml @@ -71,6 +71,7 @@ sd_bus_reply_method_error3, sd_bus_request_name3, sd_bus_set_connected_signal3, +sd_bus_set_description3, sd_bus_set_sender3, sd_bus_set_watch_bind3 sd_bus_set_slot_destroy_callback3, diff --git a/man/sd_bus_set_description.xml b/man/sd_bus_set_description.xml new file mode 100644 index 00000000000..af02c20dd8c --- /dev/null +++ b/man/sd_bus_set_description.xml @@ -0,0 +1,188 @@ + + + + + + + + + sd_bus_set_description + systemd + + + + sd_bus_set_description + 3 + + + + sd_bus_set_description + sd_bus_get_description + sd_bus_set_anonymous + sd_bus_set_trusted + sd_bus_set_allow_interactive_authorization + sd_bus_get_allow_interactive_authorization + + Set or query properties of a bus object + + + + + #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_set_trusted + sd_bus *bus + int b + + + + int sd_bus_set_allow_interactive_authorization + sd_bus *bus + int b + + + + int sd_bus_get_allow_interactive_authorization + sd_bus *bus + + + + + + Description + + sd_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 + has been 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_description3 + or similar. If not set this way, a default string like system + or user will be returned for the system or user buses, + and NULL 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 has been started. See the Authentication + Mechanisms section of the D-Bus specification for details. + + 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 has been started. + + 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 + 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 or a + similar framework. + + sd_bus_get_allow_interactive_authorization() returns + true if interactive authorization is allowed and false if not. + + + + Return Value + + On success, these functions return 0 or a positive integer. On failure, + they return a negative errno-style error code. + + + + Errors + + Returned 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. + + + + + + + + + See Also + + + systemd1, + sd-bus3, + sd_bus_default_user3, + sd_bus_default_system3, + sd_bus_open_user3, + sd_bus_open_system3 + + + +