joyce8/EMBER2024-capa huggingface dataset:
Function at 0x43f240
Capabilities:
Access peb ldr_data
Get number of processors

Disassembly:
push 0xffffffffffffffff
push 0x477f18
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x2c
push esi
mov esi, ecx
lea eax, [esp + 0xc]
mov ecx, dword [esi + 0x1c]
push eax
push ecx
call dword [sym.imp.USER32.dll_GetClientRect]
push 0
lea ecx, [esp + 0x20]
call fcn.0046ef22
mov eax, dword [esi + 0xd0]
lea edx, [esp + 0x1c]
push eax
push eax
push edx
mov dword [esp + 0x44], 0
call fcn.0043ebe0
mov eax, dword [esi + 0x4c]
mov ecx, dword [esi + 0x48]
add eax, 0x64
add esp, 0xc
add ecx, 0x64
mov dword [esp + 8], eax
lea eax, [esp + 4]
mov dword [esp + 4], ecx
push eax
lea ecx, [esp + 0x20]
call fcn.0046ee50
mov ecx, dword [esp + 4]
mov eax, dword [esp + 0x14]
mov edx, dword [esp + 0xc]
sub ecx, eax
add ecx, edx
mov eax, 0x88888889
imul ecx
add edx, ecx
push 1
sar edx, 4
mov ecx, edx
shr ecx, 0x1f
lea eax, [edx + ecx + 1]
xor edx, edx
test eax, eax
setl dl
dec edx
mov ecx, esi
and eax, edx
push eax
push 0
push 0
call fcn.0046b63a
mov ecx, dword [esp + 0x10]
mov eax, dword [esp + 0x18]
mov edx, dword [esp + 8]
sub ecx, eax
add ecx, edx
mov eax, 0x88888889
imul ecx
add edx, ecx
xor ecx, ecx
sar edx, 4
mov eax, edx
push 1
shr eax, 0x1f
lea eax, [edx + eax + 1]
test eax, eax
setl cl
dec ecx
and eax, ecx
mov ecx, esi
push eax
push 0
push 1
call fcn.0046b63a
push 1
push 0
push 0
mov ecx, esi
call fcn.0046b5e2
push 1
push 0
push 1
mov ecx, esi
call fcn.0046b5e2
lea ecx, [esp + 0x1c]
mov dword [esp + 0x38], 0xffffffff
call fcn.0046ef94
mov ecx, dword [esp + 0x30]
pop esi
mov dword fs:[0], ecx
add esp, 0x38
ret

Function at 0x43f3c0
Capabilities:
Get number of processors

Disassembly:
push 0xffffffffffffffff
push 0x477f38
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x2c
push esi
mov esi, ecx
push 0
lea ecx, [esp + 0x20]
call fcn.0046ef22
push 0x3e8
lea eax, [esp + 0x20]
push 0x3e8
push eax
mov dword [esp + 0x44], 0
call fcn.0043ebe0
mov ecx, dword [esi + 0x48]
mov eax, dword [esi + 0x4c]
add ecx, 0x64
add esp, 0xc
mov dword [esp + 4], ecx
lea ecx, [esp + 4]
add eax, 0x96
push ecx
lea ecx, [esp + 0x20]
mov dword [esp + 0xc], eax
call fcn.0046ee50
mov eax, dword [esi + 0x1c]
lea edx, [esp + 0xc]
push edx
push eax
call dword [sym.imp.USER32.dll_GetClientRect]
mov eax, dword [esp + 0x18]
mov edx, dword [esp + 0x10]
sub eax, edx
lea eax, [eax + eax*4]
lea eax, [eax + eax*4]
lea eax, [eax + eax*4]
shl eax, 3
cdq
idiv dword [esp + 8]
mov edx, dword [esp + 0xc]
mov ecx, eax
mov eax, dword [esp + 0x14]
sub eax, edx
lea eax, [eax + eax*4]
lea eax, [eax + eax*4]
lea eax, [eax + eax*4]
shl eax, 3
cdq
idiv dword [esp + 4]
cmp dword [esp + 0x44], 1
jne 0x43f484
cmp dword [esp + 0x40], 1
jne 0x43f482
cmp ecx, eax
jge 0x43f484
mov eax, ecx
cmp eax, 0xc8
jge 0x43f490
mov eax, 0xc8
mov ecx, esi
mov dword [esi + 0xd0], eax
call fcn.0043f240
mov ecx, dword [esi + 0x1c]
push 1
push 0
push ecx
call dword [sym.imp.USER32.dll_InvalidateRect]
lea ecx, [esp + 0x1c]
mov dword [esp + 0x38], 0xffffffff
call fcn.0046ef94
mov ecx, dword [esp + 0x30]
pop esi
mov dword fs:[0], ecx
add esp, 0x38
ret 8
Function at 0x43fc10
Capabilities:
Access peb ldr_data
Get number of processors

