Uploaded image for project: 'MINA SSHD'
  1. MINA SSHD
  2. SSHD-115

Missing return handling SFTP SSH_FXP_OPEN cannot create error

Attach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 0.5.0
    • 0.6.0
    • None

    Description

      Stress testing the SFTP Subsystem I found protocol errors when file creation failed. This is due to a missing return after the error status is sent.

      The patch is simple...

      --- SftpSubsystem.java	(revision 1086267)
      +++ SftpSubsystem.java	(working copy)
      @@ -409,6 +409,7 @@
                                   if (((pflags & SSH_FXF_CREAT) != 0)) {
                                       if (!file.isWritable()) {
                                           sendStatus(id, SSH_FX_FAILURE, "Can not create " + path);
      +                                    return;
                                       }
                                       file.create();
                                   }
      

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            gnodet Guillaume Nodet
            michael13stevens Michael Stevens
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment