ZF-Commons / zfc-rbac

Role-based access control module to provide additional features on top of Zend\Permissions\Rbac
BSD 3-Clause "New" or "Revised" License
181 stars 111 forks source link

ZfcRbac/Firewall/Controller #53

Closed isisis closed 11 years ago

isisis commented 11 years ago

Hey,

I'm not sure if I did something wrong, but nothing worked until I changed the "return true" to "return false" in ZfcRbac/Firewall/Controller line 52.

This was my setup in global conf:

return array( 'zfcrbac' => array( 'firewalls' => array( 'ZfcRbac\Firewall\Controller' => array( array('controller' => 'Note\Controller\Note', 'actions' => 'index', 'roles' => array('guest','member')) ), ), 'firewallController' => true, 'providers' => array( 'ZfcRbac\Provider\Generic\Role\InMemory' => array( 'roles' => array( 'admin', 'member' => array('admin'), 'guest' => array('member'), ), ), ), 'identity_provider' => 'standard_identity' ), 'service_manager' => array( 'factories' => array(
'standard_identity' => function ($sm) { $roles = array('guest','member','admin'); $identity = new \ZfcRbac\Identity\StandardIdentity($roles); return $identity; }
),
),

);

jmleroux commented 11 years ago

Time to close this one...