Function at 0x461c10
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x49facb
mov eax, dword fs:[0]
push eax
sub esp, 0xa64
mov eax, dword [0x4b4d40]
xor eax, ebp
mov dword [ebp - 0x1c], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
xor eax, eax
mov word [ebp - 0x10], ax
mov ecx, dword [0x4a6984]
mov dword [ebp - 0xa2c], ecx
mov dx, word [0x4a6988]
mov word [ebp - 0xa28], dx
mov eax, dword [ebp + 8]
push eax
call fcn.004283d0
push eax
push str.local_hs_text_s
lea ecx, [ebp - 0x21c]
push ecx
call fcn.00429460
add esp, 0x10
push 0x4a69b0
lea edx, [ebp - 0x21c]
push edx
call dword [sym.imp.MSVCR90.dll__wfopen]
add esp, 8
mov dword [ebp - 0x18], eax
cmp dword [ebp - 0x18], 0
je 0x461f4d
push 0xa
push 0
lea eax, [ebp - 0xa38]
push eax
call sub.MSVCR90.dll_memset
add esp, 0xc
mov ecx, dword [ebp - 0x18]
push ecx
push 2
push 1
lea edx, [ebp - 0xa38]
push edx
call dword [sym.imp.MSVCR90.dll_fread]
add esp, 0x10
mov eax, dword [0x4a69b8]
mov dword [ebp - 0xa40], eax
mov cx, word [0x4a69bc]
mov word [ebp - 0xa3c], cx
mov edx, dword [ebp - 0x18]
push edx
push 0x400
lea eax, [ebp - 0xa24]
push eax
call dword [sym.imp.MSVCR90.dll_fgetws]
add esp, 0xc
test eax, eax
je 0x461f3b
lea ecx, [ebp - 0xa24]
push ecx
call dword [sym.imp.MSVCR90.dll_wcslen]
add esp, 4
cmp eax, 2
jbe 0x461f3b
push 0x4a69c0
lea edx, [ebp - 0xa24]
push edx
call fcn.00463170
add esp, 8
test eax, eax
je 0x461f36
push 0x3c
call fcn.0049cc04
add esp, 4
mov dword [ebp - 0xa54], eax
mov dword [ebp - 4], 0
cmp dword [ebp - 0xa54], 0
je 0x461d68
mov ecx, dword [ebp - 0xa54]
call fcn.00463110
mov dword [ebp - 0xa68], eax
jmp 0x461d72
mov dword [ebp - 0xa68], 0
mov eax, dword [ebp - 0xa68]
mov dword [ebp - 0xa50], eax
mov dword [ebp - 4], 0xffffffff
mov ecx, dword [ebp - 0xa50]
mov dword [ebp - 0x220], ecx
mov edx, dword [ebp - 0x220]
mov byte [edx + 0x38], 1
lea eax, [ebp - 0xa40]
push eax
lea ecx, [ebp - 0xa24]
push ecx
call dword [sym.imp.MSVCR90.dll_wcstok]
add esp, 8
mov dword [ebp - 0x14], eax
lea edx, [ebp - 0xa40]
push edx
push 0
call dword [sym.imp.MSVCR90.dll_wcstok]
add esp, 8
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
je 0x461e59
mov eax, dword [ebp - 0x14]
push eax
mov ecx, dword [ebp - 0x220]
call dword [sym.imp.MSVCP90.dll_public:_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int______thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::operator_unsigned_short_int_const__]
mov ecx, dword [ebp - 0x220]
call dword [sym.imp.MSVCP90.dll_protected:_unsigned_short_int____thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Myptr_void_]
push eax
call dword [sym.imp.MSVCR90.dll_wcslen]
add esp, 4
test eax, eax
jbe 0x461e59
mov ecx, dword [ebp - 0x220]
call dword [sym.imp.MSVCP90.dll_protected:_unsigned_short_int____thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Myptr_void_]
push eax
call dword [sym.imp.MSVCR90.dll_wcslen]
add esp, 4
sub eax, 1
push eax
mov ecx, dword [ebp - 0x220]
call dword [sym.imp.MSVCP90.dll_public:_unsigned_short_int____thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::operator___unsigned_int_]
movzx ecx, word [eax]
cmp ecx, 0x20
jne 0x461e59
mov ecx, dword [ebp - 0x220]
call dword [sym.imp.MSVCP90.dll_protected:_unsigned_short_int____thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Myptr_void_]
push eax
call dword [sym.imp.MSVCR90.dll_wcslen]
add esp, 4
sub eax, 1
push eax
mov ecx, dword [ebp - 0x220]
call dword [sym.imp.MSVCP90.dll_public:_unsigned_short_int____thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::operator___unsigned_int_]
xor edx, edx
mov word [eax], dx
jmp 0x461de4
mov eax, dword [ebp - 0x18]
push eax
push 0x400
lea ecx, [ebp - 0xa24]
push ecx
call dword [sym.imp.MSVCR90.dll_fgetws]
add esp, 0xc
lea edx, [ebp - 0xa40]
push edx
lea eax, [ebp - 0xa24]
push eax
call dword [sym.imp.MSVCR90.dll_wcstok]
add esp, 8
mov dword [ebp - 0x14], eax
lea ecx, [ebp - 0xa40]
push ecx
push 0
call dword [sym.imp.MSVCR90.dll_wcstok]
add esp, 8
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
je 0x461eba
mov edx, dword [ebp - 0x14]
push edx
mov ecx, dword [ebp - 0x220]
add ecx, 0x1c
call dword [sym.imp.MSVCP90.dll_public:_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int______thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::operator_unsigned_short_int_const__]
mov eax, dword [ebp - 0x220]
push eax
mov ecx, 0x4b4fbc
call fcn.00463de0
test eax, eax
jne 0x461ef6
mov ecx, dword [ebp - 0x220]
push ecx
mov ecx, 0x4b4fbc
call fcn.004634a0
mov edx, dword [ebp - 0x220]
mov dword [eax], edx
mov ax, word [ebp - 0x10]
add ax, 1
mov word [ebp - 0x10], ax
jmp 0x461f36
mov ecx, dword [ebp - 0x220]
mov dword [ebp - 0xa5c], ecx
mov edx, dword [ebp - 0xa5c]
mov dword [ebp - 0xa58], edx
cmp dword [ebp - 0xa58], 0
je 0x461f2c
push 1
mov ecx, dword [ebp - 0xa58]
call fcn.00463190
mov dword [ebp - 0xa6c], eax
jmp 0x461f36
mov dword [ebp - 0xa6c], 0
jmp 0x461cdf
mov eax, dword [ebp - 0x18]
push eax
call dword [sym.imp.MSVCR90.dll_fclose]
add esp, 4
jmp 0x462225
lea ecx, [ebp - 0x21c]
push ecx
call dword [sym.imp.MSVCR90.dll_wcslen]
add esp, 4
xor edx, edx
mov word [ebp + eax*2 - 0x224], dx
push str..txt
lea eax, [ebp - 0x21c]
push eax
call dword [sym.imp.MSVCR90.dll_wcscat]
add esp, 8
push 0x4a69e0
lea ecx, [ebp - 0x21c]
push ecx
call dword [sym.imp.MSVCR90.dll__wfopen]
add esp, 8
mov dword [ebp - 0x18], eax
cmp dword [ebp - 0x18], 0
jne 0x461fa1
xor eax, eax
jmp 0x462229
push 0xa
push 0
lea edx, [ebp - 0xa4c]
push edx
call sub.MSVCR90.dll_memset
add esp, 0xc
mov eax, dword [ebp - 0x18]
push eax
push 2
push 1
lea ecx, [ebp - 0xa4c]
push ecx
call dword [sym.imp.MSVCR90.dll_fread]
add esp, 0x10
mov edx, dword [ebp - 0x18]
push edx
push 0x400
lea eax, [ebp - 0xa24]
push eax
call dword [sym.imp.MSVCR90.dll_fgetws]
add esp, 0xc
test eax, eax
je 0x462218
lea ecx, [ebp - 0xa24]
push ecx
call dword [sym.imp.MSVCR90.dll_wcslen]
add esp, 4
cmp eax, 2
jbe 0x462218
push 0x3c
call fcn.0049cc04
add esp, 4
mov dword [ebp - 0xa64], eax
mov dword [ebp - 4], 1
cmp dword [ebp - 0xa64], 0
je 0x462039
mov ecx, dword [ebp - 0xa64]
call fcn.00463110
mov dword [ebp - 0xa70], eax
jmp 0x462043
mov dword [ebp - 0xa70], 0
mov edx, dword [ebp - 0xa70]
mov dword [ebp - 0xa60], edx
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0xa60]
mov dword [ebp - 0x220], eax
mov ecx, dword [ebp - 0x220]
mov byte [ecx + 0x38], 1
lea edx, [ebp - 0xa2c]
push edx
lea eax, [ebp - 0xa24]
push eax
call dword [sym.imp.MSVCR90.dll_wcstok]
add esp, 8
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
je 0x4621c0
mov ecx, dword [ebp - 0x14]
movzx edx, word [ecx]
cmp edx, 0x22
jne 0x462131
mov eax, dword [ebp - 0x14]
push eax
call dword [sym.imp.MSVCR90.dll_wcslen]
add esp, 4
mov ecx, dword [ebp - 0x14]
movzx edx, word [ecx + eax*2 - 2]
cmp edx, 0x22
jne 0x462131
mov eax, dword [ebp - 0x14]
add eax, 2
push eax
mov ecx, dword [ebp - 0x220]
call dword [sym.imp.MSVCP90.dll_protected:_unsigned_short_int____thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Myptr_void_]
push eax
call dword [sym.imp.MSVCR90.dll_wcscpy]
add esp, 8
mov ecx, dword [ebp - 0x220]
call dword [sym.imp.MSVCP90.dll_protected:_unsigned_short_int____thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Myptr_void_]
push eax
call dword [sym.imp.MSVCR90.dll_wcslen]
add esp, 4
sub eax, 1
push eax
mov ecx, dword [ebp - 0x220]
call dword [sym.imp.MSVCP90.dll_public:_unsigned_short_int____thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::operator___unsigned_int_]
movzx ecx, word [eax]
cmp ecx, 0x22
jne 0x46212f
mov ecx, dword [ebp - 0x220]
call dword [sym.imp.MSVCP90.dll_protected:_unsigned_short_int____thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Myptr_void_]
push eax
call dword [sym.imp.MSVCR90.dll_wcslen]
add esp, 4
sub eax, 1
push eax
mov ecx, dword [ebp - 0x220]
call dword [sym.imp.MSVCP90.dll_public:_unsigned_short_int____thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::operator___unsigned_int_]
xor edx, edx
mov word [eax], dx
jmp 0x46214b
mov eax, dword [ebp - 0x14]
push eax
mov ecx, dword [ebp - 0x220]
call dword [sym.imp.MSVCP90.dll_protected:_unsigned_short_int____thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Myptr_void_]
push eax
call dword [sym.imp.MSVCR90.dll_wcscpy]
add esp, 8
mov ecx, dword [ebp - 0x220]
call dword [sym.imp.MSVCP90.dll_protected:_unsigned_short_int____thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Myptr_void_]
push eax
call dword [sym.imp.MSVCR90.dll_wcslen]
add esp, 4
test eax, eax
jbe 0x4621c0
mov ecx, dword [ebp - 0x220]
call dword [sym.imp.MSVCP90.dll_protected:_unsigned_short_int____thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Myptr_void_]
push eax
call dword [sym.imp.MSVCR90.dll_wcslen]
add esp, 4
sub eax, 1
push eax
mov ecx, dword [ebp - 0x220]
call dword [sym.imp.MSVCP90.dll_public:_unsigned_short_int____thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::operator___unsigned_int_]
movzx ecx, word [eax]
cmp ecx, 0x20
jne 0x4621c0
mov ecx, dword [ebp - 0x220]
call dword [sym.imp.MSVCP90.dll_protected:_unsigned_short_int____thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Myptr_void_]
push eax
call dword [sym.imp.MSVCR90.dll_wcslen]
add esp, 4
sub eax, 1
push eax
mov ecx, dword [ebp - 0x220]
call dword [sym.imp.MSVCP90.dll_public:_unsigned_short_int____thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::operator___unsigned_int_]
xor edx, edx
mov word [eax], dx
jmp 0x46214b
lea eax, [ebp - 0xa2c]
push eax
push 0
call dword [sym.imp.MSVCR90.dll_wcstok]
add esp, 8
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
je 0x4621ee
mov ecx, dword [ebp - 0x14]
push ecx
mov ecx, dword [ebp - 0x220]
add ecx, 0x1c
call dword [sym.imp.MSVCP90.dll_public:_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int______thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::operator_unsigned_short_int_const__]
mov dx, word [ebp - 0x10]
add dx, 1
mov word [ebp - 0x10], dx
mov eax, dword [ebp - 0x220]
push eax
mov ecx, 0x4b4fbc
call fcn.004634a0
mov ecx, dword [ebp - 0x220]
mov dword [eax], ecx
jmp 0x461fcc
mov edx, dword [ebp - 0x18]
push edx
call dword [sym.imp.MSVCR90.dll_fclose]
add esp, 4
mov ax, word [ebp - 0x10]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov ecx, dword [ebp - 0x1c]
xor ecx, ebp
call fcn.0049cb8e
mov esp, ebp
pop ebp
ret