Re: setgid stuff
peter karlsson wrote:
> The program, jwhois (should be in the distribution now), has been changed so
> that it will keep a cache of previous lookups. To get this to work, the
> binary need to be setgid some group. Now I wonder how this should be
> handled, should the binary be setgid in the .deb file, or should that be set
> in the installation scripts? Can it be created automatically by debhelper
> rules? Which group can I use?
If the group already exists, do something like this in postinst:
if [ -x /usr/sbin/suidregister ]; then
suidregister -s jazip /usr/bin/jazip root floppy 4754
else
chown root.floppy /usr/bin/jazip
chmod 4754 /usr/bin/jazip
fi
Which group to use? I don't know...
Can debhelper do this? Yes, see the man page for dh_suidregister
Peter
Reply to: