Skip to content

Commit

Permalink
Configure prod yubikey interface DI
Browse files Browse the repository at this point in the history
  • Loading branch information
MKodde committed Feb 21, 2024
1 parent fb16e26 commit ad35d7c
Show file tree
Hide file tree
Showing 8 changed files with 41 additions and 3 deletions.
25 changes: 25 additions & 0 deletions ci/qa/phpstan-baseline.php
Original file line number Diff line number Diff line change
Expand Up @@ -1151,6 +1151,31 @@
'count' => 1,
'path' => __DIR__ . '/../../src/Surfnet/StepupSelfService/SelfServiceBundle/Service/SelfVetMarshaller.php',
];
$ignoreErrors[] = [
'message' => '#^Access to an undefined property Surfnet\\\\StepupBundle\\\\Command\\\\SendSmsChallengeCommandInterface\\:\\:\\$country\\.$#',
'count' => 1,
'path' => __DIR__ . '/../../src/Surfnet/StepupSelfService/SelfServiceBundle/Service/SmsRecoveryTokenService.php',
];
$ignoreErrors[] = [
'message' => '#^Access to an undefined property Surfnet\\\\StepupBundle\\\\Command\\\\SendSmsChallengeCommandInterface\\:\\:\\$identity\\.$#',
'count' => 1,
'path' => __DIR__ . '/../../src/Surfnet/StepupSelfService/SelfServiceBundle/Service/SmsRecoveryTokenService.php',
];
$ignoreErrors[] = [
'message' => '#^Access to an undefined property Surfnet\\\\StepupBundle\\\\Command\\\\SendSmsChallengeCommandInterface\\:\\:\\$institution\\.$#',
'count' => 1,
'path' => __DIR__ . '/../../src/Surfnet/StepupSelfService/SelfServiceBundle/Service/SmsRecoveryTokenService.php',
];
$ignoreErrors[] = [
'message' => '#^Access to an undefined property Surfnet\\\\StepupBundle\\\\Command\\\\SendSmsChallengeCommandInterface\\:\\:\\$recoveryTokenId\\.$#',
'count' => 1,
'path' => __DIR__ . '/../../src/Surfnet/StepupSelfService/SelfServiceBundle/Service/SmsRecoveryTokenService.php',
];
$ignoreErrors[] = [
'message' => '#^Access to an undefined property Surfnet\\\\StepupBundle\\\\Command\\\\SendSmsChallengeCommandInterface\\:\\:\\$subscriber\\.$#',
'count' => 1,
'path' => __DIR__ . '/../../src/Surfnet/StepupSelfService/SelfServiceBundle/Service/SmsRecoveryTokenService.php',
];
$ignoreErrors[] = [
'message' => '#^Property Surfnet\\\\StepupMiddlewareClientBundle\\\\Identity\\\\Command\\\\ProvePhoneRecoveryTokenPossessionCommand\\:\\:\\$phoneNumber \\(string\\) does not accept string\\|null\\.$#',
'count' => 1,
Expand Down
3 changes: 3 additions & 0 deletions config/services.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@ services:
$identityService: '@Surfnet\StepupSelfService\SelfServiceBundle\Service\IdentityService'
$preferredLocaleProvider: '@self_service.locale.request_stack_locale_provider'

Surfnet\StepupBundle\Service\SmsRecoveryTokenServiceInterface:
alias: 'Surfnet\StepupBundle\Service\SmsRecoveryTokenService'

Surfnet\StepupSelfService\SelfServiceBundle\Security\Authentication\Provider\SamlProvider:
alias: surfnet_saml.saml_provider

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@

namespace Surfnet\StepupSelfService\SelfServiceBundle\Command;

use Surfnet\StepupBundle\Command\SendSmsChallengeCommandInterface;
use Surfnet\StepupBundle\Value\PhoneNumber\InternationalPhoneNumber;
use Surfnet\StepupSelfService\SelfServiceBundle\Service\SmsRecoveryTokenService;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
use Surfnet\SamlBundle\Monolog\SamlAuthenticationLogger;
use Surfnet\SamlBundle\SAML2\Response\Assertion\InResponseTo;
use Surfnet\StepupBundle\Service\LoaResolutionService;
use Surfnet\StepupBundle\Service\SmsRecoveryTokenServiceInterface;
use Surfnet\StepupBundle\Value\Loa;
use Surfnet\StepupMiddlewareClientBundle\Exception\NotFoundException;
use Surfnet\StepupSelfService\SelfServiceBundle\Command\PromiseSafeStorePossessionCommand;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@
use Surfnet\StepupSelfService\SelfServiceBundle\Service\ControllerCheckerService;
use Surfnet\StepupSelfService\SelfServiceBundle\Command\VerifyYubikeyOtpCommand;
use Surfnet\StepupSelfService\SelfServiceBundle\Form\Type\ProveYubikeyPossessionType;
use Surfnet\StepupSelfService\SelfServiceBundle\Service\YubikeySecondFactorService;
use Surfnet\StepupSelfService\SelfServiceBundle\Service\YubikeySecondFactorServiceInterface;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\Request;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -96,13 +96,16 @@ services:
- "@router"
tags: [{ name: form.type, alias: ss_status_gssf }]

surfnet_stepup_self_service_self_service.service.yubikey:
Surfnet\StepupSelfService\SelfServiceBundle\Service\YubikeyServiceInterface:
public: false
class: Surfnet\StepupSelfService\SelfServiceBundle\Service\YubikeyService
arguments:
- "@surfnet_stepup.guzzle.gateway_api"
- "@logger"

surfnet_stepup_self_service_self_service.service.yubikey:
alias: Surfnet\StepupSelfService\SelfServiceBundle\Service\YubikeyServiceInterface

surfnet_stepup_self_service_self_service.service.gsspuserattributes:
class: Surfnet\StepupSelfService\SelfServiceBundle\Service\GsspUserAttributeService
arguments:
Expand Down Expand Up @@ -285,3 +288,7 @@ services:
tags:
- { name : twig.extension }

Surfnet\StepupSelfService\SelfServiceBundle\Service\YubikeySecondFactorServiceInterface:
class: Surfnet\StepupSelfService\SelfServiceBundle\Service\YubikeySecondFactorService
arguments:
$commandService: "@surfnet_stepup_self_service_self_service.service.command"
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
<?php

declare(strict_types = 1);

/**
* Copyright 2024 SURFnet bv
*
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
<?php

declare(strict_types = 1);

/**
* Copyright 2024 SURFnet bv
*
Expand Down

0 comments on commit ad35d7c

Please sign in to comment.