Package com.sshtools.j2ssh.authentication

Examples of com.sshtools.j2ssh.authentication.AuthenticationProtocolException


     * @throws AuthenticationProtocolException
     */
    public void authenticate(AuthenticationProtocolClient authentication,
        String serviceToStart) throws IOException, TerminatedStateException {
        if ((getUsername() == null) || (agent == null)) {
            throw new AuthenticationProtocolException(
                "You must supply a username and agent");
        }

        // Iterate the agents keys, find an acceptable key and authenticate
        Map keys = agent.listKeys();
View Full Code Here


    public void setInstance(SshAuthenticationClient instance)
        throws AuthenticationProtocolException {
        if (instance instanceof PublicKeyAuthenticationClient) {
            this.instance = (PublicKeyAuthenticationClient) instance;
        } else {
            throw new AuthenticationProtocolException(
                "PublicKeyAuthenticationClient instance required");
        }
    }
View Full Code Here

    public boolean showPrompt(SshAuthenticationClient inst)
        throws AuthenticationProtocolException {
        if (inst instanceof PublicKeyAuthenticationClient) {
            instance = (PublicKeyAuthenticationClient) inst;
        } else {
            throw new AuthenticationProtocolException(
                "PublicKeyAuthenticationClient instance required");
        }

        File keyfile = (instance.getKeyfile() == null) ? null
                                                       : new File(instance.getKeyfile());
View Full Code Here

    public void setInstance(SshAuthenticationClient instance)
        throws AuthenticationProtocolException {
        if (instance instanceof PasswordAuthenticationClient) {
            this.instance = (PasswordAuthenticationClient) instance;
        } else {
            throw new AuthenticationProtocolException(
                "PasswordAuthenticationClient instance required");
        }
    }
View Full Code Here

                return true;
            } else {
                return false;
            }
        } else {
            throw new AuthenticationProtocolException(
                "PasswordAuthenticationClient instance required");
        }
    }
View Full Code Here

    public void setInstance(SshAuthenticationClient instance)
        throws AuthenticationProtocolException {
        if (instance instanceof PasswordAuthenticationClient) {
            this.instance = (PasswordAuthenticationClient) instance;
        } else {
            throw new AuthenticationProtocolException(
                "PasswordAuthenticationClient instance required");
        }
    }
View Full Code Here

                return true;
            } else {
                return false;
            }
        } else {
            throw new AuthenticationProtocolException(
                "PasswordAuthenticationClient instance required");
        }
    }
View Full Code Here

     * @throws AuthenticationProtocolException
     */
    public void authenticate(AuthenticationProtocolClient authentication,
        String serviceToStart) throws IOException, TerminatedStateException {
        if ((getUsername() == null) || (agent == null)) {
            throw new AuthenticationProtocolException(
                "You must supply a username and agent");
        }

        // Iterate the agents keys, find an acceptable key and authenticate
        Map keys = agent.listKeys();
View Full Code Here

    public void setInstance(SshAuthenticationClient instance)
        throws AuthenticationProtocolException {
        if (instance instanceof PublicKeyAuthenticationClient) {
            this.instance = (PublicKeyAuthenticationClient) instance;
        } else {
            throw new AuthenticationProtocolException(
                "PublicKeyAuthenticationClient instance required");
        }
    }
View Full Code Here

    public boolean showPrompt(SshAuthenticationClient inst)
        throws AuthenticationProtocolException {
        if (inst instanceof PublicKeyAuthenticationClient) {
            instance = (PublicKeyAuthenticationClient) inst;
        } else {
            throw new AuthenticationProtocolException(
                "PublicKeyAuthenticationClient instance required");
        }

        File keyfile = (instance.getKeyfile() == null) ? null
                                                       : new File(instance.getKeyfile());
View Full Code Here

TOP

Related Classes of com.sshtools.j2ssh.authentication.AuthenticationProtocolException

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.