[SOLVED] BackupPC: Can't get SUID on Web-Interface

This forum is for topics specific to the Raspberry Pi and Arch Linux ARM

[SOLVED] BackupPC: Can't get SUID on Web-Interface

Postby kuku » Thu Jun 28, 2012 12:28 pm

So I installed BackupPC but I can't get the web-interface script (BackupPC_Admin) to be run as backuppc user.
-r-sr-xr-- 1 backuppc http 3993 May 11 2012 /usr/share/backuppc/cgi-bin/BackupPC_Admin

Previously I have found that both Apache and Perl need to be compiled with suexec/setuidperl options. Apache seems to have suexec functionality but i'm not sure about Perl 5.16. Especially since in FreeBSD 9.0 Perl versions above 5.10 didn't have a setuidperl option in build configuration options (probably to do with the config script?).

Any ideas how to get the frontend script to be run as backuppc? (su backuppc; perl BackupPC_Admin >test.html works)
Last edited by kuku on Thu Jun 28, 2012 1:49 pm, edited 1 time in total.
kuku
 
Posts: 2
Joined: Thu Jun 28, 2012 12:14 pm

Re: BackupPC: Can't get SUID on Web-Interface

Postby kuku » Thu Jun 28, 2012 1:47 pm

So... Perl >= 5.12 no longer has setuid option.

http://backuppc.sourceforge.net/faq/BackupPC.html
$this->bbcode_second_pass_quote('', 'U')sing mod_perl with BackupPC_Admin requires a dedicated Apache to be run as the BackupPC user (__BACKUPPCUSER__). This is because BackupPC_Admin needs permission to access various files in BackupPC's data directories. In contrast, the standard installation (without mod_perl) solves this problem by having BackupPC_Admin installed as setuid to the BackupPC user, so that BackupPC_Admin runs as the BackupPC user.


This sucks. Basically you have to run Apache as the backuppc user.
kuku
 
Posts: 2
Joined: Thu Jun 28, 2012 12:14 pm


Return to Raspberry Pi

Who is online

Users browsing this forum: No registered users and 12 guests