I'm not sure what exactly is the problem, but I thought I would throw this out there. It's been a while, but I remember a while back having a problem where it was downloading files instead of executing them. As I recall, it was a cgi problem.
So having said that, I have the following installed on my backuppc server, which is running Debian/sid:
ii libcgi-fast-perl 1:2.04-1 all CGI subclass for work with FCGI
ii libcgi-pm-perl 4.09-1 all module for Common Gateway Interface applications
ii libfcgi-perl 0.77-1+b1 amd64 helper module for FastCGI
Wish I could be more help.