Tag Archives: web

Enable mod_perl on Debian, Ubuntu, & Other Linuxes.

To enable mod_perl with Apache2 on Debian & Ubuntu for all directories served up by Apache2, including user directories such as ~/public_html, add the following lines to /etc/apache2/sites-available/default

# enable mod_perl
    <Files ~ ".(pl|cgi)$">
           SetHandler perl-script
           PerlResponseHandler ModPerl::Registry
           Options +ExecCGI
           PerlSendHeader On
    </Files>

In a real production environment you probably don’t want to enable this for all directories that Apache2 serves up, but only from those directories you expect to run perl in.

Thanks to this thread on the Ubuntu Forums for the info.

Titled updated as per Ozkar’s suggestion.

Iceweasel browser identification

Debian replaced Firefox with Iceweasel which is a version of Firefox committed to all the Open Source freedom goodness stuff. However, some sites check the browser identification string and will refuse to let you view any of the pages because they don’t realise that Iceweasel is a version of Firefox (it’s based on the same code base as Firefox). Why some websites think they need to verify what browser your using is beyond me, I think they should just warn the user that the site might not work with their browser and let them in.

Updated March 2008, with formatting changes, and spelling corrections.

To get around this, you can change the browser identification that Iceweasel sends to websites. Follow the instructions below which is from Ubuntu’s wiki:

If you’re having trouble with browser identification — in other words, sites block your access because you’re “not using Firefox” — try this:

  • Open “about:config” in IceWeasel‘s address bar.
  • In the “Filter” box, type general.useragent.extra.firefox.
  • Where you see the word “Iceweasel”, right-click and pick “Modify”
  • Then replace the word “Iceweasel” with “Firefox”.
  • Close the page (or the tab).

“Masquerading” your browser like that simply prevents the host site from telling you you’re not using Firefox. Aside from that, it should have no effect whatsoever on your collective Internet experience.

This is a bit sub-optimal as it changes the identification for all sites which means when they analyise their logs they won’t realise that people are running Iceweasel. Browsers such as KDE’s Konqueror allow you to change the browser’s identification on a per-site basis which I think would be great idea for Iceweasel/Firefox too.

Update: March 2007, added screenshot.