Project

General

Profile

Actions

Bug #17280

closed

Frontend User / class_sv_auth.php

Added by Michael Kornowski over 17 years ago. Updated about 6 years ago.

Status:
Closed
Priority:
Should have
Category:
Communication
Target version:
-
Start date:
2007-05-05
Due date:
% Done:

0%

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

Description

sorry, in advance for my broken english...*
we have some typo3 projekts...we athenticate against an openldap through eu_ldap....

everything works fine exept one thing...

every time a fe_user has not already been imported fromin ldap and the group this user belongs to, has not already been imported from ldap the fe_user can not log in...

although the fe_user is is correctly imported, the fe_usergroup is imported and even a fe_user session is created and everything seems to work fine the user can not log in.

the second login works...(cause now the group is already present...

this means the first fe_user of a fe_group which has not already been imported
can not log in...

if the fe_group is already present....nice, then everything works fine...

additionally php logs an error:

HP Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /typo3_src-4.1.1/t3lib/class.t3lib_db.php on line 796, referer...

mysql debug says:

caller:
t3lib_DB::exec_SELECTquery

Error:
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '1) AND (lockToDomain='' OR lockToDomain IS NULL OR lockToDomain='www2.....' at line 4

lastBuildQuery:
SELECT uid,subgroup
FROM fe_groups
WHERE deleted=0 AND hidden=0 AND uid IN (,1) AND (lockToDomain='' OR lockToDomain IS NULL OR lockToDomain='www2.....')

( (,1) is a syntax error in sql....)

debug_backtrace:
require // ux_tslib_fe->determineid // ux_tslib_fe->fetch_the_id // ux_tslib_fe->initusergroups // tslib_feuserauth->fetchgroupdata // tx_sv_auth->getgroups // tx_sv_auth->getsubgroups // t3lib_db->exec_selectquery // t3lib_db->debug

i will try to fix this for our installed typo3 instances but it should be fixed globally....

this does only happen to frontend_users...

i tried the same scenario for be_users...
everything worked very nice....nothing went wrong...

thx in advance...

i wrote a thread related to this issue...

http://www.typo3.net/forum/list/list_post//61982/

this code produces the mysql query

on lines 190/191

[php]
if (!$this->authInfo['showHiddenRecords']) $hiddenP = 'AND hidden=0 ';
$res = $GLOBALS['TYPO3_DB']->exec_SELECTquery('uid,subgroup', 'fe_groups', 'deleted=0 '.$hiddenP.' AND uid IN ('.$grList.')'.$lockToDomain_SQL);
[/php]

the list is being created in line 211

[php]
$theList = implode(',',t3lib_div::intExplode(',',$row['subgroup']));
[/php]

(issue imported from #M5568)


Files

class.tx_sv_auth.php (7.93 KB) class.tx_sv_auth.php Administrator Admin, 2007-05-08 17:38
class.tx_sv_auth_NEW.php (8.14 KB) class.tx_sv_auth_NEW.php Administrator Admin, 2007-05-08 22:08
Actions

Also available in: Atom PDF