in src/main/java/org/apache/sling/jcr/repoinit/impl/AclUtil.java [601:606]
public boolean isContainedIn(JackrabbitAccessControlEntry other) throws RepositoryException {
return other.getPrincipal().equals(principal) &&
contains(other.getPrivileges(), privileges) &&
other.isAllow() == isAllow &&
sameRestrictions(other);
}