Project

General

Profile

Actions

Bug #21345

closed

cHash is generated when no parameters are given

Added by Michael Birchler over 14 years ago. Updated over 13 years ago.

Status:
Closed
Priority:
Should have
Category:
Caching
Target version:
-
Start date:
2009-10-23
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
4.3
PHP Version:
5.2
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

If somebody adds accidentally useCacheHash to typolink configuration the caching of Typo3 gets broken (only in combination with RealURL).

Example Typoscript :
10 = TEXT
10 {
typolink {
parameter.data = TSFE:id
additionalParams.dataWrap = &{getIndpEnv : QUERY_STRING}
useCacheHash = 1
}
}

If getIndpEnv : QUERY_STRING is empty the value of additionalParams is '&'

The typolink method of tslib_content calculates always the cHash if useCacheHash is set in typolinkconfig.

If additionalParams is '&' t3lib_div::cHashParams returns an array with two items:
'encryptionKey' => 'encrypt key
'' => empty

so the cHash gets calculated faulty and RealURL takes the faulty cHash and stores it to the tx_realurl_chashcache table.

The result is faulty cHash calculations:
The incoming cHash "f2810e4376" and calculated cHash "5de407b1c4" did not match, so caching was disabled. The fieldlist used was "encryptionKey"
and the site runs on non cached.

The attached patch pervents faulty calculations.

(issue imported from #M12322)


Files

class.tslib_content.diff (2.17 KB) class.tslib_content.diff Administrator Admin, 2009-10-23 11:45
bug_12322.diff (1.58 KB) bug_12322.diff Administrator Admin, 2009-10-23 14:36
bug_12322_class.t3lib_div.diff (1 KB) bug_12322_class.t3lib_div.diff Administrator Admin, 2009-10-28 11:10
12322.diff (1 KB) 12322.diff Administrator Admin, 2010-07-13 13:23
Actions

Also available in: Atom PDF