From charlesreid1

Line 4: Line 4:


The WebDAV protocol provides a framework for users to create, change and move documents on a server, typically a web server or web share.
The WebDAV protocol provides a framework for users to create, change and move documents on a server, typically a web server or web share.
==Metasploit Modules==
To check for WebDAV, you can use a couple of different modules:
===webdav scanner===


Scan for WebDAV:
Scan for WebDAV:
Line 17: Line 23:


Looks like it is turned off...
Looks like it is turned off...
==webdav internal ip===
we can use another scanner module to check for internal IPs with WebDAV enabled:
<pre>
msf > use auxiliary/scanner/http/webdav_internal_ip
msf auxiliary(webdav_internal_ip) > show options
Module options (auxiliary/scanner/http/webdav_internal_ip):
  Name    Current Setting  Required  Description
  ----    ---------------  --------  -----------
  PATH    /                yes      Path to use
  Proxies                  no        A proxy chain of format type:host:port[,type:host:port][...]
  RHOSTS                    yes      The target address range or CIDR identifier
  RPORT    80              yes      The target port
  THREADS  1                yes      The number of concurrent threads
  VHOST                    no        HTTP server virtual host
msf auxiliary(webdav_internal_ip) > set RHOSTS 10.0.0.27
RHOSTS => 10.0.0.27
msf auxiliary(webdav_internal_ip) > run
[*] Scanned 1 of 1 hosts (100% complete)
[*] Auxiliary module execution completed
msf auxiliary(webdav_internal_ip) >
</pre>
===webdav website content===
Similarly with the next scanner:
<pre>
msf auxiliary(webdav_website_content) > use auxiliary/scanner/http/webdav_website_content
msf auxiliary(webdav_website_content) > show options
Module options (auxiliary/scanner/http/webdav_website_content):
  Name    Current Setting  Required  Description
  ----    ---------------  --------  -----------
  PATH    /                yes      Path to use
  Proxies                  no        A proxy chain of format type:host:port[,type:host:port][...]
  RHOSTS                    yes      The target address range or CIDR identifier
  RPORT    80              yes      The target port
  THREADS  1                yes      The number of concurrent threads
  VHOST                    no        HTTP server virtual host
msf auxiliary(webdav_website_content) > set RHOSTS 10.0.0.27
RHOSTS => 10.0.0.27
msf auxiliary(webdav_website_content) > run
[*] Scanned 1 of 1 hosts (100% complete)
[*] Auxiliary module execution completed
msf auxiliary(webdav_website_content) >
</pre>
If you manage to find a writable directory, you can use it to get a remote shell: http://carnal0wnage.attackresearch.com/2010/05/more-with-metasploit-and-webdav.html


=Flags=
=Flags=


{{MSFlag}}
{{MSFlag}}

Revision as of 05:00, 29 March 2016

What Is It?

WebDAV stands for Web Distributed Authoring and Versioning.

The WebDAV protocol provides a framework for users to create, change and move documents on a server, typically a web server or web share.

Metasploit Modules

To check for WebDAV, you can use a couple of different modules:

webdav scanner

Scan for WebDAV:

msf auxiliary(webdav_scanner) > run

[*] 10.0.0.27 (Apache/2.2.8 (Ubuntu) DAV/2) WebDAV disabled.
[*] Scanned 1 of 1 hosts (100% complete)
[*] Auxiliary module execution completed
msf auxiliary(webdav_scanner) >

Looks like it is turned off...

webdav internal ip=

we can use another scanner module to check for internal IPs with WebDAV enabled:

msf > use auxiliary/scanner/http/webdav_internal_ip
msf auxiliary(webdav_internal_ip) > show options

Module options (auxiliary/scanner/http/webdav_internal_ip):

   Name     Current Setting  Required  Description
   ----     ---------------  --------  -----------
   PATH     /                yes       Path to use
   Proxies                   no        A proxy chain of format type:host:port[,type:host:port][...]
   RHOSTS                    yes       The target address range or CIDR identifier
   RPORT    80               yes       The target port
   THREADS  1                yes       The number of concurrent threads
   VHOST                     no        HTTP server virtual host

msf auxiliary(webdav_internal_ip) > set RHOSTS 10.0.0.27
RHOSTS => 10.0.0.27
msf auxiliary(webdav_internal_ip) > run

[*] Scanned 1 of 1 hosts (100% complete)
[*] Auxiliary module execution completed
msf auxiliary(webdav_internal_ip) >

webdav website content

Similarly with the next scanner:

msf auxiliary(webdav_website_content) > use auxiliary/scanner/http/webdav_website_content
msf auxiliary(webdav_website_content) > show options

Module options (auxiliary/scanner/http/webdav_website_content):

   Name     Current Setting  Required  Description
   ----     ---------------  --------  -----------
   PATH     /                yes       Path to use
   Proxies                   no        A proxy chain of format type:host:port[,type:host:port][...]
   RHOSTS                    yes       The target address range or CIDR identifier
   RPORT    80               yes       The target port
   THREADS  1                yes       The number of concurrent threads
   VHOST                     no        HTTP server virtual host

msf auxiliary(webdav_website_content) > set RHOSTS 10.0.0.27
RHOSTS => 10.0.0.27
msf auxiliary(webdav_website_content) > run

[*] Scanned 1 of 1 hosts (100% complete)
[*] Auxiliary module execution completed
msf auxiliary(webdav_website_content) >

If you manage to find a writable directory, you can use it to get a remote shell: http://carnal0wnage.attackresearch.com/2010/05/more-with-metasploit-and-webdav.html

Flags