From 99832f87ce6d621f77594d01ecf1ae1d5f1acbd3 Mon Sep 17 00:00:00 2001 From: postmannen Date: Tue, 22 Mar 2022 14:02:25 +0100 Subject: [PATCH] added logging to central when message read on socket --- message_readers.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/message_readers.go b/message_readers.go index 977fa21..f22481d 100644 --- a/message_readers.go +++ b/message_readers.go @@ -203,6 +203,11 @@ func (s *server) readSocket() { // Fill in the value for the FromNode field, so the receiver // can check this field to know where it came from. sams[i].Message.FromNode = Node(s.nodeName) + + // Send an info message to the central about the message picked + // for auditing. + er := fmt.Errorf("info: message read from socket on %v: %v", s.nodeName, sams[i].Message) + s.processes.errorKernel.errSend(s.processInitial, Message{}, er) } // Send the SAM struct to be picked up by the ring buffer.