rdo now supports taking a group name instead of only allowing a single
user.
This also completely removes the user option, as it isn't necessary
anymore with groups support.
Before we made the ensuredir() function recurse on itself
if we couldn't open /run/rdo, after mkdir()'ing it,
to retry opening the directory.
Now we simplify and add a simple fd = open([...]) directly
after the mkdir(), to avoid the recursion.
If the second open fails, we error out.
In sessions.h, now line 95, we used sizeof(ts_str) to
determine how much to write, but as ts_str can be longer
than the actual string written, it wrote random data
after the actual timestamp.
This is by far the heaviest feature of rdo, justifying
its own file for its 140loc.
It creates sessions, inspired by the way doas does it.
We use the /run/rdo temporary folder to store files in the
format of /run/rdo/pid-ts, pid being the PID of the process
that executed rdo, and ts being the timestamp at which said
process started.
As no 2 processes can have the exact same PID and startup time
(startup time is measured in the milliseconds), this seems secure.
Closes#4.