[315] in athena10

home help back first fref pref prev next nref lref last post

Re: /svn/athena r23064 - trunk/debathena/scripts

daemon@ATHENA.MIT.EDU (Timothy G Abbott)
Sat Jul 12 22:42:47 2008

Date: Sat, 12 Jul 2008 22:41:54 -0400 (EDT)
From: Timothy G Abbott <tabbott@MIT.EDU>
To: ghudson@mit.edu
cc: athena10@mit.edu
In-Reply-To: <200807101536.LAA29881@drugstore.mit.edu>
Message-ID: <alpine.DEB.1.10.0807101137120.27916@vinegar-pot.mit.edu>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed

It possible that this is worth reporting as a bug in perl's Tempfile (in 
theory, it should be using the access system call, not doing its own 
check).

Of course, one of the things the --with-afs configure option to bash does 
is that it replaces manual checks of mode bit with the access call. 
There's a comment in the bash code there noting that the access system 
call only checks uid (not euid), and thus isn't correct if uid != euid 
(and the current man page indicates this is still true).  So that may be 
the story here as well.

 	-Tim Abbott

On Thu, 10 Jul 2008, ghudson@MIT.EDU wrote:

> Author: ghudson
> Date: 2008-07-10 11:36:12 -0400 (Thu, 10 Jul 2008)
> New Revision: 23064
>
> Modified:
>   trunk/debathena/scripts/dasource
> Log:
> In dasource, chmod build dir parents to mode 777 to make work around a
> bad AFS-perl interaction in dpkg-source.
>
>
> Modified: trunk/debathena/scripts/dasource
> ===================================================================
> --- trunk/debathena/scripts/dasource	2008-07-09 16:59:58 UTC (rev 23063)
> +++ trunk/debathena/scripts/dasource	2008-07-10 15:36:12 UTC (rev 23064)
> @@ -47,6 +47,15 @@
>     mkdir $pkgname
>   fi
>
> +  # Work around a bad interaction between dpkg-source and AFS.
> +  # (dpkg-source invokes perl's Tempfile which checks if the parent
> +  # directory is writable using mode bits).  This will not actually
> +  # grant any outside access to the directory since AFS ignores
> +  # non-user mode bits.
> +  if fs whichcell . >/dev/null 2>&1; then
> +    chmod 777 $pkgname
> +  fi
> +
>   # Check out or update the package source.
>   pattern="$pkgname/$pkgname-[0-9]*[0-9]"
>   if [ $(echo $pattern | wc -w) -gt 1 ]; then
>
>

home help back first fref pref prev next nref lref last post