From 0673370edace281f1345d7411e0ec65406835530 Mon Sep 17 00:00:00 2001 From: terrafrost Date: Tue, 15 Jun 2021 07:24:34 -0500 Subject: [PATCH] SFTP: don't check SFTP packet size after SFTP initialization --- phpseclib/Net/SFTP.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/phpseclib/Net/SFTP.php b/phpseclib/Net/SFTP.php index f2d017d6..74a29739 100644 --- a/phpseclib/Net/SFTP.php +++ b/phpseclib/Net/SFTP.php @@ -3180,7 +3180,7 @@ class Net_SFTP extends Net_SSH2 // 256 * 1024 is what SFTP_MAX_MSG_LENGTH is set to in OpenSSH's sftp-common.h - if ($tempLength > 256 * 1024) { + if (!$this->use_request_id && $tempLength > 256 * 1024) { user_error('Invalid SFTP packet size'); return false; }