LaunchAgents, SecureSocketWithKey, and permissions
I've added launchd support to dbus (https://bugs.freedesktop.org/show_bug.cgi?id=14259) -- however, I have a problem with permissions if I try to use it on 10.4. On 10.5, it creates the SecureSocketWithKey socket propertly, but on 10.4, it appears I have 2 sockets: 89990228 0 srwx------ 1 ranger wheel 0 Jan 26 14:44 /tmp/launch-Gi7nee/session 89990177 0 srwx------ 1 root wheel 0 Jan 26 14:42 /tmp/launch-xURB7Y/session ...but the one that gets set in the env var while logged in as ranger is the xURB7Y one. On a whim, I thought "hm, maybe I just need to reboot for launchd to grok it properly." On reboot, I've started a shell, and now the environment variable is not set at all. However, an lsof shows that the socket is being held by launchd: $ sudo lsof | grep /session launchd 158 ranger 9u unix 0x39cb220 0t0 /tmp/launch-7woJl9/session ...and ls shows it's owned properly: srwx------ 1 ranger wheel 0 Jan 26 15:09 /tmp/launch-7woJl9/session Any idea what I need to do to make things set up properly? Do I need to set it to KeepAlive or OnDemand=false to make it initialize right, maybe? -- Benjamin Reed a.k.a. Ranger Rick Fink, KDE, and Mac OS X development http://www.racoonfink.com/
On Jan 26, 2008 3:18 PM, Benjamin Reed <rangerrick@gmail.com> wrote:
I've added launchd support to dbus (https://bugs.freedesktop.org/show_bug.cgi?id=14259) -- however, I have a problem with permissions if I try to use it on 10.4.
Replying to myself. ;) It looks like it's only the launch-on-demand that's broken. If I put <key>OnDemand</key><false /> in my plist file, it works just fine on 10.4. Not optimal, but a suitable solution. -- Benjamin Reed a.k.a. Ranger Rick Fink, KDE, and Mac OS X development http://www.racoonfink.com/
On Jan 27, 2008, at 10:58 AM, Benjamin Reed wrote:
On Jan 26, 2008 3:18 PM, Benjamin Reed <rangerrick@gmail.com> wrote:
I've added launchd support to dbus (https://bugs.freedesktop.org/show_bug.cgi?id=14259) -- however, I have a problem with permissions if I try to use it on 10.4.
Replying to myself. ;)
It looks like it's only the launch-on-demand that's broken. If I put <key>OnDemand</key><false /> in my plist file, it works just fine on 10.4.
Not optimal, but a suitable solution.
Actually, agents are practically broken on Tiger. I wouldn't recommend using them unless you're on Leopard. davez
participants (2)
-
Benjamin Reed
-
Dave Zarzycki