joyce8/EMBER2024-capa huggingface dataset:
Function at 0x40db92
Capabilities:
Create thread
Terminate process

Disassembly:
mov eax, 0x41e374
call fcn.004132a4
cmp dword [ebp + 0xc], 5
jne 0x40dd19
mov eax, dword [0x42bcd8]
push esi
xor esi, esi
cmp eax, esi
jne 0x40dbde
or dword [0x42bcd8], 0xffffffff
push esi
push esi
push esi
push 0x40dacd
push esi
push esi
mov dword [0x42b2f8], esi
call dword [sym.imp.KERNEL32.dll_CreateThread]
mov dword [0x42bcd8], 0xfffffffe
jmp 0x40dd18
cmp eax, 0xffffffff
je 0x40dd18
cmp eax, 0xfffffffe
push edi
jne 0x40dca5
mov eax, dword [0x42b2f8]
cmp eax, esi
je 0x40dd17
cmp eax, 0x1000
push esi
jge 0x40dc1c
or dword [0x42bcd8], 0xffffffff
push 0x8b
push dword [ebp + 8]
call fcn.0040beee
jmp 0x40dc32
lea eax, [ebp + 8]
push eax
call fcn.00405485
pop ecx
pop ecx
mov dword [ebp - 4], esi
mov eax, dword [ebp + 8]
cmp dword [eax - 0xc], esi
jne 0x40dc39
push 1
call fcn.00411a1d
mov eax, dword [0x42a1ac]
mov ecx, 0x42a1ac
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp + 0xc], eax
mov byte [ebp - 4], 1
mov eax, dword [0x42b2f8]
push eax
push eax
push dword [0x42b2fc]
lea eax, [ebp + 0xc]
push str._s0_ld_ld1_r_n_r_n
push eax
call fcn.004023ad
mov esi, dword [ebp + 0xc]
add esp, 0x14
push dword [ebp + 8]
mov edi, 0x42b688
push esi
push edi
call fcn.00403754
push edi
call fcn.004036e9
lea eax, [esi - 0x10]
mov dword [0x42bcd8], 1
call fcn.00402528
mov eax, dword [ebp + 8]
add eax, 0xfffffff0
call fcn.00402528
jmp 0x40dd17
push ebx
mov edi, 0x42b688
push edi
call fcn.00403c8d
mov ebx, eax
cmp ebx, esi
jl 0x40dd16
cmp ebx, 0x64
jge 0x40dcf4
cmp ebx, 0x5f
jle 0x40dcc4
push 0x5f
pop ebx
push 0x3e8
push dword [ebp + 8]
call dword [sym.imp.USER32.dll_GetDlgItem]
push esi
mov ecx, eax
push 0x64
pop esi
lea eax, [ebx + ebx*4]
shl eax, 3
xor edx, edx
div esi
add eax, 0xa
push eax
push 0x402
push ecx
call dword [sym.imp.USER32.dll_SendMessageW]
jmp 0x40dd16
push esi
mov ecx, edi
call fcn.004043c2
mov esi, dword [ebp + 8]
push 5
push esi
call dword [sym.imp.USER32.dll_KillTimer]
call fcn.0040d180
push 1
push esi
call dword [sym.imp.USER32.dll_EndDialog]
pop ebx
pop edi
pop esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
leave
ret 8
Function at 0x40df24
Capabilities:
Create process on windows
Delete file
Set file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x54
push esi
push 0x44
xor esi, esi
lea eax, [ebp - 0x54]
push esi
push eax
call fcn.0040fb60
push 0x10
lea eax, [ebp - 0x10]
push esi
push eax
mov dword [ebp - 0x54], 0x44
call fcn.0040fb60
add esp, 0x18
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 0x54]
push eax
push dword [ebp + 8]
push esi
push esi
push esi
push esi
push esi
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
test eax, eax
jne 0x40dfbb
push esi
push esi
lea eax, [ebp + 8]
push eax
push 0x400
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push esi
push 0x1300
call dword [sym.imp.KERNEL32.dll_FormatMessageW]
test eax, eax
push esi
jne 0x40df9c
push str.RunSfxSetup_CreateProcess_FormatMessage_Error._n
call fcn.0040b9f0
pop ecx
pop ecx
jmp 0x40dfb6
push dword [ebp + 8]
push ebx
push str.RunSfxSetup_CreateProcess_Cmd_s__Error:__s_n
call fcn.0040b9f0
add esp, 0x10
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_LocalFree]
or eax, 0xffffffff
jmp 0x40e010
push 0xffffffffffffffff
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
lea eax, [ebp - 0x28]
push eax
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
push dword [ebp - 0x10]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
push dword [ebp - 0xc]
call esi
push dword [ebp - 0x28]
push ebx
push str.RunSfxSetup_Cmd_s__return_d_n
call fcn.0040b9f0
add esp, 0xc
cmp dword [ebp - 0x28], 1
ja 0x40e00d
push 0x80
push ebx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
push ebx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov eax, dword [ebp - 0x28]
pop esi
leave
ret 4

