I'm using Symfony Security/ACL component to check permissions of a group of "random" users for a given domain object.
$article = ...; // domain object
$users = ...; // array of users
$oid = ObjectIdentity::fromDomainObject($article);
$sids = array();
for ($users as $user) {
$sids[] = UserSecurityIdentity::fromAccount($user);
}
$aclProvider = ...; // "security.acl.provider" service
$acl = $aclProvider->findAcl($oid, $sids);
However, I'm having trouble checking whether given permission is granted for a given user. How can I do that?