joyce8/EMBER2024-capa huggingface dataset:
Function at 0x404270
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0xc
mov eax, dword [ebp + 0x10]
push ebx
mov ebx, ecx
mov ecx, dword [ebp + 0xc]
push esi
push edi
mov edi, dword [ebp + 8]
mov dword [esp + 0xc], edi
test eax, eax
jg 0x4042a2
jl 0x404295
test ecx, ecx
jne 0x4042a2
xor eax, eax
xor edx, edx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
cmp dword [ebx + 0x38], 0
je 0x404362
mov dword [esp + 0x10], ecx
mov dword [esp + 0xc], eax
mov ecx, ebx
call fcn.00405d80
mov esi, eax
mov eax, edx
mov dword [esp + 0x14], eax
test eax, eax
jl 0x40430e
jg 0x4042cd
test esi, esi
je 0x40430e
mov ecx, dword [esp + 0xc]
cmp ecx, eax
jg 0x4042e5
mov eax, dword [esp + 0x10]
jl 0x4042df
cmp eax, esi
jae 0x4042e5
mov esi, eax
mov dword [esp + 0x14], ecx
mov eax, dword [ebx + 0x1c]
push esi
push dword [eax]
push edi
call fcn.004093b0
mov eax, dword [ebx + 0x2c]
add esp, 0xc
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0xc]
sub ecx, esi
sbb edx, dword [esp + 0x14]
sub dword [eax], esi
mov eax, dword [ebx + 0x1c]
add dword [eax], esi
jmp 0x40432f
mov eax, dword [ebx]
mov ecx, ebx
call dword [eax + 0x1c]
mov edx, dword [esp + 0xc]
cmp eax, 0xffffffff
je 0x40434b
mov ecx, dword [esp + 0x10]
mov esi, 1
add ecx, 0xffffffff
mov byte [edi], al
adc edx, 0xffffffff
add edi, esi
mov dword [esp + 0xc], edx
mov dword [esp + 0x10], ecx
test edx, edx
jg 0x4042b4
jl 0x40434b
test ecx, ecx
jne 0x4042b4
mov eax, dword [ebp + 0xc]
sub eax, dword [esp + 0x10]
mov ecx, dword [ebp + 0x10]
sbb ecx, edx
mov edx, ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov eax, dword [ebx + 0x1c]
mov edi, ecx
mov edx, dword [eax]
test edx, edx
je 0x4043a1
mov eax, dword [ebx + 0x2c]
mov eax, dword [eax]
test eax, eax
je 0x4043a1
mov edi, dword [esp + 0xc]
cmp eax, ecx
mov esi, ecx
cmovb esi, eax
push esi
push edx
push edi
call fcn.004093b0
mov eax, dword [ebx + 0x2c]
add edi, esi
mov dword [esp + 0x18], edi
add esp, 0xc
mov edi, dword [ebp + 0xc]
sub edi, esi
sub dword [eax], esi
mov eax, dword [ebx + 0x1c]
add dword [eax], esi
cmp dword [ebx + 0x4c], 0
mov ecx, edi
je 0x404410
mov esi, dword [ebx + 0xc]
lea eax, [ebx + 0x3c]
cmp dword [esi], eax
jne 0x4043c7
mov edx, dword [ebx + 0x54]
mov ecx, dword [ebx + 0x50]
sub edx, ecx
mov dword [esi], ecx
mov eax, dword [ebx + 0x1c]
mov dword [eax], ecx
mov eax, dword [ebx + 0x2c]
mov dword [eax], edx
mov esi, dword [esp + 0xc]
mov ecx, edi
cmp edi, 0xfff
jbe 0x4043f9
push dword [ebx + 0x4c]
push 0xfff
push 1
push esi
call fcn.0040cfa2
sub edi, eax
add esp, 0x10
add esi, eax
mov ecx, edi
cmp eax, 0xfff
jne 0x404424
cmp edi, eax
ja 0x4043d5
test ecx, ecx
je 0x404410
push dword [ebx + 0x4c]
push edi
push 1
push esi
call fcn.0040cfa2
mov ecx, edi
add esp, 0x10
sub ecx, eax
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
sub eax, ecx
sbb edx, 0
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
sub eax, edi
pop edi
pop esi
sbb edx, 0
pop ebx
mov esp, ebp
pop ebp
ret 0xc
Function at 0x4047a0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30
mov eax, dword [0x42d050]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
push esi
mov esi, ecx
cmp ebx, 0xffffffff
jne 0x4047d0
pop esi
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00407f49
mov esp, ebp
pop ebp
ret 4
mov eax, dword [esi + 0x20]
push edi
mov ecx, dword [eax]
test ecx, ecx
je 0x40480c
mov edx, dword [esi + 0x30]
mov edi, dword [edx]
lea eax, [edi + ecx]
cmp ecx, eax
jae 0x40480c
lea ecx, [edi - 1]
mov dword [edx], ecx
mov edx, dword [esi + 0x20]
mov esi, dword [edx]
lea ecx, [esi + 1]
mov dword [edx], ecx
mov byte [esi], bl
pop edi
pop esi
mov eax, ebx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00407f49
mov esp, ebp
pop ebp
ret 4
cmp dword [esi + 0x4c], 0
je 0x4048f6
mov edi, dword [esi + 0xc]
lea eax, [esi + 0x3c]
cmp dword [edi], eax
jne 0x404834
mov edx, dword [esi + 0x54]
mov ecx, dword [esi + 0x50]
sub edx, ecx
mov dword [edi], ecx
mov eax, dword [esi + 0x1c]
mov dword [eax], ecx
mov eax, dword [esi + 0x2c]
mov dword [eax], edx
mov ecx, dword [esi + 0x38]
test ecx, ecx
jne 0x404867
push dword [esi + 0x4c]
movsx eax, bl
push eax
call fcn.0040bf4c
add esp, 8
or ecx, 0xffffffff
cmp eax, ecx
cmovne ecx, ebx
pop edi
pop esi
mov eax, ecx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00407f49
mov esp, ebp
pop ebp
ret 4
mov byte [ebp - 0x25], bl
mov eax, dword [ecx]
mov edx, dword [eax + 0x1c]
lea eax, [ebp - 0x2c]
push eax
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x30]
push eax
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x25]
push eax
lea eax, [esi + 0x40]
push eax
call edx
sub eax, 0
je 0x4048c9
sub eax, 1
je 0x4048c9
sub eax, 2
jne 0x4048f6
push dword [esi + 0x4c]
movsx eax, byte [ebp - 0x25]
push eax
call fcn.0040bf4c
add esp, 8
or ecx, 0xffffffff
cmp eax, ecx
cmovne ecx, ebx
pop edi
pop esi
mov eax, ecx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00407f49
mov esp, ebp
pop ebp
ret 4
mov edi, dword [ebp - 0x2c]
lea eax, [ebp - 0x24]
sub edi, eax
je 0x4048e6
push dword [esi + 0x4c]
push edi
push 1
push eax
call fcn.0040c98e
add esp, 0x10
cmp edi, eax
jne 0x4048f6
lea eax, [ebp - 0x25]
mov byte [esi + 0x3d], 1
cmp dword [ebp - 0x30], eax
jne 0x4047f7
mov ecx, dword [ebp - 4]
or eax, 0xffffffff
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00407f49
mov esp, ebp
pop ebp
ret 4
Function at 0x405a90
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x28
mov eax, dword [0x42d050]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, ecx
cmp dword [esi + 0x38], 0
je 0x405b4c
cmp byte [esi + 0x3d], 0
je 0x405b4c
mov eax, dword [esi]
push edi
push 0xffffffffffffffff
call dword [eax + 0xc]
cmp eax, 0xffffffff
je 0x405b3a
mov ecx, dword [esi + 0x38]
mov eax, dword [ecx]
mov edx, dword [eax + 0x20]
lea eax, [ebp - 0x28]
push eax
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x24]
push eax
lea eax, [esi + 0x40]
push eax
call edx
sub eax, 0
je 0x405b02
sub eax, 1
je 0x405b06
sub eax, 2
jne 0x405b3a
mov byte [esi + 0x3d], al
mov al, 1
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00407f49
mov esp, ebp
pop ebp
ret
mov byte [esi + 0x3d], 0
mov edi, dword [ebp - 0x28]
lea eax, [ebp - 0x24]
sub edi, eax
je 0x405b23
push dword [esi + 0x4c]
push edi
push 1
push eax
call fcn.0040c98e
add esp, 0x10
cmp edi, eax
jne 0x405b3a
cmp byte [esi + 0x3d], 0
pop edi
sete al
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00407f49
mov esp, ebp
pop ebp
ret
pop edi
xor al, al
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00407f49
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 4]
mov al, 1
xor ecx, ebp
pop esi
call fcn.00407f49
mov esp, ebp
pop ebp
ret

Function at 0x406f80
Capabilities:
Create process on windows
Get token membership

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x25c
mov eax, dword [0x42d050]
xor eax, ebp
mov dword [ebp - 4], eax
lea eax, [ebp - 0x21c]
mov dword [ebp - 0x210], 0
push eax
push 0
push 0
push 0
push 0
push 0
push 0
push 0x220
push 0x20
push 2
lea eax, [ebp - 0x218]
mov dword [ebp - 0x21c], 0
push eax
mov dword [ebp - 0x218], 0
mov word [ebp - 0x214], 0x500
call dword [sym.imp.ADVAPI32.dll_AllocateAndInitializeSid]
test eax, eax
je 0x407012
lea eax, [ebp - 0x210]
push eax
push dword [ebp - 0x21c]
push 0
call dword [sym.imp.ADVAPI32.dll_CheckTokenMembership]
push dword [ebp - 0x21c]
neg eax
sbb eax, eax
and dword [ebp - 0x210], eax
call dword [sym.imp.ADVAPI32.dll_FreeSid]
cmp dword [ebp - 0x210], 0
jne 0x4070be
push 0x104
lea eax, [ebp - 0x20c]
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
xorps xmm0, xmm0
mov dword [ebp - 0x220], 0
lea eax, [ebp - 0x20c]
movlpd qword [ebp - 0x254], xmm0
mov dword [ebp - 0x248], eax
lea eax, [ebp - 0x258]
push eax
movlpd qword [ebp - 0x244], xmm0
movlpd qword [ebp - 0x238], xmm0
movlpd qword [ebp - 0x230], xmm0
movlpd qword [ebp - 0x228], xmm0
mov dword [ebp - 0x258], 0x3c
mov dword [ebp - 0x24c], 0x429988
mov dword [ebp - 0x23c], 1
call dword [sym.imp.SHELL32.dll_ShellExecuteExW]
test eax, eax
jne 0x4070c9
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov eax, 1
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00407f49
mov esp, ebp
pop ebp
ret 0x10
lea ecx, [ebp - 0x259]
call fcn.00402ba0
mov ecx, dword [ebp - 4]
xor eax, eax
xor ecx, ebp
call fcn.00407f49
mov esp, ebp
pop ebp
ret 0x10

Function at 0x412bf0
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.00412a66
Function at 0x430004
Capabilities:
Encode data using xor
Packed with generic packer

Disassembly:
pushal
nop
nop
mov eax, section..text
nop
mov ebx, 0x408ecc
mov ecx, 0x693838cd
nop
nop
test eax, eax
nop
nop
nop
nop
nop
je 0x43004e
nop
nop
nop
nop
nop
xor dword [eax], ecx
nop
nop
inc eax
nop
nop
nop
nop
nop
inc eax
nop
nop
nop
nop
nop
nop
nop
nop
nop
inc eax
nop
nop
nop
nop
nop
inc eax
nop
cmp eax, ebx
nop
nop
nop
nop
jne 0x430024
nop
nop
nop
nop
mov eax, section..data
mov ebx, 0x42e1d0
nop
mov ecx, 0x33d01870
nop
test eax, eax
nop
nop
nop
nop
nop
nop
je 0x430084
nop
nop
nop
xor dword [eax], ecx
nop
nop
nop
nop
nop
nop
add eax, 4
nop
nop
cmp eax, ebx
nop
nop
jne 0x43006c
nop
nop
nop
nop
popal
nop
nop
nop
nop
nop
jmp 0x401219

Function at 0xc86854
Capabilities:
Encode data using xor

Disassembly:
jmp 0xc8685e
pushal
call 0xc86864
pop ebp
sub ebp, 0x10
sub ebp, 0x886854
jmp 0xc8687a
mov eax, 0x886854
add eax, ebp
add eax, 0x4c
mov ecx, 0x5a3
mov edx, 0x40fbf2ca
xor byte [eax], dl
inc eax
dec ecx
jne 0xc86891
jmp 0xc868a4
inc ecx
pop es
inc ecx
inc ebx
test dl, 0xca
retf 0xb4b
Function at 0x44f769
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1a4
mov edx, dword [ebp + 8]
xor ecx, ecx
mov eax, 0x453190
cmp edx, dword [eax]
je 0x44f78b
add eax, 8
inc ecx
cmp eax, 0x453220
jl 0x44f77c
push esi
mov esi, ecx
shl esi, 3
cmp edx, dword [esi + 0x453190]
jne 0x44f8b9
mov eax, dword [0x453bb0]
cmp eax, 1
je 0x44f893
test eax, eax
jne 0x44f7bc
cmp dword [0x4530e4], 1
je 0x44f893
cmp edx, 0xfc
je 0x44f8b9
lea eax, [ebp - 0x1a4]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x44f7f3
lea eax, [ebp - 0x1a4]
push str._program_name_unknown_
push eax
call fcn.00450670
pop ecx
pop ecx
lea eax, [ebp - 0x1a4]
push edi
push eax
lea edi, [ebp - 0x1a4]
call fcn.00450490
inc eax
pop ecx
cmp eax, 0x3c
jbe 0x44f836
lea eax, [ebp - 0x1a4]
push eax
call fcn.00450490
mov edi, eax
lea eax, [ebp - 0x1a4]
sub eax, 0x3b
push 3
add edi, eax
push 0x45245c
push edi
call fcn.00450f00
add esp, 0x10
lea eax, [ebp - 0xa0]
push str.Runtime_Error__n_nProgram:
push eax
call fcn.00450670
lea eax, [ebp - 0xa0]
push edi
push eax
call fcn.00450680
lea eax, [ebp - 0xa0]
push 0x45243c
push eax
call fcn.00450680
push dword [esi + 0x453194]
lea eax, [ebp - 0xa0]
push eax
call fcn.00450680
push 0x12010
lea eax, [ebp - 0xa0]
push str.Microsoft_Visual_C_Runtime_Library
push eax
call fcn.00450e75
add esp, 0x2c
pop edi
jmp 0x44f8b9
lea eax, [ebp + 8]
lea esi, [esi + 0x453194]
push 0
push eax
push dword [esi]
call fcn.00450490
pop ecx
push eax
push dword [esi]
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
pop esi
leave
ret

Function at 0x401bed
Capabilities:
Parse pe header

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

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push esi
mov esi, ecx
push 0xffffffffffffffff
push 0
mov eax, dword [esi + 8]
mov dword [ebp - 8], eax
mov eax, dword [esi + 4]
mov dword [ebp - 4], eax
lea eax, [ebp - 8]
push eax
push 2
call dword [sym.imp.KERNEL32.dll_WaitForMultipleObjects]
push dword [esi + 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
mov ecx, 0x10050bb0
lock xadd dword [ecx], eax
mov ecx, dword [esi + 4]
push 0
push ecx
test eax, eax
je 0x10002380
call dword [sym.imp.KERNEL32.dll_TerminateThread]
jmp 0x10002396
push method.asio::detail::deadline_timer_service_struct_asio::detail::chrono_time_traits_struct_std::chrono::steady_clock__struct_asio::wait_traits_struct_std::chrono::steady_clock___.virtual_8
call dword [sym.imp.KERNEL32.dll_QueueUserAPC]
push 0xffffffffffffffff
push dword [esi + 4]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
pop esi
leave
ret

Function at 0x10002399
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x14
push ebx
push esi
push edi
xor eax, eax
mov esi, ecx
push eax
push eax
push 1
push eax
mov dword [esp + 0x20], esi
call dword [sym.imp.KERNEL32.dll_CreateEventW]
mov ebx, dword [ebp + 8]
mov edi, eax
mov dword [ebx + 4], edi
test edi, edi
jne 0x100023ed
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, dword [ebx]
mov ecx, ebx
push 1
mov esi, eax
call dword [edx]
mov dword [esp + 0x18], esi
call fcn.10001bef
mov dword [esp + 0x1c], eax
test esi, esi
jne 0x100024c6
mov esi, dword [esp + 0x10]
xor eax, eax
push eax
push eax
push 1
push eax
call dword [sym.imp.KERNEL32.dll_CreateEventW]
mov dword [esi + 8], eax
mov dword [ebx + 8], eax
cmp dword [esi + 8], 0
jne 0x10002439
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, dword [ebx]
mov ecx, ebx
push 1
mov esi, eax
call dword [edx]
mov dword [esp + 0x18], esi
call fcn.10001bef
mov dword [esp + 0x1c], eax
test esi, esi
je 0x10002435
mov edx, str.thread.exit_event
lea ecx, [esp + 0x18]
jmp 0x100024cf
mov esi, dword [esp + 0x10]
and dword [esp + 0x14], 0
lea eax, [esp + 0x14]
push eax
push 0
push ebx
push 0x100024d5
push dword [ebp + 0xc]
push 0
call fcn.10026ee4
add esp, 0x18
mov dword [esi + 4], eax
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
test eax, eax
jne 0x100024ad
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, dword [ebx]
mov ecx, ebx
push 1
mov dword [esp + 0x1c], eax
call dword [edx]
test edi, edi
je 0x1000247e
push edi
call esi
mov eax, dword [esp + 0x10]
cmp dword [eax + 8], 0
je 0x1000248d
push dword [eax + 8]
call esi
mov ebx, dword [esp + 0x18]
mov dword [esp + 0x18], ebx
call fcn.10001bef
mov dword [esp + 0x1c], eax
test ebx, ebx
je 0x100024ad
mov edx, str.thread
lea ecx, [esp + 0x18]
jmp 0x100024cf
test edi, edi
je 0x100024bd
push 0xffffffffffffffff
push edi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push edi
call esi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
mov edx, str.thread.entry_event
lea ecx, [esp + 0x18]
call fcn.10001b85
int3
Function at 0x100025d7
Capabilities:
Initialize winsock library

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x198
mov eax, dword [0x1004d0e0]
xor eax, esp
mov dword [esp + 0x194], eax
xor eax, eax
inc eax
lock xadd dword [0x10050fb8], eax
inc eax
cmp eax, 1
jne 0x10002615
lea eax, [esp]
push eax
push 2
call dword [sym.imp.WS2_32.dll_WSAStartup]
mov ecx, 0x10050fbc
xchg dword [ecx], eax
mov ecx, dword [esp + 0x194]
xor ecx, esp
call fcn.1002211a
mov esp, ebp
pop ebp
ret
Function at 0x1000270d
Capabilities:
Access peb ldr_data
Get kernel32 base address
Get process heap force flags

Disassembly:
push ebp
lea ebp, [esp - 0xa0]
sub esp, 0xa0
push 0xffffffffffffffff
push 0x10038a69
mov eax, dword fs:[0]
push eax
sub esp, 0x10
mov eax, dword [0x1004d0e0]
xor eax, ebp
mov dword [ebp + 0x9c], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov dword [ebp - 0x10], edi
mov eax, dword [ebp + 0xa8]
xor ecx, ecx
mov dword [ebp - 0x1c], edi
mov dword [edi + 4], ecx
mov dword [edi + 8], ecx
mov dword [edi + 0xc], eax
mov dword [edi + 0x10], ecx
mov dword [ebp - 4], ecx
mov dword [edi], vtable.asio::detail::win_iocp_io_context.0
mov dword [edi + 0x14], ecx
mov esi, 0x9c
mov dword [edi + 0x1c], ecx
push esi
push ecx
lea eax, [ebp]
mov dword [edi + 0x20], ecx
lea ebx, [edi + 0x18]
mov dword [edi + 0x24], ecx
push eax
mov dword [ebx], ecx
call fcn.100255c0
add esp, 0xc
mov dword [ebp], esi
xor esi, esi
mov dword [ebp + 4], 6
push 3
push 2
push esi
push esi
call dword [sym.imp.KERNEL32.dll_VerSetConditionMask]
push edx
push eax
push 2
lea eax, [ebp]
push eax
call dword [sym.imp.KERNEL32.dll_VerifyVersionInfoA]
neg eax
sbb eax, eax
and eax, 0xfffffe0b
add eax, 0x1f4
mov dword [edi + 0x28], eax
mov dword [edi + 0x2c], esi
mov dword [edi + 0x30], esi
mov byte [ebp - 4], 3
lea ecx, [edi + 0x38]
mov dword [edi + 0x34], esi
call fcn.10002023
mov dword [edi + 0x50], esi
mov dword [edi + 0x54], esi
mov dword [edi + 0x58], esi
or dword [edi + 0x5c], 0xffffffff
mov dword [edi + 0x60], esi
push 0xffffffffffffffff
push esi
push esi
push 0xffffffffffffffff
mov byte [ebp - 4], 6
call dword [sym.imp.KERNEL32.dll_CreateIoCompletionPort]
mov dword [edi + 0x14], eax
test eax, eax
jne 0x1000281d
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
call fcn.10001bef
mov dword [ebp - 0x18], esi
mov dword [ebp - 0x14], eax
test esi, esi
jne 0x100028a3
cmp byte [ebp + 0xb0], 0
je 0x1000287c
lock inc dword [ebx]
push 0xc
call fcn.10022312
mov esi, eax
mov dword [ebp - 0x10], esi
mov byte [ebp - 4], 7
xor ebx, ebx
push 0x10
mov dword [esi + 4], ebx
mov dword [esi + 8], ebx
call fcn.10022312
pop ecx
pop ecx
push ebx
mov dword [ebp - 0x14], eax
mov ecx, esi
push eax
mov dword [eax], vtable.asio::detail::win_thread::func_struct_asio::detail::win_iocp_io_context::thread_function_.0
mov dword [eax + 0xc], edi
call fcn.10002399
mov ebx, dword [edi + 0x60]
test ebx, ebx
je 0x10002879
push dword [ebx + 4]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 0xc
push ebx
call fcn.10022776
pop ecx
pop ecx
mov dword [edi + 0x60], esi
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x9c]
xor ecx, ebp
call fcn.1002211a
add ebp, 0xa0
leave
ret 0xc
mov edx, str.iocp
lea ecx, [ebp - 0x18]
call fcn.10001b85
int3
Function at 0x10002c75
Capabilities:
Get thread local storage value

Disassembly:
push esi
push dword [0x10050ffc]
mov esi, ecx
lea eax, [esi + 0x14]
neg esi
sbb esi, esi
and esi, eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
jmp 0x10002c96
cmp dword [eax], esi
je 0x10002c9c
mov eax, dword [eax + 8]
test eax, eax
jne 0x10002c8f
pop esi
ret
mov ecx, dword [eax + 4]
test ecx, ecx
je 0x10002c9a
pop esi
jmp fcn.10001dff

Function at 0x100034bf
Capabilities:
Set socket configuration

Disassembly:
sub esp, 0x14
push ebx
push ebp
push esi
mov ebx, ecx
xor esi, esi
mov ebp, edx
push edi
cmp ebx, 0xffffffff
je 0x1000358e
cmp byte [esp + 0x28], 0
je 0x10003512
test byte [ebp], 8
je 0x10003512
xor eax, eax
mov dword [esp + 0x1c], 0x1004d9c0
and dword [esp + 0x18], eax
mov dword [esp + 0x14], eax
lea eax, [esp + 0x18]
push eax
push 4
lea eax, [esp + 0x1c]
push eax
push 0x80
push 0xffff
call fcn.10003926
add esp, 0x14
push ebx
call dword [sym.imp.WS2_32.dll_closesocket]
mov edi, dword [esp + 0x2c]
mov esi, eax
test esi, esi
mov ecx, edi
setne dl
call fcn.10003461
test esi, esi
je 0x1000358e
call fcn.10001bef
mov ecx, dword [edi + 4]
mov ecx, dword [ecx + 4]
cmp ecx, dword [eax + 4]
jne 0x10003547
cmp dword [edi], 0x2733
je 0x1000355f
call fcn.10001bef
mov ecx, dword [edi + 4]
mov ecx, dword [ecx + 4]
cmp ecx, dword [eax + 4]
jne 0x1000358e
cmp dword [edi], 0x4d5
jne 0x1000358e
and dword [esp + 0x14], 0
lea eax, [esp + 0x14]
push eax
push 0x8004667e
push ebx
call dword [sym.imp.WS2_32.dll_ioctlsocket]
and byte [ebp], 0xfc
push ebx
call dword [sym.imp.WS2_32.dll_closesocket]
mov esi, eax
mov ecx, edi
test esi, esi
setne dl
call fcn.10003461
pop edi
mov eax, esi
pop esi
pop ebp
pop ebx
add esp, 0x14
ret