Function at 0x40e0d3
Capabilities:
Delete file

Disassembly:
push ebx
push esi
mov ebx, eax
push 0x2e
push ebx
call fcn.00410e35
mov esi, eax
test esi, esi
pop ecx
pop ecx
je 0x40e11b
push str..DLL
push esi
call fcn.0041155d
test eax, eax
pop ecx
pop ecx
jne 0x40e101
push edi
push ebx
call fcn.0040e015
jmp 0x40e121
push str..CAB
push esi
call fcn.0041155d
test eax, eax
pop ecx
pop ecx
push edi
jne 0x40e11c
push ebx
call fcn.0040331a
jmp 0x40e121
push edi
call fcn.0040df24
push edi
mov esi, eax
push ebx
push esi
push str.RunSfxSetup_ret_d__Cmd_s__Dir_s_n
call fcn.0040b9f0
add esp, 0x10
push ebx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov eax, esi
pop esi
pop ebx
ret
Function at 0x40e13f
Capabilities:
Enumerate process modules

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x228
mov eax, dword [0x4290c8]
push ebx
push esi
push edi
push dword [ebp + 0xc]
mov dword [ebp - 4], eax
xor ebx, ebx
xor eax, eax
mov dword [ebp - 0x228], ebx
mov ecx, 0x88
lea edi, [ebp - 0x224]
push 8
rep stosd dword es:[edi], eax
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov esi, eax
cmp esi, 0xffffffff
je 0x40e196
lea eax, [ebp - 0x228]
push eax
push esi
mov dword [ebp - 0x228], 0x224
call sub.KERNEL32.dll_Module32First
test eax, eax
jne 0x40e19a
xor al, al
jmp 0x40e1cd
push dword [ebp + 8]
lea eax, [ebp - 0x108]
push eax
call fcn.0041a312
test eax, eax
pop ecx
pop ecx
je 0x40e1c2
lea eax, [ebp - 0x228]
push eax
push esi
call sub.KERNEL32.dll_Module32Next
test eax, eax
jne 0x40e19a
jmp 0x40e1c4
mov bl, 1
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov al, bl
mov ecx, dword [ebp - 4]
pop edi
pop esi
pop ebx
call fcn.00412aab
leave
ret

Function at 0x40e1da
Capabilities:
Enumerate processes
Terminate process