Disassembly:
push 0xffffffffffffffff
push 0x477fa3
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
push ecx
push ebp
push esi
mov esi, ecx
push edi
mov dword [esp + 0xc], esi
call fcn.00469a5a
lea edi, [esi + 0x64]
mov dword [esp + 0x18], 0
mov dword [edi + 4], 0
mov dword [edi], vtable.CBrush.0
mov eax, dword [esp + 0x2c]
mov ebp, dword [esp + 0x24]
mov ecx, dword [esp + 0x30]
mov dword [esi + 0x3c], eax
mov eax, ebp
mov dword [esi], method.CEdit.virtual_0
mov dword [esi + 0x40], ecx
mov dword [esi + 0x44], 0
mov ecx, dword [eax]
lea edx, [esi + 0x48]
mov byte [esp + 0x18], 1
mov dword [edx], ecx
mov ecx, dword [eax + 4]
mov dword [edx + 4], ecx
mov ecx, dword [eax + 8]
mov dword [edx + 8], ecx
mov eax, dword [eax + 0xc]
mov ecx, dword [esp + 0x40]
mov dword [edx + 0xc], eax
mov eax, dword [esp + 0x44]
push eax
mov dword [esi + 0x5c], ecx
mov dword [esi + 0x60], eax
call dword [sym.imp.GDI32.dll_CreateSolidBrush]
push eax
mov ecx, edi
call fcn.0046f1ca
mov edx, dword [esp + 0x28]
mov eax, dword [esp + 0x20]
push edx
push eax
push ebp
push 0x50800044
mov ecx, esi
call fcn.00470722
test eax, eax
je 0x43fd2c
mov ecx, dword [esp + 0x3c]
call fcn.0046f1f7
mov ecx, dword [esi + 0x1c]
mov ebp, dword [sym.imp.USER32.dll_SendMessageA]
push 0
push eax
push 0x30
push ecx
mov dword [esi + 0x58], eax
call ebp
mov edi, dword [esp + 0x34]
test edi, edi
je 0x43fcf0
push edi
mov ecx, esi
call fcn.0046c7b9
mov ecx, esi
call fcn.0043fe90
cmp dword [esp + 0x38], 1
jne 0x43fd25
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
mov edx, dword [esi + 0x1c]
push 0xffffffffffffffff
not ecx
dec ecx
push ecx
push 0xb1
push edx
call ebp
mov eax, dword [esi + 0x1c]
push 0
push 0
push 0xb7
push eax
call ebp
mov ecx, esi
call fcn.0046c923
mov ecx, dword [esp + 0x10]
mov eax, esi
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
add esp, 0x10
ret 0x28
Function at 0x442760
Capabilities:
Check for software breakpoints

Disassembly:
push esi
mov esi, dword [esp + 8]
cmp dword [esi + 0x10], 0xca
jne 0x442793
push esi
call fcn.00445850
mov eax, dword [esi + 0x40]
add esp, 4
test eax, eax
je 0x44278c
mov dword [esi + 0x10], 0xcf
mov eax, 1
pop esi
ret
mov dword [esi + 0x10], 0xcb
mov eax, dword [esi + 0x10]
cmp eax, 0xcb
jne 0x442819
mov eax, dword [esi + 0x1b0]
mov ecx, dword [eax + 0x10]
test ecx, ecx
je 0x442802
mov eax, dword [esi + 8]
test eax, eax
je 0x4427b7
push esi
call dword [eax]
add esp, 4
mov ecx, dword [esi + 0x1b0]
push esi
call dword [ecx]
add esp, 4
test eax, eax
je 0x4427fe
cmp eax, 2
je 0x442802
mov ecx, dword [esi + 8]
test ecx, ecx
je 0x4427aa
cmp eax, 3
je 0x4427dd
cmp eax, 1
jne 0x4427aa
mov eax, dword [ecx + 4]
inc eax
mov dword [ecx + 4], eax
mov eax, dword [esi + 8]
mov ecx, dword [eax + 8]
mov edx, dword [eax + 4]
cmp edx, ecx
jl 0x4427aa
mov edx, dword [esi + 0x13c]
add edx, ecx
mov dword [eax + 8], edx
jmp 0x4427aa
xor eax, eax
pop esi
ret
mov eax, dword [esi + 0x90]
push esi
mov dword [esi + 0x98], eax
call fcn.00442840
add esp, 4
pop esi
ret
cmp eax, 0xcc
je 0x442828
mov ecx, dword [esi]
push esi
call dword [ecx]
add esp, 4
push esi
call fcn.00442840
add esp, 4
pop esi
ret

Function at 0x46a850
Capabilities:
Get graphical window text

Disassembly:
push esi
mov esi, ecx
mov ecx, dword [esi + 0x38]
test ecx, ecx
jne 0x46a888
push dword [esi + 0x1c]
call dword [sym.imp.USER32.dll_GetWindowTextLengthA]
lea ecx, [eax + 1]
push ecx
mov ecx, dword [esp + 0xc]
push eax
call fcn.00468904
push eax
push dword [esi + 0x1c]
call dword [sym.imp.USER32.dll_GetWindowTextA]
mov ecx, dword [esp + 8]
push 0xffffffffffffffff
call fcn.004688dc
jmp 0x46a894
mov eax, dword [ecx]
push dword [esp + 8]
call dword [eax + 0x88]
pop esi
ret 4

Function at 0x46bf42
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 0x46bf84
call fcn.00471c24
mov esi, dword [eax + 0xc]
push 0xf0
push dword [esp + 0x14]
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
cmp eax, edi
je 0x46bf84
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
cmp eax, edi
jne 0x46bf7b
xor eax, eax
jmp 0x46bf8c
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov edi, eax
push edi
mov ecx, ebx
call fcn.0046bf92
pop edi
pop esi
pop ebx
ret 4

Function at 0x472154
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 0x472182
push dword [esi]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x4721a0
push dword [esp + 0xc]
mov ecx, esi
push eax
call fcn.004720ba
jmp 0x4721a0
mov eax, dword [esi + 0x14]
test eax, eax
je 0x4721a0
push edi
push dword [esp + 0x10]
mov edi, dword [eax + 4]
mov ecx, esi
push eax
call fcn.004720ba
test edi, edi
mov eax, edi
jne 0x47218a
pop edi
push ebx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop esi
pop ebx
ret 8
Function at 0x4014a0
Capabilities:
Identify system language via api

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x48
call dword [sym.imp.KERNEL32.dll_GetUserDefaultUILanguage]
mov word [ebp - 0x20], ax
movzx eax, word [ebp - 0x20]
cmp eax, 0x804
je 0x4014c7
movzx ecx, word [ebp - 0x20]
cmp ecx, 0x404
jne 0x4014c9
jmp 0x4014d0
xor eax, eax
jmp 0x4015b0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
push 0x401110
push 0xe
call dword [sym.imp.USER32.dll_SetWindowsHookExA]
mov dword [0x411c90], eax
cmp dword [0x411c90], 0
jne 0x40150a
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.err:__d_n
call fcn.004028d2
add esp, 8
push 0
push 0
push 0
lea edx, [ebp - 0x1c]
push edx
call dword [sym.imp.USER32.dll_GetMessageA]
test eax, eax
je 0x401534
lea eax, [ebp - 0x1c]
push eax
call dword [sym.imp.USER32.dll_TranslateMessage]
lea ecx, [ebp - 0x1c]
push ecx
call dword [sym.imp.USER32.dll_DispatchMessageA]
jmp 0x40150a
mov edx, dword [0x411c90]
push edx
call dword [sym.imp.USER32.dll_UnhookWindowsHookEx]
xor eax, eax
mov dword [ebp - 0x48], eax
mov dword [ebp - 0x44], eax
mov dword [ebp - 0x40], eax
mov dword [ebp - 0x3c], eax
mov dword [ebp - 0x38], eax
mov dword [ebp - 0x34], eax
mov dword [ebp - 0x30], eax
mov dword [ebp - 0x2c], eax
mov dword [ebp - 0x28], eax
mov dword [ebp - 0x24], eax
mov ecx, dword [ebp + 8]
mov dword [ebp - 0x38], ecx
lea edx, [ebp - 0x48]
push edx
call dword [sym.imp.USER32.dll_RegisterClassA]
push 0
mov eax, dword [ebp + 8]
push eax
push 0
push 0
push 0x12c
push 0x190
push connect
push connect
push 0xcf0000
push 0x40e218
push str.Window
push 0
call dword [sym.imp.USER32.dll_CreateWindowExA]
mov dword [0x411c94], eax
mov eax, 1
mov esp, ebp
pop ebp
ret 0x10

Function at 0x406f70
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x410430]
jne 0x406f7a
repz ret
jmp fcn.004090a4
Function at 0x4076be
Capabilities:
Link many functions at runtime

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [0x410430]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
mov dword [ebp - 0x20], eax
mov eax, dword [ebp + 0xc]
push esi
push edi
mov dword [ebp - 0x1c], eax
call fcn.00405624
and dword [ebp - 0x14], 0
cmp dword [0x411948], 0
mov dword [ebp - 0x18], eax
jne 0x407771
push str.USER32.DLL
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov ebx, eax
test ebx, ebx
je 0x407819
mov edi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.MessageBoxW
push ebx
call edi
test eax, eax
je 0x407819
mov esi, dword [sym.imp.KERNEL32.dll_EncodePointer]
push eax
call esi
push str.GetActiveWindow
push ebx
mov dword [0x411948], eax
call edi
push eax
call esi
push str.GetLastActivePopup
push ebx
mov dword [0x41194c], eax
call edi
push eax
call esi
push str.GetUserObjectInformationW
push ebx
mov dword [0x411950], eax
call edi
push eax
call esi
mov dword [0x411958], eax
test eax, eax
je 0x407771
push str.GetProcessWindowStation
push ebx
call edi
push eax
call esi
mov dword [0x411954], eax
mov eax, dword [0x411954]
mov ecx, dword [ebp - 0x18]
mov esi, dword [sym.imp.KERNEL32.dll_DecodePointer]
cmp eax, ecx
je 0x4077ca
cmp dword [0x411958], ecx
je 0x4077ca
push eax
call esi
push dword [0x411958]
mov edi, eax
call esi
mov ebx, eax
test edi, edi
je 0x4077ca
test ebx, ebx
je 0x4077ca
call edi
test eax, eax
je 0x4077c1
lea ecx, [ebp - 0x24]
push ecx
push 0xc
lea ecx, [ebp - 0x10]
push ecx
push 1
push eax
call ebx
test eax, eax
je 0x4077c1
test byte [ebp - 8], 1
jne 0x4077ca
or dword [ebp + 0x10], 0x200000
jmp 0x4077fd
mov eax, dword [0x41194c]
cmp eax, dword [ebp - 0x18]
je 0x4077fd
push eax
call esi
test eax, eax
je 0x4077fd
call eax
mov dword [ebp - 0x14], eax
test eax, eax
je 0x4077fd
mov eax, dword [0x411950]
cmp eax, dword [ebp - 0x18]
je 0x4077fd
push eax
call esi
test eax, eax
je 0x4077fd
push dword [ebp - 0x14]
call eax
mov dword [ebp - 0x14], eax
push dword [0x411948]
call esi
test eax, eax
je 0x407819
push dword [ebp + 0x10]
push dword [ebp - 0x1c]
push dword [ebp - 0x20]
push dword [ebp - 0x14]
call eax
jmp 0x40781b
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00406f70
leave
ret
Function at 0x710c81
Capabilities:
Encode data using xor

Disassembly:
sub esp, 4
mov dword [esp], 0x7109ec
pop ecx
and ebx, edx
or ebx, edx
call fcn.00710cbb
and ebx, ebx
mov edx, ebx
dec ebx
xor dword [edi], ecx
and edx, edx
mov ebx, edx
dec edx
inc edi
mov edx, 0x76e11d18
sub edx, 1
mov edx, 0xa99b3532
cmp edi, esi
jne fcn.00710c81
add edx, edx
ret
Function at 0x4011b0
Capabilities:
Check os version

Disassembly:
sub esp, 0x9c
push esi
mov esi, dword [sym.imp.KERNEL32.dll_GetVersionExA]
push edi
mov ecx, 0x27
xor eax, eax
lea edi, [esp + 8]
rep stosd dword es:[edi], eax
lea eax, [esp + 8]
mov dword [esp + 8], 0x9c
push eax
call esi
mov edi, eax
test edi, edi
jne 0x4011f7
lea ecx, [esp + 8]
mov dword [esp + 8], 0x94
push ecx
call esi
test eax, eax
je 0x40128d
mov eax, dword [esp + 0x18]
dec eax
je 0x401258
dec eax
jne 0x40128d
mov eax, dword [esp + 0xc]
cmp eax, 4
ja 0x40121c
pop edi
mov eax, 3
pop esi
add esp, 0x9c
ret
mov ecx, dword [esp + 0x10]
cmp eax, 5
jne 0x401237
test ecx, ecx
jne 0x401237
pop edi
mov eax, 4
pop esi
add esp, 0x9c
ret
test edi, edi
je 0x40128d
cmp byte [esp + 0xa2], 1
jne 0x40128d
cmp eax, 5
jne 0x40128d
cmp ecx, 1
jne 0x40128d
pop edi
pop esi
add esp, 0x9c
ret
cmp dword [esp + 0xc], 4
jne 0x40128d
mov eax, dword [esp + 0x10]
test eax, eax
je 0x40126c
cmp eax, 0xa
jne 0x40127a
pop edi
mov eax, 1
pop esi
add esp, 0x9c
ret
cmp eax, 0x5a
jne 0x40128d
pop edi
mov eax, 2
pop esi
add esp, 0x9c
ret
pop edi
xor eax, eax
pop esi
add esp, 0x9c
ret
Function at 0x401ec0
Capabilities:
Query or enumerate registry value

Disassembly:
sub esp, 0x10
lea eax, [esp]
mov dword [esp], 0
push eax
push str.SoftwareTopDomain
push reloc.WSOCK32.dll_bind
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
test eax, eax
je 0x401eeb
or eax, 0xffffffff
add esp, 0x10
ret
lea ecx, [esp + 4]
push esi
lea edx, [esp + 0xc]
push ecx
mov ecx, dword [esp + 8]
lea eax, [esp + 0x14]
push edx
push eax
push 0
push str.ELCLANG
push ecx
mov dword [esp + 0x20], 4
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov edx, dword [esp + 4]
mov esi, eax
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test esi, esi
pop esi
je 0x401f2e
or eax, 0xffffffff
add esp, 0x10
ret
mov eax, dword [esp + 8]
add esp, 0x10
ret

