Merge lp:~allison/ubuntu/oneiric/backuppc/merge-debian-suidperl into lp:ubuntu/oneiric/backuppc

Proposed by Allison Randal
Status: Merged
Merged at revision: 33
Proposed branch: lp:~allison/ubuntu/oneiric/backuppc/merge-debian-suidperl
Merge into: lp:ubuntu/oneiric/backuppc
Diff against target: 148 lines (+66/-9)
7 files modified
debian/changelog (+25/-0)
debian/dirs (+1/-0)
debian/postinst (+2/-2)
debian/postrm (+1/-0)
debian/rules (+3/-3)
debian/setuidwrapper.c (+1/-4)
httpd/BackupPC.conf (+33/-0)
To merge this branch: bzr merge lp:~allison/ubuntu/oneiric/backuppc/merge-debian-suidperl
Reviewer Review Type Date Requested Status
Dave Walker (community) Approve
Review via email: mp+64770@code.launchpad.net

Description of the change

Merged Debian's implementation of the setuid wrapper replacement for perl-suid.

They chose to install the compiled wrapper in /usr/lib/backuppc/cgi-bin (not worth a distro diff). Also, dropped define check around REAL_PATH in the tiny wrapper (I was being pedantically correct, not worth a distro diff).

Kept the install mode of the install wrapper at 4750 instead of 755.

To post a comment you must log in.
Revision history for this message
Dave Walker (davewalker) wrote :

Looks great! Nice and clean.

Thanks!

builds fine, uploading and merging.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'debian/changelog'
--- debian/changelog 2011-05-29 17:49:10 +0000
+++ debian/changelog 2011-06-15 23:51:03 +0000
@@ -1,3 +1,28 @@
1backuppc (3.2.0-4ubuntu1) oneiric; urgency=low
2
3 * Merge from debian unstable. Remaining changes:
4 - debian/backup.init, debian/rules, debian/postinst: Do not call init
5 script on shutdown and reboot (TearDown) (Debian #488660)
6 - debian/control: Add dependency for libsocket6-perl.
7 - debian/control: Drop build dependency to 'par2', it's in universe.
8 - configure.pl: Do not test for par2 being available at build time
9 - debian/control: depend on default-mta | mail-transport-agent, instead of
10 enumerating a long list of alternative MTAs.
11 - debian/rules: installing setuid wrapper with setuid bit set, and no
12 permissions granted to other (mode 4750)
13
14 -- Allison Randal <allison@canonical.com> Wed, 15 Jun 2011 16:28:41 -0700
15
16backuppc (3.2.0-4) unstable; urgency=low
17
18 * debian/setuidwrapper.c: New.
19 * debian/rules: Build setuidwrapper as cgi-bin/index.cgi; install real
20 index.cgi as lib/realindex.cgi. Closes: #581950.
21 * control: Remove depends on perl-suid. Change to Architecture any, add
22 ${shlibs:Depends}.
23
24 -- Ludovic Drolez <ldrolez@debian.org> Sat, 07 May 2011 10:11:56 -0500
25
1backuppc (3.2.0-3ubuntu5) oneiric; urgency=low26backuppc (3.2.0-3ubuntu5) oneiric; urgency=low
227
3 * Replace dependency on perl-suid with a small setuid wrapper, since the28 * Replace dependency on perl-suid with a small setuid wrapper, since the
429
=== modified file 'debian/dirs'
--- debian/dirs 2009-11-06 00:30:12 +0000
+++ debian/dirs 2011-06-15 23:51:03 +0000
@@ -2,3 +2,4 @@
2etc/backuppc2etc/backuppc
3usr/share/backuppc/image3usr/share/backuppc/image
4usr/share/backuppc/conf4usr/share/backuppc/conf
5usr/lib/backuppc/cgi-bin
56
=== modified file 'debian/postinst'
--- debian/postinst 2011-01-14 11:02:06 +0000
+++ debian/postinst 2011-06-15 23:51:03 +0000
@@ -97,10 +97,10 @@
97 chmod 750 /var/lib/backuppc /var/lib/backuppc/* /var/lib/backuppc/pc/*97 chmod 750 /var/lib/backuppc /var/lib/backuppc/* /var/lib/backuppc/pc/*
98 fi98 fi
9999
100 OVERRIDDEN=`dpkg-statoverride --list /usr/share/backuppc/cgi-bin/index.cgi || true`100 OVERRIDDEN=`dpkg-statoverride --list /usr/lib/backuppc/cgi-bin/index.cgi || true`
101 # Force the perms to 4750 if 4755 was found101 # Force the perms to 4750 if 4755 was found
102 echo "$OVERRIDDEN" | grep -q 4755 && OVERRIDDEN=""102 echo "$OVERRIDDEN" | grep -q 4755 && OVERRIDDEN=""
103 [ "${OVERRIDDEN}" = "" ] && dpkg-statoverride --force --update --add backuppc www-data 4750 /usr/share/backuppc/cgi-bin/index.cgi103 [ "${OVERRIDDEN}" = "" ] && dpkg-statoverride --force --update --add backuppc www-data 4750 /usr/lib/backuppc/cgi-bin/index.cgi
104104
105 if [ ! -f /etc/backuppc/htpasswd ]; then105 if [ ! -f /etc/backuppc/htpasswd ]; then
106 touch /etc/backuppc/htpasswd106 touch /etc/backuppc/htpasswd
107107
=== modified file 'debian/postrm'
--- debian/postrm 2009-11-06 00:30:12 +0000
+++ debian/postrm 2011-06-15 23:51:03 +0000
@@ -56,6 +56,7 @@
5656
5757
58 dpkg-statoverride --remove --force /usr/share/backuppc/cgi-bin/index.cgi58 dpkg-statoverride --remove --force /usr/share/backuppc/cgi-bin/index.cgi
59 dpkg-statoverride --remove --force /usr/lib/backuppc/cgi-bin/index.cgi
59 rm -rf /etc/backuppc60 rm -rf /etc/backuppc
60 if [ -x "/usr/bin/ucf" ]; then61 if [ -x "/usr/bin/ucf" ]; then
61 ucf --purge /etc/backuppc/config.pl62 ucf --purge /etc/backuppc/config.pl
6263
=== modified file 'debian/rules'
--- debian/rules 2011-05-29 17:49:10 +0000
+++ debian/rules 2011-06-15 23:51:03 +0000
@@ -64,13 +64,13 @@
64 64
65 pod2man --section=8 --center="BackupPC manual" doc/BackupPC.pod backuppc.865 pod2man --section=8 --center="BackupPC manual" doc/BackupPC.pod backuppc.8
66 perl -e "s/.IX Title.*/.SH NAME\nbackuppc \\- BackupPC manual/g" -p -i.tmp backuppc.866 perl -e "s/.IX Title.*/.SH NAME\nbackuppc \\- BackupPC manual/g" -p -i.tmp backuppc.8
67 mv -f debian/backuppc/usr/share/backuppc/cgi-bin/BackupPC_Admin debian/backuppc/usr/share/backuppc/cgi-bin/BackupPC_Admin.pl67 mv -f debian/backuppc/usr/share/backuppc/cgi-bin/* debian/backuppc/usr/share/backuppc/lib/realindex.cgi
68 install --mode=4750 index.cgi debian/backuppc/usr/share/backuppc/cgi-bin68 install --mode=4750 index.cgi debian/backuppc/usr/lib/backuppc/cgi-bin
69 install --mode=644 conf/hosts debian/backuppc/etc/backuppc69 install --mode=644 conf/hosts debian/backuppc/etc/backuppc
70 install --mode=644 debian/localhost.pl debian/backuppc/etc/backuppc70 install --mode=644 debian/localhost.pl debian/backuppc/etc/backuppc
71 install --mode=644 debian/apache.conf debian/backuppc/etc/backuppc71 install --mode=644 debian/apache.conf debian/backuppc/etc/backuppc
72 -rmdir debian/backuppc/var/lib/backuppc/conf/72 -rmdir debian/backuppc/var/lib/backuppc/conf/
73 (cd debian/backuppc/usr/share/backuppc/cgi-bin; ln -s ../image)73 (cd debian/backuppc/usr/share/backuppc/cgi-bin; ln -s ../image; ln -s /usr/lib/backuppc/cgi-bin/index.cgi )
74 patch --no-backup-if-mismatch -p0 < debian/patches/config.pl.diff74 patch --no-backup-if-mismatch -p0 < debian/patches/config.pl.diff
75 install --mode=644 debian/backuppc/etc/backuppc/config.pl debian/backuppc/usr/share/backuppc/conf75 install --mode=644 debian/backuppc/etc/backuppc/config.pl debian/backuppc/usr/share/backuppc/conf
7676
7777
=== modified file 'debian/setuidwrapper.c'
--- debian/setuidwrapper.c 2011-05-29 17:49:10 +0000
+++ debian/setuidwrapper.c 2011-06-15 23:51:03 +0000
@@ -1,8 +1,6 @@
1#include <unistd.h>1#include <unistd.h>
22
3#ifndef REAL_PATH3#define REAL_PATH "/usr/share/backuppc/lib/realindex.cgi"
4#define REAL_PATH "/usr/share/backuppc/cgi-bin/BackupPC_Admin.pl"
5#endif
64
7int main(ac, av)5int main(ac, av)
8char **av;6char **av;
@@ -10,4 +8,3 @@
10 execv(REAL_PATH, av);8 execv(REAL_PATH, av);
11 return 0;9 return 0;
12}10}
13
1411
=== added file 'httpd/BackupPC.conf'
--- httpd/BackupPC.conf 1970-01-01 00:00:00 +0000
+++ httpd/BackupPC.conf 2011-06-15 23:51:03 +0000
@@ -0,0 +1,33 @@
1#
2# DESCRIPTION
3#
4# This file controls access and configuration for the BackupPC CGI
5# interface.
6#
7# Distributed with BackupPC version 3.1.1, released 22 Dec 2008.
8
9<Directory /usr/share/backuppc/cgi-bin >
10
11#
12# This section tells apache which machines can access the interface.
13# You can change the allow line to allow access from your local
14# network, or comment out this region to allow access from all
15# machines.
16#
17order deny,allow
18deny from all
19allow from 127.0.0.1
20
21#
22# You can change the authorization method to LDAP or another method
23# besides htaccess here if you are so inclined.
24#
25AuthType Basic
26AuthUserFile /etc/backuppc/BackupPC.users
27AuthName "BackupPC Community Edition Administrative Interface"
28require valid-user
29
30</Directory>
31
32Alias /backuppc/image /usr/share/backuppc/image
33ScriptAlias /BackupPC_Admin /usr/share/backuppc/cgi-bin/BackupPC_Admin

Subscribers

People subscribed via source and target branches