public function registerSecurityFirewalls(Application $app)
    {
        $app['security.firewalls'] = $app->share(function () {
            return [
                'base.api' => [
                    'pattern' => '^/',
                    'oauth'   => true,
                ],
            ];
        });

        $app['security.access_rules'] = $app->share(function () {
            return [];
        });
    }