ANSI Characters Messing Up Input Buffer - WeOnlyDo Discussion board

ANSI Characters Messing Up Input Buffer (wodSSH / wodSSH.NET)

by bmclellan, Tuesday, May 06, 2008, 05:23 (6046 days ago)

Hello,

On the system I am connecting to, I am running into issues where I cannot receive data after I have executed a command due to ANSI characters in the input buffer.

If I set the value: objSSH.StripANSI = 1 I can retrieve the data properly, however I need to see all of these escape characters so this isn't the way I want to retrieve my data.

Are their known characters that can cause this problem?

One interesting thing, if I use the 'WaitFor' option and the program times out, I can then peek at the buffer some of the remaining data is returned to me.

I cannot give you access to the system, but if there is anything you want me to try, let me know!


Thanks
Barry

Re: ANSI Characters Messing Up Input Buffer

by woddrazen, Tuesday, May 06, 2008, 09:11 (6046 days ago) @ bmclellan

Barry,


Did you try to change TerminalType Property to vt100? What happened?

You can try also changing TerminalType Property to 'tty' or 'dumb'

Let us know how it goes.


Drazen

Re: ANSI Characters Messing Up Input Buffer

by bmclellan, Tuesday, May 06, 2008, 17:49 (6046 days ago) @ woddrazen

Good morning,

I have had them try 'vt100, tty and dumb'.

The results are the same as above.


Thanks!
Barry

Re: ANSI Characters Messing Up Input Buffer

by wodDamir, Tuesday, May 06, 2008, 18:33 (6046 days ago) @ bmclellan

Berry,

How do you receive the response? What method do you use?

I assume that the WaitFor now times out since it doesn't receive the same string as with StripANSI set to true.

Also, what exactly happens? You simply don't get the rest or an error occurs?

Regards,
Damba

Re: ANSI Characters Messing Up Input Buffer

by bmclellan, Tuesday, May 06, 2008, 19:13 (6046 days ago) @ wodDamir

Hi Damba,

I send a command to the system, then execute a WaitFor to find the start of the command I need to retrieve, after that comes back as true, I execute a
obj.Peek (string is truncated)
obj.Retrieve(obj.DataReady) (string is truncated)

I don't receive any errors.

Barry

Re: ANSI Characters Messing Up Input Buffer

by wodDamir, Tuesday, May 06, 2008, 19:19 (6046 days ago) @ bmclellan

Barry,

What protocol is this occuring with? Is there any chance we could duplicate this?

What command are you executing? Perhaps I could try it on one of our servers?

Regards,
Damba

Re: ANSI Characters Messing Up Input Buffer

by bmclellan, Tuesday, May 06, 2008, 20:02 (6046 days ago) @ wodDamir

I am using Protocol 1 (Telnet)

Unfortunately you won't be able to generate this on a standard unix server.

Is there any kind of debug information I can give you that might help?

Re: ANSI Characters Messing Up Input Buffer

by wodDamir, Tuesday, May 06, 2008, 20:07 (6046 days ago) @ bmclellan

Barry,

You can try setting DebugFile property to some file on disk, and send it over to techsupport@weonlydo.com once you reprofuce the issue.

Perhaps that would help us find out the problem.

Regards,
Damba