joyce8/EMBER2024-capa huggingface dataset:
Function at 0x405dcd
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
cmp dword [0x422a94], 0
push esi
jne 0x405e04
xor ecx, ecx
push 8
mov eax, ecx
pop esi
mov edx, eax
and dl, 1
neg dl
sbb edx, edx
and edx, 0xedb88320
shr eax, 1
xor eax, edx
dec esi
jne 0x405dde
mov dword [ecx*4 + 0x422a90], eax
inc ecx
cmp ecx, 0x100
jl 0x405dd9
mov edx, dword [esp + 0x10]
mov eax, dword [esp + 8]
test edx, edx
not eax
jbe 0x405e35
mov ecx, dword [esp + 0xc]
push edi
movzx edi, byte [ecx]
mov esi, eax
and esi, 0xff
xor esi, edi
shr eax, 8
mov esi, dword [esi*4 + 0x422a90]
xor eax, esi
inc ecx
dec edx
jne 0x405e17
pop edi
not eax
pop esi
ret 0xc

Function at 0x1002fab
Capabilities:
Parse pe header
Terminate process

Disassembly:
push 0x28
push 0x10012b0
call fcn.01003148
xor edi, edi
push edi
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
cmp word [eax], 0x5a4d
jne 0x1002fe6
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x1002fe6
movzx eax, word [ecx + 0x18]
cmp eax, 0x10b
je 0x1002ffe
cmp eax, 0x20b
je 0x1002feb
mov dword [ebp - 0x1c], edi
jmp 0x1003012
cmp dword [ecx + 0x84], 0xe
jbe 0x1002fe6
xor eax, eax
cmp dword [ecx + 0xf8], edi
jmp 0x100300c
cmp dword [ecx + 0x74], 0xe
jbe 0x1002fe6
xor eax, eax
cmp dword [ecx + 0xe8], edi
setne al
mov dword [ebp - 0x1c], eax
mov dword [ebp - 4], edi
push 1
call dword [sym.imp.msvcrt.dll___set_app_type]
pop ecx
or dword [0x1004034], 0xffffffff
or dword [0x1004038], 0xffffffff
call dword [sym.imp.msvcrt.dll___p__fmode]
mov ecx, dword [0x1004030]
mov dword [eax], ecx
call dword [sym.imp.msvcrt.dll___p__commode]
mov ecx, dword [0x100402c]
mov dword [eax], ecx
mov eax, dword [sym.imp.msvcrt.dll__adjust_fdiv]
mov eax, dword [eax]
mov dword [0x100403c], eax
call fcn.01003144
cmp dword [0x100401c], edi
jne 0x100306d
push fcn.01003144
call dword [sym.imp.msvcrt.dll___setusermatherr]
pop ecx
call fcn.01003132
push 0x10011a8
push 0x10011a4
call sub.msvcrt.dll__initterm
mov eax, dword [0x1004028]
mov dword [ebp - 0x20], eax
lea eax, [ebp - 0x20]
push eax
push dword [0x1004024]
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x28]
push eax
lea eax, [ebp - 0x2c]
push eax
call dword [sym.imp.msvcrt.dll___getmainargs]
mov dword [ebp - 0x30], eax
push 0x10011a0
push 0x100119c
call sub.msvcrt.dll__initterm
mov eax, dword [ebp - 0x24]
mov ecx, dword [sym.imp.msvcrt.dll___initenv]
mov dword [ecx], eax
push dword [ebp - 0x24]
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
call fcn.01002f3c
add esp, 0x30
mov esi, eax
mov dword [ebp - 0x34], esi
cmp dword [ebp - 0x1c], edi
jne 0x10030e4
push esi
call dword [sym.imp.msvcrt.dll_exit]
call dword [sym.imp.msvcrt.dll__cexit]
jmp 0x1003119
or dword [ebp - 4], 0xffffffff
mov eax, esi
call fcn.01003181
ret
Function at 0x4034a0
Capabilities:
Get file version info
Reference cloudflare dns server

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x41e38b
mov eax, dword fs:[0]
push eax
sub esp, 0x238
mov eax, dword [0x4276b0]
xor eax, ebp
mov dword [ebp - 0x14], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x244], 0
lea ecx, [ebp - 0x220]
call fcn.00404ed0
mov dword [ebp - 4], 0
mov dword [ebp - 0x228], 0
push 0x208
lea eax, [ebp - 0x21c]
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
lea ecx, [ebp - 0x10]
push ecx
lea edx, [ebp - 0x21c]
push edx
call sub.VERSION.dll_GetFileVersionInfoSizeW
mov dword [ebp - 0x228], eax
cmp dword [ebp - 0x228], 0
je 0x403650
mov dword [ebp - 0x240], 0
mov eax, dword [ebp - 0x228]
push eax
push 2
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov dword [ebp - 0x22c], eax
mov ecx, dword [ebp - 0x22c]
push ecx
call dword [sym.imp.KERNEL32.dll_GlobalLock]
mov dword [ebp - 0x230], eax
mov edx, dword [ebp - 0x230]
push edx
mov eax, dword [ebp - 0x228]
push eax
mov ecx, dword [ebp - 0x10]
push ecx
lea edx, [ebp - 0x21c]
push edx
call sub.VERSION.dll_GetFileVersionInfoW
lea eax, [ebp - 0x240]
push eax
lea ecx, [ebp - 0x224]
push ecx
push 0x422b0c
mov edx, dword [ebp - 0x230]
push edx
call sub.VERSION.dll_VerQueryValueW
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x23c], eax
mov eax, dword [ebp - 0x224]
mov ecx, dword [eax + 0x10]
shr ecx, 0x10
and ecx, 0xffff
mov word [ebp - 0x238], cx
mov edx, dword [ebp - 0x224]
mov eax, dword [edx + 0x10]
and eax, 0xffff
mov word [ebp - 0x236], ax
mov ecx, dword [ebp - 0x224]
mov edx, dword [ecx + 0x14]
shr edx, 0x10
and edx, 0xffff
mov word [ebp - 0x234], dx
mov eax, dword [ebp - 0x224]
mov ecx, dword [eax + 0x14]
and ecx, 0xffff
mov word [ebp - 0x232], cx
movzx edx, word [ebp - 0x232]
push edx
movzx eax, word [ebp - 0x234]
push eax
movzx ecx, word [ebp - 0x236]
push ecx
movzx edx, word [ebp - 0x238]
push edx
push 0x422b10
lea eax, [ebp - 0x220]
push eax
call fcn.00405860
add esp, 0x18
mov ecx, dword [ebp - 0x22c]
push ecx
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
mov edx, dword [ebp - 0x22c]
push edx
call dword [sym.imp.KERNEL32.dll_GlobalFree]
jmp 0x403664
push str.1.0.0.1
lea eax, [ebp - 0x220]
push eax
call fcn.00405860
add esp, 8
lea ecx, [ebp - 0x220]
push ecx
mov ecx, dword [ebp + 8]
call fcn.00404ef0
mov edx, dword [ebp - 0x244]
or edx, 1
mov dword [ebp - 0x244], edx
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x220]
call fcn.00404f90
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.004098d7
mov esp, ebp
pop ebp
ret
Function at 0x4036b0
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x41e4d8
mov eax, dword fs:[0]
push eax
sub esp, 8
mov eax, dword [0x4276b0]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 4], 0
lea eax, [ebp - 0x14]
push eax
call fcn.004034a0
add esp, 4
mov byte [ebp - 4], 1
push 0x422b38
lea ecx, [ebp - 0x10]
call fcn.00404f10
mov byte [ebp - 4], 2
mov ecx, dword [ebp - 0x14]
push ecx
push str._updateupdate.xmlhttp:__www.koo9.com_game_update.xml_s
lea edx, [ebp - 0x10]
push edx
call fcn.00405860
add esp, 0xc
push 5
push 0
push 0
lea ecx, [ebp - 0x10]
call fcn.00404fc0
push eax
lea ecx, [ebp + 8]
call fcn.00404fb0
push eax
push str.open
push 0
call dword [sym.imp.SHELL32.dll_ShellExecuteW]
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x10]
call fcn.00404f90
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x14]
call fcn.00404f90
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.00404f90
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov esp, ebp
pop ebp
ret
Function at 0x4098d7
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x4276b0]
jne 0x4098e1
repz ret
jmp fcn.0040f59b

Function at 0x40a78d
Capabilities:
Check if file exists
Get file attributes

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
xor esi, esi
cmp dword [ebp + 8], esi
jne 0x40a7be
call fcn.0040a953
mov dword [eax], esi
call fcn.0040a940
push esi
push esi
push esi
push esi
push esi
mov dword [eax], 0x16
call fcn.00409e95
add esp, 0x14
push 0x16
pop eax
jmp 0x40a813
test dword [ebp + 0xc], 0xfffffff9
jne 0x40a79a
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x40a7eb
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.0040a966
pop ecx
call fcn.0040a940
mov eax, dword [eax]
jmp 0x40a813
test al, 0x10
jne 0x40a811
test al, 1
je 0x40a811
test byte [ebp + 0xc], 2
je 0x40a811
call fcn.0040a953
mov dword [eax], 5
call fcn.0040a940
mov dword [eax], 0xd
jmp 0x40a7e2
xor eax, eax
pop esi
pop ebp
ret

Function at 0x419fcd
Capabilities:
Link many functions at runtime

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
push esi
push edi
call fcn.0040f8b1
and dword [ebp - 4], 0
cmp dword [0x429dec], 0
mov ebx, eax
jne 0x41a07e
push str.USER32.DLL
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
test edi, edi
je 0x41a12f
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.MessageBoxA
push edi
call esi
test eax, eax
je 0x41a12f
push eax
call fcn.0040f83f
mov dword [esp], str.GetActiveWindow
push edi
mov dword [0x429dec], eax
call esi
push eax
call fcn.0040f83f
mov dword [esp], str.GetLastActivePopup
push edi
mov dword [0x429df0], eax
call esi
push eax
call fcn.0040f83f
mov dword [esp], str.GetUserObjectInformationA
push edi
mov dword [0x429df4], eax
call esi
push eax
call fcn.0040f83f
pop ecx
mov dword [0x429dfc], eax
test eax, eax
je 0x41a07e
push str.GetProcessWindowStation
push edi
call esi
push eax
call fcn.0040f83f
pop ecx
mov dword [0x429df8], eax
mov eax, dword [0x429df8]
cmp eax, ebx
je 0x41a0d6
cmp dword [0x429dfc], ebx
je 0x41a0d6
push eax
call fcn.0040f8ba
push dword [0x429dfc]
mov esi, eax
call fcn.0040f8ba
pop ecx
pop ecx
mov edi, eax
test esi, esi
je 0x41a0d6
test edi, edi
je 0x41a0d6
call esi
test eax, eax
je 0x41a0cd
lea ecx, [ebp - 8]
push ecx
push 0xc
lea ecx, [ebp - 0x14]
push ecx
push 1
push eax
call edi
test eax, eax
je 0x41a0cd
test byte [ebp - 0xc], 1
jne 0x41a0d6
or dword [ebp + 0x10], 0x200000
jmp 0x41a10f
mov eax, dword [0x429df0]
cmp eax, ebx
je 0x41a10f
push eax
call fcn.0040f8ba
pop ecx
test eax, eax
je 0x41a10f
call eax
mov dword [ebp - 4], eax
test eax, eax
je 0x41a10f
mov eax, dword [0x429df4]
cmp eax, ebx
je 0x41a10f
push eax
call fcn.0040f8ba
pop ecx
test eax, eax
je 0x41a10f
push dword [ebp - 4]
call eax
mov dword [ebp - 4], eax
push dword [0x429dec]
call fcn.0040f8ba
pop ecx
test eax, eax
je 0x41a12f
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [ebp - 4]
call eax
jmp 0x41a131
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret
Function at 0x401a30
Capabilities:
Check if file exists
Create directory

Disassembly:
sub esp, 0x800
xor eax, eax
push ebx
push ebp
push esi
mov ebp, ecx
push edi
mov edi, dword [esp + 0x814]
or ecx, 0xffffffff
mov dword [ebp], 0x4136e4
mov dword [ebp + 4], 1
lea edx, [ebp + 8]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp byte [ecx + ebp + 7], 0x5c
je 0x401aae
mov edi, 0x41c048
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov eax, dword [esp + 0x820]
test eax, eax
je 0x401bb0
mov edi, edx
or ecx, 0xffffffff
xor eax, eax
lea ebx, [esp + 0x10]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov edx, ecx
mov esi, edi
mov edi, ebx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea edi, [esp + 0x10]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp byte [esp + ecx + 0xf], 0x5c
je 0x401b21
mov edi, 0x41c048
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x10]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, 0xff
xor eax, eax
lea edi, [esp + 0x411]
mov byte [esp + 0x410], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov edi, dword [sym.imp.MSVCRT.dll__mbschr]
lea eax, [esp + 0x10]
push 0x5c
push eax
call edi
mov esi, eax
add esp, 8
test esi, esi
je 0x401ba9
mov ebx, dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
inc esi
push 0x5c
push esi
call edi
mov esi, eax
add esp, 8
test esi, esi
je 0x401ba9
mov ecx, esi
lea edx, [esp + 0x10]
sub ecx, edx
lea eax, [esp + 0x10]
push ecx
lea ecx, [esp + 0x414]
push eax
push ecx
call dword [sym.imp.MSVCRT.dll__mbsnbcpy]
add esp, 0xc
lea edx, [esp + 0x410]
push 0
push edx
call ebx
test eax, eax
jne 0x401b5a
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
je 0x401b5a
xor eax, eax
jmp 0x401bb7
mov eax, 1
jmp 0x401bb7
push edx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
mov dword [ebp + 0x10c], eax
pop edi
mov eax, ebp
pop esi
pop ebp
pop ebx
add esp, 0x800
ret 0x10
Function at 0x403b40
Capabilities:
Create directory

Disassembly:
push esi
mov esi, dword [esp + 8]
mov eax, dword [esi + 4]
test eax, eax
jne 0x403b51
mov eax, dword [sym.imp.MSVCP60.dll_char_const__private:_static_char_const____cdecl_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::_Nullstr_void_::_2::_C]
push eax
call dword [sym.imp.MSVCRT.dll__chdir]
add esp, 4
test eax, eax
je 0x403b75
mov eax, dword [esi + 4]
test eax, eax
jne 0x403b6b
mov eax, dword [sym.imp.MSVCP60.dll_char_const__private:_static_char_const____cdecl_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::_Nullstr_void_::_2::_C]
push eax
call dword [sym.imp.MSVCRT.dll__mkdir]
add esp, 4
pop esi
ret
Function at 0x407920
Capabilities:
Query or enumerate registry value

Disassembly:
push ecx
mov ecx, dword [esp + 0xc]
mov edx, dword [esp + 8]
lea eax, [esp]
push esi
xor esi, esi
push eax
push 0x20019
push esi
push ecx
push edx
mov dword [esp + 0x18], esi
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x407983
mov ecx, dword [esp + 0x18]
lea eax, [esp + 0x1c]
push eax
mov eax, dword [esp + 0x18]
lea edx, [esp + 0x14]
push ecx
mov ecx, dword [esp + 0xc]
push edx
push esi
push eax
push ecx
mov dword [esp + 0x28], 4
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x407978
mov esi, 1
mov edx, dword [esp + 4]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, esi
pop esi
pop ecx
ret

Function at 0x407990
Capabilities:
Create directory
Get common file path

Disassembly:
push 0xffffffffffffffff
push 0x4118c1
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x110
mov al, byte [0x41ca91]
push ebx
push esi
mov ebx, 1
xor esi, esi
test bl, al
mov dword [esp + 8], esi
jne 0x4079e2
mov dl, al
mov ecx, 0x41ca8c
or dl, bl
mov byte [0x41ca91], dl
call sub.MFC42.DLL_CString::CString_3
push 0x407b20
call fcn.00410fac
add esp, 4
mov eax, dword [0x41ca8c]
cmp dword [eax - 8], esi
jne 0x407ae9
push edi
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0x19]
mov byte [esp + 0x18], 0
push ebx
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea ecx, [esp + 0x1c]
push 5
push ecx
push esi
stosb byte es:[edi], al
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathA]
test eax, eax
pop edi
jl 0x407a7e
lea edx, [esp + 0x14]
mov ecx, 0x41ca8c
push edx
call sub.MFC42.DLL_CString::operator_2
mov eax, dword [0x41ca8c]
mov ecx, dword [eax - 8]
cmp byte [eax + ecx - 1], 0x5c
je 0x407a47
push 0x41c048
mov ecx, 0x41ca8c
call sub.MFC42.DLL_CString::operator
push str.My_Books_
lea eax, [esp + 0x14]
push 0x41ca8c
push eax
call sub.MFC42.DLL_operator
push eax
mov ecx, 0x41ca8c
mov dword [esp + 0x124], esi
call fcn.00410cc8
mov dword [esp + 0x120], 0xffffffff
lea ecx, [esp + 0x10]
jmp 0x407ad4
lea edx, [esp + 8]
push edx
call fcn.00407860
add esp, 4
push str.Books_
push eax
lea eax, [esp + 0x14]
mov dword [esp + 0x128], ebx
push eax
call sub.MFC42.DLL_operator
push eax
mov ecx, 0x41ca8c
mov byte [esp + 0x124], 2
call fcn.00410cc8
lea ecx, [esp + 0xc]
mov byte [esp + 0x120], bl
call sub.MFC42.DLL_CString::CString
mov dword [esp + 0x120], 0xffffffff
lea ecx, [esp + 8]
call sub.MFC42.DLL_CString::CString
mov ecx, dword [0x41ca8c]
push ecx
call dword [sym.imp.MSVCRT.dll__mkdir]
add esp, 4
mov esi, dword [esp + 0x128]
push 0x41ca8c
mov ecx, esi
call sub.MFC42.DLL_CString::CString_1
mov ecx, dword [esp + 0x118]
mov eax, esi
pop esi
pop ebx
mov dword fs:[0], ecx
add esp, 0x11c
ret

Function at 0x407b30
Capabilities:
Read .ini file

Disassembly:
mov eax, dword [esp + 4]
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0xc]
push eax
mov eax, dword [esp + 0xc]
push ecx
push edx
push eax
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileIntA]
ret
Function at 0x407b50
Capabilities:
Read .ini file

Disassembly:
mov eax, dword [esp + 4]
mov ecx, dword [esp + 0xc]
mov edx, dword [esp + 8]
push eax
push 0
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileIntA]
ret

Function at 0x407b70
Capabilities:
Read .ini file

Disassembly:
sub esp, 0x404
push esi
push edi
xor edx, edx
mov ecx, 0xff
xor eax, eax
lea edi, [esp + 0xd]
mov byte [esp + 0xc], dl
mov dword [esp + 8], edx
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov eax, dword [esp + 0x414]
lea ecx, [esp + 0xc]
push eax
mov eax, dword [esp + 0x41c]
push 0x400
push ecx
push edx
mov edx, dword [esp + 0x42c]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
mov esi, dword [esp + 0x410]
lea ecx, [esp + 0xc]
push ecx
mov ecx, esi
call fcn.00410c7a
mov eax, esi
pop edi
pop esi
add esp, 0x404
ret
Function at 0x407c40
Capabilities:
Check if file exists
Copy file

Disassembly:
push 0xffffffffffffffff
push 0x41191f
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x20
lea eax, [esp + 0x14]
mov dword [esp + 0x1c], 0
push eax
call fcn.00407990
add esp, 4
push str.CyberArticleSample.book
lea ecx, [esp + 8]
push eax
push ecx
mov dword [esp + 0x34], 1
call sub.MFC42.DLL_operator
lea ecx, [esp + 0x14]
mov byte [esp + 0x28], 3
call sub.MFC42.DLL_CString::CString
push str.SoftwareCyberArticleCurrentFileName
lea ecx, [esp + 0x14]
call fcn.00410c7a
push str.FileName
lea ecx, [esp + 0x10]
mov byte [esp + 0x2c], 4
call fcn.00410c7a
lea ecx, [esp]
mov byte [esp + 0x28], 5
call sub.MFC42.DLL_CString::CString_3
push 0x400
lea ecx, [esp + 4]
mov byte [esp + 0x2c], 6
call sub.MFC42.DLL_CString::GetBuffer
mov edx, dword [esp + 0xc]
push 0x400
push eax
mov eax, dword [esp + 0x18]
push edx
push eax
push SysReAllocStringLen
call fcn.00407920
add esp, 0x14
lea ecx, [esp]
push 0xffffffffffffffff
call sub.MFC42.DLL_CString::ReleaseBuffer
mov ecx, dword [esp]
mov eax, dword [ecx - 8]
test eax, eax
jne 0x407d16
lea edx, [esp + 4]
lea ecx, [esp]
push edx
call fcn.00410cc8
mov eax, dword [esp]
mov ecx, dword [esp + 4]
push eax
push ecx
call dword [sym.imp.MSVCRT.dll__mbscmp]
add esp, 8
test eax, eax
jne 0x407d8c
mov edx, dword [esp + 4]
push edx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
jne 0x407d8c
lea eax, [esp + 0x18]
push eax
call fcn.00407860
add esp, 4
push str.CyberArticleSample.book
lea ecx, [esp + 0xc]
push eax
push ecx
mov byte [esp + 0x34], 7
call sub.MFC42.DLL_operator
lea ecx, [esp + 0x18]
mov byte [esp + 0x28], 9
call sub.MFC42.DLL_CString::CString
mov edx, dword [esp]
mov eax, dword [esp + 8]
push 1
push edx
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileA]
lea ecx, [esp + 8]
mov byte [esp + 0x28], 6
call sub.MFC42.DLL_CString::CString
push esi
mov esi, dword [esp + 0x34]
lea ecx, [esp + 4]
push ecx
mov ecx, esi
call sub.MFC42.DLL_CString::CString_1
mov dword [esp + 0x20], 1
lea ecx, [esp + 4]
mov byte [esp + 0x2c], 5
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x10]
mov byte [esp + 0x2c], 4
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x14]
mov byte [esp + 0x2c], 3
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 8]
mov byte [esp + 0x2c], 0
call sub.MFC42.DLL_CString::CString
mov ecx, dword [esp + 0x24]
mov eax, esi
pop esi
mov dword fs:[0], ecx
add esp, 0x2c
ret

Function at 0x407df0
Capabilities:
Get common file path

Disassembly:
sub esp, 0x404
push esi
push edi
xor eax, eax
mov ecx, 0xff
lea edi, [esp + 0xd]
mov dword [esp + 8], eax
mov byte [esp + 0xc], al
push 0x400
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea eax, [esp + 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
mov esi, dword [esp + 0x410]
lea ecx, [esp + 0xc]
push ecx
mov ecx, esi
call fcn.00410c7a
mov eax, esi
pop edi
pop esi
add esp, 0x404
ret
Function at 0x407e40
Capabilities:
Get common file path

Disassembly:
sub esp, 0x404
push esi
push edi
xor eax, eax
mov ecx, 0xff
lea edi, [esp + 0xd]
mov dword [esp + 8], eax
mov byte [esp + 0xc], al
push 0x400
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea eax, [esp + 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
mov esi, dword [esp + 0x410]
lea ecx, [esp + 0xc]
push ecx
mov ecx, esi
call fcn.00410c7a
mov eax, esi
pop edi
pop esi
add esp, 0x404
ret

Function at 0x407e90
Capabilities:
Get common file path
Get program files directory

Disassembly:
push 0xffffffffffffffff
push 0x411955
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x10c
push edi
lea ecx, [esp + 4]
mov dword [esp + 8], 0
call sub.MFC42.DLL_CString::CString_3
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0xd]
mov byte [esp + 0xc], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
push 1
lea eax, [esp + 0x10]
push 0x26
push eax
push 0
mov dword [esp + 0x128], 1
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathA]
test eax, eax
pop edi
jl 0x407f1d
lea ecx, [esp + 8]
push ecx
lea ecx, [esp + 4]
call sub.MFC42.DLL_CString::operator_2
mov eax, dword [esp]
mov ecx, dword [eax - 8]
cmp byte [ecx + eax - 1], 0x5c
je 0x407f1d
push 0x41c048
lea ecx, [esp + 4]
call sub.MFC42.DLL_CString::operator
push esi
mov esi, dword [esp + 0x120]
lea edx, [esp + 4]
mov ecx, esi
push edx
call sub.MFC42.DLL_CString::CString_1
mov dword [esp + 8], 1
lea ecx, [esp + 4]
mov byte [esp + 0x118], 0
call sub.MFC42.DLL_CString::CString
mov ecx, dword [esp + 0x110]
mov eax, esi
pop esi
mov dword fs:[0], ecx
add esp, 0x118
ret
Function at 0x4098c0
Capabilities:
Check if file exists

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x411ce2
push eax
mov eax, 0x1024
mov dword fs:[0], esp
call fcn.00410fd0
push ebx
push esi
mov esi, dword [esp + 0x1044]
push edi
push esi
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
je 0x40991a
mov eax, dword [esp + 0x104c]
test eax, eax
jne 0x40991a
mov ecx, dword [esp + 0x1040]
mov edx, dword [esp + 0x1044]
push 1
push edx
mov eax, dword [ecx]
call dword [eax + 0x30]
jmp 0x409a77
lea ecx, [esp + 0x20]
call sub.MFC42.DLL_CFile::CFile
lea ecx, [esp + 0xc]
mov dword [esp + 0x1038], 0
call sub.MFC42.DLL_CException::CException
lea ecx, [esp + 0x1c]
mov byte [esp + 0x1038], 1
call sub.MFC42.DLL_CString::CString_3
mov ebx, 0x4136c8
or edi, 0xffffffff
push 0
lea ecx, [esp + 0x20]
mov byte [esp + 0x103c], 2
mov dword [esp + 0x10], ebx
mov dword [esp + 0x18], 0
mov dword [esp + 0x1c], edi
call sub.MFC42.DLL_CString::operator_2
lea eax, [esp + 0xc]
lea ecx, [esp + 0x20]
push eax
push 0x1001
push esi
mov byte [esp + 0x1044], 3
call sub.MFC42.DLL_CFile::Open
test eax, eax
jne 0x4099d2
push eax
push eax
lea ecx, [esp + 0x14]
call sub.MFC42.DLL_CException::ReportError
mov dword [esp + 0xc], ebx
lea ecx, [esp + 0x1c]
mov byte [esp + 0x1038], 4
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x20]
mov dword [esp + 0xc], 0x413668
mov dword [esp + 0x1038], edi
call fcn.00410eb4
xor eax, eax
jmp 0x409a7c
mov ecx, dword [esp + 0x1044]
mov esi, dword [esp + 0x1040]
mov eax, ecx
and ecx, 0xfff
shr eax, 0xc
test eax, eax
mov ebx, ecx
jle 0x409a1d
mov edi, eax
mov edx, dword [esi]
lea eax, [esp + 0x30]
push 0x1000
push eax
mov ecx, esi
call dword [edx + 0x3c]
lea ecx, [esp + 0x30]
push 0x1000
push ecx
lea ecx, [esp + 0x28]
call sub.MFC42.DLL_CFile::Write
dec edi
jne 0x4099f3
or edi, 0xffffffff
test ebx, ebx
jle 0x409a3d
mov edx, dword [esi]
lea eax, [esp + 0x30]
push ebx
push eax
mov ecx, esi
call dword [edx + 0x3c]
lea ecx, [esp + 0x30]
push ebx
push ecx
lea ecx, [esp + 0x28]
call sub.MFC42.DLL_CFile::Write
lea ecx, [esp + 0x20]
call sub.MFC42.DLL_CFile::Close
mov dword [esp + 0xc], 0x4136c8
lea ecx, [esp + 0x1c]
mov byte [esp + 0x1038], 5
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x20]
mov dword [esp + 0xc], 0x413668
mov dword [esp + 0x1038], edi
call fcn.00410eb4
mov eax, 1
mov ecx, dword [esp + 0x1030]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
add esp, 0x1030
ret