Activating web server home directories in Ubuntu Jaunty 10.4 / Mint Isadora

September 29th, 2010 No comments

After migrating to Linux Mint Isadora my home directory web sites ceased working (IE in /home/username/public_html).

To activate them again it was necessary to make some changes to my Apache configuration. Open a terminal and do the following:

cd /etc/apache2/mods-enabled
sudo ln -s ../mods-available/userdir.conf userdir.conf
sudo ln -s ../mods-available/userdir.load userdir.load
sudo /etc/init.d/apache2 restart

That worked, except PHP is disabled also by default for home directories. So the following “commenting out” was required as described in /etc/apache2/mods-available/php5.conf:


    
	SetHandler application/x-httpd-php
    
    
	SetHandler application/x-httpd-php-source
    
    # To re-enable php in user directories comment the following lines
    # (from  to .) Do NOT set it to On as it
    # prevents .htaccess files from disabling it.
#    
#        
#            php_admin_value engine Off
#        
#    

Unfortunately, this was not the end of the exercise. As you may gather from the file contents, PHP file parsing is only being activated for files ending in .php3 and .phtml.

Parsing of .php extensions appears to be activated elsewhere for our document root directory only, so clicking on localhost/~username/file.php resulted in the file being downloaded, not parsed and presented as a web page.

To get around this the following was added to the file /etc/apache2/mods-available/php5.conf:

    
	SetHandler application/x-httpd-php
    

I hope this help someone

Nicholas

Share
Categories: Uncategorized Tags:

Editing firefox saved passwords

May 25th, 2009 No comments

I became tired of referring to my email client to copy and paste my login details for mynetfone.net.au, so I decided to hand edit my saved passwords file (in Firefox 3.0 it is signons3.txt in firefox profile). The mynetfone website prevents firefox from prompting for the save password option.

Edit: just found this which is a global option if this suits: http://cybernetnews.com/2009/02/13/firefox-remember-passwords/. The downside to this is that it will affect all users and profiles of firefox – you may not want some users to be able to save bank/paypal logins etc! If this is the case then read on.

The trouble is, the usernames and the passwords are encrypted, and there does not appear to be a utility for generating encrypted signons.

The answer for me was to load the ‘Password Exporter’ plugin for firefox, and to export at least one of my existing saved passwords. At this stage if you have not backed up your signons3.txt file, do it now.

Open the exported xml file in a text editor (Notepad++, Wordpad) and, following the format of the exported file, add the new login credentials for mynetfone.net.au with your username and password and delete all other entries.

Start firefox and goto Tools –> Add-ons. Select ‘Password Exporter’ and choose  ‘Import Passwords’. Locate the file you have edited and import the new details.

Voila! Finally I can login to mynetfone.net.au without having to dig out the username and password.

Share
Categories: firefox Tags: ,