From bbdaa9a6451f7057a587b5a8e7a9acd54e6462c1 Mon Sep 17 00:00:00 2001 From: Maxim Mamontov Date: Wed, 10 Jan 2018 23:05:49 +0200 Subject: [PATCH] More verbose debug. --- .../plugins/authorization/inetaccess/inetaccess.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/projects/stargazer/plugins/authorization/inetaccess/inetaccess.cpp b/projects/stargazer/plugins/authorization/inetaccess/inetaccess.cpp index de30e7d2..3aec35ae 100644 --- a/projects/stargazer/plugins/authorization/inetaccess/inetaccess.cpp +++ b/projects/stargazer/plugins/authorization/inetaccess/inetaccess.cpp @@ -1203,7 +1203,7 @@ if ((iaUser->phase.GetPhase() == 2) && (connAck->rnd == iaUser->rnd + 1)) return -1; } } -printfd(__FILE__, "Invalid phase or control number. Phase: %d. Control number: %d\n", iaUser->phase.GetPhase(), connAck->rnd); +printfd(__FILE__, "Invalid phase or control number. Phase: %d. Control number: %d, expected: %d\n", iaUser->phase.GetPhase(), connAck->rnd, iaUser->rnd + 1); if (iaSettings.LogProtocolErrors()) { if (iaUser->phase.GetPhase() != 2) @@ -1248,7 +1248,7 @@ if ((iaUser->phase.GetPhase() == 2) && (connAck->rnd == iaUser->rnd + 1)) return -1; } } -printfd(__FILE__, "Invalid phase or control number. Phase: %d. Control number: %d\n", iaUser->phase.GetPhase(), connAck->rnd); +printfd(__FILE__, "Invalid phase or control number. Phase: %d. Control number: %d, expected: %d\n", iaUser->phase.GetPhase(), connAck->rnd, iaUser->rnd + 1); if (iaSettings.LogProtocolErrors()) { if (iaUser->phase.GetPhase() != 2) @@ -1411,6 +1411,8 @@ for (int j = 0; j < DIR_NUM; j++) iaUser->rnd = static_cast(random()); connSynAck6.rnd = iaUser->rnd; +printfd(__FILE__, "Sending CONN_SYN_ACK with control number %d.\n", iaUser->rnd); + connSynAck6.userTimeOut = iaSettings.GetUserTimeout().GetSec(); connSynAck6.aliveDelay = iaSettings.GetUserDelay().GetSec(); @@ -1453,6 +1455,8 @@ for (int j = 0; j < DIR_NUM; j++) iaUser->rnd = static_cast(random()); connSynAck8.rnd = iaUser->rnd; +printfd(__FILE__, "Sending CONN_SYN_ACK with control number %d.\n", iaUser->rnd); + connSynAck8.userTimeOut = iaSettings.GetUserTimeout().GetSec(); connSynAck8.aliveDelay = iaSettings.GetUserDelay().GetSec(); -- 2.44.2