Disassembly:
push ebp
lea ebp, [esp - 0x74]
sub esp, 0x238
mov eax, dword [0x4290c8]
push ebx
push esi
push edi
mov dword [ebp + 0x70], eax
push 0x104
lea eax, [ebp - 0x1bc]
xor ebx, ebx
push eax
push ebx
mov dword [ebp - 0x1c0], ebx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea eax, [ebp - 0x1bc]
push 0x5c
push eax
call fcn.00412830
pop ecx
pop ecx
push ebx
push ebx
lea ecx, [ebp - 0xb9]
sub ecx, eax
push ecx
lea esi, [eax + 1]
push esi
push 0xffffffffffffffff
push 0x42af10
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
push 0x49
pop ecx
push ebx
xor eax, eax
mov dword [ebp - 0xb8], ebx
lea edi, [ebp - 0xb4]
push 2
rep stosd dword es:[edi], eax
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
cmp eax, 0xffffffff
mov dword [ebp - 0x1c4], eax
je 0x40e27f
lea eax, [ebp - 0xb8]
push eax
push dword [ebp - 0x1c4]
mov dword [ebp - 0xb8], 0x128
call sub.KERNEL32.dll_Process32First
test eax, eax
jne 0x40e286
xor eax, eax
jmp 0x40e336
lea eax, [ebp - 0x94]
push esi
push eax
call fcn.0041a312
test eax, eax
pop ecx
pop ecx
jne 0x40e30a
push dword [ebp - 0xb0]
lea eax, [ebp - 0x1bc]
push eax
call fcn.0040e13f
test al, al
pop ecx
pop ecx
je 0x40e30a
lea eax, [ebp - 0x94]
push eax
push str.KillLavaProcessA:_pe32.szExeFile_S_n
call fcn.0040b9f0
inc dword [ebp - 0x1c0]
cmp byte [ebp + 0x7c], bl
pop ecx
pop ecx
je 0x40e324
push dword [ebp - 0xb0]
push ebx
push 0x1f0fff
call dword [sym.imp.KERNEL32.dll_OpenProcess]
push dword [ebp - 0xb0]
mov edi, eax
push edi
push str.KillLavaProcessA:_hLava0x_x__pe32.th32ProcessID0x_x_n
call fcn.0040b9f0
add esp, 0xc
cmp edi, ebx
je 0x40e303
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea eax, [ebp - 0xb8]
push eax
push dword [ebp - 0x1c4]
call sub.KERNEL32.dll_Process32Next
test eax, eax
jne 0x40e286
push dword [ebp - 0x1c4]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x1c0]
mov ecx, dword [ebp + 0x70]
pop edi
pop esi
pop ebx
call fcn.00412aab
add ebp, 0x74
leave
ret 4
Function at 0x40e348
Capabilities:
Copy file
Delete file

Disassembly:
push ebx
push ebp
push esi
push edi
xor ebx, ebx
push ebx
push 0x42ae48
mov ebp, 0x42af10
push ebp
call dword [sym.imp.KERNEL32.dll_CopyFileW]
test eax, eax
je 0x40e3f7
mov edi, str.DianjiRingExit
push ebp
inc ebx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
jne 0x40e3db
push str.CheckLavaRun_DeleteFile
call fcn.0040cf7f
cmp ebx, 1
pop ecx
jne 0x40e3be
push 0
call fcn.004022ca
cmp eax, ebx
jne 0x40e3f3
push edi
call dword [sym.imp.USER32.dll_RegisterWindowMessageW]
push 0
push 0
mov esi, eax
push esi
push 0xffff
call dword [sym.imp.USER32.dll_PostMessageW]
push edi
push esi
push str.CheckLavaRun__uMsg_d__g_szExitMessage_s_n
call fcn.0040b9f0
add esp, 0xc
jmp 0x40e3ca
cmp ebx, 0x3c
jne 0x40e3ca
push 1
call fcn.0040e1da
push 0x3e8
call dword [sym.imp.KERNEL32.dll_Sleep]
cmp ebx, 0x5a
jl 0x40e36d
inc ebx
cmp ebx, 0x5a
jl 0x40e402
push 0
push 0x82
push 0
call fcn.0040beee
push 0xfffffffffffffffd
pop eax
jmp 0x40e404
push 0xfffffffffffffffe
jmp 0x40e3f0
push str.CheckLavaRun_CopyFile
call fcn.0040cf7f
pop ecx
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
ret
Function at 0x40e8ba
Capabilities:
Copy file
Get common file path
Move file

Disassembly:
push ebp
lea ebp, [esp - 0x7c0]
sub esp, 0x840
mov eax, dword [0x4290c8]
push ebx
push esi
push edi
mov dword [ebp + 0x7bc], eax
push 0x104
lea eax, [ebp + 0x5b4]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
lea eax, [ebp + 0x5b4]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
lea ecx, [eax + eax]
lea eax, [ebp + ecx + 0x5b4]
mov dx, word [eax - 2]
cmp dx, 0x5c
je 0x40e91b
cmp dx, 0x2f
je 0x40e91b
mov word [eax], 0x5c
lea eax, [ebp + ecx + 0x5b6]
mov esi, dword [sym.imp.KERNEL32.dll_lstrcpyW]
mov edi, str.IdleTest.dll
push edi
push eax
call esi
lea eax, [ebp + 0x5b4]
push eax
push str.DoIdleTest:_idletest_to_system_directory:__s_n
call fcn.0040b9f0
mov ebx, dword [sym.imp.KERNEL32.dll_CopyFileW]
pop ecx
pop ecx
push 0
lea eax, [ebp + 0x5b4]
push eax
push 0x421a78
call ebx
push 0
lea eax, [ebp + 0x5b4]
push eax
push edi
call ebx
test eax, eax
je 0x40e971
push 1
push 0x421a78
push edi
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
push 0x104
lea eax, [ebp - 0x64]
push eax
xor edi, edi
push edi
mov dword [ebp - 0x7c], str.mainprog.bin
mov dword [ebp - 0x78], str.RDSS.exe
mov dword [ebp - 0x74], str.RDSS.bin
mov dword [ebp - 0x80], 0x42af10
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
lea eax, [ebp - 0x64]
push 0x5c
push eax
call fcn.00410e35
pop ecx
mov word [eax + 2], di
mov dword [ebp - 0x68], edi
mov edi, dword [sym.imp.KERNEL32.dll_lstrcatW]
pop ecx
lea eax, [ebp - 0x64]
push eax
lea eax, [ebp + 0x1a4]
push eax
call esi
mov eax, dword [ebp - 0x68]
push dword [ebp + eax*8 - 0x80]
lea eax, [ebp + 0x1a4]
push eax
call edi
lea eax, [ebp - 0x64]
push eax
lea eax, [ebp + 0x3ac]
push eax
call esi
mov eax, dword [ebp - 0x68]
push dword [ebp + eax*8 - 0x7c]
lea eax, [ebp + 0x3ac]
push eax
call edi
push 1
lea eax, [ebp + 0x1a4]
push eax
lea eax, [ebp + 0x3ac]
push eax
call ebx
lea eax, [ebp + 0x1a4]
push eax
call fcn.0040e866
mov dword [ebp - 0x70], eax
lea eax, [ebp + 0x3ac]
push eax
mov dword [ebp - 0x6c], edx
call fcn.0040e866
cmp dword [ebp - 0x6c], edx
pop ecx
pop ecx
jne 0x40ea2f
cmp dword [ebp - 0x70], eax
je 0x40ea4b
push 0
lea eax, [ebp + 0x3ac]
push eax
lea eax, [ebp + 0x1a4]
push eax
call ebx
test eax, eax
jne 0x40ea4b
call dword [sym.imp.KERNEL32.dll_GetLastError]
inc dword [ebp - 0x68]
cmp dword [ebp - 0x68], 2
jb 0x40e9b9
mov ecx, dword [ebp + 0x7bc]
pop edi
pop esi
pop ebx
call fcn.00412aab
add ebp, 0x7c0
leave
ret
Function at 0x40ea6e
Capabilities:
Delete file
Move file

Disassembly:
sub esp, 0x20c
mov eax, dword [0x4290c8]
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_MoveFileW]
push ebp
push esi
push edi
push 0x42af10
mov esi, 0x42ae48
push esi
mov dword [esp + 0x220], eax
call ebx
mov ebp, dword [sym.imp.KERNEL32.dll_DeleteFileW]
push esi
call ebp
xor edi, edi
lea esi, [edi + 0x421a54]
push dword [esi]
lea eax, [esp + 0x14]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyW]
push str..DEL
lea eax, [esp + 0x14]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatW]
push dword [esi]
lea eax, [esp + 0x14]
push eax
call ebx
lea eax, [esp + 0x10]
push eax
call ebp
add edi, 4
cmp edi, 0x24
jb 0x40eaa2
call fcn.0040e8ba
mov ecx, dword [esp + 0x218]
pop edi
pop esi
pop ebp
pop ebx
call fcn.00412aab
add esp, 0x20c
ret

Function at 0x410daa
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
mov edi, dword [ebp + 0x10]
xor ebx, ebx
test edi, edi
jne 0x410dc7
call fcn.0041400f
mov dword [eax], 0x16
xor eax, eax
jmp 0x410e31
push esi
push 0x8c
push 1
call fcn.0040fbc0
mov esi, eax
test esi, esi
pop ecx
pop ecx
je 0x410e1c
push esi
call fcn.004142fd
mov eax, dword [ebp + 0x14]
or dword [esi + 4], 0xffffffff
mov dword [esi + 0x50], eax
mov eax, dword [ebp + 0x1c]
test eax, eax
pop ecx
mov dword [esi + 0x4c], edi
jne 0x410dfa
lea eax, [ebp + 0x10]
push eax
push dword [ebp + 0x18]
push esi
push 0x410d15
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateThread]
test eax, eax
jne 0x410e30
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
push esi
call fcn.0040fe08
test ebx, ebx
pop ecx
je 0x410e2e
push ebx
call fcn.00414021
pop ecx
xor eax, eax
pop esi
pop edi
pop ebx
pop ebp
ret
Function at 0x41195a
Capabilities:
Terminate process

Disassembly:
push 8
push 0x41f5e0
call fcn.00412abc
push 8
call fcn.00413450
pop ecx
xor edi, edi
mov dword [ebp - 4], edi
xor esi, esi
inc esi
cmp dword [0x42a25c], esi
jne 0x41198e
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
mov dword [0x42a258], esi
mov al, byte [ebp + 0x10]
mov byte [0x42a254], al
cmp dword [ebp + 0xc], edi
jne 0x4119d8
cmp dword [0x42d2b0], edi
je 0x4119c8
mov eax, dword [0x42d2ac]
sub eax, 4
mov dword [0x42d2ac], eax
cmp eax, dword [0x42d2b0]
jb 0x4119c8
mov eax, dword [eax]
cmp eax, edi
je 0x4119a9
call eax
jmp 0x4119a9
push 0x429044
mov eax, 0x42903c
call fcn.004118d8
pop ecx
push 0x429050
mov eax, 0x429048
call fcn.004118d8
pop ecx
or dword [ebp - 4], 0xffffffff
call 0x411a09
cmp dword [ebp + 0x10], edi
jne 0x411a17
mov dword [0x42a25c], esi
push dword [ebp + 8]
call fcn.00411896
xor edi, edi
xor esi, esi
inc esi
cmp dword [ebp + 0x10], edi
je 0x411a16
push 8
call fcn.0041339b
pop ecx
ret
call fcn.00412af7
ret
Function at 0x4128a6
Capabilities:
Parse pe header
Terminate process