Function at 0x10003598
Capabilities:
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
push ecx
push edi
mov edi, edx
cmp ecx, 0xffffffff
jne 0x100035ba
call fcn.10001bef
mov ecx, dword [ebp + 0xc]
mov dword [ecx], 0x2719
mov dword [ecx + 4], eax
xor al, al
pop edi
leave
ret
push esi
lea eax, [ebp - 4]
mov dword [ebp - 4], 1
push eax
push 0x8004667e
push ecx
call dword [sym.imp.WS2_32.dll_ioctlsocket]
mov ecx, dword [ebp + 0xc]
mov esi, eax
test esi, esi
sets dl
call fcn.10003461
test esi, esi
pop esi
js 0x100035b5
or byte [edi], 2
mov al, 1
jmp 0x100035b7

Function at 0x100035ed
Capabilities:
Connect socket

Disassembly:
cmp ecx, 0xffffffff
jne 0x10003608
call fcn.10001bef
mov ecx, dword [esp + 8]
mov dword [ecx + 4], eax
or eax, 0xffffffff
mov dword [ecx], 0x2719
ret
push esi
push dword [esp + 8]
push edx
push ecx
call dword [sym.imp.WS2_32.dll_connect]
mov ecx, dword [esp + 0xc]
mov esi, eax
test esi, esi
setne dl
call fcn.10003461
mov eax, esi
pop esi
ret
Function at 0x100036a7
Capabilities:
Get socket status

Disassembly:
push ebp
lea ebp, [esp - 0x19c]
sub esp, 0x21c
mov eax, dword [0x1004d0e0]
xor eax, ebp
mov dword [ebp + 0x198], eax
push ebx
xor eax, eax
xor ebx, ebx
push esi
inc eax
mov dword [ebp - 0x80], ebx
push edi
mov dword [ebp - 0x70], eax
mov esi, ecx
mov dword [ebp + 0x94], eax
mov edi, edx
lea eax, [ebp - 0x80]
mov dword [ebp - 0x6c], esi
push eax
lea eax, [ebp + 0x94]
mov dword [ebp + 0x98], esi
push eax
lea eax, [ebp - 0x70]
mov dword [ebp - 0x7c], ebx
push eax
push ebx
lea eax, [esi + 1]
push eax
call dword [sym.imp.WS2_32.dll_select]
test eax, eax
jne 0x10003708
xor al, al
jmp 0x10003767
mov dword [ebp - 0x74], ebx
cmp esi, 0xffffffff
jne 0x1000371d
call fcn.10001bef
mov dword [edi], 0x2719
jmp 0x1000375e
lea eax, [ebp - 0x78]
mov dword [ebp - 0x78], 4
push eax
lea eax, [ebp - 0x74]
push eax
push 0x1007
push 0xffff
push esi
call dword [sym.imp.WS2_32.dll_getsockopt]
mov esi, eax
mov ecx, edi
test esi, esi
setne dl
call fcn.10003461
test esi, esi
jne 0x10003765
cmp dword [ebp - 0x74], ebx
je 0x10003763
call fcn.10001bef
mov ecx, dword [ebp - 0x74]
mov dword [edi], ecx
mov dword [edi + 4], eax
jmp 0x10003765
mov dword [edi], ebx
mov al, 1
mov ecx, dword [ebp + 0x198]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.1002211a
add ebp, 0x19c
leave
ret
Function at 0x1000404e
Capabilities:
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
xor ebx, ebx
lea eax, [ebp - 1]
push ebx
push ebx
push ebx
mov dword [ebp - 0xc], eax
xor edx, edx
lea eax, [ebp - 8]
mov byte [ebp - 1], bl
push eax
inc edx
mov dword [ebp - 8], ebx
push edx
lea eax, [ebp - 0x10]
mov dword [ebp - 0x10], edx
push eax
push dword [ecx + 4]
call dword [sym.imp.WS2_32.dll_WSASend]
call fcn.10001bef
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x40
je 0x10004095
cmp eax, 0x4d2
jne 0x1000409a
call fcn.10001bef
pop ebx
leave
ret