1832390 Members
3028 Online
110041 Solutions
New Discussion

Legacy terminal support

 

Legacy terminal support

I don't know the version numbers, but the operating systems were the latest at the time the servers were configured.

A client of mine is migrating from a server purchased in 1998 to one purchased last month. The server is used to manage communications with a legacy handheld application that uses ZModem for file transfer.

The handheld can connect to the server, but file transfers fail.

ZModem control packets are terminated with CR (0x0D) and LF | 0x80 (0x8A). Unfortunately, the packet comes across with the CR intact, but the upper ASCII second character is encoded as 0x00 0x8A. As the protocol is not expecting this spurious NUL, the file transfer fails.

I've been through all the stty settings, including "stty raw", to no avail.

Does anyone know how to configure terminal sessions on the new server so that they behave the way the old one did?

Debugging of the communication channel has revealed that the server
3 REPLIES 3

Re: Legacy terminal support

Ignore the incomplete last paragraph ("Debugging...").

Re: Legacy terminal support

It turns out that there's a bug in the telnet server installed on the new box. Debugging of the communication channel confirms that the handheld is negotiating a binary connection and the server is acknowledging same, but the binary channel is not being honoured and the host is translating CR to CR NUL. Here's the chatter between the handheld and the host:

Handheld: WILL BINARY (advertise its capability)
Handheld: DO BINARY (tell the host to do binary)
Host: DO BINARY (tell the handheld to do binary)
Handheld: WILL BINARY (acknowledgement of host request)
Host: WILL BINARY (acknowledgement of earlier handheld request)

I had to modify the handheld to send a second DO BINARY to the host after the host sends its own DO BINARY. The sequence now looks like this:

Handheld: WILL BINARY (advertise its capability)
Handheld: DO BINARY (tell the host to do binary)
Host: DO BINARY (tell the handheld to do binary)
Handheld: WILL BINARY (acknowledgement of host request)
Handheld: DO BINARY (tell the host to do binary a second time)
Host: WILL BINARY (acknowledgement of first handheld request)
Host: WILL BINARY (acknowledgement of second handheld request)

This is actually easy to test. Using the Windows XP FTP command-line client, download a binary file from the host. Note that the number of bytes to transfer at the start of the download does NOT match the number of bytes eventually transferred. The difference is in the extra NUL characters that are appended to the CR characters.

Re: Legacy terminal support

As indicated in previous post.