mirror of
https://git.libssh.org/projects/libssh.git
synced 2026-02-04 12:20:42 +09:00
Pcap: Fix bug with non-encrypted incoming packets
This commit is contained in:
@@ -175,6 +175,17 @@ static int packet_read2(ssh_session session) {
|
||||
goto error;
|
||||
}
|
||||
}
|
||||
#ifdef WITH_PCAP
|
||||
else {
|
||||
/* No crypto */
|
||||
if(session->pcap_ctx){
|
||||
ssh_pcap_context_write(session->pcap_ctx,
|
||||
SSH_PCAP_DIR_IN, buffer_get(session->in_buffer),
|
||||
buffer_get_len(session->in_buffer),
|
||||
buffer_get_len(session->in_buffer));
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
buffer_pass_bytes(session->in_buffer, sizeof(uint32_t));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user