joyce8/EMBER2024-capa huggingface dataset:
Function at 0x409d19
Capabilities:
Get common file path

Disassembly:
push ebp
lea ebp, [esp - 0x40c]
sub esp, 0x48c
mov eax, dword [0x425848]
xor eax, ebp
mov dword [ebp + 0x408], eax
mov eax, dword [ebp + 0x414]
push ebx
mov dword [ebp - 0x58], eax
mov eax, dword [ebp + 0x418]
push esi
mov esi, dword [ebp + 0x41c]
push edi
mov edi, dword [ebp + 0x420]
mov dword [ebp - 0x50], eax
lea eax, [ebp - 0x4c]
xor ebx, ebx
push eax
mov dword [ebp - 0x48], ebx
call dword [sym.imp.SHELL32.dll_SHGetMalloc]
test eax, eax
je 0x409d6f
xor eax, eax
jmp 0x409ea1
push 0x140
lea eax, [ebp + 0x2c8]
push edi
push eax
call fcn.00403610
add esp, 0xc
cmp byte [ebp + 0x2c8], bl
je 0x409db6
lea eax, [ebp + 0x2c8]
lea edi, [ebp + 0x2c8]
push eax
dec edi
call fcn.00403582
cmp byte [eax + edi], 0x5c
pop ecx
jne 0x409db6
lea eax, [ebp + 0x2c8]
push eax
call fcn.00403582
pop ecx
mov byte [eax + edi], bl
cmp byte [esi], bl
je 0x409dfe
lea eax, [ebp - 0x54]
push eax
call dword [sym.imp.SHELL32.dll_SHGetDesktopFolder]
test eax, eax
jne 0x409dfe
push 0x104
lea eax, [ebp + 0xc0]
push eax
push 0xffffffffffffffff
push esi
push 1
push ebx
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
mov eax, dword [ebp - 0x54]
mov ecx, dword [eax]
lea edx, [ebp - 0x7c]
push edx
lea edx, [ebp - 0x48]
push edx
lea edx, [ebp - 0x80]
push edx
lea edx, [ebp + 0xc0]
push edx
push ebx
push ebx
push eax
call dword [ecx + 0xc]
cmp dword [ebp - 0x48], ebx
jne 0x409e20
lea eax, [ebp - 0x48]
push eax
push ebx
push ebx
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderLocation]
test eax, eax
jne 0x409d68
cmp dword [ebp - 0x48], ebx
je 0x409d68
xor eax, eax
push 8
pop ecx
lea edi, [ebp - 0x78]
rep stosd dword es:[edi], eax
mov eax, dword [ebp - 0x58]
mov dword [ebp - 0x78], eax
mov eax, dword [ebp - 0x48]
mov dword [ebp - 0x74], eax
lea eax, [ebp - 0x44]
mov dword [ebp - 0x70], eax
mov eax, dword [ebp - 0x50]
mov dword [ebp - 0x6c], eax
lea eax, [ebp + 0x2c8]
mov dword [ebp - 0x60], eax
lea eax, [ebp - 0x78]
push eax
mov dword [ebp - 0x68], 0x40
mov dword [ebp - 0x64], 0x409ce3
mov dword [ebp - 0x5c], ebx
call dword [sym.imp.SHELL32.dll_SHBrowseForFolderA]
mov edi, eax
cmp edi, ebx
je 0x409e8a
push esi
xor ebx, ebx
push edi
inc ebx
call dword [sym.imp.SHELL32.dll_SHGetPathFromIDListA]
push ebx
push esi
call fcn.004088d4
mov eax, dword [ebp - 0x4c]
pop ecx
pop ecx
mov ecx, dword [eax]
push edi
push eax
call dword [ecx + 0x14]
mov eax, dword [ebp - 0x4c]
push dword [ebp - 0x48]
mov ecx, dword [eax]
push eax
call dword [ecx + 0x14]
mov eax, dword [ebp - 0x4c]
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, ebx
mov ecx, dword [ebp + 0x408]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0040f870
add ebp, 0x40c
leave
ret
Function at 0x40c1d5
Capabilities:
Get disk size

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
push ebx
push esi
mov esi, dword [ebp + 8]
xor ebx, ebx
push str.KERNEL32.DLL
mov dword [esi], ebx
mov dword [esi + 4], ebx
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
cmp eax, ebx
mov dword [ebp - 4], eax
jne 0x40c219
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Unable_to_load_library_KERNEL32.DLL__0x_.8X__n
call fcn.004017c6
pop ecx
pop ecx
push ebx
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
xor eax, eax
pop esi
pop ebx
leave
ret
cmp eax, 0x20
jae 0x40c23e
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Failed_to_load_KERNEL32.DLL__0x_.8X__n
call fcn.004017c6
pop ecx
pop ecx
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov eax, ebx
jmp 0x40c215
push edi
mov edi, dword [ebp + 0xc]
mov al, byte [edi + 3]
push str.GetDiskFreeSpaceExA
push dword [ebp - 4]
mov byte [ebp + 0xb], al
mov byte [edi + 3], bl
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp eax, ebx
je 0x40c2b2
lea ecx, [ebp - 0x18]
push ecx
lea ecx, [ebp - 0x10]
push ecx
lea ecx, [ebp - 0x20]
push ecx
push edi
call eax
test eax, eax
je 0x40c2fe
mov eax, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0x20]
mov edx, dword [ebp - 0x14]
shr ecx, 0xa
shl eax, 0x16
add eax, ecx
xor ecx, ecx
mov dword [esi], eax
mov dword [esi + 4], ecx
mov esi, dword [ebp - 0x18]
shl edx, 0x16
shr esi, 0xa
add edx, esi
mov esi, dword [ebp - 0x10]
push ebx
push edx
mov edx, dword [ebp - 0xc]
push ebx
shl edx, 0x16
shr esi, 0xa
add edx, esi
push edx
push ecx
push eax
push str.Free_Space_Ex_:__dk__dk__dk_n
jmp 0x40c2f3
lea eax, [ebp - 0x1c]
push eax
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 0x14]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_GetDiskFreeSpaceA]
test eax, eax
je 0x40c2fe
mov eax, dword [ebp - 0x14]
imul eax, dword [ebp - 0xc]
push dword [ebp - 0x1c]
imul eax, dword [ebp - 8]
push dword [ebp - 8]
shr eax, 0xa
push dword [ebp - 0xc]
mov dword [esi], eax
push dword [ebp - 0x14]
mov dword [esi + 4], ebx
push ebx
push eax
push str.Free_Space____:__dk__d__d__d__d_n
call fcn.004017c6
xor ebx, ebx
add esp, 0x1c
inc ebx
mov al, byte [ebp + 0xb]
mov byte [edi + 3], al
pop edi
jmp 0x40c231

Function at 0x40c91d
Capabilities:
Create directory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x144
mov eax, dword [0x425848]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
push edi
mov edi, dword [ebp + 8]
lea eax, [ebp - 0x144]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
cmp eax, 0xffffffff
jne 0x40c980
push edi
call fcn.00403582
pop ecx
mov esi, eax
jmp 0x40c959
cmp byte [edi + esi], 0x5c
je 0x40c95e
dec esi
jns 0x40c953
jmp 0x40c962
mov byte [edi + esi], 0
test esi, esi
jle 0x40c975
push edi
call fcn.0040c91d
test eax, eax
pop ecx
je 0x40c98a
mov byte [edi + esi], 0x5c
push 0
push edi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
jmp 0x40c987
push eax
call dword [sym.imp.KERNEL32.dll_FindClose]
xor eax, eax
inc eax
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.0040f870
leave
ret
Function at 0x40c998
Capabilities:
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x8c]
sub esp, 0x10c
mov eax, dword [0x425848]
xor eax, ebp
mov dword [ebp + 0x88], eax
mov eax, dword [ebp + 0x98]
push ebx
push esi
push edi
mov edi, dword [ebp + 0x94]
mov esi, 0x420d08
push esi
push edi
mov dword [ebp - 0x80], eax
call fcn.004104b6
mov ebx, eax
test ebx, ebx
pop ecx
pop ecx
jne 0x40ca44
lea eax, [ebp - 0x7c]
push edi
push eax
call fcn.004035b2
lea eax, [ebp - 0x7c]
push eax
call fcn.00403582
add esp, 0xc
lea eax, [ebp + eax - 0x7c]
jmp 0x40ca02
mov cl, byte [eax]
cmp cl, 0x5c
je 0x40ca0b
cmp cl, 0x2f
je 0x40ca0b
dec eax
lea ecx, [ebp - 0x7c]
cmp eax, ecx
ja 0x40c9f5
jmp 0x40ca0c
inc eax
mov byte [eax], 0
lea eax, [ebp - 0x7c]
push eax
call fcn.0040c91d
test eax, eax
pop ecx
jne 0x40ca2d
push edi
push str.Unable_to_create_directory__s_n
call fcn.004017c6
pop ecx
xor eax, eax
jmp 0x40ca79
push esi
push edi
call fcn.004104b6
mov ebx, eax
test ebx, ebx
pop ecx
pop ecx
jne 0x40ca44
push edi
push str.Unable_to_create_file__s_n
jmp 0x40ca23
push ebx
push dword [ebp + 0x9c]
xor esi, esi
inc esi
push esi
push dword [ebp - 0x80]
call fcn.00412090
add esp, 0x10
cmp eax, dword [ebp + 0x9c]
je 0x40ca71
push edi
push str.Unable_to_write_to_file__s_n
call fcn.004017c6
pop ecx
pop ecx
xor esi, esi
push ebx
call fcn.0040fdad
mov eax, esi
pop ecx
mov ecx, dword [ebp + 0x88]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0040f870
add ebp, 0x8c
leave
ret

Function at 0x40cb39
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x3c
push ebx
mov ebx, dword [ebp + 0x14]
and dword [ebx], 0
push esi
push edi
push 0x3c
pop esi
push esi
lea eax, [ebp - 0x3c]
push 0
push eax
call fcn.0040f880
mov edi, dword [ebp + 0xc]
add esp, 0xc
mov dword [ebp - 0x3c], esi
mov esi, dword [ebp + 8]
lea eax, [ebp - 0x3c]
push eax
mov dword [ebp - 0x30], str.open
mov dword [ebp - 0x2c], esi
mov dword [ebp - 0x28], edi
mov dword [ebp - 0x38], 0x40
mov dword [ebp - 0x20], 0xa
call dword [sym.imp.SHELL32.dll_ShellExecuteExA]
test eax, eax
jne 0x40cba4
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push edi
push esi
push str.Unable_to_execute__s__s_0x_.8X_n
call fcn.004017c6
add esp, 0x10
jmp 0x40cbfe
cmp dword [ebp + 0x10], 1
jne 0x40cbf5
call fcn.00409b50
push 0x1f4
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0x102
je 0x40cbaa
lea eax, [ebp + 0x14]
push eax
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
test eax, eax
jne 0x40cbf0
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
push eax
call esi
push eax
push str.Failed_to_get_exit_code___d___0x_.8X__n
call fcn.004017c6
add esp, 0xc
jmp 0x40cbf5
mov eax, dword [ebp + 0x14]
mov dword [ebx], eax
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
xor eax, eax
pop esi
inc eax
pop ebx
leave
ret
Function at 0x40ccb1
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
push edi
lea eax, [ebp - 4]
push eax
push 2
push 0
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderLocation]
mov esi, dword [ebp + 0xc]
push esi
push dword [ebp - 4]
call dword [sym.imp.SHELL32.dll_SHGetPathFromIDListA]
mov edi, dword [ebp + 8]
cmp byte [edi], 0
je 0x40ccfe
push esi
call fcn.00403582
cmp byte [eax + esi - 1], 0x5c
pop ecx
je 0x40ccf5
push 0x420cd0
push esi
call fcn.00404707
pop ecx
pop ecx
push edi
push esi
call fcn.00404707
pop ecx
pop ecx
xor eax, eax
pop edi
inc eax
pop esi
leave
ret

Function at 0x40cf0b
Capabilities:
Enumerate gui resources

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x188
mov eax, dword [0x425848]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
mov edx, dword [ebp + 0x18]
mov ecx, dword [ebp + 0x1c]
mov dword [ebp - 0x180], eax
mov eax, dword [ebp + 0x20]
push ebx
mov ebx, dword [ebp + 0x14]
mov dword [ebp - 0x184], eax
mov eax, 0x3e8
cmp dword [ebp + 0x10], eax
push esi
push edi
mov dword [ebp - 0x188], edx
jge 0x40cf4f
mov dword [ebp + 0x10], eax
mov edi, dword [ebp + 0xc]
push ecx
push edx
push ebx
push edi
push str.Find___d__Windows___s____s___s__n
call fcn.004017c6
add esp, 0x14
xor esi, esi
push 0x178
lea eax, [ebp - 0x17c]
push 0
push eax
call fcn.0040f880
push dword [ebp - 0x184]
lea eax, [ebp - 0x16c]
push eax
call fcn.004035b2
lea eax, [ebp - 0x7c]
push ebx
push eax
call fcn.004035b2
push dword [ebp - 0x188]
lea eax, [ebp - 0xf4]
push eax
call fcn.004035b2
add esp, 0x24
lea eax, [ebp - 0x17c]
push eax
push 0x40cd99
mov dword [ebp - 0x178], esi
mov dword [ebp - 0x17c], edi
call dword [sym.imp.USER32.dll_EnumWindows]
xor eax, eax
inc eax
cmp dword [ebp - 0x174], eax
je 0x40cff9
cmp dword [ebp - 0x170], 0
jle 0x40d017
cmp edi, eax
je 0x40cff9
mov eax, dword [ebp + 0x10]
push 0xa
cdq
pop ecx
idiv ecx
push eax
call dword [sym.imp.KERNEL32.dll_Sleep]
inc esi
cmp esi, 0xa
jl 0x40cf65
mov eax, dword [ebp - 0x180]
mov byte [eax + 0x9b0], 0
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0040f870
leave
ret
test esi, esi
jne 0x40d008
mov ecx, dword [ebp - 0x180]
mov byte [ecx + 0x9b0], 0
jmp 0x40d008
Function at 0x40d1b9
Capabilities:
Create shortcut via ishelllink

