Your best friend for file transfer.

Fetch application logoFetch

Could not get file because the SFTP server sent an unexpected response (20 posts)

  • Started 1 year ago by Erik
  • Latest reply 2 months ago from Sean
  • Erik Member

    A client of ours is trying to retrieve files from our sftp site using Fetch, and is unable. I have just downloaded Fetch 5.8.3 and I get the same error. We generally use Transmit, and many other clients use Cyberduck with no issues. We can login, upload and navigate just fine, it is the getting of files that is the problem.

    The error is: Fetch could not get <filename> because the SFTP server sent an unexpected response. Contact Fetch Softworks technical support for assistance.

    So here we are!

    Also, here is a snippet from the transcript log. It appears we are being disconnected while attempting the download:

    SSH2_FXP_READDIR 23
    SSH2_FXP_CLOSE 24
    SSH2_FX_OK 24
    SSH2_FXP_OPEN 25, /nyt-sftp/IW/LSD/LSD-PDFs/20221210_LSD_04_JMP.pdf [ SSH2_FXF_READ ]
    SSH2_FXP_FSTAT 26
    Download of 20221210_LSD_04_JMP.pdf failed (err = 2,24002) with 0 bytes transferred (state == RGET_RETRIEVING)
    retry_failed_operation derr = 2, 24002 retry_state = RGET_FILE_START cancel_cur_cmd = 1 force_reconnect = 0 tw->retry_reconnect_count = 0 making_progress = 0, tw->retry_count = 0
    Unsuccessful download of 20221210_LSD_04_JMP.pdf (0/1,091,303 bytes, 0 bytes/sec, 0:00 elapsed) stopped at 2023-02-06T21:53:03Z (error: 2,24002)
    Error retrieving file, will retry (attempt #1)
    Connecting to Core_Iw@nytftp.nytlicensing.com port 22 (2023-02-06T21:53:08Z)
    SSH2_FXP_INIT 3
    SSH2_FXP_REALPATH 1, .
    /nyt-sftp
    SSH2_FXP_STAT 2, /nyt-sftp
    SSH2_FXP_REALPATH 3, /nyt-sftp/IW/LSD/LSD-PDFs

    Appreciate any advice.
    Cheers,
    Erik

    Posted 1 year ago #

  • Jim Matthews Administrator

    Hi,

    Could you try typing this in Terminal and letting me know if it makes a difference?

    defaults write com.fetchsoftworks.Fetch MultipleOutstandingSFTPReads --bool false

    Thanks,

    Jim Matthews
    Fetch Softworks

    Posted 1 year ago #

  • Erik Member

    Thanks, Jim, that did the trick!

    Posted 1 year ago #

  • Tom Member

    I am having the same issue. Running Fetch 5.8.3. Have tried using the GET icon and also simple drag and drop. Tried the Terminal plug in, though not sure what I was doing, and no change. Help!

    Posted 11 months ago #

  • Jim Matthews Administrator

    Hi Tom,

    Could you contact me at https://fetchsoftworks.com/fetch/feedback ?

    Thanks,

    Jim Matthews
    Fetch Softworks

    Posted 11 months ago #

  • Sean Member

    Running Ventura 13.6.1 and trying to get 5.8.3 to work. Get this error:
    SFTP connection to “webserver.b-di.com” could not be opened because the SFTP server rejected your authentication information.
    The information has not changed from before upgrade. Not sure why it has port 22 previous versions did not have that.
    Any suggestions?

    Sean

    Posted 2 months ago #

  • Jim Matthews Administrator

    Hi Sean,

    Could you post the contents of the Fetch Transcript window after you get that error here or at https://fetchsoftworks.com/fetch/feedback ?

    Thanks,

    Jim Matthews
    Fetch Softworks

    Posted 2 months ago #

  • Sean Member

    Cant see the window but the popup says:

    SFTP connection to “webserver.b-di.com” could not be opened because the SFTP server rejected your authentication information.
    Contact the server administrator to verify that you have the correct hostname, username, password, and authentication method.

    I emailed the admin and he asked about the password. He is looking into it.

    Posted 2 months ago #

  • Sean Member

    Admin says it worked for him but I just got this:
    Try again, or contact the server administrator to verify that you have the correct hostname, username, password, and authentication method, and that the server is running.
    Server responded: “Unable to negotiate with 209.250.2.105 port 22: no matching host key type found. Their offer: ssh-rsa,ssh-dss

    Posted 2 months ago #

  • Jim Matthews Administrator

    Hi Sean,

    The problem is that by default your version of macOS does not use the host key algorithm used by your SFTP server (Apple made this change to improve security). You may want to ask your SFTP server administrator to upgrade the SFTP server to support newer host key algorithms. Otherwise you can work around this change by doing the following:

    1) Choose Utilities from the Go menu in the Finder
    2) Open Terminal
    3) Enter the following (replacing HOSTNAME with your server's hostname):

    echo -e "\nHost HOSTNAME\nHostkeyAlgorithms +ssh-rsa\n" >> ~/.ssh/config

    and press Return.

    Please let me know if that does not work.

    Thanks,

    Jim Matthews
    Fetch Softworks

    Posted 2 months ago #

  • Sean Member

    It did not work, as it asked for my shell password and I don't know it. It is also saying "The default interactive shell is now zsh. To update your account to use zsh, please run chsh -s /bin/zsh. "

    My admin says that my server is old and can't update to newer configurations. I know the credentials are correct because it works for FileZilla (sorry) but I want to use Fetch.

    Will see if admin has the p/w.

    Posted 2 months ago #

  • Jim Matthews Administrator

    Hi Sean,

    You shouldn't need to enter a password or change to zsh. Can you type

    ls -l ~/.ssh

    in Terminal and hit Return? What does it say?

    Thanks,

    Jim Matthews
    Fetch Softworks

    Posted 2 months ago #

  • Sean Member

    total 16
    -rw-r--r-- 1 smcdevitt staff 106 Jan 30 08:08 config
    -rw-r--r-- 1 smcdevitt staff 2561 Feb 25 2019 known_hosts
    iMac-2:~ smcdevitt$

    Posted 2 months ago #

  • Jim Matthews Administrator

    Hi Sean,

    And what do you get when you paste

    echo -e "\nHost HOSTNAME\nHostkeyAlgorithms +ssh-rsa\n" >> ~/.ssh/config

    (after replacing HOSTNAME with the hostname of your SFTP server)?

    Thanks,

    Jim Matthews
    Fetch Softworks

    Posted 2 months ago #

  • Sean Member

    same thing. credentials are invalid.

    Posted 2 months ago #

  • Jim Matthews Administrator

    Hi Sean,

    Could you post the contents of the Fetch Transcript window after you get the error, either here or at https://fetchsoftworks.com/fetch/feedback ? It's listed in the Window menu in the main menu bar.

    Thanks,

    Jim Matthews
    Fetch Softworks

    Posted 2 months ago #

  • Sean Member

    IT IS POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY!

    Someone could be eavesdropping on you right now (man-in-the-middle attack)!

    It is also possible that a host key has just been changed.

    The fingerprint for the DSA key sent by the remote host is
    SHA256:kk2jX8GWE/RX1XgElIXfW/x3wzVHewe1oEv/96ajXl8.

    Please contact your system administrator.

    Add correct host key in /Users/smcdevitt/.ssh/known_hosts to get rid of this message.

    Offending RSA key in /Users/smcdevitt/.ssh/known_hosts:3

    Host key for webserver.b-di.com has changed and you have requested strict checking.

    Host key verification failed.

    SFTP connection to “webserver.b-di.com” could not be opened because the SFTP server rejected your authentication information. (Contact the server administrator to verify that you have the correct hostname, username, password, and authentication method.)

    Posted 2 months ago #

  • Sean Member

    Sent this to admin and he asked: What authentication method are you using?

    Posted 2 months ago #

  • Jim Matthews Administrator

    Hi Sean,

    Thanks for sending the transcript. The problem is that the host key changed on the server, and the SFTP server is trying to protect you from the possibility that a hacker is impersonating your server. If it's just the case that the hosting company updated the key you can work around this problem by following these steps:

    1) Choose Utilities from the Go menu in the Finder
    2) Open Terminal
    3) Enter the following:

    sed -i -e "3d" ~/.ssh/known_hosts

    and press Return.

    Let me know if that doesn't work.

    Thanks,

    Jim Matthews
    Fetch Softworks

    Posted 2 months ago #

  • Sean Member

    I am in now. Thanks, Jim!!

    Posted 2 months ago #

Reply

  • Or nickname, if you prefer.
  • This will be kept confidential.
  • This is to ensure that you’re a person, not a spambot.