joyce8/EMBER2024-capa huggingface dataset:
Function at 0x43c6b8
Capabilities:
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
mov eax, dword [0x46dc44]
cmp byte [eax + 0xc], 0
je 0x43c825
push 0x8000
call sub.kernel32.dll_SetErrorMode
mov dword [ebp - 4], eax
xor eax, eax
push ebp
push 0x43c81e
push dword fs:[eax]
mov dword fs:[eax], esp
cmp dword [0x46eb68], 0
jne 0x43c70c
push 0x43c82c
call sub.kernel32.dll_GetModuleHandleA_2
mov ebx, eax
push 0x43c834
push ebx
call sub.kernel32.dll_GetProcAddress_1
mov dword [0x46eb68], eax
cmp dword [0x46cb70], 0
jne 0x43c807
push 0x43c844
call sub.kernel32.dll_LoadLibraryA
mov dword [0x46cb70], eax
cmp dword [0x46cb70], 0
je 0x43c807
push 0x43c850
mov eax, dword [0x46cb70]
push eax
call sub.kernel32.dll_GetProcAddress_1
mov dword [0x46eb6c], eax
push 0x43c860
mov eax, dword [0x46cb70]
push eax
call sub.kernel32.dll_GetProcAddress_1
mov dword [0x46eb70], eax
push 0x43c874
mov eax, dword [0x46cb70]
push eax
call sub.kernel32.dll_GetProcAddress_1
mov dword [0x46eb74], eax
push 0x43c88c
mov eax, dword [0x46cb70]
push eax
call sub.kernel32.dll_GetProcAddress_1
mov dword [0x46eb78], eax
push 0x43c8a4
mov eax, dword [0x46cb70]
push eax
call sub.kernel32.dll_GetProcAddress_1
mov dword [0x46eb7c], eax
push 0x43c8b8
mov eax, dword [0x46cb70]
push eax
call sub.kernel32.dll_GetProcAddress_1
mov dword [0x46eb80], eax
push 0x43c8d0
mov eax, dword [0x46cb70]
push eax
call sub.kernel32.dll_GetProcAddress_1
mov dword [0x46eb84], eax
push 0x43c8e8
mov eax, dword [0x46cb70]
push eax
call sub.kernel32.dll_GetProcAddress_1
mov dword [0x46eb88], eax
push 0x43c904
mov eax, dword [0x46cb70]
push eax
call sub.kernel32.dll_GetProcAddress_1
mov dword [0x46eb8c], eax
push 0x43c910
mov eax, dword [0x46cb70]
push eax
call sub.kernel32.dll_GetProcAddress_1
mov dword [0x46eb90], eax
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x43c825
mov eax, dword [ebp - 4]
push eax
call sub.kernel32.dll_SetErrorMode
ret
pop ebx
pop ecx
pop ebp
ret

Function at 0x4406b0
Capabilities:
Log keystrokes
Log keystrokes via polling

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffefc
push ebx
mov ebx, edx
mov word [ebp - 2], ax
mov eax, ebx
call fcn.00403ee4
push 0
xor eax, eax
mov al, byte [ebp - 2]
push eax
call sub.user32.dll_MapVirtualKeyA
shl eax, 0x10
test eax, eax
je 0x4406ff
push pe_nt_image_headers32
lea edx, [ebp - 0x102]
push edx
push eax
call sub.user32.dll_GetKeyNameTextA
mov eax, ebx
lea edx, [ebp - 0x102]
mov ecx, pe_nt_image_headers32
call fcn.00404154
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x447e3c
Capabilities:
Log keystrokes via polling

Disassembly:
push ebx
push esi
mov esi, eax
mov bl, byte [0x447e8c]
test si, 4
je 0x447e50
or bl, 1
test si, 8
je 0x447e5a
or bl, 4
test si, 1
je 0x447e64
or bl, 8
test si, 2
je 0x447e6e
or bl, 0x10
test si, 0x10
je 0x447e78
or bl, 0x20
push 0x12
call sub.user32.dll_GetKeyState
test ax, ax
jge 0x447e87
or bl, 2
mov eax, ebx
pop esi
pop ebx
ret
Function at 0x447e90
Capabilities:
Log keystrokes via polling

Disassembly:
push ebx
push esi
mov esi, eax
mov bl, byte [0x447ec8]
push 0x10
call sub.user32.dll_GetKeyState
test ax, ax
jge 0x447ea9
or bl, 1
push 0x11
call sub.user32.dll_GetKeyState
test ax, ax
jge 0x447eb8
or bl, 4
test esi, 0x20000000
je 0x447ec3
or bl, 2
mov eax, ebx
pop esi
pop ebx
ret

Function at 0x44e570
Capabilities:
Get keyboard layout

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
test dl, dl
je 0x44e582
add esp, 0xfffffff0
call fcn.00403434
mov byte [ebp - 1], dl
mov ebx, eax
xor edx, edx
mov eax, ebx
call fcn.0041adb0
mov eax, dword [0x46d6dc]
mov dword [eax + 4], ebx
mov dword [eax], 0x44e914
mov eax, dword [0x46d6ec]
mov dword [eax + 4], ebx
mov dword [eax], 0x44e920
mov eax, ebx
call fcn.0044e92c
push 0
call sub.user32.dll_GetKeyboardLayout
mov dword [ebx + 0x3c], eax
mov dl, 1
mov eax, dword [0x411b30]
call fcn.004030f8
mov dword [ebx + 0x4c], eax
mov dl, 1
mov eax, dword [0x411b30]
call fcn.004030f8
mov dword [ebx + 0x50], eax
mov dl, 1
mov eax, dword [0x411b30]
call fcn.004030f8
mov dword [ebx + 0x54], eax
mov dl, 1
mov eax, dword [0x411b30]
call fcn.004030f8
mov dword [ebx + 0x58], eax
mov dl, 1
mov eax, dword [0x411b30]
call fcn.004030f8
mov dword [ebx + 0x7c], eax
push 0
call sub.user32.dll_GetDC
mov esi, eax
push 0x5a
push esi
call sub.gdi32.dll_GetDeviceCaps
mov dword [ebx + 0x40], eax
push esi
push 0
call sub.user32.dll_ReleaseDC
mov eax, dword [ebx + 0x58]
push eax
mov eax, 0x44ad48
push eax
push 0
push 0
mov eax, dword [0x46d928]
mov eax, dword [eax]
call eax
mov dl, 1
mov eax, dword [0x41c7dc]
call fcn.0041dc20
mov dword [ebx + 0x84], eax
mov dl, 1
mov eax, dword [0x41c7dc]
call fcn.0041dc20
mov dword [ebx + 0x88], eax
mov dl, 1
mov eax, dword [0x41c7dc]
call fcn.0041dc20
mov dword [ebx + 0x80], eax
mov eax, ebx
call fcn.0044ed4c
mov eax, dword [ebx + 0x84]
mov dword [eax + 0xc], ebx
mov dword [eax + 8], 0x44ec28
mov eax, dword [ebx + 0x88]
mov dword [eax + 0xc], ebx
mov dword [eax + 8], 0x44ec28
mov eax, dword [ebx + 0x80]
mov dword [eax + 0xc], ebx
mov dword [eax + 8], 0x44ec28
mov eax, ebx
cmp byte [ebp - 1], 0
je 0x44e6bf
call fcn.0040348c
pop dword fs:[0]
add esp, 0xc
mov eax, ebx
pop esi
pop ebx
pop ecx
pop ebp
ret
Function at 0x44ea0c
Capabilities:
Get keyboard layout
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffda0
push ebx
xor edx, edx
mov dword [ebp - 0x260], edx
mov dword [ebp - 4], eax
xor eax, eax
push ebp
push 0x44ebb7
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, dword [ebp - 4]
cmp dword [eax + 0x34], 0
jne 0x44eb98
mov dl, 1
mov eax, dword [0x412194]
call fcn.004030f8
mov edx, dword [ebp - 4]
mov dword [edx + 0x34], eax
mov eax, dword [ebp - 4]
add eax, 0x38
call fcn.00403ee4
lea eax, [ebp - 0x114]
push eax
push 0x40
call sub.user32.dll_GetKeyboardLayoutList
dec eax
test eax, eax
jl 0x44eb87
inc eax
mov dword [ebp - 0x10], eax
lea eax, [ebp - 0x114]
mov dword [ebp - 0x14], eax
mov eax, dword [ebp - 0x14]
mov eax, dword [eax]
call fcn.0043ca18
test al, al
je 0x44eb7a
lea eax, [ebp - 0xc]
push eax
push 0x20019
push 0
push 0
mov eax, dword [ebp - 0x14]
mov eax, dword [eax]
mov dword [ebp - 0x25c], eax
mov byte [ebp - 0x258], 0
lea ecx, [ebp - 0x25c]
mov edx, 0x44ebc8
lea eax, [ebp - 0x254]
call fcn.00408db0
push eax
push 0x80000002
call sub.advapi32.dll_RegOpenKeyExA_1
test eax, eax
jne 0x44eb7a
xor eax, eax
push ebp
push 0x44eb73
push dword fs:[eax]
mov dword fs:[eax], esp
mov dword [ebp - 8], pe_nt_image_headers32
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0x214]
push eax
push 0
push 0
push 0x44ec00
mov eax, dword [ebp - 0xc]
push eax
call sub.advapi32.dll_RegQueryValueExA_1
test eax, eax
jne 0x44eb5c
lea eax, [ebp - 0x260]
lea edx, [ebp - 0x214]
mov ecx, pe_nt_image_headers32
call fcn.00404154
mov edx, dword [ebp - 0x260]
mov eax, dword [ebp - 0x14]
mov ecx, dword [eax]
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x34]
mov ebx, dword [eax]
call dword [ebx + 0x3c]
mov eax, dword [ebp - 0x14]
mov eax, dword [eax]
mov edx, dword [ebp - 4]
cmp eax, dword [edx + 0x3c]
jne 0x44eb5c
mov eax, dword [ebp - 4]
add eax, 0x38
lea edx, [ebp - 0x214]
mov ecx, pe_nt_image_headers32
call fcn.00404154
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x44eb7a
mov eax, dword [ebp - 0xc]
push eax
call sub.advapi32.dll_RegCloseKey_1
ret
add dword [ebp - 0x14], 4
dec dword [ebp - 0x10]
jne 0x44ea7d
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x34]
mov byte [eax + 0x1d], 0
mov dl, 1
call fcn.00416968
mov eax, dword [ebp - 4]
mov ebx, dword [eax + 0x34]
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x44ebbe
lea eax, [ebp - 0x260]
call fcn.00403ee4
ret

Function at 0x44f4ec
Capabilities:
Create thread
Set global application hook

Disassembly:
push ecx
mov eax, dword [0x46ebb4]
cmp byte [eax + 0xa5], 0
jne 0x44f55d
cmp dword [0x46ebcc], 0
jne 0x44f51e
call sub.kernel32.dll_GetCurrentThreadId_1
push eax
push 0
mov eax, 0x44f4a8
push eax
push 3
call sub.user32.dll_SetWindowsHookExA
mov dword [0x46ebcc], eax
cmp dword [0x46ebc8], 0
jne 0x44f539
push 0
push 0
push 0
push 0
call sub.kernel32.dll_CreateEventA
mov dword [0x46ebc8], eax
cmp dword [0x46ebd0], 0
jne 0x44f55d
push esp
push 0
push 0
push 0x44f44c
push 0x3e8
push 0
call sub.kernel32.dll_CreateThread_1
mov dword [0x46ebd0], eax
pop edx
ret
Function at 0x44f654
Capabilities:
Inspect load icon resource

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffefc
push ebx
push esi
test dl, dl
je 0x44f66b
add esp, 0xfffffff0
call fcn.00403434
mov byte [ebp - 1], dl
mov ebx, eax
xor edx, edx
mov eax, ebx
call fcn.0041adb0
mov eax, dword [0x46d900]
cmp word [eax + 2], 0
jne 0x44f693
mov eax, dword [0x46d900]
mov dword [eax + 4], ebx
mov dword [eax], fcn.00450d2c
mov eax, dword [0x46da34]
cmp word [eax + 2], 0
jne 0x44f6ad
mov eax, dword [0x46da34]
mov dword [eax + 4], ebx
mov dword [eax], fcn.00450f24
mov byte [ebx + 0x34], 0
mov dl, 1
mov eax, dword [0x411b30]
call fcn.004030f8
mov dword [ebx + 0x90], eax
mov dl, 1
mov eax, dword [0x411b30]
call fcn.004030f8
mov dword [ebx + 0xa8], eax
xor eax, eax
mov dword [ebx + 0x60], eax
xor eax, eax
mov dword [ebx + 0x84], eax
mov dword [ebx + 0x5c], 0xff000018
mov dword [ebx + 0x78], 0x1f4
mov byte [ebx + 0x7c], 1
xor eax, eax
mov dword [ebx + 0x80], eax
mov dword [ebx + 0x74], 0x9c4
mov byte [ebx + 0x88], 0
mov byte [ebx + 0x9d], 1
mov byte [ebx + 0xb4], 1
mov dl, 1
mov eax, dword [0x41cf8c]
call fcn.00422bd4
mov esi, eax
mov dword [ebx + 0x98], esi
push 0x44f834
mov eax, dword [0x46d794]
mov eax, dword [eax]
push eax
call sub.user32.dll_LoadIconA
mov edx, eax
mov eax, esi
call fcn.00422fa4
mov eax, dword [ebx + 0x98]
mov dword [eax + 0x14], ebx
mov dword [eax + 0x10], 0x4514c4
push pe_nt_image_headers32
lea eax, [ebp - 0x101]
push eax
mov eax, dword [0x46d794]
mov eax, dword [eax]
push eax
call sub.kernel32.dll_GetModuleFileNameA_1
lea eax, [ebp - 0x101]
push eax
lea eax, [ebp - 0x101]
push eax
call sub.user32.dll_OemToCharA
lea eax, [ebp - 0x101]
mov dl, 0x5c
call fcn.0040c534
test eax, eax
je 0x44f7a2
lea edx, [eax + 1]
lea eax, [ebp - 0x101]
call fcn.00408790
lea eax, [ebp - 0x101]
mov dl, 0x2e
call fcn.0040c55c
test eax, eax
je 0x44f7b6
mov byte [eax], 0
lea eax, [ebp - 0x101]
inc eax
push eax
call sub.user32.dll_CharLowerA
lea eax, [ebx + 0x8c]
lea edx, [ebp - 0x101]
mov ecx, pe_nt_image_headers32
call fcn.00404154
mov eax, dword [0x46d588]
cmp byte [eax], 0
jne 0x44f7ea
mov eax, ebx
call fcn.0044f95c
mov byte [ebx + 0x59], 1
mov byte [ebx + 0x5a], 1
mov byte [ebx + 0x5b], 1
mov byte [ebx + 0x9e], 1
xor eax, eax
mov dword [ebx + 0xa0], eax
mov eax, ebx
call fcn.004516a0
mov eax, ebx
call fcn.00452064
mov eax, ebx
cmp byte [ebp - 1], 0
je 0x44f82a
call fcn.0040348c
pop dword fs:[0]
add esp, 0xc
mov eax, ebx
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x44fbdc
Capabilities:
Enumerate gui resources

Disassembly:
push ebx
push esi
add esp, 0xfffffff8
mov ebx, eax
mov eax, dword [0x46ebb4]
cmp dword [eax + 0x30], 0
je 0x44fc86
cmp dword [ebx + 0x94], 0
jne 0x44fc80
mov eax, dword [ebx + 0x30]
mov dword [esp], eax
mov byte [esp + 4], dl
mov eax, esp
push eax
push 0x44fb6c
call sub.user32.dll_EnumWindows
mov eax, dword [ebx + 0x90]
cmp dword [eax + 8], 0
je 0x44fc80
push 3
mov eax, dword [esp + 4]
push eax
call sub.user32.dll_GetWindow
mov esi, eax
mov dword [esp], esi
push 0xffffffffffffffec
push esi
call sub.user32.dll_GetWindowLongA
test al, 8
je 0x44fc46
mov dword [esp], 0xfffffffe
mov eax, dword [ebx + 0x90]
mov esi, dword [eax + 8]
dec esi
cmp esi, 0
jl 0x44fc80
push 0x213
push 0
push 0
push 0
push 0
mov eax, dword [esp + 0x14]
push eax
mov edx, esi
mov eax, dword [ebx + 0x90]
call fcn.004141e8
push eax
call sub.user32.dll_SetWindowPos
dec esi
cmp esi, 0xffffffff
jne 0x44fc55
inc dword [ebx + 0x94]
pop ecx
pop edx
pop esi
pop ebx
ret

Function at 0x4507e8
Capabilities:
Get graphical window text

Disassembly:
push ebx
push esi
add esp, 0xffffff00
mov esi, edx
mov ebx, eax
cmp byte [ebx + 0xa4], 0
je 0x45081d
push pe_nt_image_headers32
lea eax, [esp + 4]
push eax
mov eax, dword [ebx + 0x30]
push eax
call sub.user32.dll_GetWindowTextA
mov ecx, eax
mov edx, esp
mov eax, esi
call fcn.00403fd4
jmp 0x45082a
mov eax, esi
mov edx, dword [ebx + 0x8c]
call fcn.00403f38
add esp, 0x100
pop esi
pop ebx
ret

Function at 0x45187c
Capabilities:
Hide graphical window

Disassembly:
push ebx
push esi
mov ebx, eax
mov esi, dword [ebx + 0x84]
test esi, esi
je 0x4518bd
mov eax, esi
call fcn.0043818c
test al, al
je 0x4518bd
mov eax, dword [ebx + 0x84]
call fcn.00437e88
push eax
call sub.user32.dll_IsWindowVisible
test eax, eax
je 0x4518bd
push 0
mov eax, dword [ebx + 0x84]
call fcn.00437e88
push eax
call sub.user32.dll_ShowWindow
pop esi
pop ebx
ret
Function at 0x45a98c
Capabilities:
Access peb ldr_data
Get kernel32 base address

Disassembly:
push ebp
mov ebp, esp
mov ecx, 8
push 0
push 0
dec ecx
jne 0x45a994
push ecx
push ebx
push esi
push edi
mov ebx, eax
xor eax, eax
push ebp
push 0x45ab86
push dword fs:[eax]
mov dword fs:[eax], esp
mov esi, dword [ebx + 8]
lea ecx, [ebp - 0xc]
mov edx, 0x45ab9c
mov eax, esi
call fcn.0045871c
mov edx, dword [ebp - 0xc]
lea eax, [ebx + 0xc]
call fcn.00403f38
lea ecx, [ebp - 0x10]
mov edx, 0x45abb0
mov eax, esi
call fcn.0045871c
mov edx, dword [ebp - 0x10]
lea eax, [ebx + 0x28]
call fcn.00403f38
lea ecx, [ebp - 0x14]
mov edx, 0x45abc8
mov eax, esi
call fcn.0045871c
mov edx, dword [ebp - 0x14]
lea eax, [ebx + 0x10]
call fcn.00403f38
lea ecx, [ebp - 0x18]
mov edx, 0x45abe4
mov eax, esi
call fcn.0045871c
mov edx, dword [ebp - 0x18]
lea eax, [ebx + 0x14]
call fcn.00403f38
lea ecx, [ebp - 0x1c]
mov edx, 0x45ac00
mov eax, esi
call fcn.0045871c
mov edx, dword [ebp - 0x1c]
lea eax, [ebx + 0x24]
call fcn.00403f38
lea ecx, [ebp - 0x24]
mov edx, 0x45ac18
mov eax, esi
call fcn.0045871c
mov eax, dword [ebp - 0x24]
lea edx, [ebp - 0x20]
call fcn.00407d24
mov eax, dword [ebp - 0x20]
or edx, 0xffffffff
call fcn.0040826c
mov edi, eax
mov dword [ebx + 0x18], edi
test edi, edi
setge al
mov byte [ebx + 0x4c], al
lea ecx, [ebp - 0x28]
mov edx, 0x45ac30
mov eax, esi
call fcn.0045871c
mov eax, dword [ebp - 0x28]
call fcn.00457834
fstp qword [ebx + 0x30]
wait
lea ecx, [ebp - 0x2c]
mov edx, 0x45ac40
mov eax, esi
call fcn.0045871c
mov eax, dword [ebp - 0x2c]
call fcn.00457834
fstp qword [ebx + 0x40]
wait
lea ecx, [ebp - 0x30]
mov edx, 0x45ac58
mov eax, esi
call fcn.0045871c
mov eax, dword [ebp - 0x30]
or edx, 0xffffffff
call fcn.0040826c
inc eax
je 0x45ab29
lea ecx, [ebp - 0x34]
mov edx, 0x45ac58
mov eax, esi
call fcn.0045871c
mov eax, dword [ebp - 0x34]
call fcn.00408230
mov edi, eax
mov eax, edi
mov ecx, 0xe10
cdq
idiv ecx
mov dword [ebp - 8], eax
mov eax, edi
mov ecx, 0xe10
cdq
idiv ecx
mov ecx, edx
mov eax, ecx
push ecx
mov ecx, 0x3c
cdq
idiv ecx
pop ecx
mov dword [ebp - 4], eax
mov eax, ecx
mov ecx, 0x3c
cdq
idiv ecx
mov edi, edx
push 0
mov ecx, edi
mov dx, word [ebp - 4]
mov ax, word [ebp - 8]
call fcn.00409700
fstp qword [ebp - 0x3c]
wait
call fcn.00409a64
fadd qword [ebp - 0x3c]
fstp qword [ebx + 0x38]
wait
jmp 0x45ab44
lea ecx, [ebp - 0x40]
mov edx, 0x45ac58
mov eax, esi
call fcn.0045871c
mov eax, dword [ebp - 0x40]
call fcn.00457834
fstp qword [ebx + 0x38]
wait
lea ecx, [ebp - 0x44]
mov edx, 0x45ac68
mov eax, esi
call fcn.0045871c
mov edx, dword [ebp - 0x44]
lea eax, [ebx + 0x48]
call fcn.00403f38
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x45ab8d
lea eax, [ebp - 0x44]
mov edx, 2
call fcn.00403f08
lea eax, [ebp - 0x34]
mov edx, 0xb
call fcn.00403f08
ret
Function at 0x466e24
Capabilities:
Access peb ldr_data

Disassembly:
push ebp
mov ebp, esp
push 0
push ebx
push esi
push edi
mov edi, ecx
mov esi, edx
xor edx, edx
push ebp
push 0x466e7e
push dword fs:[edx]
mov dword fs:[edx], esp
mov eax, dword [eax + 0x30]
call fcn.00466e14
mov ebx, eax
lea edx, [ebp - 4]
mov eax, edi
call fcn.004563a4
mov edx, dword [ebp - 4]
mov eax, dword [ebx + 0xc]
call fcn.00455fa4
mov edx, dword [esi + 8]
mov eax, dword [ebx + 0x10]
mov ecx, dword [eax]
call dword [ecx + 8]
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x466e85
lea eax, [ebp - 4]
call fcn.00403ee4
ret
Function at 0x4016a0
Capabilities:
Encode data using xor

Disassembly:
push edi
mov edi, eax
shr edi, 2
xor edx, edx
test edi, edi
jle 0x4016dd
push ebx
lea ecx, [ecx]
mov ecx, dword [esi + edx*4]
mov eax, ecx
shl ecx, 0x10
shr eax, 0x10
or eax, ecx
mov ecx, eax
shr ecx, 8
mov ebx, eax
shl ebx, 8
xor ecx, ebx
and ecx, 0xff00ff
shl eax, 8
xor ecx, eax
mov dword [esi + edx*4], ecx
inc edx
cmp edx, edi
jl 0x4016b0
pop ebx
pop edi
ret
Function at 0x403e60
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
sub esp, 8
push ebx
push ebp
push esi
mov esi, dword [esp + 0x20]
xor edx, edx
push edi
xor eax, eax
nop
mov byte [eax + esi], al
inc eax
cmp eax, 0x100
jl 0x403e70
mov edi, dword [esp + 0x20]
mov ebp, dword [esp + 0x1c]
mov byte [esi + 0x100], dl
mov byte [esi + 0x101], dl
mov byte [esp + 0x24], dl
xor bl, bl
lea ecx, [esi + 1]
mov dword [esp + 0x14], 0x40
mov al, byte [ecx - 1]
movzx edx, dl
mov dl, byte [edx + ebp]
add dl, al
add bl, dl
movzx edx, bl
add edx, esi
mov dword [esp + 0x10], edx
mov dl, byte [edx]
mov byte [ecx - 1], dl
mov edx, dword [esp + 0x10]
mov byte [edx], al
mov al, byte [esp + 0x24]
inc al
movzx eax, al
cdq
idiv edi
mov al, byte [ecx]
add ecx, 4
mov byte [esp + 0x24], dl
movzx edx, dl
mov dl, byte [edx + ebp]
add dl, al
add bl, dl
movzx edx, bl
add edx, esi
mov dword [esp + 0x10], edx
mov dl, byte [edx]
mov byte [ecx - 4], dl
mov edx, dword [esp + 0x10]
mov byte [edx], al
mov al, byte [esp + 0x24]
inc al
movzx eax, al
cdq
idiv edi
mov al, byte [ecx - 3]
mov byte [esp + 0x24], dl
movzx edx, dl
mov dl, byte [edx + ebp]
add dl, al
add bl, dl
movzx edx, bl
add edx, esi
mov dword [esp + 0x10], edx
mov dl, byte [edx]
mov byte [ecx - 3], dl
mov edx, dword [esp + 0x10]
mov byte [edx], al
mov al, byte [esp + 0x24]
inc al
movzx eax, al
cdq
idiv edi
mov al, byte [ecx - 2]
mov byte [esp + 0x24], dl
movzx edx, dl
mov dl, byte [edx + ebp]
add dl, al
add bl, dl
movzx edx, bl
add edx, esi
mov dword [esp + 0x10], edx
mov dl, byte [edx]
mov byte [ecx - 2], dl
mov edx, dword [esp + 0x10]
mov byte [edx], al
mov al, byte [esp + 0x24]
inc al
movzx eax, al
cdq
idiv edi
dec dword [esp + 0x14]
mov byte [esp + 0x24], dl
jne 0x403ea0
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret

Function at 0x403f80
Capabilities:
Encrypt data using rc4 prga

Disassembly:
mov ecx, dword [esp + 8]
push ebx
push esi
mov esi, dword [esp + 0x14]
mov dl, byte [esi + 0x100]
mov bl, byte [esi + 0x101]
xor eax, eax
test ecx, ecx
jle 0x403ffb
push ebp
push edi
jmp 0x403fa4
mov bl, byte [esp + 0x1c]
inc dl
movzx ecx, dl
lea edi, [ecx + esi]
mov cl, byte [edi]
add bl, cl
mov byte [esp + 0x1c], bl
movzx ebx, bl
lea ebp, [ebx + esi]
mov bl, byte [ebp]
mov byte [edi], bl
xor ebx, ebx
mov byte [ebp], cl
mov bl, byte [edi]
mov edi, dword [esp + 0x14]
add ebx, ecx
and ebx, 0xff
mov cl, byte [ebx + esi]
mov bl, byte [eax + edi]
xor bl, cl
mov ecx, dword [esp + 0x18]
mov byte [eax + edi], bl
inc eax
cmp eax, ecx
jl 0x403fa0
pop edi
mov byte [esi + 0x100], dl
mov dl, byte [esp + 0x18]
pop ebp
mov byte [esi + 0x101], dl
pop esi
pop ebx
ret
mov byte [esi + 0x101], bl
mov byte [esi + 0x100], dl
pop esi
pop ebx
ret
Function at 0x4040a0
Capabilities:
Create tcp socket
Create udp socket
Initialize winsock library
Set socket configuration

Disassembly:
sub esp, 0x1a0
push esi
mov esi, dword [esp + 0x1b8]
lea eax, [esp + 0x14]
push eax
push 0x101
mov dword [esi], 0xffffffff
call sub.WS2_32.dll_WSAStartup
test eax, eax
je 0x4040d2
or eax, 0xffffffff
pop esi
add esp, 0x1a0
ret
push 0
push 1
push 2
call sub.WS2_32.dll_socket
cmp eax, 0xffffffff
mov dword [esi], eax
jne 0x4040f6
call fcn.0040d8de
mov eax, 0xfffffffe
pop esi
add esp, 0x1a0
ret
mov ecx, dword [esp + 0x1ac]
test ecx, ecx
je 0x404138
lea ecx, [esp + 0x1ac]
push ecx
push 0x8004667e
push eax
call sub.WS2_32.dll_ioctlsocket
test eax, eax
je 0x404138
mov edx, dword [esi]
push edx
call sub.WS2_32.dll_closesocket
call fcn.0040d8de
mov dword [esi], 0xffffffff
mov eax, 0xfffffffe
pop esi
add esp, 0x1a0
ret
cmp dword [esp + 0x1a8], 1
jne 0x4041d3
mov eax, dword [esp + 0x1b4]
push eax
mov word [esp + 8], 2
call sub.WS2_32.dll_htons
push 0
mov word [esp + 0xa], ax
call sub.WS2_32.dll_htonl
mov edx, dword [esi]
push 0x10
lea ecx, [esp + 8]
push ecx
push edx
mov dword [esp + 0x14], eax
call sub.WS2_32.dll_bind
cmp eax, 0xffffffff
jne 0x40419e
mov eax, dword [esi]
push eax
call sub.WS2_32.dll_closesocket
call fcn.0040d8de
mov dword [esi], 0xffffffff
mov eax, 0xfffffff9
pop esi
add esp, 0x1a0
ret
mov ecx, dword [esp + 0x1b0]
mov edx, dword [esi]
push ecx
push edx
call sub.WS2_32.dll_listen
cmp eax, 0xffffffff
jne 0x4041d3
mov eax, dword [esi]
push eax
call sub.WS2_32.dll_closesocket
call fcn.0040d8de
mov dword [esi], 0xffffffff
mov eax, 0xfffffff8
pop esi
add esp, 0x1a0
ret
xor eax, eax
pop esi
add esp, 0x1a0
ret
Function at 0x4041e0
Capabilities:
Connect socket
Get socket status
Resolve dns

