Review main Abandoned

9275[BUGFIX] Incorrect redirect with multiple user groups

Dmitry Dulepov CR 0 V 0 Easy +15 −7 updated 06/03/13, 20:49

Commit message

If the "redirectMode" is set to "groupLogin" and there are several
groups with "felogin_redirectPid", the redirect should happen to
the first or last group (depending on the mode of "redirectFirst"
flag. The actual redirect result is undefined because felogin
fetches groups from the database without any sorting. Depending
on MySQL internal index state, results can come in any order and
this order can change over time. In addition felogin uses
$GLOBALS['TSFE']->fe_user->groupData['uid'], which contains sorted
uid values for groups. This prevents correct redirects for
multiple groups too.

Felogin should ensure that it adds redirects URLs in the proper order.

Review

  • Code review CR 0
  • Verified V 0

Files 1

Review log 9

  1. Markus Klein uploaded patch set 2 05/02/12, 12:55

  2. Markus Klein commented on patch set 2 05/02/12, 12:55

    Verified; Looks good to me, but someone else must approve Updated commit message
  3. Markus Klein commented on patch set 2 05/02/12, 12:55

    Fails; I would prefer that you didn't submit this Hi! After investing quite some time into "reading" the Core, I decided to stick with Dmitry's version as any other "proper" solution would require enormous changes in the auth services. Unfortunately I just realized that this change actually breaks redirects from subgroups completely. (subgroups are never loaded here) Maybe I'll push another version, where also all subgroups are loaded AND the ordering is observed. I hope I'll find time for this.
  4. Jigal van Hemert commented on patch set 1 05/02/12, 12:55

    I would prefer that you didn't submit this I'll put the explanation in forge (Gerrit is not the right place to discuss the functionality)
  5. Jigal van Hemert commented on patch set 2 05/02/12, 12:55

    I would prefer that you didn't submit this Problem I had with the first patch (see forge for more info) is not solved and now Jenkins has build issues.
  6. Jigal van Hemert commented on patch set 2 05/02/12, 12:55

    The only source for how this is supposed to work is http://wiki.typo3.org/Felogin . The note about multiple groups was added by Steffen Müller in January 2010. It is not in the extension manual. In this regard I would classify this as a feature. The new behaviour must be precisely documented. This patch does not use the "first" group (like set in the order of the user groups in the options of the fe_user record), but the "oldest" group (with the lowest uid).
  7. Mr. Jenkins commented on patch set 1 05/02/12, 12:55

  8. Mr. Jenkins commented on patch set 2 05/02/12, 12:55

    Fails; I would prefer that you didn't submit this Build Failed https://ci.typo3.org/job/typo3-v4-core-gerrit/3732/ : FAILURE
  9. Dmitry Dulepov commented on patch set 2 05/02/12, 12:55

    Abandoned