joyce8/EMBER2024-capa huggingface dataset:
Function at 0x10c4828
Capabilities:
Check os version
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x128
mov eax, dword [0x10cf230]
push ebx
push esi
mov dword [ebp - 4], eax
lea eax, [ebp - 0x120]
push eax
push 0x20019
xor ebx, ebx
push ebx
push 0x103f2e8
push SysReAllocStringLen
mov dword [ebp - 0x11c], ebx
mov dword [ebp - 0x120], ebx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
cmp eax, ebx
je 0x10c4881
jg 0x10c4875
mov esi, eax
jmp 0x10c4917
and eax, 0xffff
or eax, 0x80070000
jmp 0x10c486e
lea eax, [ebp - 0x124]
push eax
lea eax, [ebp - 0x11c]
push eax
lea eax, [ebp - 0x128]
push eax
push ebx
push 0x103f2c4
push dword [ebp - 0x120]
mov dword [ebp - 0x124], 4
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
cmp eax, ebx
je 0x10c4904
jle 0x10c48c2
and eax, 0xffff
or eax, 0x80070000
mov esi, eax
lea eax, [ebp - 0x118]
push eax
mov dword [ebp - 0x118], 0x114
call dword [sym.imp.KERNEL32.dll_GetVersionExW]
cmp dword [ebp - 0x108], 2
jne 0x10c4917
xor eax, eax
inc eax
cmp dword [ebp - 0x114], 5
ja 0x10c48fa
jne 0x10c4917
cmp dword [ebp - 0x110], eax
jb 0x10c4917
mov dword [ebp - 0x11c], eax
xor esi, esi
jmp 0x10c4917
mov esi, dword [ebp - 0x128]
sub esi, 4
neg esi
sbb esi, esi
and esi, 0x8000ffff
cmp dword [ebp - 0x120], ebx
je 0x10c492b
push dword [ebp - 0x120]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
cmp esi, ebx
jge 0x10c4935
mov dword [ebp - 0x11c], ebx
mov ecx, dword [ebp - 4]
xor eax, eax
cmp dword [ebp - 0x11c], ebx
pop esi
setne al
pop ebx
call fcn.01041c5f
leave
ret
Function at 0x10c9c19
Capabilities:
Get system information on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x24
push esi
mov esi, ecx
push edi
lea ecx, [esi + 0x820]
mov dword [esi], 0x1040b10
call fcn.010825a4
lea eax, [esi + 4]
push eax
call dword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
and dword [esi + 0x1c], 0
lea eax, [ebp - 0x24]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemInfo]
mov eax, dword [ebp - 0x20]
mov dword [esi + 0x20], eax
shl eax, 8
mov dword [esi + 0x28], eax
mov dword [esi + 0x24], 0x100
xor ecx, ecx
lea eax, [esi + 0x34]
and dword [eax], 0
inc ecx
add eax, 4
cmp ecx, dword [esi + 0x24]
jb 0x10c9c66
xor eax, eax
lea edi, [esi + 0x434]
mov ecx, 0xfb
rep stosd dword es:[edi], eax
and dword [esi + 0x30], eax
and dword [esi + 0x2c], eax
pop edi
mov eax, esi
pop esi
leave
ret

Function at 0x430000
Capabilities:
Encode data using xor
Packed with generic packer

Disassembly:
pushal
nop
nop
nop
nop
nop
mov eax, section..text
nop
nop
nop
nop
nop
push 4
nop
nop
pop edi
nop
nop
nop
nop
cmp eax, 0
nop
nop
je 0x430072
nop
nop
nop
nop
mov ebx, 0x408ecc
nop
nop
mov ecx, ebx
nop
nop
nop
nop
nop
nop
nop
sub ecx, eax
nop
nop
nop
xor edx, edx
nop
nop
nop
push eax
nop
nop
nop
nop
mov eax, ecx
nop
nop
nop
div edi
nop
nop
nop
nop
nop
nop
nop
nop
xchg ecx, eax
nop
nop
nop
nop
nop
nop
pop eax
mov esi, 0x375764e3
nop
nop
xor dword [eax], esi
nop
nop
nop
nop
nop
nop
nop
add eax, edi
nop
loop 0x430060
nop
nop
nop
nop
mov eax, section..data
nop
nop
cmp eax, 0
nop
nop
nop
nop
je 0x4300d2
nop
mov ebx, 0x42e1d0
nop
mov ecx, ebx
nop
nop
nop
nop
sub ecx, eax
nop
nop
nop
nop
nop
nop
nop
nop
xor edx, edx
nop
nop
nop
push eax
nop
nop
nop
nop
nop
mov eax, ecx
nop
nop
div edi
nop
nop
nop
nop
nop
xchg ecx, eax
nop
nop
nop
nop
nop
nop
pop eax
nop
nop
nop
mov esi, 0x7fe21a41
nop
xor dword [eax], esi
nop
nop
nop
nop
nop
nop
nop
add eax, edi
nop
nop
nop
loop 0x4300c0
nop
nop
nop
nop
nop
popal
nop
jmp 0x401219
Function at 0x4137b0
Capabilities:
Packed with generic packer

Disassembly:
pushal
mov esi, section.UPX1
lea edi, [esi - 0xc000]
push edi
jmp 0x4137ca
mov al, byte [esi]
inc esi
mov byte [edi], al
inc edi
add ebx, ebx
jne 0x4137d1
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x4137c0
mov eax, 1
add ebx, ebx
jne 0x4137e3
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
add ebx, ebx
jae 0x4137d8
jne 0x4137f4
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jae 0x4137d8
xor ecx, ecx
sub eax, 3
jb 0x413808
shl eax, 8
mov al, byte [esi]
inc esi
xor eax, 0xffffffff
je 0x41387a
mov ebp, eax
add ebx, ebx
jne 0x413813
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
jne 0x413820
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
jne 0x413844
inc ecx
add ebx, ebx
jne 0x413830
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
jae 0x413825
jne 0x413841
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jae 0x413825
add ecx, 2
cmp ebp, 0xfffff300
adc ecx, 1
lea edx, [edi + ebp]
cmp ebp, 0xfffffffc
jbe 0x413864
mov al, byte [edx]
inc edx
mov byte [edi], al
inc edi
dec ecx
jne 0x413855
jmp 0x4137c6
mov eax, dword [edx]
add edx, 4
mov dword [edi], eax
add edi, 4
sub ecx, 4
ja 0x413864
add edi, ecx
jmp 0x4137c6
pop esi
mov edi, esi
mov ecx, 0x281
mov al, byte [edi]
inc edi
sub al, 0xe8
cmp al, 1
ja 0x413882
cmp byte [edi], 5
jne 0x413882
mov eax, dword [edi]
mov bl, byte [edi + 4]
shr ax, 8
rol eax, 0x10
xchg ah, al
sub eax, edi
sub bl, 0xe8
add eax, esi
mov dword [edi], eax
add edi, 5
mov al, bl
loop 0x413887
lea edi, [esi + 0x11000]
mov eax, dword [edi]
or eax, eax
je 0x4138f6
mov ebx, dword [edi + 4]
lea eax, [eax + esi + 0x15810]
add ebx, esi
push eax
add edi, 8
call dword [esi + 0x15838]
xchg ebp, eax
mov al, byte [edi]
inc edi
or al, al
je 0x4138b4
mov ecx, edi
push edi
dec eax
repne scasb al, byte es:[edi]
push ebp
call dword [esi + 0x1583c]
or eax, eax
je 0x4138f0
mov dword [ebx], eax
add ebx, 4
jmp 0x4138d1
call dword [esi + 0x1584c]
mov ebp, dword [esi + 0x15840]
lea edi, [esi - 0x1000]
mov ebx, 0x1000
push eax
push esp
push 4
push ebx
push edi
call ebp
lea eax, [edi + 0x217]
and byte [eax], 0x7f
and byte [eax + 0x28], 0x7f
pop eax
push eax
push esp
push eax
push ebx
push edi
call ebp
pop eax
popal
lea eax, [esp - 0x80]
push 0
cmp esp, eax
jne 0x41392a
sub esp, 0xffffff80
jmp 0x4021f0
Function at 0x406a06
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x23c
push esi
mov esi, 0x104
lea eax, [ebp - 0x23c]
push esi
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
cmp eax, esi
pop esi
jbe 0x406a2a
xor eax, eax
test eax, eax
je 0x406a3d
cmp word [ebp + eax*2 - 0x23e], 0x5c
je 0x406a3d
xor ecx, ecx
jmp 0x406a40
xor ecx, ecx
inc ecx
push dword [ebp + 8]
lea ecx, [ecx*2 + 0x40a014]
lea eax, [ebp + eax*2 - 0x23c]
push ecx
push str._s_S.dll
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x10
lea eax, [ebp - 0x23c]
push 8
push 0
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
leave
ret 4

Function at 0x406b63
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
cmp dword [0x4275ec], 0
push esi
jne 0x406b9a
xor ecx, ecx
push 8
mov eax, ecx
pop esi
mov edx, eax
and dl, 1
neg dl
sbb edx, edx
and edx, 0xedb88320
shr eax, 1
xor eax, edx
dec esi
jne 0x406b74
mov dword [ecx*4 + 0x4275e8], eax
inc ecx
cmp ecx, 0x100
jl 0x406b6f
mov edx, dword [esp + 0x10]
mov eax, dword [esp + 8]
test edx, edx
not eax
jbe 0x406bcb
mov ecx, dword [esp + 0xc]
push edi
movzx edi, byte [ecx]
mov esi, eax
and esi, 0xff
xor esi, edi
shr eax, 8
mov esi, dword [esi*4 + 0x4275e8]
xor eax, esi
inc ecx
dec edx
jne 0x406bad
pop edi
not eax
pop esi
ret 0xc

Function at 0x42e000
Capabilities:
Encode data using xor
Packed with generic packer

Disassembly:
pushal
nop
nop
nop
nop
nop
call 0x42e00c
nop
nop
nop
pop eax
nop
nop
nop
add eax, 0x403ac5
nop
sub eax, 0x403a6b
mov ebx, dword [eax]
nop
nop
nop
nop
nop
nop
nop
mov ecx, dword [eax + 4]
nop
nop
nop
mov edx, dword [eax + 8]
xor dword [ebx], edx
nop
nop
nop
nop
nop
add ebx, 4
nop
nop
nop
cmp ebx, ecx
nop
nop
nop
nop
nop
nop
nop
jl 0x42e030
nop
nop
nop
add eax, 0xc
nop
nop
nop
cmp dword [eax], 0
jne 0x42e01e
nop
nop
nop
nop
popal
nop
nop
nop
nop
nop
jmp loc.00401219
Function at 0x402b60
Capabilities:
Resolve function by parsing pe exports

Disassembly:
cmp dword [eax + 0x70], 0
mov dword [eax + 0x4c], ecx
jne 0x402b73
mov dword [eax + 0x70], 1
mov dword [eax + 0x54], ecx
mov edx, ecx
sub edx, dword [eax + 0x54]
cmp edx, 0x2710
jge 0x402b88
cmp edx, 0xffffd8f0
jge 0x402b8d
mov dword [eax + 0x54], ecx
jmp 0x402b91
test edx, edx
js 0x402bac
mov edx, dword [eax + 0x50]
add dword [eax + 0x54], edx
push esi
push edi
mov edi, ecx
sub edi, dword [eax + 0x54]
pop edi
pop esi
js 0x402ba7
add edx, ecx
mov dword [eax + 0x54], edx
jmp fcn.00402570
ret

Function at 0x402cc0
Capabilities:
Initialize winsock library

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x19c
mov eax, dword [0x445824]
xor eax, ebp
mov dword [ebp - 4], eax
push edi
xor edi, edi
mov dword [esi + 8], edi
mov dword [esi + 0xc], edi
mov dword [esi + 0x10], edi
mov dword [esi], vtable.CTcpSocket.0
mov dword [esi + 0x38], edi
mov dword [esi + 0x30], edi
mov dword [esi + 0x34], edi
mov eax, vtable.CBuffer.0
mov dword [esi + 0x2c], eax
mov dword [esi + 0x3c], eax
mov dword [esi + 0x48], edi
mov dword [esi + 0x40], edi
mov dword [esi + 0x44], edi
mov dword [esi + 0x4c], eax
lea eax, [ebp - 0x198]
push eax
push 0x202
mov dword [esi + 0x58], edi
mov dword [esi + 0x50], edi
mov dword [esi + 0x54], edi
call dword [sym.imp.WS2_32.dll_WSAStartup]
push edi
push edi
push 1
push edi
call dword [sym.imp.KERNEL32.dll_CreateEventW]
push edi
lea ecx, [esi + 0x18]
push ecx
mov dword [esi + 4], eax
call dword [sym.imp.KERNEL32.dll_InterlockedExchange]
mov ecx, dword [ebp - 4]
mov dword [esi + 0x5c], edi
mov dword [esi + 0x60], edi
mov dword [esi + 0x14], edi
xor ecx, ebp
mov dword [esi + 0x64], 0xffffffff
mov eax, esi
pop edi
call fcn.0041fa5e
mov esp, ebp
pop ebp
ret
Function at 0x4038c0
Capabilities:
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
mov ebx, dword [ebp + 0xc]
push esi
push edi
mov esi, eax
mov dword [ebp - 4], 0
cmp ebx, 0x40000
jl 0x40391d
jmp 0x4038e0
xor edi, edi
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0x64]
push 0
push 0x40000
push esi
push ecx
call dword [sym.imp.WS2_32.dll_send]
test eax, eax
jg 0x403901
inc edi
cmp edi, 0xf
jl 0x4038e2
cmp edi, 0xf
je 0x40394e
add dword [ebp - 4], eax
sub ebx, 0x40000
add esi, 0x40000
cmp ebx, 0x40000
jge 0x4038e0
test ebx, ebx
jle 0x403946
xor edi, edi
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x64]
push 0
push ebx
push esi
push eax
call dword [sym.imp.WS2_32.dll_send]
test eax, eax
jg 0x40393e
inc edi
cmp edi, 0xf
jl 0x403923
cmp edi, 0xf
je 0x40394e
add dword [ebp - 4], eax
mov eax, dword [ebp - 4]
cmp eax, dword [ebp + 0xc]
je 0x403951
or eax, 0xffffffff
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8

Function at 0x403bb0
Capabilities:
Create thread
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push ebx
push esi
mov esi, eax
mov eax, dword [esi + 0x198]
xor ebx, ebx
cmp eax, ebx
jne 0x403bd2
mov dword [esi + 0x1b8], 0x598
jmp 0x403be9
cmp eax, 0x598
jbe 0x403be3
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret 4
mov dword [esi + 0x1b8], eax
push edi
mov dword [esi + 0x64], ebx
call fcn.00403d10
mov edi, dword [sym.imp.KERNEL32.dll_InterlockedIncrement]
mov eax, 1
push 0x453c64
mov dword [esi + 0x30], eax
mov dword [esi + 0x34], 5
mov dword [esi + 0x38], ebx
mov dword [esi + 0x3c], eax
mov dword [ebp - 8], ebx
call edi
mov dword [esi + 0x48], eax
cmp eax, ebx
jne 0x403c28
push 0x453c64
call edi
mov dword [esi + 0x48], eax
mov ecx, dword [esi + 0x40]
mov edi, dword [sym.imp.WS2_32.dll_setsockopt]
push 4
lea eax, [ebp - 4]
push eax
push 0x1001
push 0xffff
mov ebx, 0x40000
push ecx
mov dword [ebp - 4], ebx
call edi
mov eax, dword [esi + 0x40]
push 4
lea edx, [ebp - 4]
push edx
push 0x1002
push 0xffff
push eax
mov dword [ebp - 4], ebx
call edi
mov ecx, dword [ebp + 8]
push ecx
call fcn.00403e50
test eax, eax
je 0x403cb9
lea edx, [esi + 0x58]
push edx
push 0
push esi
push 0x403fe0
push 0
push 0
call fcn.004205ce
add esp, 0x18
mov dword [esi + 0x54], eax
test eax, eax
je 0x403cab
mov eax, dword [esi + 0x2c]
push eax
mov edi, 1
call dword [sym.imp.KERNEL32.dll_ResetEvent]
mov eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov dword [esi + 0x5c], 8
push 0x65f
jmp 0x403cc7
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [esi + 0x5c], 0xb
push eax
mov ebx, dword [sym.imp.KERNEL32.dll_SetLastError]
call ebx
xor eax, eax
mov dword [esi + 0x30], eax
mov dword [esi + 0x34], 5
mov dword [esi + 0x38], eax
mov dword [esi + 0x3c], 1
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
mov eax, esi
call fcn.004046d0
push edi
call ebx
mov edi, dword [ebp - 8]
mov eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
Function at 0x403da0
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x40004
call fcn.0042d850
mov eax, dword [0x445824]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
xor ecx, ecx
test edx, edx
jle 0x403dc9
xor byte [eax + ecx], 0x64
inc ecx
cmp ecx, edx
jl 0x403dc0
push esi
mov ecx, eax
push edi
mov esi, ecx
nop
mov dl, byte [ecx]
inc ecx
test dl, dl
jne 0x403dd0
sub ecx, esi
lea edi, [ebp - 0x40004]
mov edx, ecx
dec edi
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x403de2
mov ecx, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea edi, [ebp - 0x40004]
dec edi
nop
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x403e00
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.0041fa5e
mov esp, ebp
pop ebp
ret
Function at 0x403e50
Capabilities:
Connect socket
Connect udp socket
Create udp socket
Resolve dns
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
mov eax, dword [0x445824]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push 0x11
push 2
xor ebx, ebx
push 2
mov dword [ebp - 0x18], ebx
call dword [sym.imp.WS2_32.dll_socket]
mov dword [esi + 0x40], eax
cmp eax, 0xffffffff
jne 0x403e8d
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0041fa5e
mov esp, ebp
pop ebp
ret 4
push edi
push ebx
push ebx
lea ecx, [ebp - 0x20]
push ecx
push ebx
push ebx
push 4
lea edx, [ebp - 0x1c]
push edx
push 0x9800000c
push eax
mov dword [ebp - 0x1c], ebx
call dword [sym.imp.WS2_32.dll_WSAIoctl]
mov ecx, dword [esi + 0x40]
mov edi, dword [sym.imp.WS2_32.dll_setsockopt]
push 4
lea eax, [ebp - 0x1c]
push eax
push 0xfffffffffffffffb
push 0xffff
push ecx
call edi
mov eax, dword [esi + 0x40]
push 4
lea edx, [ebp - 0x1c]
push edx
push 4
push 0xffff
push eax
call edi
call dword [sym.imp.WS2_32.dll_WSACreateEvent]
push ebx
push ebx
push ebx
push ebx
push 0x4529e8
mov dword [esi + 0x44], eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
push eax
push 0x4529e8
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
mov ebx, eax
lea ecx, [ebx + 1]
push ecx
call fcn.0041de98
add esp, 4
push 0
push 0
push ebx
mov edi, eax
push edi
push 0x4529e8
call dword [sym.imp.KERNEL32.dll_lstrlenW]
push eax
push 0x4529e8
push 0
push 0
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
push edi
mov byte [edi + ebx], 0
call dword [sym.imp.WS2_32.dll_gethostbyname]
push edi
mov ebx, eax
call fcn.0041fa53
add esp, 4
pop edi
test ebx, ebx
je 0x403e7a
mov eax, dword [ebp + 8]
mov edx, 2
push eax
mov word [ebp - 0x14], dx
call dword [sym.imp.WS2_32.dll_htons]
mov word [ebp - 0x12], ax
mov ecx, dword [ebx + 0xc]
mov edx, dword [ecx]
mov eax, dword [edx]
mov ecx, dword [esi + 0x44]
mov edx, dword [esi + 0x40]
push 0x30
push ecx
push edx
mov dword [ebp - 0x10], eax
call dword [sym.imp.WS2_32.dll_WSAEventSelect]
cmp eax, 0xffffffff
je 0x403fcb
mov ecx, dword [esi + 0x40]
push 0x10
lea eax, [ebp - 0x14]
push eax
push ecx
call dword [sym.imp.WS2_32.dll_connect]
test eax, eax
je 0x403fc4
cmp eax, 0xffffffff
jne 0x403fa9
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
je 0x403fc4
mov dword [ebp - 0x18], 0
mov eax, dword [ebp - 0x18]
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0041fa5e
mov esp, ebp
pop ebp
ret 4
mov dword [ebp - 0x18], 1
mov ecx, dword [ebp - 4]
mov eax, dword [ebp - 0x18]
xor ecx, ebp
pop ebx
call fcn.0041fa5e
mov esp, ebp
pop ebp
ret 4
Function at 0x404360
Capabilities:
Send data
Send data on socket

Disassembly:
mov eax, dword [eax + 0x14]
push ebx
test eax, eax
jne 0x404383
mov ecx, dword [esi + 0x44]
mov edx, dword [esi + 0x40]
push 0x23
push ecx
push edx
call dword [sym.imp.WS2_32.dll_WSAEventSelect]
cmp eax, 0xffffffff
jne 0x40439c
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ebx, 1
mov dword [esi + 0x30], ebx
mov dword [esi + 0x34], 2
mov dword [esi + 0x38], eax
mov dword [esi + 0x3c], ebx
xor eax, eax
pop ebx
ret
push edi
lea eax, [esi + 0x19c]
push eax
lea ecx, [esi + 0x1d8]
mov ebx, 1
push ecx
mov dword [esi + 0x60], ebx
mov ecx, esi
mov eax, esi
mov dword [esi + 0x64], ebx
call fcn.00405800
mov edx, dword [esi + 0x40]
xor edi, edi
push edi
push edi
push edi
push edx
call dword [sym.imp.WS2_32.dll_send]
cmp eax, 0xffffffff
jne 0x4043e5
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov edi, eax
cmp edi, 0x2733
jne 0x4043e5
xor edi, edi
mov eax, dword [esi + 0x48]
push eax
call fcn.00402cb0
add esp, 4
test edi, edi
pop edi
je 0x404400
push 0x80004005
call fcn.00401300
mov eax, ebx
pop ebx
ret

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

Disassembly:
push ebp
mov ebp, esp
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
lea esp, [esp]
mov eax, dword [ebx + 0x70]
mov ecx, dword [ebx + 0x40]
push 0
push 0x598
push eax
push ecx
call dword [sym.imp.WS2_32.dll_recv]
mov edi, eax
test edi, edi
jle 0x4044e2
cmp edi, 0x10
jne 0x404468
mov edx, dword [ebx + 0x70]
mov ecx, eax
mov eax, 0x43d948
sub edx, eax
cmp ecx, 4
jb 0x40451a
mov esi, dword [edx + eax]
cmp esi, dword [eax]
jne 0x404468
sub ecx, 4
add eax, 4
jmp 0x404450
push 0
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov ecx, dword [ebx + 0x1c0]
mov edx, dword [ebx + 0x1c8]
mov eax, dword [ebx + 0x70]
lea esi, [ebx + 0x1d8]
cmp edi, 0x18
jl 0x404496
push ecx
push edi
push eax
mov edi, edx
call fcn.00405d80
jmp 0x4044a0
cmp edi, 0xc
jne 0x404510
call fcn.00405c30
cmp eax, 2
jne 0x404420
mov edx, dword [ebx + 0x48]
push edx
call fcn.00402cb0
add esp, 4
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x4044c4
mov eax, 0x4c7
mov ecx, 1
mov dword [ebx + 0x3c], ecx
mov dword [ebx + 0x34], 4
pop edi
mov dword [ebx + 0x30], ecx
mov dword [ebx + 0x38], eax
pop esi
xor eax, eax
pop ebx
pop ebp
ret 4
cmp edi, 0xffffffff
jne 0x404420
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
je 0x404537
cmp eax, 0x2744
je 0x404420
cmp eax, 0x2746
je 0x404420
jmp 0x4044c4
push 0xd
call dword [sym.imp.WS2_32.dll_WSASetLastError]
jmp 0x4044a9
xor eax, eax
pop edi
mov dword [ebx + 0x30], 1
mov dword [ebx + 0x34], 5
mov dword [ebx + 0x3c], eax
pop esi
mov dword [ebx + 0x38], eax
pop ebx
pop ebp
ret 4
pop edi
pop esi
mov eax, 1
pop ebx
pop ebp
ret 4
Function at 0x404550
Capabilities:
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push ebx
push edi
jmp 0x404560
mov eax, dword [esi + 0x194]
test eax, eax
jle 0x40468a
lea edi, [esi + 0x160]
push edi
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov ebx, dword [esi + 0x17c]
cmp ebx, dword [esi + 0x180]
je 0x40459b
mov eax, dword [ebx + 4]
mov dword [esi + 0x17c], eax
mov dword [eax + 8], 0
jmp 0x4045ad
test ebx, ebx
je 0x4045ad
xor eax, eax
mov dword [esi + 0x17c], eax
mov dword [esi + 0x180], eax
xor eax, eax
cmp ebx, eax
je 0x4045bf
mov dword [ebx + 4], eax
mov dword [ebx + 8], eax
dec dword [esi + 0x178]
push edi
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
test ebx, ebx
je 0x40468a
mov ecx, dword [ebx + 0x14]
mov eax, dword [ebx + 0x18]
push 0
sub eax, ecx
push eax
push ecx
mov ecx, dword [esi + 0x40]
push ecx
call dword [sym.imp.WS2_32.dll_send]
mov edi, eax
test edi, edi
jle 0x40460c
lea eax, [esi + 0x160]
push eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
sub dword [esi + 0x194], edi
lea eax, [esi + 0x160]
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
jmp 0x404611
cmp edi, 0xffffffff
je 0x404637
push ebx
lea edi, [esi + 0x98]
call fcn.00401500
test eax, eax
jne 0x404560
mov edx, dword [ebx]
push ebx
push eax
mov eax, dword [edx]
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
jmp 0x404560
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
jne 0x404695
lea edi, [esi + 0x160]
push edi
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov eax, dword [esi + 0x17c]
xor ecx, ecx
cmp eax, ecx
je 0x40466b
mov dword [eax + 8], ebx
mov ecx, dword [esi + 0x17c]
mov dword [ebx + 4], ecx
jmp 0x404677
mov dword [ebx + 8], ecx
mov dword [ebx + 4], ecx
mov dword [esi + 0x180], ebx
inc dword [esi + 0x178]
push edi
mov dword [esi + 0x17c], ebx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov eax, 1
pop edi
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, 1
push ebx
lea edi, [esi + 0x98]
mov dword [esi + 0x30], ecx
mov dword [esi + 0x34], 3
mov dword [esi + 0x38], eax
mov dword [esi + 0x3c], ecx
call fcn.00401500
test eax, eax
jne 0x4046c7
mov edx, dword [ebx]
push ebx
push eax
mov eax, dword [edx]
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
pop edi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x4046d0
Capabilities:
Send data
Send data on socket

Disassembly:
push ebx
push esi
push edi
mov edi, eax
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov ebx, eax
mov eax, dword [edi + 0x64]
cmp eax, 3
je 0x4047b7
lea esi, [edi + 0x15c]
push esi
call fcn.00402c60
mov ecx, dword [edi + 0x64]
cmp ecx, 1
je 0x404708
mov edx, dword [edi + 0x64]
test edx, edx
jne 0x4047b1
mov dword [edi + 0x64], 2
mov dword [esi], 0
push edi
mov eax, ebx
call fcn.004048d0
mov eax, dword [edi + 0x60]
test eax, eax
je 0x404744
cmp dword [edi + 0x3c], 0
je 0x40473d
mov ecx, dword [edi + 0x40]
push 0
push 0x10
push 0x43d948
push ecx
call dword [sym.imp.WS2_32.dll_send]
mov dword [edi + 0x60], 0
cmp dword [edi + 0x30], 0
je 0x40476c
mov edx, dword [edi + 0x48]
push edx
call fcn.00402cb0
mov eax, dword [edi + 4]
add esp, 4
push eax
call dword [sym.imp.KERNEL32.dll_SetEvent]
push 0
lea ecx, [edi + 0x18]
push ecx
call dword [sym.imp.KERNEL32.dll_InterlockedExchange]
mov eax, dword [edi + 0x44]
test eax, eax
je 0x404781
push eax
call dword [sym.imp.WS2_32.dll_WSACloseEvent]
mov dword [edi + 0x44], 0
mov eax, dword [edi + 0x40]
cmp eax, 0xffffffff
je 0x4047a3
push 1
push eax
call dword [sym.imp.WS2_32.dll_shutdown]
mov edx, dword [edi + 0x40]
push edx
call dword [sym.imp.WS2_32.dll_closesocket]
mov dword [edi + 0x40], 0xffffffff
call fcn.004047d0
pop edi
pop esi
mov eax, 1
pop ebx
ret
mov dword [esi], 0
push 0x139f
mov dword [edi + 0x5c], 1
call dword [sym.imp.KERNEL32.dll_SetLastError]
pop edi
pop esi
xor eax, eax
pop ebx
ret