KaliopIdentityManagementBundle::build()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 9

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 9
c 0
b 0
f 0
rs 9.9666
cc 1
nc 1
nop 1
1
<?php
2
3
namespace Kaliop\IdentityManagementBundle;
4
5
use Symfony\Component\HttpKernel\Bundle\Bundle;
6
use Symfony\Component\DependencyInjection\ContainerBuilder;
7
use Kaliop\IdentityManagementBundle\Security\Factory\IPFactory;
8
use Kaliop\IdentityManagementBundle\Security\Factory\RemoteUserFactory;
9
10
class KaliopIdentityManagementBundle extends Bundle {
11
12
    public function build(ContainerBuilder $container)
13
    {
14
        parent::build($container);
15
16
        // register the factories which set up the custom auth providers
17
        $extension = $container->getExtension('security');
18
        $extension->addSecurityListenerFactory(new IPFactory());
19
        $extension->addSecurityListenerFactory(new RemoteUserFactory());
20
    }
21
}
22