Function at 0x401f40
Capabilities:
Query or enumerate registry value

Disassembly:
push esi
mov esi, dword [esp + 0xc]
push edi
mov edi, dword [esp + 0xc]
push 0x40c1f4
push 0x20019
push 0
push esi
push edi
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
je 0x401f84
push 0x40bbcc
push 0x40c1f4
push 0x40bbc0
push 0xf003f
push 0
push 0
push 0
push esi
push edi
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
mov ecx, dword [esp + 0x18]
lea eax, [esp + 0x10]
push eax
mov eax, dword [esp + 0x18]
lea edx, [esp + 0x10]
push ecx
mov ecx, dword [0x40c1f4]
push edx
push 0
push eax
push ecx
mov dword [esp + 0x28], 0x104
mov dword [esp + 0x24], 1
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov edx, dword [0x40c1f4]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
xor eax, eax
pop esi
ret

Function at 0x401fd0
Capabilities:
Query or enumerate registry value

Disassembly:
push esi
mov esi, dword [esp + 0xc]
push edi
mov edi, dword [esp + 0xc]
push 0x40c1f4
push 0x20019
push 0
push esi
push edi
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
je 0x402014
push 0x40bbcc
push 0x40c1f4
push 0x40bbc0
push 0xf003f
push 0
push 0
push 0
push esi
push edi
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
mov ecx, dword [esp + 0x18]
mov eax, 4
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], eax
lea eax, [esp + 0x10]
lea edx, [esp + 0xc]
push eax
mov eax, dword [esp + 0x18]
push ecx
mov ecx, dword [0x40c1f4]
push edx
push 0
push eax
push ecx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov edx, dword [0x40c1f4]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
xor eax, eax
pop esi
ret
Function at 0x402060
Capabilities:
Set registry value

Disassembly:
sub esp, 0x10
push ebp
push esi
mov esi, dword [esp + 0x20]
push edi
mov edi, dword [esp + 0x20]
push 0x40c1f4
push 0x20006
push 0
push esi
push edi
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
je 0x4020a8
push 0x40bbcc
push 0x40c1f4
push 0x40bbc0
push 0xf003f
push 0
push 0
push 0
push esi
push edi
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
mov al, byte [esp + 0x24]
mov edi, 0x410e3c
mov byte [esp + 0xc], al
or ecx, 0xffffffff
xor eax, eax
push 1
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov dword [esp + 0x14], 0
mov ebp, ecx
lea ecx, [esp + 0x10]
push ebp
mov dword [esp + 0x1c], 0
mov dword [esp + 0x20], 0
call fcn.004027b0
test al, al
je 0x40210e
mov edi, dword [esp + 0x10]
mov ecx, ebp
mov edx, ecx
mov esi, 0x410e3c
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov eax, dword [esp + 0x10]
mov dword [esp + 0x14], ebp
mov byte [eax + ebp], 0
mov ecx, dword [esp + 0x14]
mov edx, dword [esp + 0x2c]
mov eax, dword [esp + 0x28]
push ecx
mov ecx, dword [0x40c1f4]
push edx
push 1
push 0
push eax
push ecx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov edx, dword [0x40c1f4]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [esp + 0x10]
pop edi
pop esi
pop ebp
test ecx, ecx
je 0x402166
mov al, byte [ecx - 1]
test al, al
je 0x40215c
cmp al, 0xff
je 0x40215c
dec al
mov byte [ecx - 1], al
xor eax, eax
add esp, 0x10
ret
dec ecx
push ecx
call fcn.00402ce2
add esp, 4
xor eax, eax
add esp, 0x10
ret

Function at 0x402170
Capabilities:
Set registry value

Disassembly:
push esi
mov esi, dword [esp + 0xc]
push edi
mov edi, dword [esp + 0xc]
push 0x40c1f4
push 0x20006
push 0
push esi
push edi
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
je 0x4021b4
push 0x40bbcc
push 0x40c1f4
push 0x40bbc0
push 0xf003f
push 0
push 0
push 0
push esi
push edi
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x14]
mov edx, dword [0x40c1f4]
push 4
push eax
push 4
push 0
push ecx
push edx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov eax, dword [0x40c1f4]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
xor eax, eax
pop esi
ret
Function at 0x402a2a
Capabilities:
Initialize winsock library

Disassembly:
mov ecx, 0x40c228
jmp 0x402a20
sub esp, 0x190
lea eax, [esp]
push esi
mov esi, ecx
push eax
push 0x202
mov dword [esi], 0x409188
call sub.WSOCK32.dll_WSAStartup
xor eax, eax
mov dword [esi + 8], eax
mov dword [esi + 4], eax
mov eax, esi
pop esi
add esp, 0x190
ret

Function at 0x402a80
Capabilities:
Create udp socket

Disassembly:
push esi
push 0
push 2
mov esi, ecx
push 2
call sub.WSOCK32.dll_socket
cmp eax, 0xffffffff
mov dword [esi + 8], eax
jne 0x402aa4
call sub.WSOCK32.dll_WSAGetLastError
mov dword [esi + 4], eax
xor eax, eax
pop esi
ret 8
mov ecx, dword [esp + 0xc]
mov eax, dword [esp + 8]
push edi
lea edi, [esi + 0xc]
push ecx
mov dword [esi + 0x10], eax
mov word [edi], 2
call sub.WSOCK32.dll_htons
mov edx, dword [esi + 8]
push 0x10
push edi
push edx
mov word [esi + 0xe], ax
call sub.WSOCK32.dll_bind
cmp eax, 0xffffffff
pop edi
jne 0x402ae2
call sub.WSOCK32.dll_WSAGetLastError
mov dword [esi + 4], eax
xor eax, eax
pop esi
ret 8
mov eax, 1
pop esi
ret 8

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

Disassembly:
push ecx
push ebx
push ebp
mov ebp, ecx
push esi
push edi
mov eax, dword [ebp + 8]
test eax, eax
jne 0x402b08
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
pop ecx
ret 0x10
mov esi, dword [esp + 0x24]
mov ebx, dword [esp + 0x1c]
test ebx, ebx
mov dword [esp + 0x10], 0x10
mov dword [esi], 0
je 0x402b60
mov edi, dword [esp + 0x18]
mov edx, dword [esi]
mov eax, ebx
sub eax, edx
cmp eax, 0x5a0
jle 0x402b38
mov eax, 0x5a0
mov edx, dword [esp + 0x20]
lea ecx, [esp + 0x10]
push ecx
push edx
push 0
push eax
mov eax, dword [ebp + 8]
push edi
push eax
call sub.WSOCK32.dll_recvfrom
cmp eax, 0xffffffff
je 0x402b6d
mov ecx, dword [esi]
add edi, eax
add ecx, eax
cmp ecx, ebx
mov dword [esi], ecx
jne 0x402b26
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
pop ecx
ret 0x10
call sub.WSOCK32.dll_WSAGetLastError
pop edi
mov dword [ebp + 4], eax
pop esi
pop ebp
xor eax, eax
pop ebx
pop ecx
ret 0x10

Function at 0x402ba0
Capabilities:
Set socket configuration

Disassembly:
sub esp, 8
push esi
mov esi, ecx
mov ecx, dword [esi + 8]
test ecx, ecx
jne 0x402bb6
xor eax, eax
pop esi
add esp, 8
ret 4
mov eax, dword [esp + 0x10]
mov edx, dword [esi + 0x10]
mov dword [esi + 0x20], eax
mov dword [esp + 4], eax
lea eax, [esp + 8]
push 0x10
push eax
push 2
push 0
push ecx
mov word [esi + 0x1c], 2
mov dword [esp + 0x1c], edx
call sub.WSOCK32.dll_setsockopt
cmp eax, 0xffffffff
jne 0x402bf5
call sub.WSOCK32.dll_WSAGetLastError
mov dword [esi + 4], eax
xor eax, eax
pop esi
add esp, 8
ret 4
mov edx, dword [esi + 8]
lea ecx, [esp + 4]
push 8
push ecx
push 5
push 0
push edx
call sub.WSOCK32.dll_setsockopt
cmp eax, 0xffffffff
jne 0x402c1f
call sub.WSOCK32.dll_WSAGetLastError
mov dword [esi + 4], eax
xor eax, eax
pop esi
add esp, 8
ret 4
mov eax, 1
pop esi
add esp, 8
ret 4
Function at 0x402c30
Capabilities:
Set socket configuration

Disassembly:
sub esp, 8
push esi
mov esi, ecx
mov eax, dword [esi + 8]
test eax, eax
jne 0x402c42
pop esi
add esp, 8
ret
mov ecx, dword [esi + 0x10]
mov edx, dword [esi + 0x20]
mov dword [esp + 8], ecx
lea ecx, [esp + 4]
push 8
push ecx
push 6
push 0
push eax
mov dword [esp + 0x18], edx
call sub.WSOCK32.dll_setsockopt
cmp eax, 0xffffffff
jne 0x402c75
call sub.WSOCK32.dll_WSAGetLastError
mov dword [esi + 4], eax
xor eax, eax
pop esi
add esp, 8
ret
mov eax, 1
pop esi
add esp, 8
ret

Function at 0x40652d
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1a4
mov edx, dword [ebp + 8]
xor ecx, ecx
mov eax, 0x40b4f0
cmp edx, dword [eax]
je 0x40654f
add eax, 8
inc ecx
cmp eax, 0x40b580
jl 0x406540
push esi
mov esi, ecx
shl esi, 3
cmp edx, dword [esi + 0x40b4f0]
jne 0x40667d
mov eax, dword [0x411258]
cmp eax, 1
je 0x406657
test eax, eax
jne 0x406580
cmp dword [0x40b30c], 1
je 0x406657
cmp edx, 0xfc
je 0x40667d
lea eax, [ebp - 0x1a4]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x4065b7
lea eax, [ebp - 0x1a4]
push str._program_name_unknown_
push eax
call fcn.004071c0
pop ecx
pop ecx
lea eax, [ebp - 0x1a4]
push edi
push eax
lea edi, [ebp - 0x1a4]
call fcn.00403b40
inc eax
pop ecx
cmp eax, 0x3c
jbe 0x4065fa
lea eax, [ebp - 0x1a4]
push eax
call fcn.00403b40
mov edi, eax
lea eax, [ebp - 0x1a4]
sub eax, 0x3b
push 3
add edi, eax
push 0x40960c
push edi
call fcn.00407750
add esp, 0x10
lea eax, [ebp - 0xa0]
push str.Runtime_Error__n_nProgram:
push eax
call fcn.004071c0
lea eax, [ebp - 0xa0]
push edi
push eax
call fcn.004071d0
lea eax, [ebp - 0xa0]
push 0x4095ec
push eax
call fcn.004071d0
push dword [esi + 0x40b4f4]
lea eax, [ebp - 0xa0]
push eax
call fcn.004071d0
push 0x12010
lea eax, [ebp - 0xa0]
push str.Microsoft_Visual_C_Runtime_Library
push eax
call fcn.00407dae
add esp, 0x2c
pop edi
jmp 0x40667d
lea eax, [ebp + 8]
lea esi, [esi + 0x40b4f4]
push 0
push eax
push dword [esi]
call fcn.00403b40
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 0x408920
Capabilities:
Encode data using xor

Disassembly:
mov eax, 0x4085d8
call fcn.00408946
push 0x9482be57
pop esi
dec edx
xor dword [ebx], eax
add edx, 0x353d5217
inc ebx
dec edx
cmp ebx, ecx
jne fcn.00408920
inc edx
and esi, edx
ret