Bug #78699

Method forceAbsoluteUrl should not assume that protocol is http

Added by Christian Toffolo almost 3 years ago. Updated about 1 year ago.

Status:
Closed
Priority:
Must have
Assignee:
-
Category:
-
Target version:
-
Start date:
2016-11-15
Due date:
% Done:

100%

TYPO3 Version:
7
PHP Version:
Tags:
Complexity:
Is Regression:
No
Sprint Focus:

Description

When `forceAbsoluteUrl = 1` and scheme is not part of the URL then method forceAbsoluteUrl() assumes that protocol is http:
https://github.com/TYPO3/TYPO3.CMS/blob/master/typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php#L6264

It should instead check TYPO3_SSL and set the scheme accordingly:

$urlParts['scheme'] = GeneralUtility::getIndpEnv('TYPO3_SSL') ? 'https' : 'http';

Associated revisions

Revision 1323d60b (diff)
Added by Frans Saris almost 3 years ago

[BUGFIX] Use scheme from EnvironmentVariables for forceAbsoluteUrl

Resolves: #78699
Releases: master, 7.6
Change-Id: If238a92e20f2382ad3b37a231992a122eff80826
Reviewed-on: https://review.typo3.org/50661
Reviewed-by: Andreas Fernandez <>
Tested-by: Andreas Fernandez <>
Reviewed-by: Stephan GroƟberndt <>
Reviewed-by: Frederic Gaus <>
Reviewed-by: Joerg Boesche <>
Reviewed-by: Stefan Neufeind <>
Tested-by: Stefan Neufeind <>

Revision aec2c0aa (diff)
Added by Frans Saris almost 3 years ago

[BUGFIX] Use scheme from EnvironmentVariables for forceAbsoluteUrl

Resolves: #78699
Releases: master, 7.6
Change-Id: If238a92e20f2382ad3b37a231992a122eff80826
Reviewed-on: https://review.typo3.org/50683
Reviewed-by: Stefan Neufeind <>
Tested-by: Stefan Neufeind <>

History

#1 Updated by Gerrit Code Review almost 3 years ago

  • Status changed from New to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/50661

#2 Updated by Gerrit Code Review almost 3 years ago

Patch set 1 for branch TYPO3_7-6 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/50683

#3 Updated by Frans Saris almost 3 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100

#4 Updated by Benni Mack about 1 year ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF