Function parse_ssh_identification

Source
pub fn parse_ssh_identification(
    i: &[u8],
) -> IResult<&[u8], (Vec<&[u8]>, SshVersion<'_>)>
Expand description

Parse the SSH identification phase.

In version 2.0, the SSH server is allowed to send an arbitrary number of UTF-8 lines before the final identification line containing the server version. This function allocates a vector to store these line slices in addition of the advertised version of the SSH implementation.