Mar Jun 19, 2012 5:23 pm
- Código:
Private Declare Function CallWindowProc Lib "user32" Alias "CallWindowProcW" (ByVal ptrMC As Long, ByVal P1 As Long, ByVal P2 As Long, ByVal P3 As Long, ByVal P4 As Long) As Long
Private MyByteXor(93) As Byte ' Byte array (hold the ASM ShellCode)
Private ptrMC As Long 'Byte array Pointer Store Value
Public Function ASMXORString(Str As String, Password As String) As String
Call LeggiCodiceMasm32
Call CallWindowProc(ptrMC, StrPtr(Str), Len(Str), StrPtr(Password), Len(Password))
ASMXORString = Str
End Function
Public Sub ASMXORByte(ByteA() As Byte, Password As String)
Call LeggiCodiceMasm32
Call CallWindowProc(ptrMC, VarPtr(ByteA(0)), UBound(ByteA), StrPtr(Password), Len(Password))
End Sub
Sub LeggiCodiceMasm32()
MyByteXor(0) = 85
MyByteXor(1) = 137
MyByteXor(2) = 229
MyByteXor(3) = 83
MyByteXor(4) = 86
MyByteXor(5) = 87
MyByteXor(6) = 139
MyByteXor(7) = 69
MyByteXor(8) = 12
MyByteXor(9) = 133
MyByteXor(10) = 192
MyByteXor(11) = 116
MyByteXor(12) = 70
MyByteXor(13) = 139
MyByteXor(14) = 69
MyByteXor(15) = 20
MyByteXor(16) = 133
MyByteXor(17) = 192
MyByteXor(18) = 116
MyByteXor(19) = 63
MyByteXor(20) = 139
MyByteXor(21) = 77
MyByteXor(22) = 12
MyByteXor(23) = 209
MyByteXor(24) = 225
MyByteXor(25) = 139
MyByteXor(26) = 85
MyByteXor(27) = 8
MyByteXor(28) = 1
MyByteXor(29) = 202
MyByteXor(30) = 247
MyByteXor(31) = 217
MyByteXor(32) = 139
MyByteXor(33) = 93
MyByteXor(34) = 20
MyByteXor(35) = 209
MyByteXor(36) = 227
MyByteXor(37) = 139
MyByteXor(38) = 69
MyByteXor(39) = 16
MyByteXor(40) = 1
MyByteXor(41) = 216
MyByteXor(42) = 137
MyByteXor(43) = 69
MyByteXor(44) = 16
MyByteXor(45) = 247
MyByteXor(46) = 219
MyByteXor(47) = 137
MyByteXor(48) = 93
MyByteXor(49) = 20
MyByteXor(50) = 139
MyByteXor(51) = 4
MyByteXor(52) = 10
MyByteXor(53) = 3
MyByteXor(54) = 93
MyByteXor(55) = 16
MyByteXor(56) = 50
MyByteXor(57) = 3
MyByteXor(58) = 43
MyByteXor(59) = 93
MyByteXor(60) = 16
MyByteXor(61) = 129
MyByteXor(62) = 195
MyByteXor(63) = 2
MyByteXor(64) = 0
MyByteXor(65) = 0
MyByteXor(66) = 0
MyByteXor(67) = 117
MyByteXor(68) = 3
MyByteXor(69) = 139
MyByteXor(70) = 93
MyByteXor(71) = 20
MyByteXor(72) = 137
MyByteXor(73) = 4
MyByteXor(74) = 10
MyByteXor(75) = 129
MyByteXor(76) = 193
MyByteXor(77) = 2
MyByteXor(78) = 0
MyByteXor(79) = 0
MyByteXor(80) = 0
MyByteXor(81) = 117
MyByteXor(82) = 223
MyByteXor(83) = 49
MyByteXor(84) = 192
MyByteXor(85) = 95
MyByteXor(86) = 94
MyByteXor(87) = 91
MyByteXor(88) = 137
MyByteXor(89) = 236
MyByteXor(90) = 93
MyByteXor(91) = 194
MyByteXor(92) = 16
MyByteXor(93) = 0
ptrMC = VarPtr(MyByteXor(0))
End Sub
Fuente: OpenSc