[systemd-devel] [RFC PATCH] journal: pass uid.gid in the stream header

Zbigniew Jędrzejewski-Szmek zbyszek at in.waw.pl
Mon Jan 5 11:14:59 PST 2015

On Mon, Jan 05, 2015 at 02:55:11PM +0100, Zbigniew Jędrzejewski-Szmek wrote:
> > SO_PEERCRED apparently returns the euid/egid of the original
> > process. The UNIX "saved" uid was invented precisely to allow
> > temporarily lowering the euid and later on returning to it. Maybe
> > that's what we should use here: if the uid to run something is is not
> > root: drop to the final euid temporarily, making use of the save uid
> > to return to root, then connecting to journald, and then returning
> > back to the root euid for the rest of the way. ugly, but unix.
> Yeah, that sounds like a better option. I'll remake the patch.
This was rather straightforward, I just pushed the fix.


More information about the systemd-devel mailing list