Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Interoperability with nginx #6767

Closed
cyberduck opened this issue Jul 19, 2012 · 17 comments
Closed

Interoperability with nginx #6767

cyberduck opened this issue Jul 19, 2012 · 17 comments
Assignees
Labels
bug webdav WebDAV Protocol Implementation worksforme
Milestone

Comments

@cyberduck
Copy link
Collaborator

84773dc created the issue

Hi, I have an nginx web server to host my webpages, nginx has webdav built-in support so I configured it to upload my www content to my site through webdav, I configured it on https protocol + basic authentication for security. Cyberduck is able to login succesfully, but has erratic behaviour when performing different operations, mainly:

  • It fails to upload files sometimes, both individual files and while part of a folder upload.

If you're interested in improving webdav support with nginx servers I would happily create a user account on my server for you to test.

Regards,

@cyberduck
Copy link
Collaborator Author

@dkocher commented

An account for testing would help to resolve this issue.

@cyberduck
Copy link
Collaborator Author

84773dc commented

Hi, thanks for your quick response, I've made an account in server so you can test, details follows:

Type:   WebDAV (HTTP/SSL)
Server: mdav.dejabit.net
Port:   443
Username: cyber
Password: duck

When you login you will see a welcome.txt file.

Let me know if you have any problems login in, or if you need further nginx debug on the server side..

Regards,

@cyberduck
Copy link
Collaborator Author

@dkocher commented

Replying to [comment:2 nelson]:

I get the following failure which indicates WebDAV is not setup for this virtual host.

PROPFIND / HTTP/1.1
Depth: 1
Content-Type: text/xml; charset=utf-8
Content-Length: 99
Host: mdav.dejabit.net
Connection: Keep-Alive
User-Agent: Cyberduck/4.2.2 (Mac OS X/10.8) (i386)
HTTP/1.1 405 Not Allowed
Server: nginx
Date: Sat, 21 Jul 2012 22:36:31 GMT
Content-Type: text/html
Content-Length: 166
Connection: keep-alive

@cyberduck
Copy link
Collaborator Author

84773dc commented

Hi, when do you get that failure? I can successfully login in with cyberduck..

@cyberduck
Copy link
Collaborator Author

@dkocher commented

I can now successfully connect over HTTPS.

@cyberduck
Copy link
Collaborator Author

@dkocher commented

I finally did some testing uploading a directory with files but couldn't see any issues. What specifically does go wrong?

@cyberduck
Copy link
Collaborator Author

84773dc commented

Hi, indeed I've also tested that uploading files and folders works well, what is still failing for me is the "overwriting files" operation. If I upload a file that already exists the overwrite dialog pops up but when performed the action the file didn't got overwrited and an error dialog pops up, I tried to debug the issue server side and nginx is not writing any error or access log message when the error dialog pops up in cyberduck, which it seems to me as it cyberduck didn't sent that call.

The same problem happens when using "Edit file with.." action to edit a file with a text editor, as when you save in the editor cyberduck tries to upload the file and fails to overwrite.

I hope you can reproduce this issue with the test server I set up.

Thanks!

@cyberduck
Copy link
Collaborator Author

@dkocher commented

Replying to [comment:8 nelson]:

Hi, indeed I've also tested that uploading files and folders works well, what is still failing for me is the "overwriting files" operation. If I upload a file that already exists the overwrite dialog pops up but when performed the action the file didn't got overwrited and an error dialog pops up, I tried to debug the issue server side and nginx is not writing any error or access log message when the error dialog pops up in cyberduck, which it seems to me as it cyberduck didn't sent that call.

The same problem happens when using "Edit file with.." action to edit a file with a text editor, as when you save in the editor cyberduck tries to upload the file and fails to overwrite.

I hope you can reproduce this issue with the test server I set up.

Thanks!

I get a Broken pipe. error which suggests the server is closing the underlying network connection without responding.

@cyberduck
Copy link
Collaborator Author

84773dc commented

Replying to [comment:9 dkocher]:

Replying to [comment:8 nelson]:

I get a Broken pipe. error which suggests the server is closing the underlying network connection without responding.

Yes, that was a segmentation fault in nginx, see http://trac.nginx.org/nginx/ticket/311#comment:1

The segfault is fixed in nginx-1.2.6+ and the dav upload problem real fix in nginx-1.3.9+

Anyway, as distros are only packaging stable nginx versions 1.2.x and the dav upload erratic problem is fixed in 1.3.9, can I ask if cyberduck can provide an option to disable sending the Expect: 100-continue header ? this way nginx stable versions 1.2.x could be used as reliable dav servers becuase handling the Expect: header was causing the issue.

Basically an option to make ServicePointManager.Expect100Continue = false; see these posts for more info:

http://haacked.com/archive/2004/05/15/http-web-request-expect-100-continue.aspx

http://alihamdar.com/2010/06/19/expect-100-continue/

http://msdn.microsoft.com/en-us/library/system.net.servicepoint.expect100continue.aspx

@cyberduck
Copy link
Collaborator Author

@dkocher commented

Replying to [comment:10 nelson]:

Replying to [comment:9 dkocher]:

Replying to [comment:8 nelson]:

I get a Broken pipe. error which suggests the server is closing the underlying network connection without responding.

