Re: multiple users cannot do perl installation due to chmod on .bs file
Manohar Koduru <[email protected]> Thu, 14 Oct 2010 12:32:35 +0100 (BST)
| Newsgroups | gmane.comp.lang.perl.modules.extutils-makemaker.devel |
|---|---|
| Message-ID | <[email protected]> |
I saw the below reply from Michael at http://www.nntp.perl.org/group/perl.makemaker/2010/10/msg3225.html but did not know how to reply to it. So I am sending my reply through my mail account again. >> Then use newgrp to change to that group before installing modules. Even if all people installing perl modules belong to the same group, there can be only one owner for the .bs file. So chmod statement in MM_Unix.pm would still fail for all people except for the owner as one needs to be the owner to change permissions of a file. Let me know if I am missing something. ================================================================== From:Michael G Schwern Date:October 13, 2010 10:44 Subject:Re: multiple users cannot do perl installation due to chmod on .bsfile Message ID:[email protected] On 2010.10.13 2:04 AM, Manohar Koduru wrote: > The following code in ExtUtils::MM_Unix is doing chmod 664 on .bs file. This > means that two different users cannot do installation as if one user if the > owner, then the other cannot do chmod on it. Is there any solution to this? Or > am I missing something? Having your library files be writable by anyone on the system is a security hole, anyone who gets minimum access can install a trojan, so the chmod is doing the right thing. Simplest thing to do is to put all the users who can install Perl modules into the same group. Then use newgrp to change to that group before installing modules. --- On Wed, 13/10/10, Manohar Koduru <[email protected]> wrote: From: Manohar Koduru <[email protected]> Subject: multiple users cannot do perl installation due to chmod on .bs file To: [email protected] Date: Wednesday, 13 October, 2010, 11:34 AM The following code in ExtUtils::MM_Unix is doing chmod 664 on .bs file. This means that two different users cannot do installation as if one user if the owner, then the other cannot do chmod on it. Is there any solution to this? Or am I missing something? # As Mkbootstrap might not write a file (if none is required) # we use touch to prevent make continually trying to remake it. # The DynaLoader only reads a non-empty file. $(BOOTSTRAP) : $(FIRST_MAKEFILE) $(BOOTDEP) $(INST_ARCHAUTODIR)$(DFSEP).exists $(NOECHO) $(ECHO) "Running Mkbootstrap for $(NAME) ($(BSLOADLIBS))" $(NOECHO) $(PERLRUN) \ "-MExtUtils::Mkbootstrap" \ -e "Mkbootstrap('$(BASEEXT)','$(BSLOADLIBS)');" $(NOECHO) $(TOUCH) %s $(CHMOD) $(PERM_RW) %s