[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#2091: creating packages requires root privileges

Package: dpkg

To create a binary *.deb package, root privileges are required.  This
is because you must create a complete directory structure with proper
ownerships and permissions first, and then use dpkg-deb to create
a package from it.

But this should't really be necessary.  A tar file is a tar file, and
you can set any permissions inside it if you can write to it.  The
only thing that is necessary is a program to set permissions inside
tar files.

Another idea: unpack everything with mode 000 root.root (just because
I am paranoid and to easily see failed installation, such permissions
are rather unusual), and set all permissions correctly in postinst.
This has the advantage that if permissions ever get messed up, they
can be restored quickly without reinstalling the entire package.

There is a package we could use for that, called fixperms (it is on
sunsite).  It can set and verify permissions using a text file where
permissions are stored.  It is GPLed, and the documentation even says
that it is part of Debian - but I can't find it anywhere in the
current distribution.


Reply to: