joyce8/EMBER2024-capa huggingface dataset:
Function at 0x489f70
Capabilities:
Compute adler32 checksum

Disassembly:
push ebx
push esi
push edi
mov edi, edx
mov esi, ecx
movzx ecx, di
shr edi, 0x10
test esi, esi
mov ebx, eax
jne 0x489f8a
pop edi
lea eax, [esi + 1]
pop esi
pop ebx
ret
test ebx, ebx
jbe 0x48a08c
push ebp
cmp ebx, 0x15b0
mov eax, ebx
jb 0x489fa2
mov eax, 0x15b0
sub ebx, eax
cmp eax, 0x10
jl 0x48a04b
mov edx, eax
shr edx, 4
mov ebp, edx
neg ebp
shl ebp, 4
add eax, ebp
jmp 0x489fc0
movzx ebp, byte [esi]
add ecx, ebp
movzx ebp, byte [esi + 1]
add edi, ecx
add ecx, ebp
movzx ebp, byte [esi + 2]
add edi, ecx
add ecx, ebp
movzx ebp, byte [esi + 3]
add edi, ecx
add ecx, ebp
movzx ebp, byte [esi + 4]
add edi, ecx
add ecx, ebp
movzx ebp, byte [esi + 5]
add edi, ecx
add ecx, ebp
movzx ebp, byte [esi + 6]
add edi, ecx
add ecx, ebp
movzx ebp, byte [esi + 7]
add edi, ecx
add ecx, ebp
movzx ebp, byte [esi + 8]
add edi, ecx
add ecx, ebp
movzx ebp, byte [esi + 9]
add edi, ecx
add ecx, ebp
movzx ebp, byte [esi + 0xa]
add edi, ecx
add ecx, ebp
movzx ebp, byte [esi + 0xb]
add edi, ecx
add ecx, ebp
movzx ebp, byte [esi + 0xc]
add edi, ecx
add ecx, ebp
movzx ebp, byte [esi + 0xd]
add edi, ecx
add ecx, ebp
movzx ebp, byte [esi + 0xe]
add edi, ecx
add ecx, ebp
movzx ebp, byte [esi + 0xf]
add edi, ecx
add ecx, ebp
add edi, ecx
add esi, 0x10
sub edx, 1
jne 0x489fc0
test eax, eax
je 0x48a05f
nop
movzx edx, byte [esi]
add ecx, edx
add esi, 1
add edi, ecx
sub eax, 1
jne 0x48a050
mov eax, 0x80078071
mul ecx
shr edx, 0xf
imul edx, edx, 0xffff000f
add ecx, edx
mov eax, 0x80078071
mul edi
shr edx, 0xf
imul edx, edx, 0xffff000f
add edi, edx
test ebx, ebx
ja 0x489f93
pop ebp
mov eax, edi
pop edi
shl eax, 0x10
pop esi
or eax, ecx
pop ebx
ret

Function at 0x48a560
Capabilities:
Hash data with crc32

Disassembly:
test ecx, ecx
jne 0x48a567
xor eax, eax
ret
mov eax, dword [esp + 4]
jmp fcn.0048a570
Function at 0x48a570
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
push esi
mov esi, edx
test esi, esi
not eax
je 0x48a5a2
lea esp, [esp]
test cl, 3
je 0x48a5a2
movzx edx, byte [ecx]
xor edx, eax
and edx, 0xff
shr eax, 8
xor eax, dword [edx*4 + 0x5d1bd8]
add ecx, 1
sub esi, 1
jne 0x48a580
cmp esi, 0x20
push ebx
push edi
jb 0x48a78c
mov edi, esi
shr edi, 5
xor eax, dword [ecx]
add ecx, 4
mov edx, eax
shr edx, 0x10
movzx ebx, ah
and edx, 0xff
mov edx, dword [edx*4 + 0x5d1fd8]
xor edx, dword [ebx*4 + 0x5d23d8]
mov ebx, eax
and eax, 0xff
shr ebx, 0x18
xor edx, dword [ebx*4 + 0x5d1bd8]
add ecx, 4
xor edx, dword [eax*4 + 0x5d27d8]
add ecx, 4
xor edx, dword [ecx - 8]
add ecx, 4
mov eax, edx
shr eax, 0x10
and eax, 0xff
mov eax, dword [eax*4 + 0x5d1fd8]
movzx ebx, dh
xor eax, dword [ebx*4 + 0x5d23d8]
mov ebx, edx
and edx, 0xff
shr ebx, 0x18
xor eax, dword [ebx*4 + 0x5d1bd8]
add ecx, 4
xor eax, dword [edx*4 + 0x5d27d8]
add ecx, 4
xor eax, dword [ecx - 0x10]
mov edx, eax
shr edx, 0x10
movzx ebx, ah
and edx, 0xff
mov edx, dword [edx*4 + 0x5d1fd8]
xor edx, dword [ebx*4 + 0x5d23d8]
mov ebx, eax
and eax, 0xff
shr ebx, 0x18
xor edx, dword [ebx*4 + 0x5d1bd8]
xor edx, dword [eax*4 + 0x5d27d8]
xor edx, dword [ecx - 0xc]
mov eax, edx
shr eax, 0x10
and eax, 0xff
mov eax, dword [eax*4 + 0x5d1fd8]
movzx ebx, dh
xor eax, dword [ebx*4 + 0x5d23d8]
mov ebx, edx
and edx, 0xff
shr ebx, 0x18
xor eax, dword [ebx*4 + 0x5d1bd8]
xor eax, dword [edx*4 + 0x5d27d8]
xor eax, dword [ecx - 8]
mov edx, eax
shr edx, 0x10
movzx ebx, ah
and edx, 0xff
mov edx, dword [edx*4 + 0x5d1fd8]
xor edx, dword [ebx*4 + 0x5d23d8]
mov ebx, eax
and eax, 0xff
shr ebx, 0x18
xor edx, dword [ebx*4 + 0x5d1bd8]
xor edx, dword [eax*4 + 0x5d27d8]
xor edx, dword [ecx - 4]
mov eax, edx
shr eax, 0x10
and eax, 0xff
mov eax, dword [eax*4 + 0x5d1fd8]
movzx ebx, dh
xor eax, dword [ebx*4 + 0x5d23d8]
mov ebx, edx
shr ebx, 0x18
xor eax, dword [ebx*4 + 0x5d1bd8]
and edx, 0xff
xor eax, dword [edx*4 + 0x5d27d8]
xor eax, dword [ecx]
add ecx, 4
mov edx, eax
shr edx, 0x10
movzx ebx, ah
and edx, 0xff
mov edx, dword [edx*4 + 0x5d1fd8]
xor edx, dword [ebx*4 + 0x5d23d8]
mov ebx, eax
and eax, 0xff
shr ebx, 0x18
xor edx, dword [ebx*4 + 0x5d1bd8]
add ecx, 4
xor edx, dword [eax*4 + 0x5d27d8]
sub esi, 0x20
xor edx, dword [ecx - 4]
mov eax, edx
shr eax, 0x10
and eax, 0xff
mov eax, dword [eax*4 + 0x5d1fd8]
movzx ebx, dh
xor eax, dword [ebx*4 + 0x5d23d8]
mov ebx, edx
shr ebx, 0x18
xor eax, dword [ebx*4 + 0x5d1bd8]
and edx, 0xff
xor eax, dword [edx*4 + 0x5d27d8]
sub edi, 1
jne 0x48a5b2
cmp esi, 4
jb 0x48a7d9
mov edx, esi
shr edx, 2
xor eax, dword [ecx]
add ecx, 4
mov edi, eax
shr edi, 0x10
and edi, 0xff
mov edi, dword [edi*4 + 0x5d1fd8]
movzx ebx, ah
xor edi, dword [ebx*4 + 0x5d23d8]
mov ebx, eax
shr ebx, 0x18
xor edi, dword [ebx*4 + 0x5d1bd8]
and eax, 0xff
xor edi, dword [eax*4 + 0x5d27d8]
sub esi, 4
sub edx, 1
mov eax, edi
jne 0x48a796
test esi, esi
pop edi
pop ebx
je 0x48a7fd
nop
movzx edx, byte [ecx]
xor edx, eax
and edx, 0xff
shr eax, 8
xor eax, dword [edx*4 + 0x5d1bd8]
add ecx, 1
sub esi, 1
jne 0x48a7e0
not eax
pop esi
ret
Function at 0x48aee8
Capabilities:
Check os version

Disassembly:
push ebp
lea ebp, [esp - 0x78]
sub esp, 0x98
mov eax, dword [0x5f30a8]
xor eax, ebp
mov dword [ebp + 0x74], eax
push esi
mov esi, ecx
call fcn.0048ae27
mov eax, 0x400000
push 0x94
mov dword [esi + 8], eax
mov dword [esi + 4], eax
lea eax, [ebp - 0x20]
push 0
push eax
mov dword [esi], 0x3c
mov byte [esi + 0xc], 0
call sub.MSVCR80.dll_memset
add esp, 0xc
lea eax, [ebp - 0x20]
push eax
mov dword [ebp - 0x20], 0x94
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
cmp dword [ebp - 0x10], 2
jne 0x48af37
cmp dword [ebp - 0x1c], 5
jb 0x48af4f
jmp 0x48af4b
cmp dword [ebp - 0x10], 1
jne 0x48af4f
cmp dword [ebp - 0x1c], 4
ja 0x48af4b
jne 0x48af4f
cmp dword [ebp - 0x18], 0
jbe 0x48af4f
mov byte [esi + 0xc], 1
lea ecx, [esi + 0x18]
mov dword [esi + 0x10], 0x800
mov dword [esi + 0x14], 0x593f8c
call fcn.0042bed0
test eax, eax
jge 0x48af70
mov byte [0x601008], 1
mov ecx, dword [ebp + 0x74]
mov eax, esi
xor ecx, ebp
pop esi
call fcn.004a1f8d
add ebp, 0x78
leave
ret

Function at 0x48b3da
Capabilities:
Allocate or change rwx memory
Execute shellcode via indirect call

Disassembly:
cmp dword [0x5febe0], 0
push esi
jne 0x48b34d
call fcn.0048b278
test eax, eax
je 0x48b390
mov eax, dword [0x5febe0]
cmp eax, 1
jne 0x48b36e
push 0xd
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
test eax, eax
je 0x48b390
pop esi
ret
push eax
call dword [0x5febe8]
test eax, eax
jne 0x48b3d8
push 0x40
mov eax, 0x1000
push eax
push eax
push 0
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov esi, eax
test esi, esi
jne 0x48b394
xor eax, eax
pop esi
ret
mov eax, dword [esi]
push edi
push dword [0x5febe0]
call dword [0x5febe8]
mov edi, eax
test edi, edi
je 0x48b3bb
push 0x8000
push 0
push esi
call dword [sym.imp.KERNEL32.dll_VirtualFree]
mov eax, edi
jmp 0x48b3d7
lea edi, [esi + 0xff0]
push esi
push dword [0x5febe0]
call dword [0x5febe4]
add esi, 0x10
cmp esi, edi
jb 0x48b3c1
mov eax, esi
pop edi
pop esi
ret
jmp 0x48b33a

Function at 0x48c399
Capabilities:
Initialize winsock library

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x194
mov eax, dword [0x5f30a8]
xor eax, ebp
mov dword [ebp - 4], eax
lea eax, [ebp - 0x194]
push eax
push 0x202
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
jne 0x48c3da
cmp byte [ebp - 0x194], 2
jne 0x48c3d4
cmp byte [ebp - 0x193], 2
je 0x48c3dd
call dword [sym.imp.WS2_32.dll_WSACleanup]
push 2
pop eax
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004a1f8d
leave
ret

Function at 0x49466b
Capabilities:
Receive data
Receive data on socket

Disassembly:
push 0
push dword [esp + 0x10]
push dword [esp + 0x10]
push dword [esp + 0x10]
call dword [sym.imp.WS2_32.dll_recv]
cmp eax, 0xffffffff
jne 0x49469a
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
sub eax, 0x2733
neg eax
sbb eax, eax
and eax, 0xffffffe7
add eax, 0x51
ret
mov ecx, dword [esp + 0x10]
mov dword [ecx], eax
xor eax, eax
ret
Function at 0x4947bb
Capabilities:
Write file on windows

Disassembly:
mov ecx, dword [esi + 0x164]
test ecx, ecx
je 0x4947db
push dword [esi + 0xf4]
push dword [esp + 0xc]
push dword [esp + 0xc]
push eax
push esi
call ecx
add esp, 0x14
ret
test eax, eax
jl 0x494816
cmp eax, 2
jg 0x494816
imul eax, eax, 3
push edi
push dword [esi + 0xf0]
mov edi, dword [sym.imp.MSVCR80.dll_fwrite]
push 1
add eax, 0x594dd0
push 2
push eax
call edi
push dword [esi + 0xf0]
push 1
push dword [esp + 0x24]
push dword [esp + 0x24]
call edi
add esp, 0x20
pop edi
xor eax, eax
ret

