/** * Verify trust in the signature of a signed Assertion. This method is separate so that * the user can override if if they want. * @param assertion The signed Assertion * @param data The RequestData context * @return A Credential instance * @throws WSSecurityException */ protected Credential verifySignedAssertion( AssertionWrapper assertion, RequestData data ) throws WSSecurityException { Credential trustCredential = new Credential(); SAMLKeyInfo samlKeyInfo = assertion.getSignatureKeyInfo(); trustCredential.setPublicKey(samlKeyInfo.getPublicKey()); trustCredential.setCertificates(samlKeyInfo.getCerts()); return super.validate(trustCredential, data); }
/** * Verify trust in the signature of a signed Assertion. This method is separate so that * the user can override if if they want. * @param assertion The signed Assertion * @param data The RequestData context * @return A Credential instance * @throws WSSecurityException */ protected Credential verifySignedAssertion( AssertionWrapper assertion, RequestData data ) throws WSSecurityException { Credential trustCredential = new Credential(); SAMLKeyInfo samlKeyInfo = assertion.getSignatureKeyInfo(); trustCredential.setPublicKey(samlKeyInfo.getPublicKey()); trustCredential.setCertificates(samlKeyInfo.getCerts()); return super.validate(trustCredential, data); }
data, wsDocInfo, bspCompliant); certs = keyInfo.getCerts(); } else { throw new WSSecurityException(
data, wsDocInfo, bspCompliant); certs = keyInfo.getCerts(); } else { throw new WSSecurityException(
SAMLUtil.getCredentialFromSubject(assertion, data, wsDocInfo, bspCompliant); certs = samlKi.getCerts(); } else { if (bspCompliant) {
SAMLUtil.getCredentialFromSubject(assertion, data, wsDocInfo, bspCompliant); certs = samlKi.getCerts(); } else { if (bspCompliant) {
X509Certificate[] foundCerts = keyInfo.getCerts(); if (foundCerts != null && foundCerts.length > 0) { certs = new X509Certificate[]{foundCerts[0]};
X509Certificate[] foundCerts = keyInfo.getCerts(); if (foundCerts != null && foundCerts.length > 0) { certs = new X509Certificate[]{foundCerts[0]};
X509Certificate[] foundCerts = samlKi.getCerts(); if (foundCerts != null && foundCerts.length > 0) { certs = new X509Certificate[]{foundCerts[0]};
X509Certificate[] foundCerts = samlKi.getCerts(); if (foundCerts != null && foundCerts.length > 0) { certs = new X509Certificate[]{foundCerts[0]};
); X509Certificate[] foundCerts = keyInfo.getCerts(); if (foundCerts != null) { certs = new X509Certificate[]{foundCerts[0]};
); X509Certificate[] foundCerts = keyInfo.getCerts(); if (foundCerts != null) { certs = new X509Certificate[]{foundCerts[0]};
if (samlKeyInfo != null) { publicKey = samlKeyInfo.getPublicKey(); certs = samlKeyInfo.getCerts(); wsDocInfo.setCrypto(userCrypto);
if (samlKeyInfo != null) { publicKey = samlKeyInfo.getPublicKey(); certs = samlKeyInfo.getCerts(); wsDocInfo.setCrypto(userCrypto);