joyce8/EMBER2024-capa huggingface dataset:
Function at 0x402200
Capabilities:
Set registry value

Disassembly:
push 0xffffffffffffffff
push 0x42d0f8
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x18
mov al, byte [esp + 0x30]
push ebx
push ebp
push esi
mov esi, dword [esp + 0x38]
push edi
mov edi, ecx
mov dword [esp + 0x10], esi
test al, al
mov dword [esp + 0x14], edi
jne 0x40234c
lea ebp, [edi + 0x2c]
mov dword [edi + 8], 7
mov ecx, dword [ebp + 4]
mov eax, dword [ebp + 8]
push ecx
push eax
push eax
call fcn.00403ba0
add esp, 0xc
mov ebx, eax
mov eax, dword [ebp + 8]
mov ecx, ebp
push eax
push ebx
call fcn.004030f0
cmp esi, 2
mov dword [ebp + 8], ebx
jbe 0x40234c
mov eax, dword [esp + 0x38]
mov cl, byte [eax + esi - 1]
test cl, cl
jne 0x40227e
lea ecx, [esi - 1]
mov dword [esp + 0x10], ecx
push 0
push eax
call fcn.0040d29d
mov ecx, dword [esp + 0x18]
mov ebx, eax
mov eax, dword [esp + 0x40]
add esp, 8
sub ebx, eax
cmp ebx, ecx
jae 0x40234c
mov esi, eax
mov dl, byte [esp + 0x40]
push 0
lea ecx, [esp + 0x1c]
mov byte [esp + 0x1c], dl
call fcn.00402b20
mov edi, esi
or ecx, 0xffffffff
xor eax, eax
push 1
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov edi, ecx
lea ecx, [esp + 0x1c]
push edi
mov dword [esp + 0x48], edi
call fcn.00403200
test al, al
je 0x4022f4
mov ecx, edi
mov edi, dword [esp + 0x1c]
mov eax, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x1c]
mov dword [esp + 0x20], eax
mov byte [ecx + eax], 0
mov eax, dword [ebp + 8]
lea edx, [esp + 0x18]
push edx
push 1
push eax
mov ecx, ebp
mov dword [esp + 0x3c], 0
call fcn.004034f0
push 1
lea ecx, [esp + 0x1c]
mov dword [esp + 0x34], 0xffffffff
call fcn.00402b20
mov edi, dword [esp + 0x38]
push 0
lea esi, [ebx + edi + 1]
push esi
call fcn.0040d29d
sub eax, edi
add esp, 8
mov ebx, eax
mov eax, dword [esp + 0x10]
cmp ebx, eax
jb 0x40229f
mov esi, dword [esp + 0x3c]
mov edi, dword [esp + 0x14]
mov ecx, dword [edi + 0xc]
mov eax, dword [ecx + 8]
test al, 8
jne 0x402397
mov edx, dword [edi + 4]
test edx, edx
je 0x402397
test al, 2
je 0x40236c
push 2
call fcn.004026a0
test al, al
jne 0x40237c
mov eax, dword [edi + 0xc]
test byte [eax + 8], 2
jne 0x402397
mov ecx, dword [eax + 4]
test ecx, ecx
je 0x402397
mov eax, dword [esp + 0x38]
mov edx, dword [edi + 0xc]
mov ecx, dword [edi + 4]
push esi
push eax
mov eax, dword [edx + 4]
push 7
push 0
push ecx
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov ecx, dword [edi + 0xc]
test byte [ecx + 8], 2
je 0x4023a5
call fcn.004026d0
mov ecx, dword [esp + 0x28]
mov byte [edi + 0x11], 1
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x24
ret 0xc
Function at 0x402920
Capabilities:
Delete registry key

