Hi, I'm following the guidelines of configuring a SAML service in CAS, but I'm having trouble connecting to Liferay portal.
In Liferay were created the certificates and imported in the idp-metadata file which was sent back to Liferay and imported. Everything runs fine, BUT after entering the credentials in CAS, this error (or similar) appears in Liferay logs:
2024-10-04 21:51:11.830 DEBUG [http-nio-0.0.0.0-9444-exec-4][ApacheSantuarioSignatureValidationProviderImpl:65] Validating signature with signature algorithm URI:
http://www.w3.org/2001/04/xmldsig-more#rsa-sha2562024-10-04 21:51:11.830 DEBUG [http-nio-0.0.0.0-9444-exec-4][ApacheSantuarioSignatureValidationProviderImpl:66] Validation credential key algorithm 'RSA', key instance class 'sun.security.rsa.RSAPublicKeyImpl'
2024-10-04 21:51:11.831 WARN [http-nio-0.0.0.0-9444-exec-4][XMLSignature:891] Signature verification failed.
2024-10-04 21:51:11.831 DEBUG [http-nio-0.0.0.0-9444-exec-4][ApacheSantuarioSignatureValidationProviderImpl:78] Signature cryptographic validation not successful
2024-10-04 21:51:11.831 DEBUG [http-nio-0.0.0.0-9444-exec-4][BaseSignatureTrustEngine:244] Signature validation using candidate validation credential failed
org.opensaml.xmlsec.signature.support.SignatureException: Signature cryptographic validation not successful
.....
2024-10-04 21:51:11.832 DEBUG [http-nio-0.0.0.0-9444-exec-4][ExplicitKeySignatureTrustEngine:124] Failed to verify signature using either KeyInfo-derived or directly trusted credentials
2024-10-04 21:51:11.833 DEBUG [http-nio-0.0.0.0-9444-exec-4][SAMLProtocolMessageXMLSignatureSecurityHandler:142] Message Handler: Validation of protocol message signature failed for context issuer 'ENTITY_ID', message type: {urn:oasis:names:tc:SAML:2.0:protocol}Response
2024-10-04 21:51:11.833 DEBUG [http-nio-0.0.0.0-9444-exec-4][WebSsoProfileImpl:210] Validation of protocol message signature failed
.....
According to the Liferay admin, the main issue may come from CAS, because is not using the right key to generate the values in the SAML Response. Other reason may be encryption or signature.
I have tried both encryption and signature options in service.json file, but no avail, the errors are th same.
How can I verify this suspicions of Liferay admin? how can I force CAS to use a certain private key to generate the data in SAML response?
Thanks in advance.