From 90eb0220af3c95563360efd03f750deaa90f6e61 Mon Sep 17 00:00:00 2001 From: terrafrost Date: Sat, 10 Aug 2024 19:55:03 -0500 Subject: [PATCH] SSH2: fix possible infinite loop on packet timeout get_channel_packet() could call close_channel() which would call get_channel_packet(), again, repeat ad nauseam --- phpseclib/Net/SSH2.php | 3 --- 1 file changed, 3 deletions(-) diff --git a/phpseclib/Net/SSH2.php b/phpseclib/Net/SSH2.php index 516d1f9f..0ae1e055 100644 --- a/phpseclib/Net/SSH2.php +++ b/phpseclib/Net/SSH2.php @@ -4096,9 +4096,6 @@ class Net_SSH2 } else { $response = $this->_get_binary_packet(true); if ($response === true && $this->is_timeout) { - if ($client_channel == NET_SSH2_CHANNEL_EXEC && !$this->request_pty) { - $this->_close_channel($client_channel); - } return true; } if ($response === false) {