Function at 0x4949dc
Capabilities:
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 0xc]
push esi
mov esi, dword [ebp + 8]
mov eax, dword [esi + eax*4 + 0x12c]
push edi
push 0
push dword [ebp + 0x14]
push dword [ebp + 0x10]
push eax
call dword [sym.imp.WS2_32.dll_send]
mov edi, dword [ebp + 0x18]
and dword [edi], 0
cmp eax, 0xffffffff
mov dword [ebp + 8], eax
jne 0x494a4e
push ebx
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ebx, eax
cmp ebx, 0x2733
jne 0x494a28
and dword [ebp + 8], 0
mov dword [edi], 0x51
jmp 0x494a4d
push ebx
push esi
call fcn.004a096a
push eax
push str.Send_failure:__s
push dword [esi]
call fcn.00494948
mov eax, dword [esi]
mov dword [eax + 0x855c], ebx
add esp, 0x14
mov dword [edi], 0x37
pop ebx
mov eax, dword [ebp + 8]
pop edi
pop esi
pop ebp
ret
Function at 0x4950fd
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
push ebp
lea ebp, [esp - 0x90]
sub esp, 0x110
mov eax, dword [0x5f30a8]
xor eax, ebp
mov dword [ebp + 0x8c], eax
push ebx
push esi
mov esi, dword [ebp + 0x98]
cmp dword [esi + 0x1b8], 0
mov ebx, dword [esi]
push edi
mov dword [ebp - 0x78], esi
mov dword [ebp - 0x80], ebx
jne 0x49521a
lea eax, [ebp - 0x7c]
push eax
lea eax, [ebp - 0x74]
push eax
push dword [ebp + 0x9c]
mov edi, 0x80
mov dword [ebp - 0x7c], edi
call dword [sym.imp.WS2_32.dll_getpeername]
test eax, eax
je 0x49517a
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov edi, eax
push edi
push esi
call fcn.004a096a
push eax
push edi
push str.getpeername___failed_with_errno__d:__s
push ebx
call fcn.00494948
add esp, 0x18
jmp 0x495221
lea eax, [ebp - 0x7c]
push eax
lea eax, [ebp + 0xc]
push eax
push dword [ebp + 0x9c]
mov dword [ebp - 0x7c], edi
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
je 0x4951ad
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov edi, eax
push edi
push esi
call fcn.004a096a
push eax
push edi
push str.getsockname___failed_with_errno__d:__s
jmp 0x49516c
lea edi, [esi + 0xc8]
lea ebx, [esi + 0x9a]
lea esi, [ebp - 0x74]
call fcn.004950c4
test eax, eax
jne 0x4951e2
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
push esi
push dword [ebp - 0x78]
call fcn.004a096a
push eax
push esi
push str.ssrem_inet_ntop___failed_with_errno__d:__s
push dword [ebp - 0x80]
jmp 0x49516d
mov eax, dword [ebp - 0x78]
lea edi, [eax + 0xfc]
lea ebx, [eax + 0xcc]
lea esi, [ebp + 0xc]
call fcn.004950c4
test eax, eax
jne 0x495217
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
push esi
push dword [ebp - 0x78]
call fcn.004a096a
push eax
push esi
push str.ssloc_inet_ntop___failed_with_errno__d:__s
jmp 0x4951dd
mov esi, dword [ebp - 0x78]
push esi
call fcn.00495075
pop ecx
mov ecx, dword [ebp + 0x8c]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004a1f8d
add ebp, 0x90
leave
ret

Function at 0x495239
Capabilities:
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
mov esi, dword [edi]
mov eax, dword [esi + 0x308]
push 4
mov dword [ebp - 4], eax
lea eax, [ebp - 4]
push eax
push 1
push 6
push dword [ebp + 8]
call dword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jge 0x49527e
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push edi
call fcn.004a096a
push eax
push str.Could_not_set_TCP_NODELAY:__s_n
push esi
call fcn.004948d5
add esp, 0x14
jmp 0x49528b
push str.TCP_NODELAY_set_n
push esi
call fcn.004948d5
pop ecx
pop ecx
pop esi
leave
ret
Function at 0x4956e2
Capabilities:
Receive data
Receive data on socket

