What is IAC (Interpret as Command) in TELNET
TELNET commands and options are sent along with data stream. TELNET commands are identified by setting the most significant (left-most) bit as 1. In TELNET, IAC (Interpret As Command) is a special command used for negotiating and signaling between TELNET client and TELNET server. IAC (Interpret As Command) is a special command code 255 in decimals (FF in hexadecimals). The meaning of IAC (Interpret As Command) in telnet is to treat the next byte as command, not as data.
The data from TELNET client to TELNET server except 0xFF are transmitted as is. IAC (Interpret As Command) points that next byte is a command, not data. IAC (Interpret as Command) is repeated two times (think it as escape character) if that is appeared in normal data stream.
Please refer below Wireshark packet capture screenshot.
The 0xff marked in above image is the special TELNET IAC (Interpret As Command). Here IAC (Interpret As Command) points that the next byte 0xfb (251 in decimals), is a TELNET command, not data.