Disassembly:
sub esp, 0x94
lea eax, [esp]
push esi
mov esi, ecx
push eax
mov dword [esp + 8], 0x94
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
test eax, eax
je 0x402965
cmp dword [esp + 0x14], 2
jne 0x402965
mov ecx, dword [esi + 0x10]
mov edx, dword [esi + 0xc]
push ecx
push edx
mov ecx, esi
call fcn.00402990
mov ecx, esi
call fcn.00402a60
pop esi
add esp, 0x94
ret
mov eax, dword [esi + 0x10]
mov ecx, dword [esi + 0xc]
push eax
push ecx
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
mov ecx, esi
call fcn.00402a60
pop esi
add esp, 0x94
ret

Function at 0x402990
Capabilities:
Delete registry key
Query or enumerate registry key

Disassembly:
sub esp, 0x10
push ebx
push ebp
push esi
push edi
mov ebx, ecx
push 0x104
call fcn.0041e2e5
mov ebp, dword [esp + 0x2c]
mov esi, eax
mov edi, ebp
or ecx, 0xffffffff
xor eax, eax
add esp, 4
repne scasb al, byte es:[edi]
not ecx
dec ecx
je 0x402a3f
mov eax, dword [esp + 0x24]
test eax, eax
je 0x402a3f
lea ecx, [esp + 0x10]
push ecx
push 0x2000e
push 0
push ebp
push eax
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x402a3f
mov edi, dword [sym.imp.ADVAPI32.dll_RegEnumKeyExA]
mov ecx, dword [esp + 0x10]
lea edx, [esp + 0x18]
push edx
push 0
push 0
lea eax, [esp + 0x20]
push 0
push eax
push esi
push 0
push ecx
mov dword [esp + 0x34], 0x104
call edi
test eax, eax
jne 0x402a19
mov edx, dword [esp + 0x10]
push esi
push edx
mov ecx, ebx
call fcn.00402990
jmp 0x4029e4
cmp eax, 0x103
jne 0x402a2c
mov eax, dword [esp + 0x24]
push ebp
push eax
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
mov ecx, dword [esp + 0x10]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov dword [esp + 0x10], 0
push esi
call fcn.0041e30e
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x10
ret 8

Function at 0x403fc0
Capabilities:
Check os version