Disassembly:
push ebp
lea ebp, [esp - 0x4a4]
sub esp, 0x524
mov eax, dword [0x425848]
xor eax, ebp
mov dword [ebp + 0x4a0], eax
mov eax, dword [ebp + 0x4ac]
push ebx
mov ebx, dword [ebp + 0x4bc]
push esi
mov esi, dword [ebp + 0x4b0]
push edi
mov edi, dword [ebp + 0x4b4]
push edi
push esi
push ebx
push 0x4285e8
push str.Create_Item___s_:__s___s____s__n
mov dword [ebp - 0x80], eax
call fcn.004017c6
push ebx
push dword [ebp + 0x4b8]
lea eax, [ebp + 0x194]
push edi
push esi
push eax
call fcn.0040cd05
add esp, 0x28
lea eax, [ebp - 0x78]
push eax
push 0x421d3c
push 1
push 0
push 0x421d5c
call dword [sym.imp.ole32.dll_CoCreateInstance]
test eax, eax
jne 0x40d360
lea eax, [ebp + 0x39c]
push esi
push eax
call fcn.004035b2
cmp byte [ebp + 0x39c], 0x24
pop ecx
pop ecx
jne 0x40d25d
mov byte [ebp + 0x39e], 0
jmp 0x40d264
mov byte [ebp + 0x39c], 0
lea eax, [ebp - 0x80]
push eax
lea eax, [ebp + 0x298]
push eax
lea eax, [ebp + 0x39c]
push eax
push dword [ebp - 0x80]
call fcn.0040d02a
push esi
lea eax, [ebp + 0x298]
push eax
push str._s_s
mov esi, 0x104
lea eax, [ebp + 0x39c]
push esi
push eax
call fcn.004046ed
mov eax, dword [ebp - 0x78]
mov ecx, dword [eax]
add esp, 0x24
lea edx, [ebp + 0x39c]
push edx
push eax
call dword [ecx + 0x50]
mov eax, dword [ebp - 0x78]
mov ecx, dword [eax]
push edi
push eax
call dword [ecx + 0x2c]
mov eax, dword [ebp - 0x78]
mov ecx, dword [eax]
push ebx
push eax
call dword [ecx + 0x1c]
push dword [ebp + 0x4b8]
mov eax, dword [ebp - 0x78]
mov ecx, dword [eax]
lea edx, [ebp + 0x39c]
push edx
push eax
call dword [ecx + 0x44]
mov eax, dword [ebp - 0x78]
mov ecx, dword [eax]
lea edx, [ebp + 0x298]
push edx
push eax
call dword [ecx + 0x24]
mov eax, dword [ebp - 0x78]
mov ecx, dword [eax]
lea edx, [ebp - 0x7c]
push edx
push 0x421d4c
push eax
call dword [ecx]
test eax, eax
jne 0x40d348
push esi
lea eax, [ebp - 0x74]
push eax
push 0xffffffffffffffff
lea eax, [ebp + 0x194]
push eax
push 0
push 0
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
mov eax, dword [ebp - 0x7c]
mov ecx, dword [eax]
push 1
lea edx, [ebp - 0x74]
push edx
push eax
call dword [ecx + 0x18]
test eax, eax
je 0x40d33d
lea eax, [ebp + 0x194]
push eax
push str.Unable_to_save__s_n
call fcn.004017c6
pop ecx
pop ecx
mov eax, dword [ebp - 0x7c]
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
jmp 0x40d355
push eax
push str.Couldnt_query_ShellLink_0x_.8X_n
call fcn.004017c6
pop ecx
pop ecx
mov eax, dword [ebp - 0x78]
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
jmp 0x40d36d
push eax
push str.Couldnt_attach_ShellLink_0x_.8X_n
call fcn.004017c6
pop ecx
pop ecx
mov ecx, dword [ebp + 0x4a0]
pop edi
xor eax, eax
pop esi
xor ecx, ebp
inc eax
pop ebx
call fcn.0040f870
add ebp, 0x4a4
leave
ret
Function at 0x40f870
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x425848]
jne 0x40f87a
repz ret
jmp fcn.00414a18
Function at 0x40fe29
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
mov ecx, dword [ebp + 8]
push ebx
mov ebx, dword [ebp + 0xc]
push esi
push edi
xor edi, edi
cmp dword [ebp + 0x10], edi
mov dword [ebp - 8], ecx
mov dword [ebp - 4], ebx
je 0x40fe66
cmp dword [ebp + 0x14], edi
je 0x40fe66
cmp ecx, edi
jne 0x40fe6d
call fcn.0040ed67
push edi
push edi
push edi
push edi
mov dword [eax], 0x16
push edi
call fcn.00412467
add esp, 0x14
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret
mov esi, dword [ebp + 0x18]
cmp esi, edi
je 0x40fe81
or eax, 0xffffffff
xor edx, edx
div dword [ebp + 0x10]
cmp dword [ebp + 0x14], eax
jbe 0x40fea2
cmp ebx, 0xffffffff
je 0x40fe91
push ebx
push edi
push ecx
call fcn.0040f880
add esp, 0xc
cmp esi, edi
je 0x40fe4e
or eax, 0xffffffff
xor edx, edx
div dword [ebp + 0x10]
cmp dword [ebp + 0x14], eax
ja 0x40fe4e
mov edi, dword [ebp + 0x10]
imul edi, dword [ebp + 0x14]
test word [esi + 0xc], 0x10c
mov dword [ebp - 0x10], edi
mov ebx, edi
je 0x40febe
mov eax, dword [esi + 0x18]
mov dword [ebp - 0xc], eax
jmp 0x40fec5
mov dword [ebp - 0xc], 0x1000
test edi, edi
je 0x40ffb6
test word [esi + 0xc], 0x10c
je 0x40ff19
mov eax, dword [esi + 4]
test eax, eax
je 0x40ff19
jl 0x410017
cmp ebx, eax
mov edi, ebx
jb 0x40feea
mov edi, eax
cmp edi, dword [ebp - 4]
ja 0x40ffbe
push edi
push dword [esi]
push dword [ebp - 4]
push dword [ebp - 8]
call fcn.00416b28
sub dword [esi + 4], edi
add dword [esi], edi
add dword [ebp - 8], edi
sub ebx, edi
add esp, 0x10
sub dword [ebp - 4], edi
mov edi, dword [ebp - 0x10]
jmp 0x40ffae
cmp ebx, dword [ebp - 0xc]
jb 0x40ff86
cmp dword [ebp - 0xc], 0
je 0x40ff43
mov ecx, 0x7fffffff
xor edx, edx
cmp ebx, ecx
jbe 0x40ff38
mov eax, ecx
div dword [ebp - 0xc]
mov eax, ecx
jmp 0x40ff3f
mov eax, ebx
div dword [ebp - 0xc]
mov eax, ebx
sub eax, edx
jmp 0x40ff4e
mov eax, 0x7fffffff
cmp ebx, eax
ja 0x40ff4e
mov eax, ebx
cmp eax, dword [ebp - 4]
ja 0x40ffea
push eax
push dword [ebp - 8]
push esi
call fcn.00416687
pop ecx
push eax
call fcn.00411bce
add esp, 0xc
test eax, eax
je 0x410029
cmp eax, 0xffffffff
je 0x410017
add dword [ebp - 8], eax
sub ebx, eax
sub dword [ebp - 4], eax
jmp 0x40ffae
push esi
call fcn.00416a08
cmp eax, 0xffffffff
pop ecx
je 0x41001b
cmp dword [ebp - 4], 0
je 0x40ffea
mov ecx, dword [ebp - 8]
inc dword [ebp - 8]
mov byte [ecx], al
mov eax, dword [esi + 0x18]
dec ebx
dec dword [ebp - 4]
mov dword [ebp - 0xc], eax
test ebx, ebx
jne 0x40fecd
mov eax, dword [ebp + 0x14]
jmp 0x40fe68
xor esi, esi
cmp dword [ebp + 0xc], 0xffffffff
je 0x40ffd5
push dword [ebp + 0xc]
push esi
push dword [ebp + 8]
call fcn.0040f880
add esp, 0xc
call fcn.0040ed67
push esi
push esi
push esi
push esi
mov dword [eax], 0x22
push esi
jmp 0x40fe5e
cmp dword [ebp + 0xc], 0xffffffff
je 0x410000
push dword [ebp + 0xc]
push 0
push dword [ebp + 8]
call fcn.0040f880
add esp, 0xc
call fcn.0040ed67
mov dword [eax], 0x22
xor eax, eax
push eax
push eax
push eax
push eax
push eax
jmp 0x40fe5e
or dword [esi + 0xc], 0x20
mov eax, edi
sub eax, ebx
xor edx, edx
div dword [ebp + 0x10]
jmp 0x40fe68
or dword [esi + 0xc], 0x10
jmp 0x41001b
Function at 0x413426
Capabilities:
Write file on windows

Disassembly:
push ecx
push ebx
mov ebx, dword [esp + 0xc]
push esi
push edi
xor esi, esi
xor edi, edi
cmp ebx, dword [edi*8 + 0x425ae8]
je 0x413441
inc edi
cmp edi, 0x17
jb 0x413432
cmp edi, 0x17
jae 0x4135c1
push ebp
push 3
call fcn.004199fd
cmp eax, 1
pop ecx
je 0x41358d
push 3
call fcn.004199fd
test eax, eax
pop ecx
jne 0x413475
cmp dword [0x425a20], 1
je 0x41358d
cmp ebx, 0xfc
je 0x4135c0
push str.Runtime_Error__n_nProgram:
mov ebx, 0x314
push ebx
mov ebp, 0x428878
push ebp
call fcn.00417a8a
add esp, 0xc
test eax, eax
je 0x4134ab
push esi
push esi
push esi
push esi
push esi
call fcn.0041236b
add esp, 0x14
push 0x104
mov esi, 0x428891
push esi
push 0
mov byte [0x428995], 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x4134ef
push str._program_name_unknown_
push 0x2fb
push esi
call fcn.00417a8a
add esp, 0xc
test eax, eax
je 0x4134ef
xor eax, eax
push eax
push eax
push eax
push eax
push eax
call fcn.0041236b
add esp, 0x14
push esi
call fcn.00417c20
inc eax
cmp eax, 0x3c
pop ecx
jbe 0x413534
push esi
call fcn.00417c20
sub esi, 0x3b
add eax, esi
push 3
mov ecx, 0x428b8c
push 0x420ba4
sub ecx, eax
push ecx
push eax
call fcn.004195e0
add esp, 0x14
test eax, eax
je 0x413534
xor esi, esi
push esi
push esi
push esi
push esi
push esi
call fcn.0041236b
add esp, 0x14
jmp 0x413536
xor esi, esi
push 0x4224b0
push ebx
push ebp
call fcn.0041998c
add esp, 0xc
test eax, eax
je 0x413556
push esi
push esi
push esi
push esi
push esi
call fcn.0041236b
add esp, 0x14
push dword [edi*8 + 0x425aec]
push ebx
push ebp
call fcn.0041998c
add esp, 0xc
test eax, eax
je 0x413578
push esi
push esi
push esi
push esi
push esi
call fcn.0041236b
add esp, 0x14
push 0x12010
push str.Microsoft_Visual_C_Runtime_Library
push ebp
call fcn.004197cf
add esp, 0xc
jmp 0x4135c0
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
mov ebp, eax
cmp ebp, esi
je 0x4135c0
cmp ebp, 0xffffffff
je 0x4135c0
push 0
lea eax, [esp + 0x14]
push eax
lea esi, [edi*8 + 0x425aec]
push dword [esi]
call fcn.00417c20
pop ecx
push eax
push dword [esi]
push ebp
call dword [sym.imp.KERNEL32.dll_WriteFile]
pop ebp
pop edi
pop esi
pop ebx
pop ecx
ret
Function at 0x4197cf
Capabilities:
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
push ebx
push esi
push edi
call fcn.00412f44
xor ebx, ebx
cmp dword [0x4291a4], ebx
mov dword [ebp - 8], eax
mov dword [ebp - 4], ebx
mov dword [ebp - 0xc], ebx
mov dword [ebp - 0x10], ebx
jne 0x4198a5
push str.USER32.DLL
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
cmp edi, ebx
je 0x419985
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x42282c
push edi
call esi
cmp eax, ebx
je 0x419985
push eax
call fcn.00412ed6
mov dword [esp], str.GetActiveWindow
push edi
mov dword [0x4291a4], eax
call esi
push eax
call fcn.00412ed6
mov dword [esp], str.GetLastActivePopup
push edi
mov dword [0x4291a8], eax
call esi
push eax
call fcn.00412ed6
mov dword [0x4291ac], eax
lea eax, [ebp - 0xc]
push eax
call fcn.0040e1d5
test eax, eax
pop ecx
pop ecx
je 0x419873
push ebx
push ebx
push ebx
push ebx
push ebx
call fcn.0041236b
add esp, 0x14
cmp dword [ebp - 0xc], 2
jne 0x4198a5
push str.GetUserObjectInformationA
push edi
call esi
push eax
call fcn.00412ed6
cmp eax, ebx
pop ecx
mov dword [0x4291b4], eax
je 0x4198a5
push str.GetProcessWindowStation
push edi
call esi
push eax
call fcn.00412ed6
pop ecx
mov dword [0x4291b0], eax
mov eax, dword [0x4291b0]
mov ecx, dword [ebp - 8]
cmp eax, ecx
je 0x41992a
cmp dword [0x4291b4], ecx
je 0x41992a
push eax
call fcn.00412f4d
push dword [0x4291b4]
mov esi, eax
call fcn.00412f4d
cmp esi, ebx
pop ecx
pop ecx
mov edi, eax
je 0x41992a
cmp edi, ebx
je 0x41992a
call esi
cmp eax, ebx
je 0x4198f7
lea ecx, [ebp - 0x14]
push ecx
push 0xc
lea ecx, [ebp - 0x20]
push ecx
push 1
push eax
call edi
test eax, eax
je 0x4198f7
test byte [ebp - 0x18], 1
jne 0x41992a
lea eax, [ebp - 0x10]
push eax
call fcn.0040e20c
test eax, eax
pop ecx
je 0x419912
push ebx
push ebx
push ebx
push ebx
push ebx
call fcn.0041236b
add esp, 0x14
cmp dword [ebp - 0x10], 4
jb 0x419921
or dword [ebp + 0x10], 0x200000
jmp 0x419965
or dword [ebp + 0x10], 0x40000
jmp 0x419965
mov eax, dword [0x4291a8]
cmp eax, dword [ebp - 8]
je 0x419965
push eax
call fcn.00412f4d
cmp eax, ebx
pop ecx
je 0x419965
call eax
cmp eax, ebx
mov dword [ebp - 4], eax
je 0x419965
mov eax, dword [0x4291ac]
cmp eax, dword [ebp - 8]
je 0x419965
push eax
call fcn.00412f4d
cmp eax, ebx
pop ecx
je 0x419965
push dword [ebp - 4]
call eax
mov dword [ebp - 4], eax
push dword [0x4291a4]
call fcn.00412f4d
cmp eax, ebx
pop ecx
je 0x419985
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [ebp - 4]
call eax
jmp 0x419987
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret