Re: Bitkeeper licence issues

From: Ton Hospel (linux-kernel@ton.iguana.be)
Date: Wed Mar 20 2002 - 17:42:20 EST


In article <20020319215800.GN12260@atrey.karlin.m__.cuni.cz>,
        Pavel Machek <pavel@suse.cz> writes:
> If nasty user on same system creates symlink (ln -s /etc/passwd
> /tmp/installer123), he may overwrite any file on the system. You probably want
>
> fd = open(installer_name, O_WRONLY | O_TRUNC | O_CREAT | O_EXCL, 0755);
>
> Same goes for data.
> Pavel
fd = open(installer_name, O_WRONLY | O_TRUNC | O_CREAT | O_EXCL, 0777);

the 0777 will still be modified by the umask. If people want e.g.
writability for group for some reason, let them.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Sat Mar 23 2002 - 22:00:23 EST