fix: persist empty POST in TR-069 trace when CPE uses a new TCP port
When a CPE sends an empty POST (polling) on a new TCP connection, the remoteKey (IP:port) differs from the one registered during Inform. Add StateMachineManager.getHashIdForRemoteIp() to find the device by IP alone as a fallback, so cwmpDeviceId is resolved and the exchange is properly stored in the trace (cwmpMethod: Empty, dashed arrow).
This commit is contained in:
1 parent
3bb85d9031
commit
d44d896556
2 files changed
+28
No files matched your search
@@ -40,7 +40,10 @@ export default class CwmpController {
|
||||
try {
|
||||
if (isEmpty) {
|
||||
const rebound = manager.ensureSessionForRemote(remoteKey, sessionId)
|
||||
// Try exact remoteKey first (same TCP connection), then fall back to IP-only
|
||||
// (CPE may open a new TCP port for the empty POST)
|
||||
const hashId = manager.getHashIdForRemote(remoteKey)
|
||||
?? manager.getHashIdForRemoteIp(request.ip())
|
||||
if (hashId) ctx.cwmpDeviceId = hashId
|
||||
|
||||
logger.debug(
|
||||
|
||||
Reference in new issue
Block a user