Package org.exolab.jms.net.util

Examples of org.exolab.jms.net.util.SSLProperties


     */
    protected ConnectionRequestInfo getManagedConnectionRequestInfo()
            throws Exception {
        TCPSRequestInfo info =
                new TCPSRequestInfo(new URI("tcps://localhost:5099"));
        SSLProperties properties =
                SSLUtil.getSSLProperties("test.keystore", "secret");
        info.setSSLProperties(properties);
        return info;
    }
View Full Code Here


     */
    protected ConnectionRequestInfo getManagedConnectionRequestInfo()
            throws Exception {
        HTTPRequestInfo info = new HTTPRequestInfo(
                new URI("https://localhost:8443/openjms-tunnel/tunnel"));
        SSLProperties properties =
                SSLUtil.getSSLProperties("test.keystore", "secret");
        info.setSSLProperties(properties);
        return info;
    }
View Full Code Here

        final String uri = "http://localhost:80";
        final String proxyHost = "foo";
        final int proxyPort = 1030;
        final String proxyUser = "bar";
        final String proxyPassword = "fly";
        final SSLProperties ssl = new SSLProperties();

        HTTPRequestInfo info = populate(uri, proxyHost, proxyPort, proxyUser,
                                        proxyPassword, ssl);

        assertEquals(uri, info.getURI().toString());
View Full Code Here

        final String uri = "http://exolab.org:80";
        final String proxyHost = "boo";
        final int proxyPort = 9090;
        final String proxyUser = "hoo";
        final String proxyPassword = "shoo";
        final SSLProperties ssl = new SSLProperties();

        HTTPRequestInfo info1 = populate(uri, proxyHost, proxyPort, proxyUser,
                                         proxyPassword, null);
        HTTPRequestInfo info2 = populate(uri, proxyHost, proxyPort, proxyUser,
                                         proxyPassword, null);
View Full Code Here

        final String uri = "https://exolab.org";
        final String proxyHost = "binky";
        final int proxyPort = 1032;
        final String proxyUser = "gum";
        final String proxyPassword = "ball";
        final SSLProperties ssl = new SSLProperties();
        ssl.setKeyStore("keyStore");
        ssl.setKeyStorePassword("keyStorePassword");
        ssl.setKeyStoreType("JKS");
        ssl.setTrustStore("trustStore");
        ssl.setTrustStorePassword("trustStorePassword");
        ssl.setTrustStoreType("PCKS12");

        Properties properties = new Properties(prefix);
        HTTPRequestInfo info1 = populate(uri, proxyHost, proxyPort, proxyUser,
                                         proxyPassword, ssl);
        info1.export(properties);
View Full Code Here

     *
     * @throws Exception for any error
     */
    public void testAccessors() throws Exception {
        final String uri = "tcps://localhost:8050";
        final SSLProperties ssl = new SSLProperties();
        final boolean clientAuthReqd = true;
        final boolean clientAuthNotReqd = false;

        TCPSRequestInfo info = populate(uri, null, true, ssl, clientAuthReqd);

View Full Code Here

     */
    public void testEquals() throws Exception {
        final String uri = "tcp://localhost:8050";
        final String alternativeURI = "tcp://foo.org:9090";
        final boolean bindAll = true;
        final SSLProperties ssl = new SSLProperties();
        final boolean clientAuthReqd = true;
        final boolean clientAuthNotReqd = false;

        TCPSRequestInfo info1 = populate(uri, alternativeURI, bindAll,
                                         ssl, clientAuthReqd);
View Full Code Here

    public void testProperties() throws Exception {
        final String prefix = "org.exolab.jms.net.tcps.";
        final String uri = "tcps://exolab.org:4040/";
        final String alternativeHost = "localhost";
        final boolean bindAll = false;
        final SSLProperties ssl = new SSLProperties();
        final boolean clientAuthReqd = true;

        ssl.setKeyStore("keyStore");
        ssl.setKeyStorePassword("keyStorePassword");
        ssl.setKeyStoreType("JKS");
        ssl.setTrustStore("trustStore");
        ssl.setTrustStorePassword("trustStorePassword");
        ssl.setTrustStoreType("PCKS12");

        Properties properties = new Properties(prefix);
        TCPSRequestInfo info1 = populate(uri, alternativeHost, bindAll,
                                         ssl, clientAuthReqd);
        info1.export(properties);
View Full Code Here

     * @throws ResourceException if any of the properties are invalid
     */
    public TCPSRequestInfo(URI uri, Properties properties)
            throws ResourceException {
        super(uri, properties);
        SSLProperties ssl = new SSLProperties(properties);
        if (!ssl.isEmpty()) {
            setSSLProperties(ssl);
        }
        setNeedClientAuth(
                properties.getBoolean(NEED_CLIENT_AUTH, _needCientAuth));
    }
View Full Code Here

     *
     * @param properties the properties to export to.
     */
    public void export(Properties properties) {
        super.export(properties);
        SSLProperties ssl = getSSLProperties();
        if (ssl != null) {
            ssl.export(properties);
        }
        properties.set(NEED_CLIENT_AUTH, getNeedClientAuth());
    }
View Full Code Here

TOP

Related Classes of org.exolab.jms.net.util.SSLProperties

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.