Skip to content

Avoid setting SFTP rename flags below version 5#754

Merged
hierynomus merged 2 commits intohierynomus:masterfrom
exceptionfactory:issue-751
Dec 22, 2021
Merged

Avoid setting SFTP rename flags below version 5#754
hierynomus merged 2 commits intohierynomus:masterfrom
exceptionfactory:issue-751

Conversation

@exceptionfactory
Copy link
Contributor

Pull request #652 introduced support for SFTP rename flags, which was released in SSHJ 0.32.0. The SFTPEngine.rename() method includes the rename flag mask without checking the SFTP operative version, causing communication issues described in #750 and #751.

The SFTP Version 5 Section 6.5 specification added support for rename flags, but previous versions such as SFTP Version 3 do not support rename flags.

This pull request changes the behavior and avoids appending the rename flag mask to the SFTP request packet for operative versions less than 5.

@hierynomus
Copy link
Owner

And thanks again! Totally missed that during the merge.

@hierynomus hierynomus merged commit ce0a7d5 into hierynomus:master Dec 22, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants