mirror of
https://github.com/espressif/openthread.git
synced 2026-09-11 19:50:05 +00:00
Fix mismatching source address of secured CoAP server (#1520)
* fix wrong source address of coap server
This commit is contained in:
@@ -118,6 +118,13 @@ void SecureServer::Receive(Message &aMessage, const Ip6::MessageInfo &aMessageIn
|
||||
mPeerAddress.SetPeerAddr(aMessageInfo.GetPeerAddr());
|
||||
mPeerAddress.SetPeerPort(aMessageInfo.GetPeerPort());
|
||||
|
||||
if (mNetif.IsUnicastAddress(aMessageInfo.GetSockAddr()))
|
||||
{
|
||||
mPeerAddress.SetSockAddr(aMessageInfo.GetSockAddr());
|
||||
}
|
||||
|
||||
mPeerAddress.SetSockPort(aMessageInfo.GetSockPort());
|
||||
|
||||
mNetif.GetDtls().Start(false, HandleDtlsConnected, HandleDtlsReceive, HandleDtlsSend, this);
|
||||
}
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user