Skip to content

Commit

Permalink
https://telecominfraproject.atlassian.net/browse/WIFI-7831
Browse files Browse the repository at this point in the history
Signed-off-by: stephb9959 <[email protected]>
  • Loading branch information
stephb9959 committed Oct 16, 2023
1 parent c73a7c6 commit 6f3079a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
7 changes: 2 additions & 5 deletions src/RADIUS_Destination.h
Original file line number Diff line number Diff line change
Expand Up @@ -125,24 +125,21 @@ namespace OpenWifi {
P.PacketType(), NumberOfReceivedBytes));
AP_WS_Server()->SendRadiusAuthenticationData(SerialNumber, Buffer,
NumberOfReceivedBytes);
P.Log(std::cout);
// P.Log(std::cout);
} else {
poco_trace(Logger_, "AUTH packet dropped.");
}
} else if (P.IsAccounting()) {
DBGLINE
auto SerialNumber = P.ExtractSerialNumberFromProxyState();
if (!SerialNumber.empty()) {
DBGLINE
P.Log(std::cout);
// P.Log(std::cout);
poco_trace(Logger_,
fmt::format("{}: {} Received {} bytes.", SerialNumber,
P.PacketType(), NumberOfReceivedBytes));
AP_WS_Server()->SendRadiusAccountingData(SerialNumber, Buffer,
NumberOfReceivedBytes);
DBGLINE
} else {
DBGLINE
poco_trace(Logger_, "ACCT packet dropped.");
}
} else if (P.IsAuthority()) {
Expand Down
2 changes: 1 addition & 1 deletion src/RADIUS_proxy_server.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@ namespace OpenWifi {
poco_trace(Logger(),fmt::format("{}: Sending Acct {} bytes to {}", serialNumber, P.Size(), Destination));
if(DestinationServer->second->ServerType()!=GWObjects::RadiusEndpointType::generic) {
Secret = DestinationServer->second->Pool().acctConfig.servers[0].secret;
std::cout << "Secret" << Secret << std::endl;
if(RecomputeAuthenticator) {
DBGLINE
P.RecomputeAuthenticator(Secret);
Expand Down Expand Up @@ -139,7 +140,6 @@ namespace OpenWifi {
std::string Secret;
RouteAndSendAccountingPacket(Destination, serialNumber, P, false, Secret);
RADIUSSessionTracker()->AddAccountingSession(Destination, serialNumber, P, Secret);

} catch (const Poco::Exception &E) {
Logger().log(E);
} catch (...) {
Expand Down

0 comments on commit 6f3079a

Please sign in to comment.