LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 12-25-2010, 01:24 PM   #1
skoinga
Member
 
Registered: May 2010
Posts: 87

Rep: Reputation: 0
phpmyadmin and login via ssl


Hi,

I've a problem with phpmyadmin and login via https.
My server is a VPS with Centos 5.5; apache and phpmyadmin are installed with yum:

Quote:
phpmyadmin.noarch 2.11.11.1-1.el5.rf
httpd.x86_64 2.2.3-43.el5.centos.3
I can reach the page with this url:

https://sql.xxxxxyzyz.org

when I type login/password, the URL is automatically redirect to:

http://sql.xxxxxyzyz.org

so I must manually re-add the "s" in order to succesfully view phpmyadmin.

This happens with every browser (Opera, IE, Firefox).
Any suggestion?
Thankyou!

p.s. I also tried to set PmaAbsoluteUri parameter with the URL above, but the problem still occurs..
 
Old 12-25-2010, 02:54 PM   #2
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,223
Blog Entries: 1

Rep: Reputation: 2076Reputation: 2076Reputation: 2076Reputation: 2076Reputation: 2076Reputation: 2076Reputation: 2076Reputation: 2076Reputation: 2076Reputation: 2076Reputation: 2076
Hi,

There must be mod_rewrite the reason of this behavior.
Search for a .htaccess in /var/www/html/phpmyadmin, or wherever you installed phpmyadmin containing rewriting rules to turn https into http.
If there is not .htaccess, then look into httpd.conf, or phpmyadmin.conf

Regards
 
Old 12-25-2010, 08:37 PM   #3
Noway2
Senior Member
 
Registered: Jul 2007
Distribution: Gentoo
Posts: 2,125

Rep: Reputation: 781Reputation: 781Reputation: 781Reputation: 781Reputation: 781Reputation: 781Reputation: 781
One other thing to check: If I recall correctly, PhpMyAdmin installs the PHP files somewhere in the /usr tree and creates an alias directive for /phpmyadmin to point to this section of the tree. You may need or want to have this alias directive referenced in your vhost for the SSL site only.

Another, potentially more secure option, would be to make this site accessible only via localhost or your LAN and not accessible via the Internet. Then you can use SSH with a socks proxy to connect to your server and then bring PhpMyAdmin up in your web browser. This will help prevent dictionary attacks as myadmin is a commonly attempted service to find given how much damage you can do with it.
 
Old 12-27-2010, 01:47 PM   #4
skoinga
Member
 
Registered: May 2010
Posts: 87

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by bathory View Post
Hi,

There must be mod_rewrite the reason of this behavior.
Search for a .htaccess in /var/www/html/phpmyadmin, or wherever you installed phpmyadmin containing rewriting rules to turn https into http.
If there is not .htaccess, then look into httpd.conf, or phpmyadmin.conf

Regards
Hi,
I've disabled the DSO mod_rewrite: same behavior.
 
Old 12-27-2010, 01:49 PM   #5
skoinga
Member
 
Registered: May 2010
Posts: 87

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by Noway2 View Post
One other thing to check: If I recall correctly, PhpMyAdmin installs the PHP files somewhere in the /usr tree and creates an alias directive for /phpmyadmin to point to this section of the tree. You may need or want to have this alias directive referenced in your vhost for the SSL site only.
Hi,
I'm not using any Alias, I've a dedicated virtual host that points in the actual DocumentRoot (/usr/share/phpmyadmin).
 
Old 12-27-2010, 04:53 PM   #6
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,223
Blog Entries: 1

Rep: Reputation: 2076Reputation: 2076Reputation: 2076Reputation: 2076Reputation: 2076Reputation: 2076Reputation: 2076Reputation: 2076Reputation: 2076Reputation: 2076Reputation: 2076
Hi,

Without posting the rewrite rules and the apache configuration there is not much we can do.
You can try to use a .htaccess with:
Code:
Options +FollowSymLinks
RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI}
And make sure you have
Code:
AllowOverride All
in <Directory /usr/share/phpmyadmin>...</Directory> definition, so .htaccess can be red by apache

Regards
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Can't login to phpMyAdmin rodriguez Linux - Newbie 12 12-22-2014 08:48 AM
can't login to phpmyadmin candyman123 Linux - Software 2 05-27-2006 08:18 PM
phpmyadmin: can not login quarry_06 Linux - Software 1 04-27-2005 10:37 AM
phpmyadmin login issues basq3 Linux - Software 10 04-21-2005 01:46 AM
phpmyadmin can't login vladimir@ares Linux - Software 2 12-31-2004 03:00 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 05:01 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration