1 | <?php |
||
31 | class AdfsService |
||
32 | { |
||
33 | /** @var RequestHelper */ |
||
34 | private $adfsRequestHelper; |
||
35 | |||
36 | /** @var ResponseHelper */ |
||
37 | private $adfsResponseHelper; |
||
38 | |||
39 | /** |
||
40 | * SecondFactorAdfsService constructor. |
||
41 | * @param RequestHelper $adfsRequestHelper |
||
42 | * @param ResponseHelper $adfsResponseHelper |
||
43 | */ |
||
44 | public function __construct(RequestHelper $adfsRequestHelper, ResponseHelper $adfsResponseHelper) |
||
49 | |||
50 | /** |
||
51 | * This method detects if a request is made by ADFS, and converts it to a valid |
||
52 | * Saml AuthnRequest request which could be processed. |
||
53 | * |
||
54 | * @param LoggerInterface $logger |
||
55 | * @param Request $httpRequest |
||
56 | * @param ReceivedAuthnRequest $originalRequest |
||
57 | * @return Request |
||
58 | * @throws InvalidAdfsRequestException |
||
59 | */ |
||
60 | public function handleAdfsRequest(LoggerInterface $logger, Request $httpRequest, ReceivedAuthnRequest $originalRequest) |
||
78 | |||
79 | /** |
||
80 | * This method detectds if we need to return a ADFS response, If so ADFS parameters are returned. |
||
81 | * |
||
82 | * Second factor verification handled by SecondFactorController is |
||
83 | * finished. The user was forwarded back to this action with an internal |
||
84 | * redirect. This method sends a AuthnResponse back to the service |
||
85 | * provider in response to the AuthnRequest received in ssoAction(). |
||
86 | * |
||
87 | * @param LoggerInterface $logger |
||
88 | * @param ResponseContext $responseContext |
||
89 | * @return null|\Surfnet\StepupGateway\SecondFactorOnlyBundle\Adfs\ValueObject\Response |
||
90 | * @throws InvalidAdfsResponseException |
||
91 | */ |
||
92 | public function handleAdfsResponse(LoggerInterface $logger, ResponseContext $responseContext) |
||
111 | } |
||
112 |