public static byte[] encodeOctetString(byte[] value)
    {
        byte[] lengthEncoded = encodeLength(value.length);
        ByteArrayDataOutput out = ByteStreams.newDataOutput(2 + lengthEncoded.length + value.length);
        out.write(OCTET_STRING_TAG);
        out.write(lengthEncoded);
        out.write(value);
        return out.toByteArray();
    }
public static byte[] encodeOctetString(byte[] value)
    {
        byte[] lengthEncoded = encodeLength(value.length);
        ByteArrayDataOutput out = ByteStreams.newDataOutput(2 + lengthEncoded.length + value.length);
        out.write(OCTET_STRING_TAG);
        out.write(lengthEncoded);
        out.write(value);
        return out.toByteArray();
    }
public static byte [ ] encodeOctetString ( byte [ ] value ) { byte [ ] lengthEncoded = encodeLength ( value . length ) ; ByteArrayDataOutput out = ByteStreams . newDataOutput ( 2 + lengthEncoded . length + value . length ) ; out . write ( OCTET_STRING_TAG ) ; out . write ( lengthEncoded ) ; out . write ( value ) ; return out . toByteArray ( ) ; }
Encodes an octet string.
Encodes an octet string .