Package org.apache.qpid.proton.amqp.security

Examples of org.apache.qpid.proton.amqp.security.SaslInit


        DecoderImpl decoder = new DecoderImpl();
        EncoderImpl encoder = new EncoderImpl(decoder);
        AMQPDefinedTypes.registerAllTypes(decoder,encoder);

        _frameParser = new SaslFrameParser(_mockSaslFrameHandler, decoder);
        _saslFrameBody = new SaslInit();
        _saslFrameBody.setMechanism(Symbol.getSymbol("unused"));
        _saslFrameBytes = ByteBuffer.wrap(_amqpFramer.generateSaslFrame(0, new byte[0], _saslFrameBody));
    }
View Full Code Here


        writeFrame(response);
    }

    private void processInit()
    {
        SaslInit init = new SaslInit();
        init.setHostname(_hostname);
        init.setMechanism(_chosenMechanism);
        if(getChallengeResponse() != null)
        {
            init.setInitialResponse(getChallengeResponse());
            setChallengeResponse(null);
        }
        _initSent = true;
        writeFrame(init);
    }
View Full Code Here

        writeFrame(response);
    }

    private void processInit()
    {
        SaslInit init = new SaslInit();
        init.setHostname(_hostname);
        init.setMechanism(_chosenMechanism);
        if(getChallengeResponse() != null)
        {
            init.setInitialResponse(getChallengeResponse());
            setChallengeResponse(null);
        }
        _initSent = true;
        writeFrame(init);
    }
View Full Code Here

    public SaslInit newInstance(Object described)
    {
        List l = (List) described;

        SaslInit o = new SaslInit();

        if(l.size() <= 0)
        {
            throw new DecodeException("The mechanism field cannot be omitted");
        }

        switch(3 - l.size())
        {

            case 0:
                o.setHostname( (String) l.get( 2 ) );
            case 1:
                o.setInitialResponse( (Binary) l.get( 1 ) );
            case 2:
                o.setMechanism( (Symbol) l.get( 0 ) );
        }


        return o;
    }
View Full Code Here

TOP

Related Classes of org.apache.qpid.proton.amqp.security.SaslInit

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.