Code Duplication    Length = 12-13 lines in 2 locations

src/Surfnet/StepupGateway/GatewayBundle/Saml/ResponseContext.php 1 location

@@ 69-80 (lines=12) @@
66
     */
67
    private $targetServiceProvider;
68
69
    public function __construct(
70
        IdentityProvider $identityProvider,
71
        SamlEntityService $samlEntityService,
72
        ProxyStateHandler $stateHandler,
73
        LoggerInterface $logger
74
    ) {
75
        $this->hostedIdentityProvider = $identityProvider;
76
        $this->samlEntityService      = $samlEntityService;
77
        $this->stateHandler           = $stateHandler;
78
        $this->logger                 = $logger;
79
        $this->generationTime         = new DateTime('now', new DateTimeZone('UTC'));
80
    }
81
82
    /**
83
     * The ACS location requested in the AuthnRequest.

src/Surfnet/StepupGateway/SamlStepupProviderBundle/Saml/ProxyResponseFactory.php 1 location

@@ 64-76 (lines=13) @@
61
     */
62
    private $currentTime;
63
64
    public function __construct(
65
        LoggerInterface $logger,
66
        IdentityProvider $hostedIdentityProvider,
67
        StateHandler $stateHandler,
68
        AssertionSigningService $assertionSigningService
69
    ) {
70
        $this->logger                  = $logger;
71
        $this->hostedIdentityProvider  = $hostedIdentityProvider;
72
        $this->stateHandler            = $stateHandler;
73
        $this->assertionSigningService = $assertionSigningService;
74
75
        $this->currentTime = new DateTime('now', new DateTimeZone('UTC'));
76
    }
77
78
    /**
79
     * @param Assertion $assertion