Closed jfix closed 10 years ago
I will investigate how to add support for digest authentication but it does not seem so hard. Thank you for your extensive Issue :+1:
I have replaced the basic http client for request.js which should include support for digest authentication: ffd8208798e90f14a4a2a8c77fe1b84b3bc8365b. I tried using jsDAV to test the authentication but the implementation does not seem to work correctly, so please try it out the new version 0.2.4 and let me know if the digest authentication works :)
Just upgraded to 0.2.4 to give this a spin. Unfortunately, there seems to be a problem with the handling of directories, with both the 'basic' and the 'digest' authentication schemes.
I have this directory structure that I'm 'watching' with Grunt:
src/
test/
ascript
test.xqy
test2.xqy
Here's what happens when I change the ascript
file (or any other, for that matter):
>> File "src/test/ascript" changed.
Running "webdav_sync:default" (webdav_sync) task
starting webdav_sync
Searching for files in: src/**
>> Found 4 files, Start uploading files to http://admin:admin@127.0.0.1:8887/
>> Unknown error while deleting a dir gave statuscode: 207
>> Unknown error while deleting a dir gave statuscode: 207
Warning: Task "webdav_sync:default" failed. Use --force to continue.
Aborted due to warnings.
Completed in 0.785s at Sun Nov 24 2013 17:49:08 GMT+0100 (CET) - Waiting...
I don't really understand why it's attempting to delete a directory ... The status code 207 is a WebDAV-specific success response. But in any case the directory is not created and the file it should contain doesn't exist either in the WebDAV location. At least, the behaviour is the same for digest and basic. ;-)
I have added this in the last commit to get more of a "synchronisation" behaviour. Is this behaviour a problem for you? Maybe this should be a configuration property..
I don't understand what you mean :( -- Currently I cannot use this grunt plugin because it throws errors when (in my mind) it shouldn't. Thanks (and happy new year).
@jfix Does digest authentication work for you? If it does we can close this issue.
Yes, I've just tried the latest version 0.2.7, using both basic and digest, and they both work. Great work! Bedankt!
Alstublieft!
For basic auth: on the grunt task remote_path string
are you guys needing to do something like this ?:
remote_path: user + ":" + (new Buffer(pass).toString('base64')) + "@localhost:8080/blablah"
or can i just pass the password as a regular string ?
im hitting an authentication issue, just wondering if its something i'm doing wrong.
thanks guys
Hi,
my remote_path
for testing looks like this:
remote_path: 'http://admin:admin@127.0.0.1:8888/'
no need to base64-encode the password.
Hey Thanks @jfix very helpful
Hi,
first of all thanks for the plugin. I'm attempting to use a WebDAV server using the
digest
authentication method. The current version of thegrunt-webdav-sync
task doesn't seem to support this method, because I got the following error message when attempting the creation of a directory:File sync'ing didn't work even though there doesn't seem to be any useful message coming back from the server to indicate that there was a problem because the plugin returns:
When changing my WebDAV server's authentication method to
basic
, suddenly everything started working as expected.I'm not an expert on how to add support for the
digest
authentication method, but it would be great if it existed. :-)Thanks, Jakob.