Disassembly:
sub esp, 0x120
xor eax, eax
mov dword [esp + 0xc], eax
mov dword [esp + 0x10], eax
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], eax
cmp dword [esp + 0x124], 1
push esi
push edi
mov dword [esp + 0x10], 0x10
jne 0x4042df
mov edi, dword [esp + 0x144]
test edi, edi
je 0x40442d
mov esi, dword [esp + 0x130]
lea ecx, [esp + 0x10]
push ecx
lea edx, [esp + 0x18]
push edx
push esi
call sub.WS2_32.dll_accept
cmp eax, 0xffffffff
mov dword [edi], eax
jne 0x404422
call sub.WS2_32.dll_WSAGetLastError
cmp eax, 0x2733
jne 0x4042d1
mov eax, dword [esp + 0x134]
test eax, eax
jle 0x404414
lea edx, [esp + 0x24]
xor ecx, ecx
mov dword [esp + 8], ecx
push edx
push esi
mov dword [esp + 0x14], ecx
mov dword [esp + 0x10], eax
mov dword [esp + 0x30], esi
mov dword [esp + 0x2c], 1
call sub.WS2_32.dll___WSAFDIsSet
lea eax, [esp + 8]
push eax
push 0
push 0
lea ecx, [esp + 0x30]
push ecx
push 0
call sub.WS2_32.dll_select
cmp eax, 1
jne 0x404406
lea edx, [esp + 0x24]
push edx
push esi
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x404406
lea eax, [esp + 0x10]
push eax
lea ecx, [esp + 0x18]
push ecx
push esi
call sub.WS2_32.dll_accept
cmp eax, 0xffffffff
mov dword [edi], eax
jne 0x404422
pop edi
mov eax, 0xfffffff6
pop esi
add esp, 0x120
ret
mov eax, dword [esp + 0x138]
test eax, eax
mov word [esp + 0x14], 2
je 0x404310
push eax
call sub.WS2_32.dll_inet_addr
cmp eax, 0xffffffff
jne 0x40430a
pop edi
mov eax, 0xfffffffc
pop esi
add esp, 0x120
ret
mov dword [esp + 0x18], eax
jmp 0x404352
mov eax, dword [esp + 0x13c]
test eax, eax
je 0x40442d
push eax
call sub.WS2_32.dll_gethostbyname
test eax, eax
jne 0x404337
pop edi
mov eax, 0xfffffffb
pop esi
add esp, 0x120
ret
movsx ecx, word [eax + 0xa]
mov edx, dword [eax + 0xc]
mov esi, dword [edx]
mov eax, ecx
shr ecx, 2
lea edi, [esp + 0x18]
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x140]
push ecx
call sub.WS2_32.dll_htons
mov esi, dword [esp + 0x130]
push 0x10
lea edx, [esp + 0x18]
push edx
push esi
mov word [esp + 0x22], ax
call sub.WS2_32.dll_connect
cmp eax, 0xffffffff
jne 0x404422
call sub.WS2_32.dll_WSAGetLastError
cmp eax, 0x2733
je 0x4043ad
cmp eax, 0x2735
je 0x4043ad
cmp eax, 0x2748
je 0x404422
pop edi
mov eax, 0xfffffffa
pop esi
add esp, 0x120
ret
mov eax, dword [esp + 0x134]
test eax, eax
jle 0x404414
lea edx, [esp + 0x24]
xor ecx, ecx
mov dword [esp + 8], ecx
push edx
push esi
mov dword [esp + 0x14], ecx
mov dword [esp + 0x10], eax
mov dword [esp + 0x30], esi
mov dword [esp + 0x2c], 1
call sub.WS2_32.dll___WSAFDIsSet
lea eax, [esp + 8]
push eax
push 0
lea ecx, [esp + 0x2c]
push ecx
push 0
push 0
call sub.WS2_32.dll_select
cmp eax, 1
jne 0x404406
lea edx, [esp + 0x24]
push edx
push esi
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
jne 0x404422
pop edi
mov eax, 0xfffffff1
pop esi
add esp, 0x120
ret
pop edi
mov eax, 0xfffffff7
pop esi
add esp, 0x120
ret
pop edi
xor eax, eax
pop esi
add esp, 0x120
ret
pop edi
mov eax, 0xfffffffd
pop esi
add esp, 0x120
ret