Skip to main content

parse_ident_reply

Function parse_ident_reply 

Source
pub fn parse_ident_reply(line: &str) -> IdentReply
Expand description

Parse one reply line.

Strict on purpose. Every field position in RFC 1413’s grammar carries meaning to whoever reads the result, so a line that does not fill them is reported as malformed rather than half-read: a USERID line with no userid must not become an empty username, and an unrecognised response type must not become an error token.

Whitespace is tolerated everywhere the grammar allows it — around the commas, around the colons, and at either end of the line.