Would like to know if there a proper way to communicate with the terminal
before the session actually starts.



On Wed, Sep 5, 2012 at 7:47 PM, Kanupriya Dadariya <
kanupriya.dadar...@gmail.com> wrote:

> Hi,
>
> The requirement is not just display the message but also prompt for user
> input.
> For ex: If when the prompt to change the password comes from the
> Authentication service.
>
> I think , we should be using SSH_MSG_USERAUTH_FAILURE in this case.
>
> However, that doesn't help and I see the writeStatus as false without any
> exception.
>
>
> On Wed, Sep 5, 2012 at 12:50 PM, Kanupriya Dadariya <
> kanupriya.dadar...@gmail.com> wrote:
>
>> Thanks for the response . Will check with this.
>>
>>
>> On Tue, Sep 4, 2012 at 7:09 PM, Guillaume Nodet <gno...@gmail.com> wrote:
>>
>>> There is the SSH_MSG_DEBUG message though which is logged by the
>>> client/server upon reception.
>>>
>>> On Fri, Aug 31, 2012 at 3:42 PM, Kanupriya Dadariya <
>>> kanupriya.dadar...@gmail.com> wrote:
>>>
>>> > Hi,
>>> >
>>> > I am using Apache Mina sshd . Do not have my own encoder/decoder. Need
>>> to
>>> > display the message to client terminal during authentication .
>>> >
>>> > Probably making some obvious mistake , Can somebody please help me out
>>> ?
>>> >
>>> > Here is the code snippet : I get the writeStatus as false always and
>>> don't
>>> > get the message displayed .
>>> >
>>> > =============================
>>> > IoBuffer buffer = IoBuffer.allocate(1024, true);
>>> >     buffer.setAutoExpand(true);
>>> >     try {
>>> >       buffer.putString("small", Charset.forName("UTF-8").newEncoder());
>>> >
>>> >     } catch (CharacterCodingException e) {
>>> >
>>> >     }
>>> >
>>> >     WriteFuture future = ioSession.write(buffer,
>>> > ioSession.getRemoteAddress());
>>> >     IoFutureListener iof = new MinaIOFutureListener();
>>> >     future.addListener(iof);
>>> >
>>> >     if(future.isWritten()){
>>> >       writeStatus = true;
>>> >     } else {
>>> >       writeStatus = false;
>>> >     }
>>> >     future.removeListener(iof);
>>> > =================================
>>> > Appreciate any help .
>>> >
>>>
>>>
>>>
>>> --
>>> ------------------------
>>> Guillaume Nodet
>>> ------------------------
>>> Blog: http://gnodet.blogspot.com/
>>> ------------------------
>>> FuseSource, Integration everywhere
>>> http://fusesource.com
>>>
>>
>>
>

Reply via email to