Re: [SlimDevices: Unix] which files does slimuser need write access to?

2009-10-28 Thread slackgraham

ah, closer inspection of the rpm shows it's just those .conf files (in
addition to logs, prefs  cache).


-- 
slackgraham

slackgraham's Profile: http://forums.slimdevices.com/member.php?userid=24814
View this thread: http://forums.slimdevices.com/showthread.php?t=70477

___
unix mailing list
unix@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/unix


[SlimDevices: Unix] which files does slimuser need write access to?

2009-10-27 Thread slackgraham

Hi,

I need advice on fine tuning some directory permissions of a 7.4.1
installation (on slackware):

The server runs as user slimuser.
I've extracted from the tarball, and as per the usual practice of
separating the application code from runtime files I've:

* relocated obviously runtime data files, as defined by the server
flags --logdir, --prefsdir, --cachedir into various dirs under /var, and
changed their ownership to slimuser

* left the main tree (/opt/squeezeboxserver) owned by root, readonly
for slimuser (this directory contains the rest of the tarball, ie.
slimserver.pl, Bin, CPAN, MySQL, et al)

This is working fine but I'm wary that sooner or later the server,
running as slimuser, will expect to be able to write into
/opt/squeezeboxserver.
I notice for example that the redhat install relocates the various
.conf files into /etc/squeezeboxserver.

Can anyone advise on whether these .conf files and/or any others need
to be writeable by slimuser?


-- 
slackgraham

slackgraham's Profile: http://forums.slimdevices.com/member.php?userid=24814
View this thread: http://forums.slimdevices.com/showthread.php?t=70477

___
unix mailing list
unix@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/unix


Re: [SlimDevices: Unix] root dir of 7.4.1 tarball ?

2009-10-26 Thread slackgraham

yes, I expect it's something like that, just want to know for sure from
someone involved in creating the builds...


-- 
slackgraham

slackgraham's Profile: http://forums.slimdevices.com/member.php?userid=24814
View this thread: http://forums.slimdevices.com/showthread.php?t=70370

___
unix mailing list
unix@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/unix


Re: [SlimDevices: Unix] root dir of 7.4.1 tarball ?

2009-10-26 Thread slackgraham

thanks :)


-- 
slackgraham

slackgraham's Profile: http://forums.slimdevices.com/member.php?userid=24814
View this thread: http://forums.slimdevices.com/showthread.php?t=70370

___
unix mailing list
unix@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/unix


Re: [SlimDevices: Unix] spawned mplayer process running as root

2009-10-13 Thread slackgraham

The root issue doesn't happen with Ubuntu or SuSe installations so I
think it may be specific to your system, your distribution or how
mplayer has been installed.

My system is slackware 12, stock kernel; mplayer has no set uid/gid
flags.
If it works on other Linux distros then I guess it must be down to
different compilation options the distros use for the kernels.

Unfortunately I don't have the time to look through the slimserver code
in detail, but on slackware setting the real uid  gid solves the
problem, as per the patch below.


*** slimserver.pl.orig  2009-07-25 14:38:12.0 +0100
--- slimserver.pl   2009-07-25 15:26:35.0 +0100
***
*** 879,885 
# $) = 1234 1234

undef $!;
!   $) = $pgid $pgid  . join ( , @sgids);

if ( $! ) {
die Unable to set effective group(s) to $group ($gid) is: $):
$!\n;
--- 879,887 
# $) = 1234 1234

undef $!;
!   #$) = $pgid $pgid  . join ( , @sgids);
!   # and real groups
!   $( = $) = $pgid $pgid  . join ( , @sgids);

if ( $! ) {
die Unable to set effective group(s) to $group ($gid) is: $):
$!\n;
***
*** 888,894 
# Finally, change effective user id.

undef $!;
!   $ = $uid;

if ( $! ) {
die Unable to set effective user to $user, ($uid)!\n;
--- 890,898 
# Finally, change effective user id.

undef $!;
!   #$ = $uid;
!   # AND real uid (so child processes also have this uid)
!   $ = $ = $uid;

if ( $! ) {
die Unable to set effective user to $user, ($uid)!\n;


-- 
slackgraham

slackgraham's Profile: http://forums.slimdevices.com/member.php?userid=24814
View this thread: http://forums.slimdevices.com/showthread.php?t=65938

___
unix mailing list
unix@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/unix


[SlimDevices: Unix] spawned mplayer process running as root

2009-07-25 Thread slackgraham

Hi,

As per the normal install I'm running squeezecenter as a non-root uid.
However, I notice that spawned mplayer processes (eg. via the Alien
plugin) are running as root (and my firewall setup will block them).

It seems that when slimserver starts it changes just the *effective*
uid not real uid.

Does anyone know of a specific reason it the real uid is not changed?
Alternatively, is there some way to configure squeezecenter/alien to
launch mplayer with the same effective uid as the parent process?

rgds,
g.


-- 
slackgraham

slackgraham's Profile: http://forums.slimdevices.com/member.php?userid=24814
View this thread: http://forums.slimdevices.com/showthread.php?t=65938

___
unix mailing list
unix@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/unix