joyce8/EMBER2024-capa huggingface dataset:
Function at 0x401d10
Capabilities:
Query or enumerate registry value

Disassembly:
sub esp, 0xd0
mov eax, dword [0x4d437c]
xor eax, esp
mov dword [esp + 0xcc], eax
push esi
push edi
lea eax, [esp + 8]
push eax
push 0x4be6f8
xor edi, edi
push 0x80000002
mov dword [esp + 0x14], edi
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyW]
test eax, eax
je 0x401d82
call fcn.004b6ae0
mov edi, eax
mov esi, dword [edi]
push 0x11a
add esi, 8
call fcn.00401140
mov ecx, dword [esi]
push eax
push str._s:_Failed_to_open_key
push edi
call ecx
add esp, 0x10
pop edi
xor eax, eax
pop esi
mov ecx, dword [esp + 0xcc]
xor ecx, esp
call fcn.004b76e6
add esp, 0xd0
ret
push 0x7e
lea edx, [esp + 0x5a]
push edi
push edx
mov word [esp + 0x60], di
call sub.ntdll.dll_memset
push 0x3e
lea eax, [esp + 0x26]
push edi
push eax
mov word [esp + 0x2c], di
call sub.ntdll.dll_memset
mov esi, dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
add esp, 0x18
lea ecx, [esp + 0xc]
push ecx
mov ecx, dword [esp + 0xc]
lea edx, [esp + 0x58]
push edx
lea eax, [esp + 0x18]
push eax
push edi
push str.ProductName
push ecx
mov dword [esp + 0x28], edi
mov dword [esp + 0x24], 0x80
call esi
test eax, eax
jne 0x401e0e
lea edx, [esp + 0x54]
push str.Windows_Server_2022
push edx
call dword [sym.imp.ntdll.dll_wcsstr]
add esp, 8
test eax, eax
je 0x401e0e
pop edi
mov eax, 0x55f0
pop esi
mov ecx, dword [esp + 0xcc]
xor ecx, esp
call fcn.004b76e6
add esp, 0xd0
ret
lea eax, [esp + 0xc]
push eax
mov eax, dword [esp + 0xc]
lea ecx, [esp + 0x18]
push ecx
lea edx, [esp + 0x18]
push edx
push edi
push str.CurrentBuildNumber
push eax
mov dword [esp + 0x24], 0x40
call esi
test eax, eax
je 0x401ea8
lea ecx, [esp + 0xc]
push ecx
mov ecx, dword [esp + 0xc]
lea edx, [esp + 0x18]
push edx
lea eax, [esp + 0x18]
push eax
push edi
push str.CurrentBuildNumber
push ecx
call esi
test eax, eax
je 0x401ea8
call fcn.004b6ae0
mov edi, eax
mov esi, dword [edi]
add esi, 8
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x133
call fcn.00401140
mov edx, dword [esi]
add esp, 4
push eax
push str._s:_Failed_to_get_current_os_build_version.__d
push edi
call edx
mov eax, dword [esp + 0x18]
add esp, 0x10
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
xor eax, eax
pop esi
mov ecx, dword [esp + 0xcc]
xor ecx, esp
call fcn.004b76e6
add esp, 0xd0
ret
mov ecx, dword [esp + 8]
push ebx
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea edx, [esp + 0x18]
push edx
call dword [sym.imp.ntdll.dll__wtoi]
add esp, 4
mov edi, eax
call fcn.004b6ae0
mov ebx, eax
mov esi, dword [ebx]
push edi
push 0x140
add esi, 8
call fcn.00401140
add esp, 4
push eax
mov eax, dword [esi]
push str._s:_Build_Number:__d
push ebx
call eax
mov ecx, dword [esp + 0xe8]
add esp, 0x10
pop ebx
mov eax, edi
pop edi
pop esi
xor ecx, esp
call fcn.004b76e6
add esp, 0xd0
ret
Function at 0x401f10
Capabilities:
Check os version

Disassembly:
sub esp, 0x124
mov eax, dword [0x4d437c]
xor eax, esp
mov dword [esp + 0x120], eax
push esi
push 0x4be81c
mov dword [esp + 8], 0
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], 0
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
test eax, eax
mov esi, dword [sym.imp.MSVCR80.dll_printf]
jne 0x401fd9
push str.Failed_to_load_ntdll.dll_n
call esi
add esp, 4
push 0x114
lea edx, [esp + 0x14]
push 0
push edx
call sub.ntdll.dll_memset
add esp, 0xc
lea eax, [esp + 0x10]
push eax
mov dword [esp + 0x14], 0x114
call dword [sym.imp.KERNEL32.dll_GetVersionExW]
test eax, eax
je 0x401fa3
mov ecx, dword [esp + 0x14]
mov edx, dword [esp + 0x18]
mov eax, dword [esp + 0x1c]
mov dword [esp + 8], ecx
mov dword [esp + 0xc], edx
mov dword [esp + 4], eax
call fcn.00401d10
mov ecx, dword [esp + 0xc]
mov edx, dword [esp + 8]
push eax
push ecx
push edx
push str.Current_os_version:__d._d_BuildID:__d_n
mov dword [esp + 0x14], eax
call esi
add esp, 0x10
cmp dword [esp + 8], 0xa
jb 0x402006
cmp dword [esp + 4], 0x55f0
jb 0x402006
push str.Current_OS_is_win11._n
jmp 0x40200b
push str.RtlGetNtVersionNumbers
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
jne 0x401ff3
push str.Failed_to_get_RtlGetNtVersionNumbers_n
jmp 0x401f5b
lea ecx, [esp + 4]
push ecx
lea edx, [esp + 0x10]
push edx
lea ecx, [esp + 0x10]
push ecx
call eax
jmp 0x401fa3
push str.Current_OS_is_not_win11._n
call esi
add esp, 4
cmp dword [esp + 8], 0xa
pop esi
jb 0x40203b
cmp dword [esp], 0x55f0
jb 0x40203b
mov eax, 1
mov ecx, dword [esp + 0x120]
xor ecx, esp
call fcn.004b76e6
add esp, 0x124
ret
mov ecx, dword [esp + 0x120]
xor ecx, esp
xor eax, eax
call fcn.004b76e6
add esp, 0x124
ret
Function at 0x402060
Capabilities:
Access peb ldr_data
Check if file exists
Create directory
Get common file path
Get file attributes

Disassembly:
push 0xffffffffffffffff
push 0x4b8f4c
mov eax, dword fs:[0]
push eax
sub esp, 0x124
mov eax, dword [0x4d437c]
xor eax, esp
mov dword [esp + 0x120], eax
push edi
mov eax, dword [0x4d437c]
xor eax, esp
push eax
lea eax, [esp + 0x12c]
mov dword fs:[0], eax
push 0x103
lea eax, [esp + 0x29]
push 0
push eax
mov byte [esp + 0x30], 0
call sub.ntdll.dll_memset
add esp, 0xc
lea ecx, [esp + 0x24]
push ecx
push 0
push 0
push 0x23
push 0
call dword [sym.imp.SHELL32.dll_SHGetFolderPathA]
push str.AomeiBR
lea edx, [esp + 0x28]
push 0x104
push edx
call dword [sym.imp.MSVCR80.dll_strcat_s]
add esp, 0xc
lea eax, [esp + 0x24]
push eax
lea ecx, [esp + 0xc]
call dword [sym.imp.MSVCP80.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::constructor_char_const__]
mov dword [esp + 0x134], 0
cmp dword [esp + 0x20], 0x10
mov eax, dword [esp + 0xc]
jae 0x402105
lea eax, [esp + 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x40214d
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
call edi
cmp eax, 2
jne 0x40214d
cmp dword [esp + 0x20], 0x10
mov eax, dword [esp + 0xc]
jae 0x40212d
lea eax, [esp + 0xc]
push 0
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
test eax, eax
jne 0x40214d
call edi
push eax
push str.Failed_to_CreateDirectory_by_GetUserConfig_____d
call dword [sym.imp.MSVCR80.dll_printf]
add esp, 8
jmp 0x402174
lea ecx, [esp + 8]
push ecx
mov ecx, esi
call dword [0x4bd1cc]
push 0x4be6f0
mov ecx, esi
call dword [0x4bd1f8]
push str.usercfg.ini
mov ecx, esi
call dword [0x4bd1f8]
lea ecx, [esp + 8]
mov dword [esp + 0x134], 0xffffffff
call dword [sym.imp.MSVCP80.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::destructor_void_]
mov ecx, dword [esp + 0x12c]
mov dword fs:[0], ecx
pop ecx
pop edi
mov ecx, dword [esp + 0x120]
xor ecx, esp
call fcn.004b76e6
add esp, 0x130
ret
Function at 0x4021b0
Capabilities:
Delete file
Query or enumerate registry value
Write file on windows

Disassembly:
sub esp, 0x2c
mov eax, dword [0x4d437c]
xor eax, esp
mov dword [esp + 0x28], eax
mov eax, dword [esp + 0x30]
lea ecx, [esp]
push ecx
or eax, 9
push eax
push 0
push str.SOFTWAREMicrosoftAOMEI
push 0x80000002
mov dword [esp + 0x14], 0
mov dword [esp + 0x18], 0
mov dword [esp + 0x1c], 0
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
je 0x402209
xor al, al
mov ecx, dword [esp + 0x28]
xor ecx, esp
call fcn.004b76e6
add esp, 0x2c
ret
mov ecx, dword [esp]
push esi
mov esi, dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
lea edx, [esp + 8]
push edx
push 0
lea eax, [esp + 0x14]
push eax
push 0
push str.retainreginfo
push ecx
call esi
test eax, eax
jne 0x40230d
mov edx, dword [esp + 8]
push edi
push edx
call fcn.004b76d4
mov edx, dword [esp + 0xc]
add esp, 4
mov edi, eax
lea eax, [esp + 0xc]
push eax
push edi
lea ecx, [esp + 0x18]
push ecx
push 0
push str.retainreginfo
push edx
call esi
test eax, eax
jne 0x4022e2
call fcn.004018d0
push eax
lea ecx, [esp + 0x18]
call dword [sym.imp.MSVCP80.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::constructor_char_const__]
cmp dword [esp + 0x2c], 0x10
mov eax, dword [esp + 0x18]
jae 0x402281
lea eax, [esp + 0x18]
push 0x4be984
push eax
call dword [sym.imp.MSVCR80.dll_fopen]
mov esi, eax
add esp, 8
test esi, esi
je 0x4022d8
mov eax, dword [esp + 0xc]
push esi
push 1
push eax
push edi
call dword [sym.imp.MSVCR80.dll_fwrite]
add esp, 0x10
cmp eax, 1
push esi
je 0x4022cf
call dword [sym.imp.MSVCR80.dll_fclose]
mov eax, dword [esp + 0x1c]
add esp, 4
cmp dword [esp + 0x2c], 0x10
jae 0x4022c6
lea eax, [esp + 0x18]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
jmp 0x4022d8
call dword [sym.imp.MSVCR80.dll_fclose]
add esp, 4
lea ecx, [esp + 0x14]
call dword [sym.imp.MSVCP80.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::destructor_void_]
push edi
call sub.MSVCR80.dll_void___cdecl_operator_delete_void__
mov eax, dword [esp + 0xc]
add esp, 4
test eax, eax
pop edi
je 0x4022fb
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov al, 1
pop esi
mov ecx, dword [esp + 0x28]
xor ecx, esp
call fcn.004b76e6
add esp, 0x2c
ret
mov ecx, dword [esp + 0x2c]
pop esi
xor ecx, esp
xor al, al
call fcn.004b76e6
add esp, 0x2c
ret

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

Disassembly:
sub esp, 0x14c
mov eax, dword [0x4d437c]
xor eax, esp
mov dword [esp + 0x144], eax
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x40238a
push 0x13c
lea eax, [esp + 8]
push 0
push eax
mov dword [esp + 0xc], 0
call sub.ntdll.dll_memset
add esp, 0xc
lea ecx, [esp]
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
cmp eax, 0xffffffff
jne 0x402383
xor al, al
mov ecx, dword [esp + 0x144]
xor ecx, esp
call fcn.004b76e6
add esp, 0x14c
ret
push eax
call dword [sym.imp.KERNEL32.dll_FindClose]
mov ecx, dword [esp + 0x144]
xor ecx, esp
mov al, 1
call fcn.004b76e6
add esp, 0x14c
ret
Function at 0x4023b0
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x4b9e29
mov eax, dword fs:[0]
push eax
sub esp, 0x20
mov eax, dword [0x4d437c]
xor eax, esp
mov dword [esp + 0x1c], eax
push esi
mov eax, dword [0x4d437c]
xor eax, esp
push eax
lea eax, [esp + 0x28]
mov dword fs:[0], eax
call fcn.004018d0
push eax
lea ecx, [esp + 0xc]
call dword [sym.imp.MSVCP80.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::constructor_char_const__]
mov dword [esp + 0x30], 0
cmp dword [esp + 0x20], 0x10
mov esi, dword [esp + 0xc]
jae 0x402406
lea esi, [esp + 0xc]
call fcn.00402320
test al, al
jne 0x40245b
push 0x200
call fcn.004021b0
add esp, 4
test al, al
jne 0x40242d
push 0x100
call fcn.004021b0
add esp, 4
cmp dword [esp + 0x20], 0x10
mov esi, dword [esp + 0xc]
jae 0x40243c
lea esi, [esp + 0xc]
call fcn.00402320
test al, al
jne 0x40245b
lea ecx, [esp + 8]
mov dword [esp + 0x30], 0xffffffff
call dword [sym.imp.MSVCP80.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::destructor_void_]
xor al, al
jmp 0x40246f
lea ecx, [esp + 8]
mov dword [esp + 0x30], 0xffffffff
call dword [sym.imp.MSVCP80.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::destructor_void_]
mov al, 1
mov ecx, dword [esp + 0x28]
mov dword fs:[0], ecx
pop ecx
pop esi
mov ecx, dword [esp + 0x1c]
xor ecx, esp
call fcn.004b76e6
add esp, 0x2c
ret
Function at 0x402d90
Capabilities:
Read .ini file

Disassembly:
push 0xffffffffffffffff
push 0x4b9a4c
mov eax, dword fs:[0]
push eax
sub esp, 0x100
mov eax, dword [0x4d437c]
xor eax, esp
mov dword [esp + 0xf8], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x4d437c]
xor eax, esp
push eax
lea eax, [esp + 0x114]
mov dword fs:[0], eax
mov eax, dword [esp + 0x124]
mov dword [esp + 0x18], eax
call fcn.00401860
push eax
lea ecx, [esp + 0x34]
call dword [sym.imp.MSVCP80.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::constructor_char_const__]
xor ebx, ebx
mov dword [esp + 0x11c], ebx
mov ebp, dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
xor edi, edi
jmp 0x402e00
push 0x3f
lea ecx, [esp + 0x91]
push ebx
push ecx
mov byte [esp + 0x98], bl
call sub.ntdll.dll_memset
add esp, 0xc
push 0x3f
lea edx, [esp + 0x51]
push ebx
push edx
mov byte [esp + 0x58], bl
call sub.ntdll.dll_memset
add esp, 0xc
push 0x3f
lea eax, [esp + 0xd1]
push ebx
push eax
mov byte [esp + 0xd8], bl
call sub.ntdll.dll_memset
add esp, 0xc
push edi
push str.Event_d
lea ecx, [esp + 0x94]
push 0x40
push ecx
call dword [sym.imp.MSVCR80.dll_sprintf_s]
mov eax, dword [esp + 0x44]
mov esi, 0x10
add esp, 0x10
cmp dword [esp + 0x48], esi
jae 0x402e74
lea eax, [esp + 0x34]
push eax
push 0x40
lea edx, [esp + 0x54]
push edx
push 0x4be5f0
push str.OPTime
lea eax, [esp + 0xa0]
push eax
call ebp
test eax, eax
je 0x402f26
cmp byte [esp + 0x4c], 0x30
je 0x402f26
cmp dword [esp + 0x48], esi
mov eax, dword [esp + 0x34]
jae 0x402eb1
lea eax, [esp + 0x34]
push eax
push 0x40
lea ecx, [esp + 0xd4]
push ecx
push 0x4be5f0
push str.Event
lea edx, [esp + 0xa0]
push edx
call ebp
test eax, eax
je 0x402f26
cmp byte [esp + 0x4c], 0x30
je 0x402f26
lea eax, [esp + 0x4c]
push eax
call dword [sym.imp.ntdll.dll__atoi64]
lea ecx, [esp + 0xd0]
add esp, 4
push ecx
mov dword [esp + 0x20], eax
mov dword [esp + 0x24], edx
call dword [sym.imp.ntdll.dll_atoi]
add esp, 4
cmp eax, 4
mov dword [esp + 0x24], eax
je 0x402f10
cmp eax, 0xf
jne 0x402f17
mov byte [0x4d69ac], 1
mov esi, dword [esp + 0x18]
lea ebx, [esp + 0x1c]
call fcn.00403260
xor ebx, ebx
add edi, 1
cmp edi, 0xa
jl 0x402e00
lea ecx, [esp + 0x30]
mov dword [esp + 0x11c], 0xffffffff
call dword [sym.imp.MSVCP80.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::destructor_void_]
mov al, 1
mov ecx, dword [esp + 0x114]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0xf8]
xor ecx, esp
call fcn.004b76e6
add esp, 0x10c
ret
Function at 0x409030
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x4b9239
mov eax, dword fs:[0]
push eax
push esi
push edi
mov eax, dword [0x4d437c]
xor eax, esp
push eax
lea eax, [esp + 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov esi, dword [esp + 0x1c]
push edi
mov ecx, esi
call dword [sym.imp.MSVCP80.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::constructor_class_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char___const__]
mov dword [esp + 0x14], 0
mov eax, dword [edi + 0x20]
mov dword [esi + 0x20], eax
mov ecx, dword [edi + 0x28]
mov dword [esi + 0x28], ecx
mov edx, dword [edi + 0x28]
mov dword [esi + 0x28], edx
mov eax, dword [edi + 0x2c]
add edi, 0x30
push edi
lea ecx, [esi + 0x30]
mov dword [esi + 0x2c], eax
call dword [sym.imp.MSVCP80.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::constructor_class_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char___const__]
mov eax, esi
mov ecx, dword [esp + 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
add esp, 0xc
ret 4

Function at 0x409280
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x4b9239
mov eax, dword fs:[0]
push eax
push esi
push edi
mov eax, dword [0x4d437c]
xor eax, esp
push eax
lea eax, [esp + 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov esi, dword [esp + 0x1c]
mov eax, dword [esp + 0x20]
push eax
mov ecx, esi
call dword [sym.imp.MSVCP80.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::constructor_class_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char___const__]
mov dword [esp + 0x14], 0
mov ecx, dword [edi]
mov dword [esi + 0x20], ecx
mov edx, dword [edi + 8]
mov dword [esi + 0x28], edx
mov eax, dword [edi + 8]
mov dword [esi + 0x28], eax
mov ecx, dword [edi + 0xc]
add edi, 0x10
mov dword [esi + 0x2c], ecx
push edi
lea ecx, [esi + 0x30]
call dword [sym.imp.MSVCP80.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::constructor_class_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char___const__]
mov eax, esi
mov ecx, dword [esp + 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
add esp, 0xc
ret 8
Function at 0x40a020
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x24
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
push 0x4bee38
mov dword [esp + 0x14], ecx
xor esi, esi
push eax
lea ecx, [esp + 0x14]
push ecx
xor bl, bl
mov dword [esp + 0x24], esi
mov dword [esp + 0x28], esi
mov dword [esp + 0x18], esi
call dword [sym.imp.MSVCR80.dll_fopen_s]
add esp, 0xc
test eax, eax
jne 0x40a196
mov edx, dword [esp + 0xc]
push 2
push esi
mov esi, dword [sym.imp.MSVCR80.dll_fseek]
push edx
call esi
mov eax, dword [esp + 0x18]
add esp, 0xc
push eax
call dword [sym.imp.MSVCR80.dll_ftell]
mov ecx, dword [esp + 0x10]
add esp, 4
cdq
push 0
mov edi, eax
push 0
push ecx
mov dword [esp + 0x2c], edi
mov dword [esp + 0x30], edx
call esi
add esp, 0xc
push edi
call fcn.004b76d4
mov ecx, dword [esp + 0x14]
add esp, 4
test eax, eax
mov dword [ecx + 0xc], eax
je 0x40a196
mov edx, dword [esp + 0xc]
mov esi, dword [esp + 0x24]
push edx
push 1
push edi
push eax
mov dword [ecx + 0x28], edi
mov dword [ecx + 0x2c], esi
call dword [sym.imp.MSVCR80.dll_fread]
add esp, 0x10
test esi, esi
jb 0x40a194
ja 0x40a0df
test edi, edi
jbe 0x40a194
mov edi, dword [ebp + 0xc]
mov eax, dword [esp + 0x10]
mov esi, dword [eax + 0xc]
mov ebx, dword [esp + 0x18]
mov eax, dword [esi + ebx]
add esi, ebx
test eax, eax
mov dword [esp + 0x14], esi
je 0x40a194
cdq
add eax, ebx
adc edx, dword [esp + 0x1c]
cmp edx, dword [esp + 0x24]
ja 0x40a194
jb 0x40a117
cmp eax, dword [esp + 0x20]
ja 0x40a194
mov edx, dword [edi + 4]
test edx, edx
jne 0x40a122
xor ecx, ecx
jmp 0x40a12a
mov ecx, dword [edi + 8]
sub ecx, edx
sar ecx, 2
test edx, edx
je 0x40a147
mov eax, dword [edi + 0xc]
sub eax, edx
sar eax, 2
cmp ecx, eax
jae 0x40a147
mov eax, dword [edi + 8]
mov dword [eax], esi
add eax, 4
mov dword [edi + 8], eax
jmp 0x40a16b
mov esi, dword [edi + 8]
cmp edx, esi
jbe 0x40a154
call dword [sym.imp.MSVCR80.dll__invalid_parameter_noinfo]
push esi
push edi
lea ecx, [esp + 0x1c]
push ecx
lea edx, [esp + 0x34]
push edx
mov eax, edi
call fcn.0040aaa0
mov esi, dword [esp + 0x14]
mov eax, dword [esi]
cdq
add ebx, eax
mov eax, dword [esp + 0x1c]
adc eax, edx
cmp eax, dword [esp + 0x24]
mov dword [esp + 0x18], ebx
mov dword [esp + 0x1c], eax
jb 0x40a0e2
ja 0x40a194
cmp ebx, dword [esp + 0x20]
jb 0x40a0e2
mov bl, 1
mov eax, dword [esp + 0xc]
test eax, eax
je 0x40a1a8
push eax
call dword [sym.imp.MSVCR80.dll_fclose]
add esp, 4
pop edi
pop esi
mov al, bl
pop ebx
mov esp, ebp
pop ebp
ret 8
Function at 0x40a1c0
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x4bad83
mov eax, dword fs:[0]
push eax
sub esp, 0xb0
mov eax, dword [0x4d437c]
xor eax, esp
mov dword [esp + 0xa8], eax
push ebx
push esi
push edi
mov eax, dword [0x4d437c]
xor eax, esp
push eax
lea eax, [esp + 0xc0]
mov dword fs:[0], eax
mov eax, dword [ebp + 8]
mov edi, dword [ebp + 0xc]
lea ecx, [esp + 0x3c]
push ecx
mov dword [esp + 0x2c], eax
call fcn.004b39c0
xor esi, esi
mov dword [esp + 0xc8], esi
mov dword [esp + 0x18], esi
mov dword [esp + 0x1c], esi
mov dword [esp + 0x20], esi
xor ebx, ebx
mov ecx, edi
mov dword [esp + 0x24], ebx
call fcn.0040a6c0
test eax, eax
jbe 0x40a37a
mov dword [esp + 0x10], ebx
and dword [esp + 0x34], 0xfffffe00
mov dword [esp + 0x38], 0
mov byte [esp + 0xc8], 3
mov eax, dword [edi + 4]
test eax, eax
je 0x40a27d
mov ecx, dword [edi + 8]
sub ecx, eax
mov eax, 0x92492493
imul ecx
add edx, ecx
sar edx, 4
mov eax, edx
shr eax, 0x1f
add eax, edx
cmp ebx, eax
jb 0x40a283
call dword [sym.imp.MSVCR80.dll__invalid_parameter_noinfo]
mov eax, dword [edi + 4]
add eax, dword [esp + 0x10]
lea ecx, [esp + 0x64]
push eax
call dword [0x4bd1cc]
cmp dword [esp + 0x7c], 0x10
mov eax, dword [esp + 0x68]
jae 0x40a2a4
lea eax, [esp + 0x68]
mov edx, dword [esp + 0x78]
lea ecx, [edx + eax]
lea edx, [esp + 0x2c]
push edx
push ecx
push eax
lea eax, [esp + 0x48]
push eax
call fcn.004b3a40
mov al, byte [esp + 0x34]
test al, al
je 0x40a2cc
cmp al, 6
je 0x40a2cc
cmp al, 7
jne 0x40a2de
lea ecx, [esp + 0x2c]
call fcn.004b0e20
test eax, eax
sete al
test al, al
jne 0x40a2ef
lea ebx, [esp + 0x2c]
lea esi, [esp + 0x14]
call fcn.0040a7e0
mov ebx, dword [esp + 0x24]
lea eax, [esp + 0x2c]
mov byte [esp + 0xc8], 1
call fcn.004b0720
add dword [esp + 0x10], 0x1c
add ebx, 1
mov ecx, edi
mov dword [esp + 0x24], ebx
call fcn.0040a6c0
cmp ebx, eax
jb 0x40a242
mov esi, dword [esp + 0x18]
test esi, esi
je 0x40a37a
mov eax, dword [esp + 0x1c]
sub eax, esi
sar eax, 4
je 0x40a37a
test eax, eax
jbe 0x40a37a
xor ebx, ebx
mov dword [esp + 0x10], ebx
test esi, esi
je 0x40a37a
mov eax, dword [esp + 0x1c]
sub eax, esi
sar eax, 4
cmp ebx, eax
jae 0x40a37a
mov ecx, dword [esp + 0x10]
lea edi, [ecx + esi]
mov esi, dword [esp + 0x28]
mov ecx, esi
call fcn.004b0e20
push eax
mov ecx, esi
call fcn.004b0ea0
mov esi, eax
mov eax, edi
call fcn.004b07c0
mov esi, dword [esp + 0x18]
add ebx, 1
add dword [esp + 0x10], 0x10
jmp 0x40a338
xor ebx, ebx
cmp esi, ebx
mov byte [esp + 0xc8], 0
je 0x40a3ab
mov edi, dword [esp + 0x1c]
cmp esi, edi
je 0x40a3a2
mov eax, esi
call fcn.004b0720
add esi, 0x10
cmp esi, edi
jne 0x40a390
mov esi, dword [esp + 0x18]
push esi
call sub.MSVCR80.dll_void___cdecl_operator_delete_void__
add esp, 4
lea edx, [esp + 0x3c]
push edx
mov dword [esp + 0x1c], ebx
mov dword [esp + 0x20], ebx
mov dword [esp + 0x24], ebx
mov dword [esp + 0xcc], 0xffffffff
call fcn.0040a400
mov ecx, dword [esp + 0xc0]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0xa8]
xor ecx, esp
call fcn.004b76e6
mov esp, ebp
pop ebp
ret 8
Function at 0x40c550
Capabilities:
Read .ini file

Disassembly:
sub esp, 0x20c
mov eax, dword [0x4d437c]
xor eax, esp
mov dword [esp + 0x208], eax
push 0x207
lea eax, [esp + 5]
push 0
push eax
mov byte [esp + 0xc], 0
call sub.ntdll.dll_memset
add esp, 0xc
push esi
push 0x208
lea ecx, [esp + 8]
push ecx
push 0x4be549
push str.DevID
push str.User
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
test eax, eax
je 0x40c5ad
lea edx, [esp]
push edx
mov ecx, edi
call dword [sym.imp.MSVCP80.dll_public:_class_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char______thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::operator_char_const__]
mov ecx, dword [esp + 0x208]
xor ecx, esp
call fcn.004b76e6
add esp, 0x20c
ret