On 04/27, Christian Weisgerber wrote:
> On 2019-04-27, Marco Bonetti <[email protected]> wrote:
> 
> > +unpriv -f SHA256.sig.tmp ftp -Vmo SHA256.sig.tmp ${URL}SHA256.sig
> > +TMP_SHA=$(sha256 -q SHA256.sig.tmp)
> > +
> > +unpriv touch SHA256.sig
> 
> This fails if SHA256.sig doesn't exist yet.  The unprivileged user
> cannot create files in $SETSDIR.
> 
> > +unpriv cat SHA256.sig.tmp >SHA256.sig
> 
> Do you understand that the I/O redirection is performed before
> calling unpriv?
> 
> -- 
> Christian "naddy" Weisgerber                          [email protected]
> 

Thanks for the suggestions, I've incorporated them in the new version of the
patch.

Cheers,
Marco

Reply via email to