Skip to content

File upload to Akamai NetStorage causes error "SSH_FX_BAD_MESSAGE" #4015

Closed

Description

@cyberduck

b012d94 created the issue

Version: 3.3 (5552)

Connecting to Akamai NetStorage (Akamai Storage in the cloud) via SSH. Can login and browse files successfully. When I drap and drop a file from the Finder in to cyberduck, the upload process connects and then errors out with the following

Bad message (SSH_FX_BAD_MESSAGE: A badly formatted packet or other SFTP protocol incompatibility was detected.).

No information is available in the trace window

Note that I can upload correctly on same machine to same host using Filezilla

Activity

  1. cyberduck commented on Jan 6, 2010

    @cyberduck
    ContributorAuthor

    paul167 commented

    Same issue here, can't upload to akamai over sftp

  2. cyberduck commented on Jan 7, 2010

    @cyberduck
    ContributorAuthor

    @dkocher commented

    I would need a test account at Akamai to debug this issue.

  3. cyberduck commented on Jan 7, 2010

    @cyberduck
    ContributorAuthor

    b012d94 commented

    I can take care of this

  4. cyberduck commented on Jan 8, 2010

    @cyberduck
    ContributorAuthor

    @dkocher commented

    Replying to [comment:4 graeme@…]:

    I can take care of this

    I have written an email to [ccare@akamai.com] about this.

  5. cyberduck commented on Jan 19, 2010

    @cyberduck
    ContributorAuthor

    9a8d2c8 commented

    Replying to [comment:5 dkocher]:

    Replying to [comment:4 graeme@…]:

    I can take care of this

    I have written an email to [ccare@akamai.com] about this.
    Anyway I can help out ? I dig cyberduck and this is a feature I could really use.
    I tried checking out the code but couldn't figure out anyway to debug the Java stuff which seems to be the interesting part.
    I did manage to upload a file with a simple project that uses Ganymed, so it doesn't seem to be broken in there.

  6. cyberduck commented on Jan 19, 2010

    @cyberduck
    ContributorAuthor

    @dkocher commented

    Replying to [comment:6 paul167@…]:

    Anyway I can help out ? I dig cyberduck and this is a feature I could really use.
    I tried checking out the code but couldn't figure out anyway to debug the Java stuff which seems to be the interesting part.
    I did manage to upload a file with a simple project that uses Ganymed, so it doesn't seem to be broken in there.

    That is interesting. How does your setup of Ganymed differ from what you can find in [source:trunk/source/ch/cyberduck/core/sftp/SFTPSession.java SFTPSession]?

  7. cyberduck commented on Jan 22, 2010

    @cyberduck
    ContributorAuthor

    9a8d2c8 commented

    Replying to [comment:7 dkocher]:

    That is interesting. How does your setup of Ganymed differ from what you can find in [source:trunk/source/ch/cyberduck/core/sftp/SFTPSession.java SFTPSession]?
    Hard to say, my code is only about 10 lines long. All it does is create a connection, do public key auth then create a client and call put() on that client. Is there anyway I can debug the Java code / Instantiate SFTP Session without too much hassle ? There seems to be a buch of dependencies on preferences and so on.

  8. cyberduck commented on Jan 22, 2010

    @cyberduck
    ContributorAuthor

    @dkocher commented

    Before trying to debug it might also help to look closer at the log. Using defaults in Terminal.app set the logging level of Cyberduck to debug:

    defaults write ch.sudo.cyberduck logging debug
    
  9. cyberduck commented on Jan 22, 2010

    @cyberduck
    ContributorAuthor

    @dkocher commented

    To debug Cyberduck, build it as usual but copy the file Info.plist.debug to build/Release/Cyberduck.app/Contents/Info.plist. You can then attach the Java remote debugger to port 5005`.

  10. cyberduck commented on Jan 28, 2010

    @cyberduck
    ContributorAuthor

    9a8d2c8 commented

    So enabling logging only got me an "Upload failed" trace, but debugging got me a bit further (?).
    The problem seems to happen in SFTPv3Client.java here.
    The code expects a type of SSH_FXP_HANDLE but is getting a value of 101, so SSH_FXP_STATUS. I don't know about the protocol so this doesn't help me. Maybe you have an idea / tip ?
    In the meanwhile I'll try to see how that execution differs from my lightweight test.

  11. cyberduck commented on Jan 28, 2010

    @cyberduck
    ContributorAuthor

    9a8d2c8 commented

    It seems that my test only uses SCPClient and never SFTPv3Client, the latter seems to be a more complex implementation (and experimental according to the javadoc).

  12. cyberduck commented on Jan 28, 2010

    @cyberduck
    ContributorAuthor

    9a8d2c8 commented

    Found the problem! This is it.
    The remote file is created with read/write permissions (0x3), and akamai apparently only allows write. So If I replace that with 0x2 for write-only, I can upload fine.

    My guess is you don't need read-write anyway, if you're creating/truncating a file, why would you read it ?
    Can we incorporate a fix for the next release ? That'd be great.

  13. cyberduck commented on Jan 28, 2010

    @cyberduck
    ContributorAuthor

    @dkocher commented

    Replying to [comment:13 paul167@…]:

    Found the problem! This is it.
    The remote file is created with read/write permissions (0x3), and akamai apparently only allows write. So If I replace that with 0x2 for write-only, I can upload fine.

    My guess is you don't need read-write anyway, if you're creating/truncating a file, why would you read it ?
    Can we incorporate a fix for the next release ? That'd be great.

    I am hesitant to change this as it might break compatiblity with other servers.

  14. cyberduck commented on Jan 28, 2010

    @cyberduck
    ContributorAuthor

    2f05b9c commented

    Any chance we could beta test this? Or find a different way to incorporate this like a bookmark option ?

  15. cyberduck commented on Jul 23, 2010

    @cyberduck
    ContributorAuthor

    @dkocher commented

    In 3b0432f. Please test with the snapshot build available later today at (http://update.cyberduck.ch/nightly/).

  16. cyberduck commented on Jul 25, 2010

    @cyberduck
    ContributorAuthor

    paul167 commented

    Replying to [comment:16 dkocher]:

    In 3b0432f. Please test with the snapshot build available later today at (http://update.cyberduck.ch/nightly/).

    Yep works.

  17. locked as resolved and limited conversation to collaborators on Nov 26, 2021
  18. added theissue type on Sep 2, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

sftpSFTP Protocol Implementation

Type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions