Morning,

"Alexandre Ratchov" <a...@caoua.org> wrote:
> Hi,
>
> mixerctl is still the appropriate tool here, sndioctl is not inteded
> to be run as root.

Oh, really?

> usbhidaction runs as root, given /dev/uhidN permissions, it's clearly
> not intended to run "high level" user commands.

The keys, however frivolous memight find them, are clearly to apply to
the output belonging to the terminal that the kbd is attached to.

Your design is flawed, on multiple levels. Read my message from
yesterday to find out why.

> For instance it makes
> no sense to run "audiocious -u" when Pause/Play key is hit, it's the
> similar for sndioctl. The mixerctl utility remains for such "low
> level" use cases.

Again, just like scroll lock (and just about every other key), it's to
apply (by default) to the current terminal (mesupposes X as a whole,
taking up a single ttyC, counts as one). They're software keys, not
hardware buttons. The latter are not generally attached to the keyboard
interface, to prevent exactly this kind of confusion of levels.

> Any program using sndiod is intended to be used one user at a time for
> obvious privacy reasons, this is quickly explained in the last
> section of sndio(7).

The privacy concern is legitimate; the solution you have implemented is
needlessly restrictive. At the very least, socket permissions can be
relied on to provide access control. root will ignore such permissions,
making access by root always work (as it should).

        --zeurkous.

-- 
Friggin' Machines!

Reply via email to