Disassembly:
push 0x60
push 0x41f680
call fcn.00412abc
mov edi, 0x94
mov eax, edi
call fcn.00416c50
mov dword [ebp - 0x18], esp
mov esi, esp
mov dword [esi], edi
push esi
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
mov ecx, dword [esi + 0x10]
mov dword [0x42a21c], ecx
mov eax, dword [esi + 4]
mov dword [0x42a228], eax
mov edx, dword [esi + 8]
mov dword [0x42a22c], edx
mov esi, dword [esi + 0xc]
and esi, 0x7fff
mov dword [0x42a220], esi
cmp ecx, 2
je 0x412906
or esi, 0x8000
mov dword [0x42a220], esi
shl eax, 8
add eax, edx
mov dword [0x42a224], eax
xor esi, esi
push esi
mov edi, dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
call edi
cmp word [eax], 0x5a4d
jne 0x412941
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x412941
movzx eax, word [ecx + 0x18]
cmp eax, 0x10b
je 0x412959
cmp eax, 0x20b
je 0x412946
mov dword [ebp - 0x1c], esi
jmp 0x41296d
cmp dword [ecx + 0x84], 0xe
jbe 0x412941
xor eax, eax
cmp dword [ecx + 0xf8], esi
jmp 0x412967
cmp dword [ecx + 0x74], 0xe
jbe 0x412941
xor eax, eax
cmp dword [ecx + 0xe8], esi
setne al
mov dword [ebp - 0x1c], eax
push 1
call fcn.0041349b
pop ecx
test eax, eax
jne 0x412981
push 0x1c
call fcn.00412882
pop ecx
call fcn.004144f7
test eax, eax
jne 0x412992
push 0x10
call fcn.00412882
pop ecx
call fcn.0041687d
mov dword [ebp - 4], esi
call fcn.00418820
test eax, eax
jge 0x4129ab
push 0x1b
call fcn.0041285d
pop ecx
call fcn.00418781
mov dword [0x42d2a4], eax
call fcn.00418617
mov dword [0x42a26c], eax
call fcn.00418581
test eax, eax
jge 0x4129d0
push 8
call fcn.0041285d
pop ecx
call fcn.0041834e
test eax, eax
jge 0x4129e1
push 9
call fcn.0041285d
pop ecx
push 1
call fcn.004118f0
pop ecx
mov dword [ebp - 0x28], eax
cmp eax, esi
je 0x4129f7
push eax
call fcn.0041285d
pop ecx
mov dword [ebp - 0x44], esi
lea eax, [ebp - 0x70]
push eax
call dword [sym.imp.KERNEL32.dll_GetStartupInfoW]
call fcn.00418308
mov dword [ebp - 0x20], eax
test byte [ebp - 0x44], 1
je 0x412a18
movzx eax, word [ebp - 0x40]
jmp 0x412a1b
push 0xa
pop eax
push eax
push dword [ebp - 0x20]
push esi
push esi
call edi
push eax
call fcn.004086b2
mov edi, eax
mov dword [ebp - 0x2c], edi
cmp dword [ebp - 0x1c], esi
jne 0x412a39
push edi
call fcn.00411a1d
call fcn.00411a3f
jmp 0x412a6b
or dword [ebp - 4], 0xffffffff
mov eax, edi
lea esp, [ebp - 0x7c]
call fcn.00412af7
ret
Function at 0x415aed
Capabilities:
Get common file path

Disassembly:
push 0x120
push 0x41fe48
call fcn.00412abc
mov eax, dword [0x4290c8]
mov dword [ebp - 0x1c], eax
lea edi, [ebp - 0x124]
and dword [ebp - 0x128], 0
mov eax, edi
push eax
push 0x105
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
mov esi, eax
mov dword [ebp - 0x12c], esi
cmp esi, 0x104
jle 0x415b91
and dword [ebp - 4], 0
lea eax, [esi + 1]
add eax, 3
and eax, 0xfffffffc
call fcn.00416c50
mov dword [ebp - 0x18], esp
mov edi, esp
mov dword [ebp - 0x130], edi
jmp 0x415b7e
or dword [ebp - 4], 0xffffffff
test esi, esi
je 0x415b91
push edi
inc esi
push esi
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
mov esi, eax
xor ebx, ebx
test esi, esi
je 0x415bac
cmp byte [edi + 1], 0x3a
jne 0x415bac
movzx eax, byte [edi]
push eax
call fcn.0041a47b
pop ecx
mov ebx, eax
sub ebx, 0x40
cmp dword [ebp - 0x128], 0
je 0x415bbc
push edi
call fcn.0040fe08
pop ecx
mov eax, ebx
lea esp, [ebp - 0x13c]
mov ecx, dword [ebp - 0x1c]
call fcn.00412aab
call fcn.00412af7
ret

