Files
edubox-prestashop/edubox-frontcontroller.patch
T

25 lines
1.0 KiB
Diff

--- a/classes/controller/FrontController.php
+++ b/classes/controller/FrontController.php
@@ -849,18 +849,9 @@
*/
protected function sslRedirection()
{
- // If we call a SSL controller without SSL or a non SSL controller with SSL, we redirect with the right protocol
- if (Configuration::get('PS_SSL_ENABLED') && $_SERVER['REQUEST_METHOD'] != 'POST' && $this->ssl != Tools::usingSecureMode()) {
- $this->context->cookie->disallowWriting();
- header('HTTP/1.1 301 Moved Permanently');
- header('Cache-Control: no-cache');
- if ($this->ssl) {
- header('Location: ' . Tools::getShopDomainSsl(true) . $_SERVER['REQUEST_URI']);
- } else {
- header('Location: ' . Tools::getShopDomain(true) . $_SERVER['REQUEST_URI']);
- }
- exit;
- }
+ // EduBox: disabled. Behind the EduBox reverse proxy every request is
+ // served over HTTPS publicly, so PrestaShop must never redirect to HTTP.
+ return;
}
/**