public function __construct(BBApplication $app)
 {
     $this->logger = $app->getLogging();
     $this->routing = $app->getRouting();
     parent::__construct($app);
 }
 /**
  * Same as isGranted() but throw exception if it is not instead of return false.
  *
  * @param string $attributes
  * @param mixed  $object
  *
  * @return boolean
  */
 protected function granted($attributes, $object = null, $message = 'Permission denied')
 {
     $security_context = $this->getApplication()->getSecurityContext();
     if (null !== $security_context->getACLProvider() && false === parent::isGranted($attributes, $object)) {
         throw new InsufficientAuthenticationException($message);
     }
     return true;
 }