News:

AbanteCart v1.4.2 is released.

Main Menu

Do you like AbanteCart? Please rate AbanteCart or share your experience with other eCommerce entrepreneurs. Go to Softaculous rating page to add your rating or write a review

Admin timeout login URL HTTPS_SERVER

Started by gswan, June 16, 2017, 10:01:34 PM

Previous topic - Next topic

gswan

Hi,
I am using abantecart 1.2.8, php-5.6.30.

After leaving the admin console to timeout it appears to redirect to the admin login page, however it has the string "HTTPS_SERVER" in the URL.
If I manually remove the string I get the admin login page.
Example: HTTPS_SERVERindex.php?rt=index/

The server URL's are configured and SSL is enabled in the settings. Is there anywhere else I should be looking for where this comes from?

eCommerce Core

This looks like some misconfiguration on your web server. Check Apache settings or contact your hosting company.
"If you're in the luckiest one per cent of humanity, you owe it to the rest of humanity to think about the other 99 per cent."
― Warren Buffett

gswan

Checked apache settings and .htaccess rewrite rules. Nothing there.
It looks more like a string coming from PHP, where HTTPS_SERVER is supposed to be defined somewhere, but isn't.



abolabo

Hello.
The better way to solve it is upgrading up to 1.2.10 version.
AbanteCart becomes more stable version-by-version.
"No one is useless in this world who lightens the burdens of another."
― Charles Dickens

gswan

I ended up finding this in the code (html.php), and there does not appear to be any check to see if HTTPS_SERVER is actually defined.

               
public function getURL($rt, $params = '', $encode = '') {
      if (isset($this->registry->get('request')->server['HTTPS'])
            && (($this->registry->get('request')->server['HTTPS'] == 'on') || ($this->registry->get('request')->server['HTTPS'] == '1'))) {
         $server = HTTPS_SERVER;
      } else {
         //to prevent garbage session need to check constant HTTP_SERVER
         $server = defined('HTTP_SERVER') ? HTTP_SERVER : 'http://' . REAL_HOST . get_url_path($_SERVER['PHP_SELF']);
      }


gswan

Once the "SEO URL's" setting was enabled (and .htaccess included) the problem is no longer present.


Basara


Forum Rules Code of conduct
AbanteCart.com 2010 -