フォーラム: ヘルプ (スレッド #40154)

Trailing Zero Byte on Custom User Key Mapping (2018-11-22 02:58 by davbro #82192)

Attempting to map a user key. I need to send Esc d followed by a carriage return. So I modified KEYBOARD.CNF to include this:

User11=575,0,$01$64$0D

According to WireShark, what is actually being sent is 1B 64 0D 00. The trailing zero byte is tripping up the host. We do this same emulation on an old 32-bit ProComm and it sends the expected 1B 64 0D with no trailing zero byte. I have tried changing the mapping to this:

User11=575,1,$01$64$0D

(modify the 2nd parameter to a 1) and it has the same result. Please advise

Re: Trailing Zero Byte on Custom User Key Mapping (2018-11-22 09:59 by doda #82193)

メッセージ #82192 への返信
> According to WireShark, what is actually being sent is 1B 64 0D 00.

This behavior came from a specification of the telnet protocol.
Please use the "other" instead of "telnet" for service when connecting.
#82192 への返信

Re: Trailing Zero Byte on Custom User Key Mapping (2018-11-27 03:00 by davbro #82197)

Reply To Message #82193
> メッセージ #82192 への返信
> > According to WireShark, what is actually being sent is 1B 64 0D 00.
>
> This behavior came from a specification of the telnet protocol.
> Please use the "other" instead of "telnet" for service when connecting.

Thanks for that. I tried using 'Other' this morning and it made no difference. (the null byte still terminated the string) Any other ideas?
#82193 への返信

Re: Trailing Zero Byte on Custom User Key Mapping (2018-11-28 12:11 by doda #82208)

What the server type did you connect to? Telnet server? Or other?
And what port number that the server using?
#82197 への返信

Re: Trailing Zero Byte on Custom User Key Mapping (2018-11-29 00:39 by davbro #82211)

Reply To Message #82208
> What the server type did you connect to? Telnet server? Or other?
> And what port number that the server using?

Host is an RS6000. Port number 23 so it is Telnet. If the trailing 0x00 is coming from the protocol stack, then why is it not sent by ProComm? It appears to be generated by TeraTerm.
#82208 への返信

Re: Trailing Zero Byte on Custom User Key Mapping (2018-11-29 13:04 by doda #82214)

メッセージ #82211 への返信
> If the trailing 0x00 is coming from the protocol stack,

RFC 854 says:
| Therefore, the sequence "CR LF" must be treated as a single "new
| line" character and used whenever their combined action is
| intended; the sequence "CR NUL" must be used where a carriage
| return alone is actually desired; and the CR character must be
| avoided in other contexts.

On the telnet connection, Tera Term add NUL after CR.
Telnet server must trims this NUL, and past the CR alone to the application program.

> then why is it not sent by ProComm? It appears to be generated by TeraTerm.

ProCom may be using the TELNET binary option.
Could you try using the / B option when connecting?
#82211 への返信