Package org.apache.directory.api.asn1.actions

Examples of org.apache.directory.api.asn1.actions.AbstractReadOctetString


        if ( tlv.getLength() == 0 )
        {
            LOG.error( I18n.err( I18n.ERR_04066 ) );

            // This will generate a PROTOCOL_ERROR
            throw new DecoderException( I18n.err( I18n.ERR_04067 ) );
        }

        KrbCred krbCred = new KrbCred();
        krbCredContainer.setKrbCred( krbCred );
View Full Code Here


        if ( tlv.getLength() == 0 )
        {
            LOG.error( I18n.err( I18n.ERR_04066 ) );

            // This will generate a PROTOCOL_ERROR
            throw new DecoderException( I18n.err( I18n.ERR_04067 ) );
        }

        // decoder for Ticket
        Asn1Decoder decoder = new Asn1Decoder();
View Full Code Here

        if ( tlv.getLength() == 0 )
        {
            LOG.error( I18n.err( I18n.ERR_744_NULL_PDU_LENGTH ) );

            // This will generate a PROTOCOL_ERROR
            throw new DecoderException( I18n.err( I18n.ERR_744_NULL_PDU_LENGTH ) );
        }

        // Create the Ticket now
        Ticket ticket = new Ticket();
View Full Code Here

        if ( tlv.getLength() == 0 )
        {
            LOG.error( I18n.err( I18n.ERR_04066 ) );

            // This will generate a PROTOCOL_ERROR
            throw new DecoderException( I18n.err( I18n.ERR_04067 ) );
        }

        Checksum checksum = checksumContainer.getChecksum();
        // The Checksum's type is an integer
        BerValue value = tlv.getValue();

        try
        {
            int cksumType = IntegerDecoder.parse( value );

            checksum.setChecksumType( ChecksumType.getTypeByValue( cksumType ) );

            if ( IS_DEBUG )
            {
                LOG.debug( "cksumType : " + cksumType );
            }
        }
        catch ( IntegerDecoderException ide )
        {
            LOG.error( I18n.err( I18n.ERR_04070, Strings.dumpBytes( value.getData() ), ide
                .getLocalizedMessage() ) );

            // This will generate a PROTOCOL_ERROR
            throw new DecoderException( ide.getMessage() );
        }

    }
View Full Code Here

        if ( tlv.getLength() == 0 )
        {
            LOG.error( I18n.err( I18n.ERR_04066 ) );

            // This will generate a PROTOCOL_ERROR
            throw new DecoderException( I18n.err( I18n.ERR_04067 ) );
        }

        Checksum checksum = new Checksum();
        checksumContainer.setChecksum( checksum );
View Full Code Here

        if ( tlv.getLength() == 0 )
        {
            LOG.error( I18n.err( I18n.ERR_04066 ) );

            // This will generate a PROTOCOL_ERROR
            throw new DecoderException( I18n.err( I18n.ERR_04067 ) );
        }

        // Now, let's decode the KDC-REQ
        Asn1Decoder kdcReqDecoder = new Asn1Decoder();

        KdcReqContainer kdcReqContainer = new KdcReqContainer( tgsReqContainer.getStream() );

        // Store the created TGS-REQ object into the KDC-REQ container
        TgsReq tgsReq = new TgsReq();
        kdcReqContainer.setKdcReq( tgsReq );

        // Decode the KDC_REQ PDU
        try
        {
            kdcReqDecoder.decode( tgsReqContainer.getStream(), kdcReqContainer );
        }
        catch ( DecoderException de )
        {
            throw de;
        }

        // Update the expected length for the current TLV
        tlv.setExpectedLength( tlv.getExpectedLength() - tlv.getLength() );

        // Update the parent
        tgsReqContainer.updateParent();

        if ( tgsReq.getMessageType() != KerberosMessageType.TGS_REQ )
        {
            throw new DecoderException( "Bad message type" );
        }

        tgsReqContainer.setTgsReq( tgsReq );

        if ( IS_DEBUG )
View Full Code Here

        if ( tlv.getLength() == 0 )
        {
            LOG.error( I18n.err( I18n.ERR_04066 ) );

            // This will generate a PROTOCOL_ERROR
            throw new DecoderException( I18n.err( I18n.ERR_04067 ) );
        }

        // Now, let's decode the EncKdcRepPart
        Asn1Decoder encKdcRepPartDecoder = new Asn1Decoder();
View Full Code Here

            { 0x30, 0x00 } );

        stream.flip();

        // Allocate a KDC-REQ Container
        Asn1Container kdcReqContainer = new KdcReqContainer( stream );

        // Decode the KDC-REQ PDU
        kerberosDecoder.decode( stream, kdcReqContainer );
        fail();
    }
View Full Code Here

        } );

        stream.flip();

        // Allocate a KDC-REQ Container
        Asn1Container kdcReqContainer = new KdcReqContainer( stream );

        // Decode the KDC-REQ PDU
        kerberosDecoder.decode( stream, kdcReqContainer );
        fail();
    }
View Full Code Here

        } );

        stream.flip();

        // Allocate a KDC-REQ Container
        Asn1Container kdcReqContainer = new KdcReqContainer( stream );

        // Decode the KDC-REQ PDU
        kerberosDecoder.decode( stream, kdcReqContainer );
        fail();
    }
View Full Code Here

TOP

Related Classes of org.apache.directory.api.asn1.actions.AbstractReadOctetString

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.