[pulseaudio-discuss] System mode & SHM

David Henningsson david.henningsson at canonical.com
Sun Nov 23 00:25:46 PST 2014



On 2014-11-22 22:39, Pali Rohár wrote:
> Hello,
>
> it is possible to enable shared memory when pulseaudio is stared
> in system mode?

Not without recompiling PulseAudio, the relevant code is in 
src/pulsecore/protocol_native.c, function command_auth:

#ifdef HAVE_CREDS
     if (do_shm) {
         /* Only enable SHM if both sides are owned by the same
          * user. This is a security measure because otherwise data
          * private to the user might leak. */

         const pa_creds *creds;
         if (!(creds = pa_pdispatch_creds(pd)) || getuid() != creds->uid)
             do_shm = false;
     }
#endif

Maybe there's more stuff that needs to be changed as well, I don't know.


-- 
David Henningsson, Canonical Ltd.
https://launchpad.net/~diwic


More information about the pulseaudio-discuss mailing list