summaryrefslogtreecommitdiff
path: root/src/libsystemd-bus/bus-util.h
AgeCommit message (Collapse)Author
2013-12-19bus: fix exit-on-idle for driverdLennart Poettering
2013-12-13event: rework sd-event exit logicLennart Poettering
With this change a failing event source handler will not cause the entire event loop to fail. Instead, we just disable the specific event source, log a message at debug level and go on. This also introduces a new concept of "exit code" which can be stored in the event loop and is returned by sd_event_loop(). We also rename "quit" to "exit" everywhere else. Altogether this should make things more robus and keep errors local while still providing a way to return event loop errors in a clear way.
2013-11-28bus: add new sd_bus_creds object to encapsulate process credentialsLennart Poettering
This way we can unify handling of credentials that are attached to messages, or can be queried for bus name owners or connection peers. This also adds the ability to extend incomplete credential information with data from /proc, Also, provide a convenience call that will automatically determine the most appropriate credential object for an incoming message, by using the the attached information if possible, the sending name information if available and otherwise the peer's credentials.
2013-11-28bus: add bus_name_has_owner() helperDavid Herrmann
Small helper to run a synchronous "NameHasOwner" request on the dbus-daemon.
2013-11-22bus: protected dual timestamp property macro for misusageLennart Poettering
2013-11-21bus: rework message handlers to always take an error argumentLennart Poettering
Message handler callbacks can be simplified drastically if the dispatcher automatically replies to method calls if errors are returned. Thus: add an sd_bus_error argument to all message handlers. When we dispatch a message handler and it returns negative or a set sd_bus_error we send this as message error back to the client. This means errors returned by handlers by default are given back to clients instead of rippling all the way up to the event loop, which is desirable to make things robust. As a side-effect we can now easily turn the SELinux checks into normal function calls, since the method call dispatcher will generate the right error replies automatically now. Also, make sure we always pass the error structure to all property and method handlers as last argument to follow the usual style of passing variables for return values as last argument.
2013-11-20core: convert PID 1 to libsystemd-busLennart Poettering
This patch converts PID 1 to libsystemd-bus and thus drops the dependency on libdbus. The only remaining code using libdbus is a test case that validates our bus marshalling against libdbus' marshalling, and this dependency can be turned off. This patch also adds a couple of things to libsystem-bus, that are necessary to make the port work: - Synthesizing of "Disconnected" messages when bus connections are severed. - Support for attaching multiple vtables for the same interface on the same path. This patch also fixes the SetDefaultTarget() and GetDefaultTarget() bus calls which used an inappropriate signature. As a side effect we will now generate PropertiesChanged messages which carry property contents, rather than just invalidation information.
2013-11-08systemctl: restore ability to directly connect to PID1 from systemctlLennart Poettering
2013-11-08systemctl: port to libsystemd-busMarc-Antoine Perennou
2013-11-07bus: log message parsing errors everywhere with a generalized ↵Lennart Poettering
bus_log_parse_error()
2013-11-07bus: make bus_print_all_properties work for non machinectl casesSimon Peeters
add a destination parameter and skip properties we can't read
2013-11-05bus: update bus_map_all_properties()Kay Sievers
2013-11-05logind: port logind to libsystemd-busLennart Poettering
2013-11-05bus: make it easy to serialize C99 bools and uids/gids/pids via vtable ↵Lennart Poettering
properties
2013-11-02bus: use internal helper to read org.freedesktop.DBus.Properties::GetAll ↵Kay Sievers
variables
2013-10-30run: add support for executing commands remotely via SSH or in a containerLennart Poettering
Also, unify the transport logic a bit, since we reuse the same scheme in many of our client tools.
2013-10-30bus: move ssh support into public API of libsystem-busLennart Poettering
2013-10-30machinectl: port to sd-busTom Gundersen
2013-10-30machined: port over to libsystemd-busLennart Poettering
2013-10-18fsck: port to sd-busTom Gundersen
2013-10-16timedated: use libsystemd-bus instead of libdbus for bus communicationLennart Poettering
Among other things this also adds a few things necessary for the change: - Considerably more powerful error returning APIs in libsystemd-bus - Adapter for connecting an sd_bus to an sd_event - As I reworked the PolicyKit logic to the new library I also made it asynchronous, so that PolicyKit requests of one user cannot block out another user anymore. - We always use the macro names for common bus error. That way it is harder to mistype them since the compiler will notice