[TYPO3-core] RFC: #2300: [TS] Condition hostname doesn't work

Steffen Kamper info at sk-typo3.de
Mon Sep 15 20:32:45 CEST 2008


Thorsten Kahler schrieb:
> Hi Steffen,
> 
> Steffen Kamper schrieb am 9/15/08 12:35 PM:
>> Description:
>>
>> The condition [hostname = www.domain.com]
>> doesn't work.
>>
>> Reason for that is the kind of comparison
>>
>> As it's compared with t3lib_div::cmpFQDN it doesn't work:
>> In this function the IP is resolved with gethostbyaddr() which is in
>> most cases not equal to the domain available in HTTP_HOST.
>>
>> I changed the comparison so that this works for me on several servers.
>>
>> This is a very old Bug and i stumbled today over this, i wonder why not
>> more people complained.
>>
> 
> -1 from me: you totally change the intention of the comparison by your
> change. The original condition checks the domain name of the client (via
> REMOTE_ADDR); your version checks the domain name of the server (via
> HTTP_HOST).
> 
> I don't have access to the bugtracker at the moment, but maybe the
> originator of the issue had the same misunderstanding.
> 
> Additionally your patch lacks support for wildcards in the hostname (as
> documented in TSref and PHPDoc in class t3lib_div).
> 
> Nevertheless, at least the documentation of that condition needs some
> change.
> 
> Regards
> Thorsten
> 
> 
> 

Hi Thorsten,

look to my last post where i state the same :-)

I also commented it in BT and closed the issue.

vg Steffen


More information about the TYPO3-team-core mailing list