[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: swapon permissions



> >>>Noticed today in the middle of bootup messages that swapon is
> >>>complaining about permissions set to 1660 and were insecure. It
> >>>suggested (as I recall) 0660. I never saw this before.
> >>>How do I go about changing them ?
> >>
> >>This bug was already reported here:
> >>http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=196857
> >>
> >>You can get rid of that annoying message by issuing following as root:
> >>chmod 0600 /sbin/swapon
> >
> >You mixed up something here, that should be the permission of *swap
> >files*, not of the swapon utility.  But it is true that this will get
> >rid of the message, because no swap space is going to activated if
> >/sbin/swapon is not executable by anyone.

Indeed, my fault.

>   So what's the solution..and is it that important. After reading
> the bug report I don't think it's all that big a deal ?

As you've read from the link, the swapfile shouldn't be world
readable. Swapon just wrongly assumes that file has bad 
permissions (due to the sticky bit).

So, yes, chmod 0600 swapfile will get rid of the warning.

T.


Reply to: