CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Installing CiviCRM »
  • Drupal Installations (Moderator: Piotr Szotkowski) »
  • SSL 10-minute login time after Ubuntu Server upgrade
Pages: [1]

Author Topic: SSL 10-minute login time after Ubuntu Server upgrade  (Read 868 times)

naomi

  • I’m new here
  • *
  • Posts: 9
  • Karma: 0
  • CiviCRM version: 4.5
  • CMS version: Drupal 7
  • MySQL version: 5.5
  • PHP version: 5.5
SSL 10-minute login time after Ubuntu Server upgrade
March 31, 2015, 03:44:59 am
This isn't exactly an installation question but I wasn't sure where else to put it - let me know if I should move it.

My CiviCRM site was working fine over SSL (with HTTP requests redirected at the Apache level) until I upgraded the underlying OS from Ubuntu 12.04 to 14.04.

Now it takes 5 or 10 minutes to log in. Once the user has logged in, everything works at normal speed.

Removing the redirect and just serving the site over HTTP completely removes this problem so it is definitely SSL related.
 
Part of this upgrade was that Apached went from 2.2 to 2.4, and I had to change some configuration (the new "require all granted" syntax was the main one).

I've googled for hours and the only similar problem I found references too was to do with the sever failing to make outbound requests (in general or to its own domain). However on my server there is no indication of outbound requests failing. I checked the Drupal status page, and also made a curl request on the command line to the same domain using https which was successful.

Any ideas?

EDIT: The site is set up with /?=civicrm as the home page. So the first request after login is that page. Actually logging in itself is not the problem. By going to /?q=user instead you can log into Drupal fine and quickly. But then you get the long wait when navigating to /?=civicrm.
« Last Edit: March 31, 2015, 03:52:25 am by naomi »

Hershel

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4640
  • Karma: 176
    • CiviHosting
  • CiviCRM version: Latest
  • CMS version: Mostly WordPress and Drupal
Re: SSL 10-minute login time after Ubuntu Server upgrade
March 31, 2015, 04:12:46 am
Seems to me this issue has nothing to do with CiviCRM in reality. It might be a bit of a Drupal question, but it really sounds like an issue with Apache or Ubuntu. I would suggest you ask on forums dedicated to those tools.
CiviHosting and CiviOnline -- The CiviCRM hosting experts, since 2007

See here for the official: What to do if you think you've found a bug.

naomi

  • I’m new here
  • *
  • Posts: 9
  • Karma: 0
  • CiviCRM version: 4.5
  • CMS version: Drupal 7
  • MySQL version: 5.5
  • PHP version: 5.5
Re: SSL 10-minute login time after Ubuntu Server upgrade
March 31, 2015, 01:46:45 pm
It's definitely a Civi problem.

The rest of the Drupal site works fine. Loading /?q=civicrm is the ONLY thing that is taking time.

naomi

  • I’m new here
  • *
  • Posts: 9
  • Karma: 0
  • CiviCRM version: 4.5
  • CMS version: Drupal 7
  • MySQL version: 5.5
  • PHP version: 5.5
Re: SSL 10-minute login time after Ubuntu Server upgrade
April 01, 2015, 02:46:43 am
It turned out to be the call to file_get_contents() in the isBrowsable() function in CRM/Utils/Check/Security.php that was hanging,

isBrowsable() performs checks to ensure that certain directories are not publicly browsable, namely:


/sites/default/files/civicrm/upload/
/sites/default/files/civicrm/custom/
/sites/default/files/civicrm/persist/contribute
/sites/default/files/civicrm/ConfigAndLog

 In my case, /sites/default/files/civicrm/persist/contribute was browsable. Adding the .htaccess to make it not browsable made the problem go away.

This is not ideal behaviour though since if the directories are browsable it should show a warning. When accessing the site over http without SSL a warning was shown as desired, but over SSL it just hung.

Having confirmed that the server is able to make requests to itself over HTTPS I am inclined to think this is a bug in Civ, although it may be an obscure one due to my particular environment of course (Ubuntu server 14.04, apache 2.4, php 5.5.9, CiviCRM 4.5.2). However I don't have another Civi site with an SSL certificate to try it out on. To reproduce you would need to make /sites/default/files/civicrm/persist/contribute browsable and then try to load /?q=civicrm.

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Installing CiviCRM »
  • Drupal Installations (Moderator: Piotr Szotkowski) »
  • SSL 10-minute login time after Ubuntu Server upgrade

This forum was archived on 2017-11-26.