use of uk.gov.ida.saml.core.validation.assertion.AssertionAttributeStatementValidator in project verify-hub by alphagov.
the class HubTransformersFactory method getResponseToInboundResponseFromMatchingServiceTransformer.
public DecoratedSamlResponseToInboundResponseFromMatchingServiceTransformer getResponseToInboundResponseFromMatchingServiceTransformer(SigningKeyStore signingKeyStore, IdaKeyStore keyStore, String hubEntityId) {
ResponseAssertionsFromMatchingServiceValidator responseAssertionsFromMatchingServiceValidator = new ResponseAssertionsFromMatchingServiceValidator(new AssertionValidator(new IssuerValidator(), new AssertionSubjectValidator(), new AssertionAttributeStatementValidator(), new BasicAssertionSubjectConfirmationValidator()), hubEntityId);
InboundResponseFromMatchingServiceUnmarshaller inboundResponseFromMatchingServiceUnmarshaller = new InboundResponseFromMatchingServiceUnmarshaller(getAssertionToPassthroughAssertionTransformer(), new MatchingServiceIdaStatusUnmarshaller());
SignatureValidator signatureValidator = getSignatureValidator(signingKeyStore);
MatchingServiceResponseValidator matchingServiceResponseValidator = new MatchingServiceResponseValidator(new EncryptedResponseFromMatchingServiceValidator(), getSamlResponseSignatureValidator(signatureValidator), new AssertionsDecrypters(getSamlResponseAssertionDecrypters(keyStore)), getSamlAssertionsSignatureValidator(signatureValidator), responseAssertionsFromMatchingServiceValidator);
return new DecoratedSamlResponseToInboundResponseFromMatchingServiceTransformer(matchingServiceResponseValidator, inboundResponseFromMatchingServiceUnmarshaller);
}
Aggregations