From 6003817c6d0be63b83551b010e9c981849c8b51d Mon Sep 17 00:00:00 2001 From: Vivien Nicolas Date: Thu, 19 Sep 2024 14:24:16 +0200 Subject: [PATCH] [Logging] Use the ephemeral initiator node id in the logging message when the responder transmit a message (#35654) --- src/transport/SessionManager.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/transport/SessionManager.cpp b/src/transport/SessionManager.cpp index 82287339117182..d68a5f3e6e6480 100644 --- a/src/transport/SessionManager.cpp +++ b/src/transport/SessionManager.cpp @@ -332,6 +332,10 @@ CHIP_ERROR SessionManager::PrepareMessage(const SessionHandle & sessionHandle, P #if CHIP_PROGRESS_LOGGING destination = kUndefinedNodeId; fabricIndex = kUndefinedFabricIndex; + if (session->GetSessionRole() == Transport::UnauthenticatedSession::SessionRole::kResponder) + { + destination = session->GetEphemeralInitiatorNodeID(); + } #endif // CHIP_PROGRESS_LOGGING } break;