Package de.adorsys.psd2.xs2a.service
Class ScaApproachResolver
- java.lang.Object
-
- de.adorsys.psd2.xs2a.service.ScaApproachResolver
-
@Service public class ScaApproachResolver extends Object
-
-
Constructor Summary
Constructors Constructor Description ScaApproachResolver(ServiceTypeDiscoveryService serviceTypeDiscoveryService, Xs2aAisConsentService xs2aAisConsentService, PisAuthorisationService pisAuthorisationService, de.adorsys.psd2.aspsp.profile.service.AspspProfileService aspspProfileService, RequestProviderService requestProviderService)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description @NotNull de.adorsys.psd2.xs2a.core.profile.ScaApproachgetScaApproach(@NotNull String authorisationId)Gets SCA approach from the existing initiation authorisationde.adorsys.psd2.xs2a.core.profile.ScaApproachresolveScaApproach()Resolve which sca approach from sca approaches list in ASPSP-profile should be used for authorisation.
-
-
-
Constructor Detail
-
ScaApproachResolver
public ScaApproachResolver(ServiceTypeDiscoveryService serviceTypeDiscoveryService, @Lazy Xs2aAisConsentService xs2aAisConsentService, @Lazy PisAuthorisationService pisAuthorisationService, de.adorsys.psd2.aspsp.profile.service.AspspProfileService aspspProfileService, RequestProviderService requestProviderService)
-
-
Method Detail
-
resolveScaApproach
public de.adorsys.psd2.xs2a.core.profile.ScaApproach resolveScaApproach()
Resolve which sca approach from sca approaches list in ASPSP-profile should be used for authorisation.If header "tpp-redirect-preferred" is provided with value "true" and ASPSP supports Redirect approach, then this approach will be used. If header "tpp-redirect-preferred" is provided with value "false", the first non-Redirect approach from the list will be used. If header "tpp-redirect-preferred" is not provided, the first approach from the list will be chosen. If ASPSP has only one SCA approach in profile, header "tpp-redirect-preferred" will be ignored and only approach from profile will be used
- Returns:
- chosen ScaApproach to be used for authorisation
-
getScaApproach
@NotNull public @NotNull de.adorsys.psd2.xs2a.core.profile.ScaApproach getScaApproach(@NotNull @NotNull String authorisationId)Gets SCA approach from the existing initiation authorisation- Parameters:
authorisationId- authorisation identifier- Returns:
- SCA approach, stored in the authorisation
-
-