Fix body size, receive (elapsed time) and timestamps (#258)

* Fix the HTTP body size (it's not applicable to AMQP and Kafka)

* Fix the elapsed time

* Change JSON fields from snake_case to camelCase
This commit is contained in:
M. Mert Yıldıran
2021-09-04 17:15:39 +03:00
committed by GitHub
parent 366c1d0c6c
commit 4e0ff74944
14 changed files with 98 additions and 67 deletions

View File

@@ -144,13 +144,14 @@ func (t *tcpStream) ReassembledSG(sg reassembly.ScatterGather, ac reassembly.Ass
// This is where we pass the reassembled information onwards
// This channel is read by an tcpReader object
statsTracker.incReassembledTcpPayloadsCount()
timestamp := ac.GetCaptureInfo().Timestamp
if dir == reassembly.TCPDirClientToServer {
for _, reader := range t.clients {
reader.msgQueue <- tcpReaderDataMsg{data, ac.GetCaptureInfo().Timestamp}
reader.msgQueue <- tcpReaderDataMsg{data, timestamp}
}
} else {
for _, reader := range t.servers {
reader.msgQueue <- tcpReaderDataMsg{data, ac.GetCaptureInfo().Timestamp}
reader.msgQueue <- tcpReaderDataMsg{data, timestamp}
}
}
}