[server,proxy] discard closed dyn channel data

If a dynamic channel does no longer exist or has been closed discard the
channel data received from client
This commit is contained in:
akallabeth 2024-07-25 12:01:46 +02:00
parent eaf0bd8a69
commit 3820858c63
No known key found for this signature in database
GPG Key ID: A49454A3FC909FD5
1 changed files with 2 additions and 2 deletions

View File

@ -311,9 +311,9 @@ static PfChannelResult DynvcTrackerPeekFn(ChannelStateTracker* tracker, BOOL fir
*/
dynChannel = (pServerDynamicChannelContext*)HashTable_GetItemValue(
dynChannelContext->channels, &dynChannelId);
if (cmd != CREATE_REQUEST_PDU || !isBackData)
if ((cmd != CREATE_REQUEST_PDU) || !isBackData)
{
if (!dynChannel)
if (!dynChannel || (dynChannel->openStatus == CHANNEL_OPENSTATE_CLOSED))
{
/* we've not found the target channel, so we drop this chunk, plus all the rest of
* the packet */