Uploads when using as WebDav

920 views
Skip to first unread message

neilc

unread,
Jan 3, 2013, 11:10:06 AM1/3/13
to mongoos...@googlegroups.com
Hi,
 
I have installed Mongoose as a WebDav server, and it seems to work fine when there is content to view in the server... but whenever i try and create a new directory or upload a file to the WebDav server, it fails.
 
I am using CarotDav as my client, and here is the exact error:
 
Rei.Fs.SimpleWebException: The remote server returned an error: (400) Bad Request.
   at Rei.Fs.Webdav.WebdavFs.GetResponse(HttpWebRequest request, Boolean notreqstream)
   at Rei.Fs.Webdav.WebdavFs.CreateCollection(ResourceId parendid, String name)
   at CarotDAV.CacheManager.CreateCollection(FsBase fs, ResourceId parentid, String name)
   at CarotDAV.MainForm.Fs_CreateCollection(ResourceId parentid, String name)
 
 
 
This is my Mongoose.conf config file:
# cgi_pattern **.cgi$|**.pl$|**.php$
# cgi_environment <value>
put_delete_passwords_file priv.txt
# cgi_interpreter <value>
# protect_uri passwords.txt
authentication_domain localhost
# ssi_pattern **.shtml$|**.shtm$
# throttle <value>
access_log_file access.log
# enable_directory_listing yes
error_log_file error.log
global_passwords_file passwords.txt
# index_files index.html,index.htm,index.cgi,index.shtml,index.php
# enable_keep_alive no
# access_control_list <value>
# extra_mime_types <value>
listening_ports 443s
document_root httproot
ssl_certificate cert.pem
# num_threads 20
# run_as_user <value>
# url_rewrite_patterns <value>
# hide_files_patterns <value>
 
What have i done wrong ??
 
N
 

Sergey Lyubka

unread,
Jan 3, 2013, 1:19:19 PM1/3/13
to mongoos...@googlegroups.com
Could you show full request, including headers, sent by the client, please?

 
N
 

--
You received this message because you are subscribed to the Google Groups "mongoose-users" group.
To view this discussion on the web visit https://groups.google.com/d/msg/mongoose-users/-/e6vwmb_EHA8J.
To post to this group, send email to mongoos...@googlegroups.com.
To unsubscribe from this group, send email to mongoose-user...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/mongoose-users?hl=en.

neilc

unread,
Jan 3, 2013, 9:02:39 PM1/3/13
to mongoos...@googlegroups.com
I am not sure how to do that (can you advise?).. here is some more detail from the client side.
 
Request To xxx.xxx.xxx.xxx
> MKCOL /test/ HTTP/1.1
> User-Agent: Rei.Fs.WebDAV1.9.8
AuthorizationMethod = Digest
System.Net.WebException: The remote server returned an error: (400) Bad Request.
   at System.Net.HttpWebRequest.EndGetResponse(IAsyncResult asyncResult)

   at Rei.Fs.Webdav.WebdavFs.GetResponse(HttpWebRequest request, Boolean notreqstream)
<HTTP/1.1 400 Bad Request
< Connection: close
< Content-Length: 57

Rei.Fs.SimpleWebException: The remote server returned an error: (400) Bad Request.
   at Rei.Fs.Webdav.WebdavFs.GetResponse(HttpWebRequest request, Boolean notreqstream)
   at Rei.Fs.Webdav.WebdavFs.CreateCollection(ResourceId parendid, String name)
   at CarotDAV.CacheManager.CreateCollection(FsBase fs, ResourceId parentid, String name)
   at CarotDAV.MainForm.Fs_CreateCollection(ResourceId parentid, String name)
 
 
 
 
and them from the server side, here is the access log file from Mongoose:
7.50.19.10 - - [04/Jan/2013:09:00:04 SE Asia Standard Time] "PROPFIND / HTTP/1.1" 401 0 - "Rei.Fs.WebDAV1.9.8"
27.50.19.10 - - [04/Jan/2013:09:00:07 SE Asia Standard Time] "PROPFIND / HTTP/1.1" 401 0 - "Rei.Fs.WebDAV1.9.8"
27.50.19.10 - - [04/Jan/2013:09:00:08 SE Asia Standard Time] "PROPFIND / HTTP/1.1" 401 0 - "Rei.Fs.WebDAV1.9.8"
27.50.19.10 - neilc [04/Jan/2013:09:00:08 SE Asia Standard Time] "PROPFIND / HTTP/1.1" 207 653 - "Rei.Fs.WebDAV1.9.8"
27.50.19.10 - neilc [04/Jan/2013:09:00:09 SE Asia Standard Time] "GET /favicon.ico HTTP/1.1" 404 35 - "Rei.Fs.WebDAV1.9.8"
 
 
Note that whilst i have defined an error log, there is nothing being generated in it.
 
N

Sergey Lyubka

unread,
Jan 4, 2013, 12:25:27 AM1/4/13
to mongoos...@googlegroups.com
On Fri, Jan 4, 2013 at 2:02 AM, neilc <neil.cr...@indonesiancloud.com> wrote:
I am not sure how to do that (can you advise?).. here is some more detail from the client side.
 
Request To xxx.xxx.xxx.xxx
> MKCOL /test/ HTTP/1.1

It looks like this is the problem. Method "MKCOL" is not understood by mongoose.
To get the request printed, I usually use netcat utility, "nc". You have to be on Mac or UNIX to do that.
In one terminal, start netcat: "nl -l 8080"
In other terminal, run your client: "curl http://127.0.0.1:8080/index.html"

Sometimes client has the capability to print out it's own request. Curl can do it: "curl --trace /dev/stdout http://...."

 
To view this discussion on the web visit https://groups.google.com/d/msg/mongoose-users/-/FVx6Jkfiwj4J.

lucky...@gmail.com

unread,
Jan 25, 2014, 8:30:12 AM1/25/14
to mongoos...@googlegroups.com
hi,I want to know how to install Mongoose as a WebDav server.Please tell me ,think you very much!
my email:      lucky...@gmail.com

在 2013年1月4日星期五UTC+8上午12时10分06秒,neilc写道:
Reply all
Reply to author
Forward
0 new messages