Disassembly:
sub esp, 0x94
push ebx
push esi
mov esi, ecx
push edi
mov ecx, 0x7a
xor eax, eax
lea edi, [esi + 0x3c]
mov dword [esp + 0xc], 0x94
rep stosd dword es:[edi], eax
mov ecx, 0x24
lea edi, [esp + 0x10]
rep stosd dword es:[edi], eax
lea eax, [esp + 0xc]
xor ebx, ebx
push eax
mov dword [esi + 0x224], ebx
mov dword [esi + 0x228], 1
mov dword [esi + 0x22c], 1
mov dword [esi + 0x26c], ebx
mov dword [esi + 0x270], 1
mov dword [esi + 0x230], ebx
mov dword [esi + 0x250], ebx
mov dword [esi + 0x268], ebx
mov dword [esi + 0x238], ebx
mov dword [esi + 0x274], ebx
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
cmp dword [esp + 0x1c], 2
jne 0x404062
cmp dword [esp + 0x10], 5
jb 0x404062
mov eax, 1
pop edi
mov dword [esi + 0x234], eax
pop esi
pop ebx
add esp, 0x94
ret
mov dword [esi + 0x234], ebx
pop edi
pop esi
pop ebx
add esp, 0x94
ret
Function at 0x411899
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1a4
mov edx, dword [ebp + 8]
xor ecx, ecx
mov eax, 0x43c838
cmp edx, dword [eax]
je 0x4118bb
add eax, 8
inc ecx
cmp eax, 0x43c8c8
jl 0x4118ac
push esi
mov esi, ecx
shl esi, 3
cmp edx, dword [esi + 0x43c838]
jne 0x4119e9
mov eax, dword [0x441464]
cmp eax, 1
je 0x4119c3
test eax, eax
jne 0x4118ec
cmp dword [0x43c148], 1
je 0x4119c3
cmp edx, 0xfc
je 0x4119e9
lea eax, [ebp - 0x1a4]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x411923
lea eax, [ebp - 0x1a4]
push str._program_name_unknown_
push eax
call fcn.00410770
pop ecx
pop ecx
lea eax, [ebp - 0x1a4]
push edi
push eax
lea edi, [ebp - 0x1a4]
call fcn.0040f0d0
inc eax
pop ecx
cmp eax, 0x3c
jbe 0x411966
lea eax, [ebp - 0x1a4]
push eax
call fcn.0040f0d0
mov edi, eax
lea eax, [ebp - 0x1a4]
sub eax, 0x3b
push 3
add edi, eax
push 0x433384
push edi
call fcn.004101a0
add esp, 0x10
lea eax, [ebp - 0xa0]
push str.Runtime_Error__n_nProgram:
push eax
call fcn.00410770
lea eax, [ebp - 0xa0]
push edi
push eax
call fcn.00410780
lea eax, [ebp - 0xa0]
push 0x433364
push eax
call fcn.00410780
push dword [esi + 0x43c83c]
lea eax, [ebp - 0xa0]
push eax
call fcn.00410780
push 0x12010
lea eax, [ebp - 0xa0]
push str.Microsoft_Visual_C_Runtime_Library
push eax
call fcn.00414234
add esp, 0x2c
pop edi
jmp 0x4119e9
lea eax, [ebp + 8]
lea esi, [esi + 0x43c83c]
push 0
push eax
push dword [esi]
call fcn.0040f0d0
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 0x418f60
Capabilities:
Get graphical window text

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push ebx
push esi
push edi
mov esi, dword [ebp + 0x10]
push 0xf00021
mov edx, dword [esi + 4]
mov ecx, dword [esi]
mov eax, dword [esi + 0xc]
sub eax, edx
push eax
mov eax, dword [esi + 8]
sub eax, ecx
push eax
push edx
push ecx
mov ecx, dword [ebp + 0xc]
push ecx
call dword [sym.imp.GDI32.dll_PatBlt]
mov edi, dword [ebp + 8]
push edi
call dword [sym.imp.USER32.dll_GetWindowTextLengthA]
mov ebx, eax
lea eax, [eax + 5]
add eax, 3
and eax, 0xfffffffc
call fcn.0040df30
mov dword [ebp - 4], esp
cmp dword [ebp - 4], 0
je 0x41902b
add ebx, 2
mov eax, dword [ebp - 4]
push ebx
push eax
push edi
call dword [sym.imp.USER32.dll_GetWindowTextA]
test eax, eax
je 0x41902b
mov bx, 0x140
mov edi, dword [ebp + 0x14]
mov eax, edi
and al, 0xf
cmp al, 0xc
je 0x418fde
mov ebx, edi
and bx, 0xf
or bx, 0x150
test edi, 0x80
je 0x418fe9
or bh, 8
and edi, 0x8000000
je 0x419004
mov eax, dword [0x442bbc]
mov ecx, dword [ebp + 0xc]
push eax
push ecx
call dword [sym.imp.GDI32.dll_SetTextColor]
mov dword [ebp - 8], eax
mov ecx, dword [ebp - 4]
mov edx, dword [ebp + 0xc]
movzx eax, bx
push eax
push esi
push 0xffffffffffffffff
push ecx
push edx
call dword [sym.imp.USER32.dll_DrawTextA]
test edi, edi
je 0x41902b
mov eax, dword [ebp - 8]
mov ecx, dword [ebp + 0xc]
push eax
push ecx
call dword [sym.imp.GDI32.dll_SetTextColor]
lea esp, [ebp - 0x14]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x419400
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov eax, dword [esp + 8]
sub esp, 4
push ebx
push esi
mov esi, dword [esp + 0x10]
push edi
push ebp
push 2
push eax
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
mov edi, eax
test edi, edi
jne 0x41942b
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret 0x20
push edi
push esi
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov ebx, eax
push edi
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov esi, eax
test esi, esi
jne 0x41944f
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret 0x20
push ebx
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov ebp, eax
test ebp, ebp
jne 0x41946a
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret 0x20
mov edi, ebp
mov ecx, ebx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov eax, dword [esp + 0x20]
xor ecx, ecx
mov cl, ah
mov edx, eax
mov dword [esp + 0x10], 0
shl ecx, 8
shr edx, 0x10
mov byte [esp + 0x10], dl
xor edx, edx
or ecx, dword [esp + 0x10]
mov dl, al
shl edx, 0x10
mov eax, dword [esp + 0x28]
or ecx, edx
mov edx, eax
shr edx, 0x10
mov dword [ebp + 0x28], ecx
mov dword [esp + 0x10], 0
xor ecx, ecx
mov byte [esp + 0x10], dl
mov cl, ah
xor edx, edx
shl ecx, 8
mov dl, al
shl edx, 0x10
or ecx, dword [esp + 0x10]
or ecx, edx
mov eax, dword [esp + 0x24]
mov edx, eax
mov dword [ebp + 0x44], ecx
shr edx, 0x10
xor ecx, ecx
mov dword [esp + 0x10], 0
mov cl, ah
mov byte [esp + 0x10], dl
shl ecx, 8
xor edx, edx
or ecx, dword [esp + 0x10]
mov dl, al
shl edx, 0x10
mov eax, dword [esp + 0x2c]
or ecx, edx
xor edx, edx
mov dl, al
mov dword [ebp + 0x48], ecx
shl edx, 0x10
xor ecx, ecx
mov cl, ah
shl ecx, 8
shr eax, 0x10
or ecx, edx
xor edx, edx
mov dl, al
mov eax, dword [esp + 0x30]
or ecx, edx
xor edx, edx
mov dl, al
mov dword [ebp + 0x64], ecx
shl edx, 0x10
xor ecx, ecx
mov cl, ah
shl ecx, 8
shr eax, 0x10
or ecx, edx
xor edx, edx
mov dl, al
mov eax, dword [esp + 0x34]
or ecx, edx
xor edx, edx
mov dl, al
mov dword [ebp + 0x54], ecx
shl edx, 0x10
xor ecx, ecx
mov cl, ah
shl ecx, 8
push 0
shr eax, 0x10
or ecx, edx
xor edx, edx
mov dl, al
or ecx, edx
mov dword [ebp + 0x50], ecx
call dword [sym.imp.USER32.dll_GetDC]
mov edi, eax
push 0
push ebp
lea ecx, [ebp + 0x68]
push ecx
push 4
push ebp
push edi
call dword [sym.imp.GDI32.dll_CreateDIBitmap]
mov esi, eax
push edi
push 0
call dword [sym.imp.USER32.dll_ReleaseDC]
push ebp
call dword [sym.imp.KERNEL32.dll_GlobalFree]
mov eax, esi
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret 0x20
Function at 0x41d235
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebx
push esi
push edi
xor edi, edi
cmp dword [esp + 0x10], edi
mov ebx, ecx
je 0x41d277
call fcn.0042a22d
mov esi, dword [eax + 0xc]
push 0xf0
push dword [esp + 0x14]
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
cmp eax, edi
je 0x41d277
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
cmp eax, edi
jne 0x41d26e
xor eax, eax
jmp 0x41d27f
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov edi, eax
push edi
mov ecx, ebx
call fcn.0041d285
pop edi
pop esi
pop ebx
ret 4

Function at 0x41e7c3
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov eax, 0x42d50c
call fcn.0040dbf8
sub esp, 0x18
push ebx
push esi
mov esi, ecx
push edi
mov dword [ebp - 0x10], esp
mov dword [ebp - 0x1c], esi
mov eax, dword [esi + 0x48]
mov edi, dword [esi + 0x44]
mov dword [ebp - 0x18], eax
call fcn.0042a22d
cmp dword [esi + 0x40], 0
mov ebx, dword [eax + 0xc]
je 0x41e802
call fcn.0042a22d
mov ebx, dword [eax + 0xc]
push 5
push dword [esi + 0x40]
push ebx
call dword [sym.imp.KERNEL32.dll_FindResourceA]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov edi, eax
test edi, edi
je 0x41e810
push edi
call dword [sym.imp.KERNEL32.dll_LockResource]
mov dword [ebp - 0x18], eax
cmp dword [ebp - 0x18], 0
jne 0x41e81e
or eax, 0xffffffff
jmp 0x41e906
mov ecx, esi
call fcn.0041e739
mov dword [ebp - 0x14], eax
call fcn.0041b53c
xor edi, edi
cmp dword [ebp - 0x14], edi
mov dword [ebp - 0x20], edi
je 0x41e855
push dword [ebp - 0x14]
call dword [sym.imp.USER32.dll_IsWindowEnabled]
test eax, eax
je 0x41e855
push edi
push dword [ebp - 0x14]
call dword [sym.imp.USER32.dll_EnableWindow]
mov dword [ebp - 0x20], 1
push esi
mov dword [ebp - 4], edi
call fcn.0041b4f0
push dword [ebp - 0x14]
call fcn.0041b03e
push ebx
push eax
push dword [ebp - 0x18]
mov ecx, esi
call fcn.0041e4d1
cmp eax, edi
je 0x41e8c8
test byte [esi + 0x24], 0x10
je 0x41e896
push 4
mov ecx, esi
pop ebx
call fcn.0041dac3
test ah, 1
je 0x41e88e
push 5
pop ebx
push ebx
mov ecx, esi
call fcn.0041d48c
cmp dword [esi + 0x1c], edi
je 0x41e8c8
push 0x97
push edi
push edi
push edi
push edi
push edi
mov ecx, esi
call fcn.0041dc0b
jmp 0x41e8c8
or dword [ebp - 4], 0xffffffff
cmp dword [ebp - 0x20], edi
je 0x41e8dc
push 1
push dword [ebp - 0x14]
call dword [sym.imp.USER32.dll_EnableWindow]
cmp dword [ebp - 0x14], edi
je 0x41e8f5
call dword [sym.imp.USER32.dll_GetActiveWindow]
cmp eax, dword [esi + 0x1c]
jne 0x41e8f5
push dword [ebp - 0x14]
call dword [sym.imp.USER32.dll_SetActiveWindow]
mov eax, dword [esi]
mov ecx, esi
call dword [eax + 0x58]
mov ecx, esi
call fcn.0041e773
mov eax, dword [esi + 0x2c]
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
leave
ret
Function at 0x42a855
Capabilities:
Get thread local storage value

Disassembly:
push ebx
push esi
mov esi, ecx
lea ebx, [esi + 0x1c]
push ebx
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
cmp dword [esp + 0x10], 0
jne 0x42a883
push dword [esi]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x42a8a1
push dword [esp + 0xc]
mov ecx, esi
push eax
call fcn.0042a7bb
jmp 0x42a8a1
mov eax, dword [esi + 0x14]
test eax, eax
je 0x42a8a1
push edi
push dword [esp + 0x10]
mov edi, dword [eax + 4]
mov ecx, esi
push eax
call fcn.0042a7bb
test edi, edi
mov eax, edi
jne 0x42a88b
pop edi
push ebx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop esi
pop ebx
ret 8
Function at 0x404bd0
Capabilities:
Get local ipv4 addresses
Get socket information
Set socket configuration

Disassembly:
push esi
push ebx
sub esp, 0x34
mov ebx, dword [esp + 0x40]
lea esi, [esp + 0x28]
mov dword [esp + 0x28], pe_nt_image_headers32
mov dword [esp + 8], esi
lea eax, [ebx + 0x60]
mov dword [esp + 4], eax
mov eax, dword [ebx + 0xc]
mov dword [esp], eax
call sub.cygwin1.dll_getsockname
test eax, eax
js 0x404cd3
lea eax, [ebx + 0xe0]
mov dword [esp + 8], esi
mov dword [esp + 0x28], pe_nt_image_headers32
mov dword [esp + 4], eax
mov eax, dword [ebx + 0xc]
mov dword [esp], eax
call sub.cygwin1.dll_getpeername
test eax, eax
js 0x404cd3
mov eax, dword [esp + 0x44]
mov eax, dword [eax + 0x164]
mov eax, dword [eax + 0x2c]
test eax, eax
mov dword [esp + 0x2c], eax
jne 0x404c50
xor eax, eax
add esp, 0x34
pop ebx
pop esi
ret
mov eax, dword [ebx + 0xc]
mov dword [esp], eax
call fcn.0040da20
cmp eax, 0x17
lea eax, [esp + 0x2c]
mov dword [esp + 0x10], 4
mov dword [esp + 0xc], eax
je 0x404ca0
mov dword [esp + 8], 3
mov dword [esp + 4], 0
mov eax, dword [ebx + 0xc]
mov dword [esp], eax
call sub.cygwin1.dll_setsockopt
test eax, eax
jns 0x404c41
mov dword [0x41cb64], 0x7d
mov eax, 0xffffffff
jmp 0x404c43
mov dword [esp + 8], 0x27
mov dword [esp + 4], 0x29
mov eax, dword [ebx + 0xc]
mov dword [esp], eax
call sub.cygwin1.dll_setsockopt
test eax, eax
jns 0x404c41
mov dword [0x41cb64], 0x7e
mov eax, 0xffffffff
jmp 0x404c43
mov dword [0x41cb64], 0xc9
mov eax, 0xffffffff
jmp 0x404c43
Function at 0x407c20
Capabilities:
Terminate process

Disassembly:
push esi
push ebx
sub esp, 0x404
lea eax, [esp + 0x418]
mov ebx, dword [esp + 0x410]
lea esi, [esp + 0x18]
mov dword [esp + 4], 0x3e8
mov dword [esp + 0xc], eax
mov eax, dword [esp + 0x414]
mov dword [esp], esi
mov dword [esp + 8], eax
call sub.cygwin1.dll_vsnprintf
test ebx, ebx
je 0x407ced
mov eax, dword [ebx + 0x84]
test eax, eax
je 0x407ca0
cmp dword [ebx + 0x17c], 0
je 0x407ca0
mov dword [esp], esi
call fcn.004109e0
mov dword [esp + 4], 0x414058
mov dword [esp + 8], eax
mov eax, dword [ebx + 0x17c]
mov dword [esp], eax
call fcn.00410540
mov dword [esp], ebx
call fcn.00405370
jmp 0x407cbb
mov eax, dword [ebx + 0x5c]
test eax, eax
je 0x407ccf
mov dword [esp + 8], esi
mov dword [esp + 4], str.iperf3:__s_n
mov dword [esp], eax
call sub.cygwin1.dll_fprintf
mov dword [esp], ebx
call fcn.00405270
mov dword [esp], 1
call sub.cygwin1.dll_exit
call sub.cygwin1.dll___getreent
mov dword [esp + 8], esi
mov dword [esp + 4], str.iperf3:__s_n
mov eax, dword [eax + 0xc]
mov dword [esp], eax
call sub.cygwin1.dll_fprintf
jmp 0x407cbb
call sub.cygwin1.dll___getreent
mov dword [esp + 8], esi
mov dword [esp + 4], str.iperf3:__s_n
mov eax, dword [eax + 0xc]
mov dword [esp], eax
call sub.cygwin1.dll_fprintf
jmp 0x407cc3
Function at 0x40c4f0
Capabilities:
Set socket configuration

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x9c
mov ebx, dword [esp + 0xb0]
mov esi, dword [esp + 0xb4]
lea edi, [esp + 0x38]
mov eax, dword [ebx + 0x164]
mov eax, dword [eax + 4]
test eax, eax
mov dword [esp + 0x38], eax
je 0x40c579
lea edi, [esp + 0x38]
mov dword [esp + 0x10], 4
mov dword [esp + 8], 0x1002
mov dword [esp + 4], 0xffff
mov dword [esp], esi
mov dword [esp + 0xc], edi
call sub.cygwin1.dll_setsockopt
test eax, eax
js 0x40c750
mov dword [esp + 0x10], 4
mov dword [esp + 0xc], edi
mov dword [esp + 8], 0x1001
mov dword [esp + 4], 0xffff
mov dword [esp], esi
call sub.cygwin1.dll_setsockopt
test eax, eax
js 0x40c750
lea ebp, [esp + 0x3c]
mov dword [esp + 0xc], edi
mov dword [esp + 8], 0x1001
mov dword [esp + 4], 0xffff
mov dword [esp], esi
mov dword [esp + 0x10], ebp
mov dword [esp + 0x3c], 4
call sub.cygwin1.dll_getsockopt
test eax, eax
js 0x40c750
mov edx, dword [ebx + 0x8c]
test edx, edx
jne 0x40c6b0
mov eax, dword [ebx + 0x164]
mov edx, dword [esp + 0x38]
mov ecx, dword [eax + 4]
test ecx, ecx
jne 0x40c680
mov eax, dword [eax + 8]
mov dword [esp + 0x2c], 0
cmp eax, edx
jg 0x40c6e0
mov dword [esp + 0x10], ebp
mov dword [esp + 0xc], edi
mov dword [esp + 8], 0x1002
mov dword [esp + 4], 0xffff
mov dword [esp], esi
mov dword [esp + 0x3c], 4
call sub.cygwin1.dll_getsockopt
test eax, eax
js 0x40c750
mov eax, dword [ebx + 0x8c]
test eax, eax
jne 0x40c721
mov eax, dword [ebx + 0x164]
mov edx, dword [esp + 0x38]
mov ecx, dword [eax + 4]
test ecx, ecx
jne 0x40c6a0
mov ecx, dword [eax + 8]
mov eax, dword [esp + 0x2c]
cmp ecx, edx
jle 0x40c66e
lea ebx, [esp + 0x40]
mov dword [esp + 0x10], edx
mov dword [esp + 0xc], ecx
mov dword [esp + 8], str.Block_size__d___receiving_socket_buffer_size__d
mov dword [esp + 4], 0x50
mov dword [esp], ebx
call sub.cygwin1.dll_snprintf
mov dword [esp], ebx
call fcn.00401f70
mov eax, 1
add esp, 0x9c
pop ebx
pop esi
pop edi
pop ebp
ret
cmp ecx, edx
jle 0x40c5d0
mov dword [0x41cb64], 0x8d
mov eax, 0xffffffff
jmp 0x40c66e
cmp ecx, edx
jle 0x40c632
jmp 0x40c688
mov eax, dword [ebx + 0x164]
mov eax, dword [eax + 4]
mov dword [esp], str.SNDBUF_is__u__expecting__u_n
mov dword [esp + 8], eax
mov eax, dword [esp + 0x38]
mov dword [esp + 4], eax
call sub.cygwin1.dll_printf
jmp 0x40c5bb
mov dword [esp + 0x10], edx
lea edx, [esp + 0x40]
mov dword [esp + 0xc], eax
mov dword [esp + 8], str.Block_size__d___sending_socket_buffer_size__d
mov dword [esp + 4], 0x50
mov dword [esp], edx
mov dword [esp + 0x2c], edx
call sub.cygwin1.dll_snprintf
mov edx, dword [esp + 0x2c]
mov dword [esp], edx
call fcn.00401f70
mov dword [esp + 0x2c], 1
jmp 0x40c5e3
mov eax, dword [ebx + 0x164]
mov eax, dword [eax + 4]
mov dword [esp], str.RCVBUF_is__u__expecting__u_n
mov dword [esp + 8], eax
mov eax, dword [esp + 0x38]
mov dword [esp + 4], eax
call sub.cygwin1.dll_printf
jmp 0x40c621
mov dword [0x41cb64], 0x7c
mov eax, 0xffffffff
jmp 0x40c66e
Function at 0x40cba0
Capabilities:
Get hostname

