Package org.apache.juddi.v3.client.cryptor

Examples of org.apache.juddi.v3.client.cryptor.DigSigUtil


                        DeleteBusinesses(saveBusiness.getBusinessEntity().get(0).getBusinessKey(), authInfoJoe, publicationJoe);
                }
        }

        org.apache.juddi.v3.client.cryptor.DigSigUtil GetDigSig() throws CertificateException {
                org.apache.juddi.v3.client.cryptor.DigSigUtil ds = new DigSigUtil(TckPublisher.getProperties());
                /*
                ds.put(DigSigUtil.SIGNATURE_KEYSTORE_FILE, "./src/test/resources/keystore.jks");
                ds.put(DigSigUtil.SIGNATURE_KEYSTORE_FILETYPE, "JKS");
                ds.put(DigSigUtil.SIGNATURE_KEYSTORE_FILE_PASSWORD, "Test");
                ds.put(DigSigUtil.SIGNATURE_KEYSTORE_KEY_ALIAS, "Test");
                ds.put(DigSigUtil.TRUSTSTORE_FILE, "./src/test/resources/truststore.jks");
                ds.put(DigSigUtil.TRUSTSTORE_FILETYPE, "JKS");
                ds.put(DigSigUtil.TRUSTSTORE_FILE_PASSWORD, "Test");*/
                ds.put(DigSigUtil.SIGNATURE_OPTION_CERT_INCLUSION_BASE64, "true");
                return ds;
        }
View Full Code Here


        ds.put(DigSigUtil.TRUSTSTORE_FILETYPE, "JKS");
        ds.put(DigSigUtil.TRUSTSTORE_FILE_PASSWORD, "Test");
    }

    void Default() throws CertificateException {
        ds = new DigSigUtil();
        SetCertStoreSettigns();
        ds.put(DigSigUtil.SIGNATURE_OPTION_CERT_INCLUSION_BASE64, "true");
    }
View Full Code Here

        SetCertStoreSettigns();
        ds.put(DigSigUtil.SIGNATURE_OPTION_CERT_INCLUSION_BASE64, "true");
    }

    void Everything() throws CertificateException {
        ds = new DigSigUtil();
        SetCertStoreSettigns();
        ds.put(DigSigUtil.SIGNATURE_OPTION_CERT_INCLUSION_BASE64, "true");
        ds.put(DigSigUtil.SIGNATURE_OPTION_CERT_INCLUSION_SUBJECTDN, "true");
        ds.put(DigSigUtil.SIGNATURE_OPTION_CERT_INCLUSION_SERIAL, "true");
    }
View Full Code Here

        ds.put(DigSigUtil.SIGNATURE_OPTION_CERT_INCLUSION_SUBJECTDN, "true");
        ds.put(DigSigUtil.SIGNATURE_OPTION_CERT_INCLUSION_SERIAL, "true");
    }

    void SubjectDNOnly() throws CertificateException {
        ds = new DigSigUtil();
        SetCertStoreSettigns();
        ds.put(DigSigUtil.SIGNATURE_OPTION_CERT_INCLUSION_SUBJECTDN, "true");
    }
View Full Code Here

        SetCertStoreSettigns();
        ds.put(DigSigUtil.SIGNATURE_OPTION_CERT_INCLUSION_SUBJECTDN, "true");
    }

    void SerialAndIssuerOnly() throws CertificateException {
        ds = new DigSigUtil();
        SetCertStoreSettigns();
        ds.put(DigSigUtil.SIGNATURE_OPTION_CERT_INCLUSION_SERIAL, "true");
    }
View Full Code Here

                                break;
                        case DoNothing:
                                break;
                        case SignAlways:
                                try {
                                        DigSigUtil ds = new DigSigUtil(client.getClientConfig().getDigitalSignatureConfiguration());
                                        bt = ds.signUddiEntity(bt);
                                } catch (Exception ex) {
                                        log.error("Unable to sign", ex);
                                        throw new UnableToSignException(ex);
                                }

                                break;
                        case SignOnlyIfParentIsntSigned:
                                if (!CheckServiceAndParentForSignature(bt.getServiceKey(), uddiInquiryService, token)) {
                                        try {
                                                DigSigUtil ds = new DigSigUtil(client.getClientConfig().getDigitalSignatureConfiguration());
                                                bt = ds.signUddiEntity(bt);
                                        } catch (Exception ex) {
                                                log.error("Unable to sign", ex);
                                                throw new UnableToSignException(ex);
                                        }
                                }
View Full Code Here

            ex.printStackTrace();
        }
    }

    org.apache.juddi.v3.client.cryptor.DigSigUtil GetDigSig() throws CertificateException {
        org.apache.juddi.v3.client.cryptor.DigSigUtil ds = new DigSigUtil();
        ds.put(DigSigUtil.SIGNATURE_KEYSTORE_FILE, "./src/test/resources/keystore.jks");
        ds.put(DigSigUtil.SIGNATURE_KEYSTORE_FILETYPE, "JKS");
        ds.put(DigSigUtil.SIGNATURE_KEYSTORE_FILE_PASSWORD, "Test");
        ds.put(DigSigUtil.SIGNATURE_KEYSTORE_KEY_ALIAS, "Test");
        ds.put(DigSigUtil.TRUSTSTORE_FILE, "./src/test/resources/truststore.jks");
        ds.put(DigSigUtil.TRUSTSTORE_FILETYPE, "JKS");
        ds.put(DigSigUtil.TRUSTSTORE_FILE_PASSWORD, "Test");
        ds.put(DigSigUtil.SIGNATURE_OPTION_CERT_INCLUSION_BASE64, "true");
        return ds;
    }
View Full Code Here

        sb.setAuthInfo(authInfoJoe);
        BusinessEntity be = new BusinessEntity();
        Name n = new Name();
        n.setValue("JUDDI_JUDDI_712_SaveBusinessProjectionWithSignature");
        be.getName().add(n);
        DigSigUtil ds = GetDigSig();
        be = ds.signUddiEntity(be);
        sb.getBusinessEntity().add(be);
        try {
            BusinessDetail saveBusiness = publication.saveBusiness(sb);
            Assert.fail("unexpected success");
        } catch (Exception ex) {
View Full Code Here

        BusinessService bs = new BusinessService();
        bs.getName().add(new Name("Joe's bs", null));
        be.setBusinessServices(new BusinessServices());
        be.getBusinessServices().getBusinessService().add(bs);

        DigSigUtil ds = GetDigSig();
        be = ds.signUddiEntity(be);
        sb.getBusinessEntity().add(be);
        try {
            BusinessDetail saveBusiness = publication.saveBusiness(sb);
            Assert.fail("unexpected success");
        } catch (Exception ex) {
View Full Code Here

        bs.setBusinessKey(TckBusiness.JOE_BUSINESS_KEY);
        bs.getName().add(new Name("Joe's bs", null));
        be.setBusinessServices(new BusinessServices());
        be.getBusinessServices().getBusinessService().add(bs);

        DigSigUtil ds = GetDigSig();
        be = ds.signUddiEntity(be);
        sb.getBusinessEntity().add(be);
        try {
            BusinessDetail saveBusiness = publication.saveBusiness(sb);
            Assert.fail("unexpected success");
        } catch (Exception ex) {
View Full Code Here

TOP

Related Classes of org.apache.juddi.v3.client.cryptor.DigSigUtil

Copyright © 2018 www.massapicom. 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.