Function at 0x416905
Capabilities:
Get system information on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x4c
push ebx
push esi
push edi
push 4
pop eax
call fcn.00416c50
mov esi, esp
push 0x1c
lea eax, [ebp - 0x28]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x4169a0
mov ebx, dword [ebp - 0x24]
lea eax, [ebp - 0x4c]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemInfo]
mov ecx, dword [ebp - 0x48]
mov eax, dword [0x42a21c]
lea edi, [ecx - 1]
not edi
and edi, esi
sub edi, ecx
mov esi, eax
dec esi
neg esi
sbb esi, esi
and esi, 0xfffffff1
add esi, 0x11
imul esi, ecx
add esi, ebx
cmp edi, esi
mov dword [ebp - 8], ecx
jb 0x4169a0
cmp eax, 1
je 0x4169c1
mov dword [ebp - 4], ebx
mov ebx, 0x1000
push 0x1c
lea eax, [ebp - 0x28]
push eax
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x4169a0
mov eax, dword [ebp - 0x1c]
add dword [ebp - 4], eax
test dword [ebp - 0x18], ebx
je 0x41696d
test byte [ebp - 0x13], 1
mov eax, dword [ebp - 0x28]
mov dword [ebp - 4], eax
je 0x41699c
xor eax, eax
inc eax
jmp 0x4169e0
cmp edi, eax
jae 0x4169a4
xor eax, eax
jmp 0x4169e0
cmp eax, esi
jae 0x4169ab
mov dword [ebp - 4], esi
push 4
push ebx
push dword [ebp - 8]
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov eax, dword [0x42a21c]
jmp 0x4169c4
mov dword [ebp - 4], edi
dec eax
neg eax
sbb eax, eax
and eax, 0x103
lea ecx, [ebp - 0xc]
push ecx
inc eax
push eax
push dword [ebp - 8]
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
lea esp, [ebp - 0x58]
pop edi
pop esi
pop ebx
leave
ret
Function at 0x417767
Capabilities:
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x3a0]
sub esp, 0x420
mov eax, dword [0x4290c8]
push edi
xor edi, edi
cmp dword [ebp + 0x3b0], edi
mov dword [ebp + 0x39c], eax
mov dword [ebp - 0x78], edi
mov dword [ebp - 0x7c], edi
jne 0x417798
xor eax, eax
jmp 0x417921
mov eax, dword [ebp + 0x3a8]
push ebx
mov ebx, dword [ebp + 0x3a8]
and eax, 0x1f
sar ebx, 5
push esi
lea esi, [eax + eax*8]
lea ebx, [ebx*4 + 0x42bf20]
mov eax, dword [ebx]
shl esi, 2
test byte [eax + esi + 4], 0x20
je 0x4177d4
push 2
push edi
push edi
push dword [ebp + 0x3a8]
call fcn.0041b214
add esp, 0x10
mov eax, dword [ebx]
add eax, esi
test byte [eax + 4], 0x80
je 0x4178af
cmp dword [ebp + 0x3b0], edi
mov eax, dword [ebp + 0x3ac]
mov dword [ebp - 0x74], eax
mov dword [ebp - 0x6c], edi
jbe 0x4178ed
mov ecx, dword [ebp - 0x74]
sub ecx, dword [ebp + 0x3ac]
lea eax, [ebp - 0x68]
mov dword [ebp - 0x70], edi
cmp ecx, dword [ebp + 0x3b0]
jae 0x417838
mov edx, dword [ebp - 0x74]
inc dword [ebp - 0x74]
mov dl, byte [edx]
inc ecx
cmp dl, 0xa
jne 0x417829
inc dword [ebp - 0x7c]
mov byte [eax], 0xd
inc eax
inc dword [ebp - 0x70]
mov byte [eax], dl
inc eax
inc dword [ebp - 0x70]
cmp dword [ebp - 0x70], 0x400
jl 0x417809
mov edi, eax
lea eax, [ebp - 0x68]
sub edi, eax
push 0
lea eax, [ebp - 0x80]
push eax
push edi
lea eax, [ebp - 0x68]
push eax
mov eax, dword [ebx]
push dword [eax + esi]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x417878
mov eax, dword [ebp - 0x80]
add dword [ebp - 0x78], eax
cmp eax, edi
jl 0x417881
mov eax, dword [ebp - 0x74]
sub eax, dword [ebp + 0x3ac]
xor edi, edi
cmp eax, dword [ebp + 0x3b0]
jb 0x4177fa
jmp 0x417883
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x6c], eax
xor edi, edi
mov eax, dword [ebp - 0x78]
cmp eax, edi
jne 0x41791c
cmp dword [ebp - 0x6c], edi
je 0x4178ed
push 5
pop esi
cmp dword [ebp - 0x6c], esi
jne 0x4178e2
call fcn.0041400f
mov dword [eax], 9
call fcn.00414018
mov dword [eax], esi
jmp 0x417917
push edi
lea ecx, [ebp - 0x80]
push ecx
push dword [ebp + 0x3b0]
push dword [ebp + 0x3ac]
push dword [eax]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x4178d7
mov eax, dword [ebp - 0x80]
mov dword [ebp - 0x6c], edi
mov dword [ebp - 0x78], eax
jmp 0x417883
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x6c], eax
jmp 0x417883
push dword [ebp - 0x6c]
call fcn.00414021
pop ecx
jmp 0x417917
mov eax, dword [ebx]
test byte [eax + esi + 4], 0x40
je 0x417905
mov eax, dword [ebp + 0x3ac]
cmp byte [eax], 0x1a
jne 0x417905
xor eax, eax
jmp 0x41791f
call fcn.0041400f
mov dword [eax], 0x1c
call fcn.00414018
mov dword [eax], edi
or eax, 0xffffffff
jmp 0x41791f
sub eax, dword [ebp - 0x7c]
pop esi
pop ebx
mov ecx, dword [ebp + 0x39c]
pop edi
call fcn.00412aab
add ebp, 0x3a0
leave
ret
Function at 0x418158
Capabilities:
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x8c]
sub esp, 0x10c
mov eax, dword [0x4290c8]
mov ecx, dword [ebp + 0x94]
push ebx
push esi
mov dword [ebp + 0x88], eax
xor edx, edx
push edi
xor eax, eax
cmp ecx, dword [eax*8 + 0x429a38]
je 0x41818d
inc eax
cmp eax, 0x13
jb 0x41817e
mov esi, eax
shl esi, 3
cmp ecx, dword [esi + 0x429a38]
jne 0x4182b3
mov eax, dword [0x42a270]
cmp eax, 1
je 0x41828b
cmp eax, edx
jne 0x4181bd
cmp dword [0x4290c4], 1
je 0x41828b
cmp ecx, 0xfc
je 0x4182b3
push 0x104
lea eax, [ebp - 0x80]
push eax
push edx
mov byte [ebp + 0x84], dl
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x4181f3
lea eax, [ebp - 0x80]
push str._program_name_unknown_
push eax
call fcn.0040fd10
pop ecx
pop ecx
lea edi, [ebp - 0x80]
mov eax, edi
push eax
call fcn.0040fc80
inc eax
cmp eax, 0x3c
pop ecx
jbe 0x418227
mov eax, edi
push eax
call fcn.0040fc80
mov edi, eax
lea eax, [ebp - 0x80]
sub eax, 0x3b
push 3
add edi, eax
push 0x420380
push edi
call fcn.0040fe80
add esp, 0x10
push edi
call fcn.0040fc80
push dword [esi + 0x429a3c]
mov ebx, eax
call fcn.0040fc80
lea eax, [ebx + eax + 0x1c]
pop ecx
add eax, 3
pop ecx
and eax, 0xfffffffc
call fcn.00416c50
mov ebx, esp
push str.Runtime_Error__n_nProgram:
push ebx
call fcn.0040fd10
push edi
push ebx
call fcn.0040fd20
push 0x420360
push ebx
call fcn.0040fd20
push dword [esi + 0x429a3c]
push ebx
call fcn.0040fd20
push 0x12010
push str.Microsoft_Visual_C_Runtime_Library
push ebx
call fcn.0041b318
add esp, 0x2c
jmp 0x4182b3
push edx
lea eax, [ebp + 0x94]
push eax
lea esi, [esi + 0x429a3c]
push dword [esi]
call fcn.0040fc80
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]
lea esp, [ebp - 0x8c]
mov ecx, dword [ebp + 0x88]
call fcn.00412aab
pop edi
pop esi
pop ebx
add ebp, 0x8c
leave
ret