Disassembly:
push edi
push esi
push ebx
sub esp, 0x620
mov dword [esp], 0
mov ebx, dword [esp + 0x630]
call sub.cygwin1.dll_time
mov esi, eax
call sub.cygwin1.dll_getpid
xor eax, esi
lea esi, [esp + 0x44]
mov dword [esp], eax
call sub.cygwin1.dll_srandom
mov dword [esp], esi
mov dword [esp + 4], 0x1f4
call sub.cygwin1.dll_gethostname
lea eax, [esp + 0x3c]
mov dword [esp + 4], 0
mov dword [esp], eax
call sub.cygwin1.dll_gettimeofday
call sub.cygwin1.dll_random
mov edi, eax
call sub.cygwin1.dll_random
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0x40]
mov dword [esp + 0x1c], edi
mov dword [esp + 0xc], esi
mov dword [esp + 0x20], 0x4168d4
mov dword [esp + 8], str._s._ld._06ld._08lx_08lx._s
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0x3c]
mov dword [esp + 4], 0x3e8
mov dword [esp + 0x10], eax
lea eax, [esp + 0x238]
mov dword [esp], eax
call sub.cygwin1.dll_snprintf
mov eax, dword [esp + 0x238]
mov byte [ebx + 0x24], 0
mov dword [ebx], eax
mov eax, dword [esp + 0x23c]
mov dword [ebx + 4], eax
mov eax, dword [esp + 0x240]
mov dword [ebx + 8], eax
mov eax, dword [esp + 0x244]
mov dword [ebx + 0xc], eax
mov eax, dword [esp + 0x248]
mov dword [ebx + 0x10], eax
mov eax, dword [esp + 0x24c]
mov dword [ebx + 0x14], eax
mov eax, dword [esp + 0x250]
mov dword [ebx + 0x18], eax
mov eax, dword [esp + 0x254]
mov dword [ebx + 0x1c], eax
mov eax, dword [esp + 0x258]
mov dword [ebx + 0x20], eax
add esp, 0x620
pop ebx
pop esi
pop edi
ret

Function at 0x40ccb0
Capabilities:
Get socket status

Disassembly:
sub esp, 0x3c
mov eax, 1
mov ecx, dword [esp + 0x40]
mov byte [esp + 0x28], 0
mov byte [esp + 0x29], 0
mov byte [esp + 0x2a], 0
mov byte [esp + 0x2b], 0
mov byte [esp + 0x2c], 0
mov edx, ecx
shl eax, cl
mov byte [esp + 0x2d], 0
shr edx, 5
mov byte [esp + 0x2e], 0
mov byte [esp + 0x2f], 0
or dword [esp + edx*4 + 0x28], eax
lea eax, [esp + 0x20]
add ecx, 1
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 0x10], eax
lea eax, [esp + 0x28]
mov dword [esp], ecx
mov dword [esp + 0x20], 0
mov dword [esp + 4], eax
mov dword [esp + 0x24], 0
call sub.cygwin1.dll_select
xor edx, edx
test eax, eax
js 0x40cd40
mov eax, edx
add esp, 0x3c
ret
call sub.cygwin1.dll___errno
xor edx, edx
cmp dword [eax], 9
sete dl
add esp, 0x3c
mov eax, edx
ret