On Wed, Jan 16, 2013 at 2:42 PM, Lucas De Marchi
<[email protected]> wrote:
> Hi Josh,
>
> On Wed, Jan 16, 2013 at 11:55 AM, Josh Boyer <[email protected]> wrote:
>> On Tue, Jan 8, 2013 at 9:55 AM, Josh Boyer <[email protected]> wrote:
>>> Hello,
>>>
>>> We've had a report[1] that depmod -a with a non-default umask (0027 in
>>> this case) can leave the produced modules.* files with permissions other
>>> than 0644.  Now, this isn't really a bug because depmod is already
>>> explicit with its permissions and open/openat honor umask.  It can,
>>> however, leave a machine in a state where non-root users can't read those
>>> files.
>>>
>>> I'm curious if people think depmod should set its own explicit umask to
>>> ensure the file permissions are set to 0644.  If so, I could create a
>>> patch to do this rather quickly.  I wanted to get the upstream opinion on
>>> this situation first though.
>>
>> Any thoughts at all?
>
> Sorry for the delay.
>
> I think it's weird to set the umask so files are not created with read
> permission for users and then complain that depmod did exactly that.

Yeah, I do as well.

> How do I know if he indeed want to allow the user to run modinfo and
> other tools that doesn't require privilege?  After all if we reset the
> umask I don't want to receive bug reports by users complaining they
> told not to create file that way and that we are not honoring that.

Yes, that makes sense.

> That said, I never saw such a setup but if it's common to do this we
> could think about resetting the umask.  Does any distro ship with that
> umask by default?

Not that I'm aware of.  I was only asking to see if anyone else thought
it was a good idea, but it seems not.  I'll tell the bug reporter that
he should manually change the umask himself.

Thanks for the reply.

josh
--
To unsubscribe from this list: send the line "unsubscribe linux-modules" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to