diff --git a/go.mod b/go.mod index a6caacaf..e17a34c6 100644 --- a/go.mod +++ b/go.mod @@ -15,7 +15,7 @@ require ( github.com/mitchellh/hashstructure v1.0.0 github.com/patrickmn/go-cache v2.1.0+incompatible github.com/pkg/sftp v1.11.0 - github.com/secsy/goftp v0.0.0-20190720192957-f31499d7c79a + github.com/secsy/goftp v0.0.0-20200609142545-aa2de14babf4 github.com/sirupsen/logrus v1.4.2 // indirect github.com/stretchr/testify v1.4.0 github.com/tidwall/gjson v1.3.5 diff --git a/go.sum b/go.sum index 2d24f486..46216b29 100644 --- a/go.sum +++ b/go.sum @@ -90,6 +90,8 @@ github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZb github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/secsy/goftp v0.0.0-20190720192957-f31499d7c79a h1:C6IhVTxNkhlb0tlCB6JfHOUv1f0xHPK7V8X4HlJZEJw= github.com/secsy/goftp v0.0.0-20190720192957-f31499d7c79a/go.mod h1:MnkX001NG75g3p8bhFycnyIjeQoOjGL6CEIsdE/nKSY= +github.com/secsy/goftp v0.0.0-20200609142545-aa2de14babf4 h1:PT+ElG/UUFMfqy5HrxJxNzj3QBOf7dZwupeVC+mG1Lo= +github.com/secsy/goftp v0.0.0-20200609142545-aa2de14babf4/go.mod h1:MnkX001NG75g3p8bhFycnyIjeQoOjGL6CEIsdE/nKSY= github.com/sergi/go-diff v1.0.0 h1:Kpca3qRNrduNnOQeazBd0ysaKrUJiIuISHxogkT9RPQ= github.com/sergi/go-diff v1.0.0/go.mod h1:0CfEIISq7TuYL3j771MWULgwwjU+GofnZX9QAmXWZgo= github.com/sirupsen/logrus v1.4.2 h1:SPIRibHv4MatM3XXNO2BJeFLZwZ2LvZgfQ5+UNI2im4= diff --git a/vendor/github.com/secsy/goftp/persistent_connection.go b/vendor/github.com/secsy/goftp/persistent_connection.go index 7a7c39d9..15f5d749 100644 --- a/vendor/github.com/secsy/goftp/persistent_connection.go +++ b/vendor/github.com/secsy/goftp/persistent_connection.go @@ -250,6 +250,19 @@ func (pconn *persistentConn) logIn() error { return ftpError{code: code, msg: msg} } + if pconn.config.TLSConfig != nil && pconn.config.TLSMode == TLSImplicit { + + err = pconn.sendCommandExpected(replyGroupPositiveCompletion, "PBSZ 0") + if err != nil { + return err + } + + err = pconn.sendCommandExpected(replyGroupPositiveCompletion, "PROT P") + if err != nil { + return err + } + } + return nil } diff --git a/vendor/modules.txt b/vendor/modules.txt index 53e3175c..d2f760e7 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -108,7 +108,7 @@ github.com/pkg/errors github.com/pkg/sftp # github.com/pmezard/go-difflib v1.0.0 github.com/pmezard/go-difflib/difflib -# github.com/secsy/goftp v0.0.0-20190720192957-f31499d7c79a +# github.com/secsy/goftp v0.0.0-20200609142545-aa2de14babf4 github.com/secsy/goftp # github.com/sergi/go-diff v1.0.0 github.com/sergi/go-diff/diffmatchpatch