View Single Post
  #1  
Old 23rd March 2013, 02:24
breakaway breakaway is offline
Junior Member
 
Join Date: Jun 2007
Posts: 21
Thanks: 2
Thanked 2 Times in 1 Post
Exclamation Simple phpmyadmin question

Hello gentlemen,

My setup is an Ubuntu 12.10 system.

I have used this guide to successfully set up the server. However I have a problem with phpMyAdmin.



Page #4 of the guide states to add a specific nginix directive inside ISPConfig to enable phpMyAdmin for a specific site.

Now being security concious I only want phpMyAdmin to work over https.

So I have added the following code snippet

Code:
location /phpmyadmin {
       root /usr/share/;
       index index.php index.html index.htm;
       location ~ ^/phpmyadmin/(.+\.php)$ {
       try_files $uri =404;
       root /usr/share/;
       fastcgi_pass unix:/var/run/php5-fpm.sock;
       fastcgi_param HTTPS on; # <-- add this line
       fastcgi_index index.php;
       fastcgi_param SCRIPT_FILENAME $request_filename;
       include /etc/nginx/fastcgi_params;
       fastcgi_param PATH_INFO $fastcgi_script_name;
       fastcgi_buffer_size 128k;
       fastcgi_buffers 256 4k;
       fastcgi_busy_buffers_size 256k;
       fastcgi_temp_file_write_size 256k;
       fastcgi_intercept_errors on;
       }
       location ~* ^/phpmyadmin/(.+\.(jpg|jpeg|gif|css|png|js|ico|html|xml|txt))$ {
       root /usr/share/;
       }
}
location /phpMyAdmin {
       rewrite ^/* /phpmyadmin last;
}
As per the guide says.

However, I have found that even after saving the above directive into ISPConfig for that site and reloading (and also restarting) nginx, phpMyAdmin is accessible via http on port 8081! If I try HTTPS port 8081 it won't work - firefox produces a

Code:
SSL received a record that exceeded the maximum permissible length.
error.

How can I force this (phpmyadmin) to ONLY work over HTTPS?

Thanks in advance!
Reply With Quote
Sponsored Links