Examples of verifySignature()


Examples of de.anomic.tools.CryptoLib.verifySignature()

                final CharBuffer signBuffer = new CharBuffer(getSignatureFile());
                final byte[] signByteBuffer = Base64Order.standardCoder.decode(signBuffer.toString().trim());
                final CryptoLib cl = new CryptoLib();
                for(final yacyUpdateLocation updateLocation : latestReleaseLocations) {
                    try {
                        if(cl.verifySignature(updateLocation.getPublicKey(),
                            new FileInputStream(this.releaseFile), signByteBuffer)) {
                            return true;
                        }
                    } catch (final InvalidKeyException e) {
                    } catch (final SignatureException e) {
View Full Code Here

Examples of org.apache.harmony.xnet.provider.jsse.DigitalSignature.verifySignature()

        byte[] enc = dsig.sign();

        // Now let's verify
        dsig.init(cert);
        assertTrue(dsig.verifySignature(enc));
    }
}
View Full Code Here

Examples of org.apache.poi.poifs.crypt.dsig.SignatureInfo.verifySignature()

                assertNotNull(result);
                assertEquals("test-file: "+testFile, 1, result.size());
                X509Certificate signer = result.get(0);
                LOG.log(POILogger.DEBUG, "signer: " + signer.getSubjectX500Principal());
   
                boolean b = si.verifySignature();
                assertTrue("test-file: "+testFile, b);
                pkg.revert();
            } finally {
                pkg.close();
            }
View Full Code Here

Examples of org.apache.ws.security.saml.ext.AssertionWrapper.verifySignature()

            requestData.setWssConfig(wssConfig);
            requestData.setCallbackHandler(callbackHandler);
            requestData.setMsgContext(tokenParameters.getWebServiceContext().getMessageContext());

            // Verify the signature
            assertion.verifySignature(
                requestData, new WSDocInfo(validateTargetElement.getOwnerDocument())
            );
               
            SecurityToken secToken = null;
            byte[] signatureValue = assertion.getSignatureValue();
View Full Code Here

Examples of org.apache.ws.security.saml.ext.AssertionWrapper.verifySignature()

                algorithmSuiteValidator.checkSignatureAlgorithms(xmlSignature);
                algorithmSuiteValidator.checkAsymmetricKeyLength(key);
            }

            assertion.verifySignature(samlKeyInfo);
        }
        // Parse the HOK subject if it exists
        assertion.parseHOKSubject(data, docInfo);
           
        // Now delegate the rest of the verification to the Validator
View Full Code Here

Examples of org.apache.ws.security.saml.ext.AssertionWrapper.verifySignature()

            if (!assertion.isSigned()) {
                LOG.warn("Assertion is not signed");
                throw new ProcessingException(TYPE.TOKEN_NO_SIGNATURE);
            }
            // Verify the signature
            assertion.verifySignature(requestData,
                    new WSDocInfo(token.getOwnerDocument()));

            // Now verify trust on the signature
            Credential trustCredential = new Credential();
            SAMLKeyInfo samlKeyInfo = assertion.getSignatureKeyInfo();
View Full Code Here

Examples of org.apache.ws.security.saml.ext.AssertionWrapper.verifySignature()

                algorithmSuiteValidator.checkSignatureAlgorithms(xmlSignature);
                algorithmSuiteValidator.checkAsymmetricKeyLength(key);
            }

            assertion.verifySignature(samlKeyInfo);
        }
        // Parse the HOK subject if it exists
        assertion.parseHOKSubject(data, docInfo);
           
        // Now delegate the rest of the verification to the Validator
View Full Code Here

Examples of org.apache.ws.security.saml.ext.AssertionWrapper.verifySignature()

                WSSConfig wssConfig = WSSConfig.getNewInstance();
                requestData.setWssConfig(wssConfig);
                requestData.setCallbackHandler(callbackHandler);
               
                // Verify the signature
                assertion.verifySignature(
                    requestData, new WSDocInfo(validateTargetElement.getOwnerDocument())
                );

                // Now verify trust on the signature
                Credential trustCredential = new Credential();
View Full Code Here

Examples of org.apache.ws.security.saml.ext.AssertionWrapper.verifySignature()

            if (!assertion.isSigned()) {
                LOG.warn("Assertion is not signed");
                throw new ProcessingException(TYPE.TOKEN_NO_SIGNATURE);
            }
            // Verify the signature
            assertion.verifySignature(requestData,
                    new WSDocInfo(token.getOwnerDocument()));

            // Now verify trust on the signature
            Credential trustCredential = new Credential();
            SAMLKeyInfo samlKeyInfo = assertion.getSignatureKeyInfo();
View Full Code Here

Examples of org.apache.ws.security.saml.ext.AssertionWrapper.verifySignature()

                algorithmSuiteValidator.checkSignatureAlgorithms(xmlSignature);
                algorithmSuiteValidator.checkAsymmetricKeyLength(key);
            }

            assertion.verifySignature(samlKeyInfo);
        }
        // Parse the HOK subject if it exists
        assertion.parseHOKSubject(data, docInfo);
           
        // Now delegate the rest of the verification to the Validator
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.