pcp
[Top] [All Lists]

Re: [pcp] pmlc access control, was Re: PCP Updates: qa fallout from ipv6

To: Nathan Scott <nathans@xxxxxxxxxx>
Subject: Re: [pcp] pmlc access control, was Re: PCP Updates: qa fallout from ipv6/unix sockets for pmlogger and pmlc
From: Dave Brolley <brolley@xxxxxxxxxx>
Date: Fri, 21 Feb 2014 08:22:14 -0500
Cc: pcp@xxxxxxxxxxx
Delivered-to: pcp@xxxxxxxxxxx
In-reply-to: <1760935757.13397936.1392936985421.JavaMail.zimbra@xxxxxxxxxx>
References: <52FE5058.4030702@xxxxxxxxxx> <y0mmwhoqu69.fsf@xxxxxxxx> <757832688.10280462.1392753861578.JavaMail.zimbra@xxxxxxxxxx> <896174788.10421447.1392770006295.JavaMail.zimbra@xxxxxxxxxx> <5304D039.9010708@xxxxxxxxxx> <1347098955.12246278.1392874951684.JavaMail.zimbra@xxxxxxxxxx> <530612EC.8020206@xxxxxxxxxx> <y0meh2xmtb9.fsf_-_@xxxxxxxx> <1760935757.13397936.1392936985421.JavaMail.zimbra@xxxxxxxxxx>
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.2.0
On 02/20/2014 05:56 PM, Nathan Scott wrote:

----- Original Message -----
[...]
To secure pmlogger across AF_UNIX, it's not enough to put the sockets
into variously owned owned directories.  /var/lib/pcp/tmp is currently
world-readable, and the socket's own permissions may or may not be
Its /var/lib/pcp/tmp/pmlogger though isn't it?  We could install that 770
with no trouble, nowadays, I think...?  (and likewise for pmie)

I've currently got the system-wide socket being created in /var/run/pcp (same location as the pmcd socket) as /var/run/pcp/pmlogger.<pid>.socket. I figured that the sockets should all be in the same location. Currently the user level socket is created as ~/.pcp/pmlogger/pmlogger.<pid>.socket.

If the system-wide one stays where it is, and you want the user level hierarchy to match the systen-wide one, then then the user level socket would then go into to ~/.pcp/run/pmlogger.<pid>.socket, I suppose.

If you want the system-wide socket to go into /var/lib/pcp/tmp/pmlogger, then they would become /var/lib/pcp/tmp/pmlogger/<pid>.socket and ~/.pcp/tmp/pmlogger/<pid>.socket respectively.

It doesn't matter to me. This is all encapsulated into __pmLogLocalSocketDefault() and __pmLogLocalSocketUser() and can be changed easily.

I'm on vacation starting this afternoon and not returning until Friday Feb 28. I'll push what I have and you can change/merge/ignore it in the mean time.

Dave

<Prev in Thread] Current Thread [Next in Thread>