Author: aitor Date: To: dng Subject: [DNG] New release of simple-netaid relaying on OpenWRT system bus
Hi,
Recently I packaged a new version of simple-netaid based on the U-Bus framework (OpenWRT microversion of D-Bus),
an inter-process communication that allows users to access and use services from the same place.
The main piece of U-Bus is the ubusd daemon. It provides an interface for other daemons to register themselves
as well as sending messages. Therefore, ubusd must be run in first place before the daemon of simple-netaid can
be started.
Often, U-Bus makes use of a collection of utilities widely used in the OpenWRT project, and taken from U-Box
(micro Box) such as polling, event handling, socket helper functions, and so on.
The ubus command line tool allows to interact with the ubusd server, giving us a very powerful tool for accessing
services both locally and remotely.
From the shell, we can list what services are available on the bus using the 'ubus list' command. In the live images
of gnuinos chimaera, we will get:
# ubus list
ering.netaid
To find out what procedures a certain service provides, we add '-v' in addition to the namespace path:
"Server reply - Request is being proceeded: ": "blahblahblah"
}
Note that i'm running the above command as a regular user without granted permissions, because the 'netaid'
group is already assigned to my current user account.
The ACLs are defined in /usr/share/acl.c/netaid-server.json:
Connecting to snetaid via the ubus command line interface, we'll be able to rewrite Edward Bartolo's original
backend, that may turn into a very simple bash script relaying on the 'libnetaid' library.