Disassembly:
push ebp
mov ebp, esp
mov ecx, dword [ebp + 8]
mov eax, dword [ecx + 0x520]
cmp eax, 0xffffffff
push esi
je 0x495729
mov ecx, dword [ecx + 0x514]
mov ecx, dword [ecx]
lea eax, [ecx + eax*4]
cmp dword [eax], 0
je 0x495729
mov ecx, dword [ebp + 0xc]
test ecx, ecx
mov eax, dword [eax]
je 0x49570f
mov dword [ecx], eax
cmp dword [eax + 0x144], 0
mov esi, dword [eax + 0x12c]
je 0x49572f
push eax
call fcn.0048cab9
pop ecx
test eax, eax
jne 0x495740
or eax, 0xffffffff
pop esi
pop ebp
ret
push 2
push 1
lea eax, [ebp + 0xb]
push eax
push esi
call dword [sym.imp.WS2_32.dll_recv]
jmp 0x495725
mov eax, esi
jmp 0x49572c

Function at 0x495744
Capabilities:
Parse pe header

Disassembly:
movsx eax, byte [esp + 4]
add eax, 0xffffff9f
cmp eax, 0x19
ja case.default.0x495751
jmp dword [eax*4 + 0x4957ac]
mov al, 0x41
ret
mov al, 0x42
ret
mov al, 0x43
ret
mov al, 0x44
ret
mov al, 0x45
ret
mov al, 0x46
ret
mov al, 0x47
ret
mov al, 0x48
ret
mov al, 0x49
ret
mov al, 0x4a
ret
mov al, 0x4b
ret
mov al, 0x4c
ret
mov al, 0x4d
ret
mov al, 0x4e
ret
mov al, 0x4f
ret
mov al, 0x50
ret
mov al, 0x51
ret
mov al, 0x52
ret
mov al, 0x53
ret
mov al, 0x54
ret
mov al, 0x55
ret
mov al, 0x56
ret
mov al, 0x57
ret
mov al, 0x58
ret
mov al, 0x59
ret
mov al, 0x5a
ret
mov al, byte [esp + 4]
ret
Function at 0x499a0f
Capabilities:
Resolve dns

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
mov eax, dword [ebp + 0x14]
and dword [eax], 0
and dword [ebp - 4], 0
and dword [ebp - 0x14], 0
lea eax, [ebp - 0x10]
push eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.WS2_32.dll_getaddrinfo]
test eax, eax
mov dword [ebp - 8], eax
jne 0x499b81
push esi
mov esi, dword [ebp - 0x10]
test esi, esi
mov dword [ebp - 0xc], esi
je 0x499b66
push ebx
push edi
jmp 0x499a57
mov esi, dword [ebp - 0xc]
cmp dword [esi + 4], 2
jne 0x499afa
cmp dword [esi + 0x18], 0
je 0x499afa
mov eax, dword [esi + 0x10]
test eax, eax
jbe 0x499afa
push 0x10
pop edi
cmp eax, edi
jb 0x499afa
push 0x20
call dword [0x5f306c]
mov ebx, eax
xor eax, eax
cmp ebx, eax
pop ecx
je 0x499b0a
mov ecx, dword [esi]
mov dword [ebx], ecx
mov ecx, dword [esi + 4]
mov dword [ebx + 4], ecx
mov ecx, dword [esi + 8]
mov dword [ebx + 8], ecx
mov ecx, dword [esi + 0xc]
push edi
mov dword [ebx + 0xc], ecx
mov dword [ebx + 0x10], edi
mov dword [ebx + 0x18], eax
mov dword [ebx + 0x14], eax
mov dword [ebx + 0x1c], eax
call dword [0x5f306c]
test eax, eax
pop ecx
mov dword [ebx + 0x18], eax
je 0x499b13
mov esi, dword [esi + 0x18]
mov edi, eax
mov eax, dword [ebp - 0xc]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
mov eax, dword [eax + 0x14]
test eax, eax
je 0x499ae1
push eax
call dword [0x5f3078]
test eax, eax
pop ecx
mov dword [ebx + 0x14], eax
je 0x499b23
cmp dword [ebp - 4], 0
jne 0x499aea
mov dword [ebp - 4], ebx
mov eax, dword [ebp - 0x14]
test eax, eax
je 0x499af4
mov dword [eax + 0x1c], ebx
mov esi, dword [ebp - 0xc]
mov dword [ebp - 0x14], ebx
mov esi, dword [esi + 0x1c]
test esi, esi
mov dword [ebp - 0xc], esi
jne 0x499a54
jmp 0x499b3c
mov dword [ebp - 8], 8
jmp 0x499b3c
push ebx
mov dword [ebp - 8], 8
call dword [0x5f3070]
jmp 0x499b3b
push dword [ebx + 0x18]
mov dword [ebp - 8], 8
call dword [0x5f3070]
push ebx
call dword [0x5f3070]
pop ecx
pop ecx
xor esi, esi
cmp dword [ebp - 0x10], esi
pop edi
pop ebx
je 0x499b4e
push dword [ebp - 0x10]
call dword [sym.imp.WS2_32.dll_freeaddrinfo]
cmp dword [ebp - 8], esi
je 0x499b61
push dword [ebp - 4]
call fcn.004999d3
pop ecx
mov dword [ebp - 4], esi
jmp 0x499b75
cmp dword [ebp - 4], esi
jne 0x499b75
mov eax, 0x2af9
push eax
mov dword [ebp - 8], eax
call dword [sym.imp.WS2_32.dll_WSASetLastError]
mov eax, dword [ebp - 4]
mov ecx, dword [ebp + 0x14]
mov dword [ecx], eax
mov eax, dword [ebp - 8]
pop esi
leave
ret
Function at 0x499ed3
Capabilities:
Create udp socket

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
push edi
push 0x48
push 1
mov ebx, eax
mov edi, ecx
call dword [0x5f307c]
mov esi, eax
xor eax, eax
cmp esi, eax
pop ecx
pop ecx
mov dword [ebp - 4], 0xc
mov dword [edi + 0x3cc], esi
je 0x499f86
mov dword [edi + 0x3c4], eax
mov dword [edi + 0x3c8], eax
mov dword [edi + 0x3c0], eax
mov dword [edi + 0x3bc], ebx
or dword [esi + 4], 0xffffffff
push ebx
push dword [ebp + 8]
mov dword [esi], eax
lea eax, [esi + 0x10]
call fcn.00499d8f
test eax, eax
pop ecx
pop ecx
je 0x499f86
lea ebx, [edi + 0x3b8]
push dword [ebx]
call fcn.0048cf43
push dword [ebp + 8]
call dword [0x5f3078]
test eax, eax
pop ecx
pop ecx
mov dword [ebx], eax
je 0x499f86
push 0
push 2
push 2
call dword [sym.imp.WS2_32.dll_socket]
cmp eax, 0xffffffff
mov dword [esi + 4], eax
je 0x499f86
lea eax, [esi + 0x10]
push eax
push 0x499e03
call fcn.004a119d
test eax, eax
pop ecx
pop ecx
mov dword [esi], eax
jne 0x499fa0
call dword [sym.imp.MSVCR80.dll__errno]
mov eax, dword [eax]
mov dword [ebp - 4], eax
add edi, 0x3b8
push edi
call fcn.00499e81
pop ecx
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
jmp 0x499fa3
xor eax, eax
inc eax
pop edi
pop esi
pop ebx
leave
ret
Function at 0x49da77
Capabilities:
Check for time delay via gettickcount
Get socket status

Disassembly:
push ebp
lea ebp, [esp - 0x6c]
sub esp, 0x31c
push ebx
mov ebx, dword [ebp + 0x78]
push esi
mov esi, dword [ebp + 0x74]
xor edx, edx
push edi
xor edi, edi
cmp esi, 0xffffffff
mov dword [ebp + 0x64], edx
mov dword [ebp + 0x68], edx
jne 0x49daab
cmp ebx, esi
jne 0x49daab
mov eax, dword [ebp + 0x7c]
call fcn.0049da58
jmp 0x49dc48
cmp dword [ebp + 0x7c], edx
jle 0x49dac0
mov edi, dword [ebp + 0x7c]
call fcn.0049f03f
mov dword [ebp + 0x68], edx
mov dword [ebp + 0x64], eax
xor edx, edx
xor eax, eax
or ecx, 0xffffffff
inc eax
cmp esi, ecx
mov dword [ebp - 0xa8], edx
mov dword [ebp - 0x1ac], edx
je 0x49daf0
mov dword [ebp - 0x1a8], esi
mov dword [ebp - 0x1ac], eax
mov dword [ebp - 0xa4], esi
mov dword [ebp - 0xa8], eax
mov ecx, esi
cmp ebx, 0xffffffff
mov dword [ebp - 0x2b0], edx
je 0x49db47
mov dword [ebp - 0x2b0], eax
xor eax, eax
cmp dword [ebp - 0xa8], edx
mov dword [ebp - 0x2ac], ebx
jbe 0x49db23
cmp dword [ebp + eax*4 - 0xa4], ebx
je 0x49db23
inc eax
cmp eax, dword [ebp - 0xa8]
jb 0x49db11
cmp eax, dword [ebp - 0xa8]
jne 0x49db41
cmp dword [ebp - 0xa8], 0x40
jae 0x49db41
mov dword [ebp + eax*4 - 0xa4], ebx
inc dword [ebp - 0xa8]
cmp ebx, ecx
jbe 0x49db47
mov ecx, ebx
cmp dword [ebp + 0x7c], edx
jge 0x49db50
xor ebx, ebx
jmp 0x49db53
lea ebx, [ebp + 0x5c]
lea esi, [ecx + 1]
xor eax, eax
cmp dword [ebp + 0x7c], eax
jle 0x49db72
mov eax, edi
cdq
mov ecx, 0x3e8
idiv ecx
imul edx, edx, 0x3e8
mov dword [ebp + 0x60], edx
jmp 0x49db77
jne 0x49db7a
mov dword [ebp + 0x60], eax
mov dword [ebp + 0x5c], eax
push ebx
lea eax, [ebp - 0xa8]
push eax
lea eax, [ebp - 0x2b0]
push eax
lea eax, [ebp - 0x1ac]
push eax
push esi
call dword [sym.imp.WS2_32.dll_select]
cmp eax, 0xffffffff
jne 0x49dbd3
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
test eax, eax
je 0x49dbad
cmp eax, 0x2714
jne 0x49dbd7
cmp dword [ebp + 0x7c], 0
jle 0x49db56
push dword [ebp + 0x68]
push dword [ebp + 0x64]
call fcn.0049f03f
push edx
push eax
call fcn.0049f055
mov edi, dword [ebp + 0x7c]
sub edi, eax
add esp, 0x10
test edi, edi
jg 0x49db56
jmp 0x49dbd7
test eax, eax
jge 0x49dbdc
or eax, 0xffffffff
jmp 0x49dc48
jne 0x49dbe2
xor eax, eax
jmp 0x49dc48
xor esi, esi
cmp dword [ebp + 0x74], 0xffffffff
je 0x49dc14
lea eax, [ebp - 0x1ac]
push eax
push dword [ebp + 0x74]
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x49dbfe
inc esi
lea eax, [ebp - 0xa8]
push eax
push dword [ebp + 0x74]
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x49dc14
or esi, 4
cmp dword [ebp + 0x78], 0xffffffff
je 0x49dc46
lea eax, [ebp - 0x2b0]
push eax
push dword [ebp + 0x78]
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x49dc30
or esi, 2
lea eax, [ebp - 0xa8]
push eax
push dword [ebp + 0x78]
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x49dc46
or esi, 4
mov eax, esi
pop edi
pop esi
pop ebx
add ebp, 0x6c
leave
ret

Function at 0x4a119d
Capabilities:
Create thread

Disassembly:
push 0
push 0
push dword [esp + 0x10]
push dword [esp + 0x10]
push 0
push 0
call dword [sym.imp.MSVCR80.dll__beginthreadex]
add esp, 0x18
test eax, eax
je 0x4a11bf
cmp eax, 0xffffffff
jne 0x4a11c1
xor eax, eax
ret
Function at 0x4a1678
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [esi]
push ebx
xor ebx, ebx
cmp dword [eax + 4], 2
push edi
sete bl
test ebx, ebx
je 0x4a169c
push dword [eax + 8]
push dword [ebp + 0xc]
push 1
push dword [ebp + 8]
call dword [esi + 0xc]
jmp 0x4a16cf
cmp dword [esi + 8], 0
jne 0x4a16be
push 0x5989e4
push dword [eax + 8]
call dword [sym.imp.MSVCR80.dll_fopen]
test eax, eax
pop ecx
pop ecx
mov dword [esi + 8], eax
jne 0x4a16be
or eax, 0xffffffff
jmp 0x4a16f6
push dword [esi + 8]
push dword [ebp + 0xc]
push 1
push dword [ebp + 8]
call dword [sym.imp.MSVCR80.dll_fread]
mov edi, eax
add esp, 0x10
test edi, edi
je 0x4a16dd
cmp edi, dword [ebp + 0xc]
jbe 0x4a16f4
test ebx, ebx
jne 0x4a16ee
push dword [esi + 8]
call dword [sym.imp.MSVCR80.dll_fclose]
and dword [esi + 8], ebx
pop ecx
mov eax, dword [esi]
mov eax, dword [eax]
mov dword [esi], eax
mov eax, edi
pop edi
pop ebx
pop ebp
ret
Function at 0x4a1f8d
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x5f30a8]
jne 0x4a1f97
repz ret
jmp fcn.004a297b
Function at 0x4d0870
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xffffffc0
mov eax, 0x474
call fcn.004a2950
mov eax, dword [0x5f30a8]
xor eax, esp
mov dword [esp + 0x470], eax
push ebx
push esi
mov esi, dword [ebp + 8]
test esi, esi
push edi
mov dword [esp + 0x3c], 0
jne 0x4d08b7
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x470]
xor ecx, esp
call fcn.004a1f8d
mov esp, ebp
pop ebp
ret
lea eax, [esp + 0x48]
push eax
push esi
call sub.MSVCR80.dll__stat64i32
add esp, 8
test eax, eax
jl 0x4d08a0
mov eax, 8
call fcn.004a2950
fldz
fstp qword [esp]
lea ecx, [esp + 0x50]
push 0x30
push ecx
call fcn.004d06e0
mov ebx, dword [ebp + 0xc]
add esp, 0x10
test ebx, ebx
je 0x4d08a0
push 0x5989e4
push esi
call sub.MSVCR80.dll_fopen
add esp, 8
test eax, eax
mov dword [esp + 0x40], eax
je 0x4d0991
jmp 0x4d0914
mov eax, dword [esp + 0x40]
test ebx, ebx
jle 0x4d0922
cmp ebx, 0x400
mov esi, ebx
jl 0x4d0927
mov esi, 0x400
push eax
push esi
lea edx, [esp + 0x80]
push 1
push edx
call sub.MSVCR80.dll_fread
mov edi, eax
add esp, 0x10
test edi, edi
mov dword [esp + 0x44], edi
jle 0x4d0975
fild dword [esp + 0x44]
mov eax, 8
call fcn.004a2950
lea eax, [esp + 0x80]
fstp qword [esp]
push esi
push eax
call fcn.004d06e0
add dword [esp + 0x4c], edi
add esp, 0x10
test ebx, ebx
jle 0x4d0910
sub ebx, esi
test ebx, ebx
jg 0x4d0910
mov ecx, dword [esp + 0x40]
push ecx
call sub.MSVCR80.dll_fclose
lea edx, [esp + 0x7c]
push 0x400
push edx
call fcn.004ea520
add esp, 0xc
mov ecx, dword [esp + 0x47c]
mov eax, dword [esp + 0x3c]
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.004a1f8d
mov esp, ebp
pop ebp
ret

Function at 0x4d09b0
Capabilities:
Query environment variable

Disassembly:
push esi
push edi
xor esi, esi
call fcn.004bdd70
test eax, eax
mov edi, dword [esp + 0x10]
jne 0x4d0a0a
push str.RANDFILE
call sub.MSVCR80.dll_getenv
mov esi, eax
add esp, 4
test esi, esi
je 0x4d0a0a
cmp byte [esi], 0
je 0x4d0a0a
lea edx, [eax + 1]
lea esp, [esp]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x4d09e0
sub eax, edx
add eax, 1
cmp eax, edi
jae 0x4d0a0a
push edi
push esi
mov esi, dword [esp + 0x14]
push esi
call fcn.004dfd20
add esp, 0xc
cmp eax, edi
jb 0x4d0a7c
pop edi
xor eax, eax
pop esi
ret
call fcn.004bdd70
test eax, eax
jne 0x4d0a22
push str.HOME
call sub.MSVCR80.dll_getenv
add esp, 4
mov esi, eax
test esi, esi
jne 0x4d0a2d
mov esi, 0x59fa84
jmp 0x4d0a32
cmp byte [esi], 0
je 0x4d0a75
mov eax, esi
lea edx, [eax + 1]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x4d0a37
sub eax, edx
add eax, 6
cmp eax, edi
jae 0x4d0a75
push edi
push esi
mov esi, dword [esp + 0x14]
push esi
call fcn.004dfd20
push edi
push 0x5942d8
push esi
call fcn.004dfd70
push edi
push str..rnd
push esi
call fcn.004dfd70
add esp, 0x24
pop edi
mov eax, esi
pop esi
ret
mov esi, dword [esp + 0xc]
mov byte [esi], 0
pop edi
mov eax, esi
pop esi
ret