AllStarLink / app_rpt

Refactoring and upgrade of AllStarLink's app_rpt, etc.
8 stars 6 forks source link

chan_echolink: Does not report correct call sign for clients connecting through a relay #186

Closed KB4MDD closed 1 year ago

KB4MDD commented 1 year ago

chan_echolink does not report the correct call sign for clients connecting through a relay. When a client uses the relay option, they are not included in the master echolink directory. They are issued a different node number than the one assigned by echolink. Their IP address is the one associated with the proxy, not the client.

To address this issue, the query routine now looks up the node number in the currently connected nodes table. If it not found, it falls back to the internal directory table.

twalk_r is used to search the table for the connected node. This function was added to search.h in 2019. It provides the ability to pass and retrieve data from the action routine using the closure variable. It eliminates the need for global variables.

There are several routines that use twalk. In most cases, they depend on global variables to accumulate data or provide instructions for the twalk action. These routines were updated to use twalk_r and the new closure variable to pass or retrieve information.

This closes #185