« Previous | Next » 

Revision 861231e1

ID861231e1eff72b53d3dd415c496bed2b29752358

Added by Sebastian Kurfuerst over 9 years ago

[BUGFIX] Context::hasRole() now checks roles recursively

Previously, hasRole() only considered the first level of roles of a
token. getRoles() instead always considered all roles, including those
on a lower level.

This patch fixes the behavior of hasRole() by checking for roles
recursively. As before, the "Everybody" role is a role even non-
authenticated and anonymous users have.

This also fixes <f:security.ifHasRole>, as this ViewHelper directly uses
Context::getRoles.

Fixes: #31997
Releases: 1.1
Change-Id: I4a2c5ed8013c1d2a02dd569da6efa4101a5f7792

  • added
  • modified
  • copied
  • renamed
  • deleted