Yes, that was a segmentation fault in nginx, see http://trac.nginx.org/nginx/ticket/311#comment:1

The segfault is fixed in nginx-1.2.6+ and the dav upload problem real fix in nginx-1.3.9+

Anyway, as distros are only packaging stable nginx versions 1.2.x and the dav upload erratic problem is fixed in 1.3.9, can I ask if cyberduck can provide an option to disable sending the Expect: 100-continue header ? this way nginx stable versions 1.2.x could be used as reliable dav servers becuase handling the Expect: header was causing the issue.

Basically an option to make ServicePointManager.Expect100Continue = false; see these posts for more info:

http://haacked.com/archive/2004/05/15/http-web-request-expect-100-continue.aspx

http://alihamdar.com/2010/06/19/expect-100-continue/

http://msdn.microsoft.com/en-us/library/system.net.servicepoint.expect100continue.aspx

You can use the hidden option

defaults write ch.sudo.cyberduck webdav.expect-continue false

@cyberduck
Copy link
Collaborator Author

84773dc commented

Thanks very much for that!!

Btw where do I write that command? I've search for it and it seems a Mac OS X configuration command, but I'm running Cyberduck on windows and running that command in the windows shell gives me "unrecognized command" error.

Regards,

@cyberduck
Copy link
Collaborator Author

@dkocher commented

Replying to [comment:12 nelson]:

Thanks very much for that!!

Btw where do I write that command? I've search for it and it seems a Mac OS X configuration command, but I'm running Cyberduck on windows and running that command in the windows shell gives me "unrecognized command" error.

Regards,

Please refer to Hidden configuration options.

@cyberduck
Copy link
Collaborator Author

@dkocher commented

Replying to [comment:10 nelson]:

Replying to [comment:9 dkocher]:

Replying to [comment:8 nelson]:

I get a Broken pipe. error which suggests the server is closing the underlying network connection without responding.

Yes, that was a segmentation fault in nginx, see http://trac.nginx.org/nginx/ticket/311#comment:1

Thanks for the reference.

@cyberduck
Copy link
Collaborator Author

84773dc commented

Replying to [comment:13 dkocher]:

Replying to [comment:12 nelson]:

Thanks very much for that!!

Btw where do I write that command? I've search for it and it seems a Mac OS X configuration command, but I'm running Cyberduck on windows and running that command in the windows shell gives me "unrecognized command" error.

Regards,

Please refer to Hidden configuration options.

Thanks for the info! unfortunately it seems Cyberduck is not obeying that config option, I write it as the help says but Cyberduck continues sending Expect header and so nginx failing.

I'm sure I have written it right, see:

<?xml version="1.0" encoding="utf-8"?>
<configuration>
    <userSettings>
        <Ch.Cyberduck.Properties.Settings>
            <setting name="UpgradeSettings" serializeAs="String">
                <value>False</value>
            </setting>
            <setting name="CdSettings" serializeAs="Xml">
                <value>
                    <settings>
                         ...
                         <setting name="webdav.expect-continue" value="false" />
                         <setting name="bookmark.import.com.flashfxp3" value="true" />
                          ... and so on

It seems to me like a bug in Cyberduck windows version reading that config.. :-(

Regards,

@cyberduck
Copy link
Collaborator Author

@dkocher commented

Replying to [comment:15 nelson]:

Replying to [comment:13 dkocher]:

Replying to [comment:12 nelson]:

Thanks very much for that!!

Btw where do I write that command? I've search for it and it seems a Mac OS X configuration command, but I'm running Cyberduck on windows and running that command in the windows shell gives me "unrecognized command" error.

Regards,

Please refer to Hidden configuration options.

Thanks for the info! unfortunately it seems Cyberduck is not obeying that config option, I write it as the help says but Cyberduck continues sending Expect header and so nginx failing.

I'm sure I have written it right, see:

<?xml version="1.0" encoding="utf-8"?>
<configuration>
    <userSettings>
        <Ch.Cyberduck.Properties.Settings>
            <setting name="UpgradeSettings" serializeAs="String">
                <value>False</value>
            </setting>
            <setting name="CdSettings" serializeAs="Xml">
                <value>
                    <settings>
                         ...
                         <setting name="webdav.expect-continue" value="false" />
                         <setting name="bookmark.import.com.flashfxp3" value="true" />
                          ... and so on

It seems to me like a bug in Cyberduck windows version reading that config.. :-(

Regards,

You must use the latest beta build for this setting to work.

@cyberduck
Copy link
Collaborator Author

84773dc commented

Replying to [comment:16 dkocher]:

You must use the latest beta build for this setting to work.

Thanks, indeed I've updated to latest beta 4.2.2(10748) and the webdav.expect-continue works well and I could upload files successfully.

That said, deleting a file causes cyberduck to crash, and I clicked the dialog to send you the crash trace along.

@cyberduck
Copy link
Collaborator Author

84773dc commented

Well, it also crashes just when trying to exit the application in "File -> Exit" menu. I updated through Beta channel from within the application.

@iterate-ch iterate-ch locked as resolved and limited conversation to collaborators Nov 26, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug webdav WebDAV Protocol Implementation worksforme
Projects
None yet
Development

No branches or pull requests

2 participants