Function at 0x4056f0
Capabilities:
Get file size
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x40e51b
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x23c
mov al, byte [ebp + 0xb]
push ebx
push esi
xor ebx, ebx
push edi
push ebx
lea ecx, [ebp - 0x30]
mov dword [ebp - 0x10], ebx
mov byte [ebp - 0x30], al
call dword [sym.imp.MSVCP60.dll_private:_void___thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Tidy_bool_]
mov ecx, 0x81
xor eax, eax
lea edi, [ebp - 0x246]
mov word [ebp - 0x248], bx
rep stosd dword es:[edi], eax
lea ecx, [ebp - 0x248]
mov dword [ebp - 4], ebx
push ecx
stosw word es:[edi], ax
call fcn.0040b420
mov edx, dword [str.js_antispyConfig.js]
lea eax, [ebp - 0x248]
push edx
push eax
call dword [sym.imp.MSVCRT.dll_wcscat]
lea ecx, [ebp - 0x248]
push ebx
push ecx
call dword [sym.imp.MSVCRT.dll__waccess]
add esp, 0x14
test eax, eax
jne 0x40592f
mov dl, byte [ebp + 0xb]
push ebx
lea ecx, [ebp - 0x20]
mov byte [ebp - 0x20], dl
call dword [sym.imp.MSVCP60.dll_private:_void___thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Tidy_bool_]
push ebx
push 0x80
push 3
push ebx
push 1
lea eax, [ebp - 0x248]
push SysReAllocStringLen
push eax
mov byte [ebp - 4], 1
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
cmp esi, 0xffffffff
je 0x405865
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
cmp edi, ebx
jbe 0x405865
push edi
mov dword [ebp - 0x10], ebx
call sub.MFC42u.DLL_operatornew
mov ebx, eax
add esp, 4
test ebx, ebx
je 0x405865
lea ecx, [ebp - 0x10]
push 0
push ecx
push edi
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x40585c
mov edi, ebx
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov esi, ecx
inc esi
lea eax, [esi + esi]
add eax, 3
and al, 0xfc
call fcn.0040d3a0
mov edi, esp
push esi
push edi
push 0xffffffffffffffff
push ebx
push 0
mov word [edi], 0
call dword [sym.imp.KERNEL32.dll_GetACP]
push eax
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
push edi
call dword [sym.imp.MSVCRT.dll_wcslen]
add esp, 4
mov esi, eax
lea ecx, [ebp - 0x20]
push 1
push esi
call dword [sym.imp.MSVCP60.dll_private:_bool___thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Grow_unsigned_int__bool_]
test al, al
je 0x40585c
mov edx, dword [ebp - 0x1c]
push esi
push edi
push edx
call fcn.00403cc0
add esp, 0xc
lea ecx, [ebp - 0x20]
push esi
call dword [sym.imp.MSVCP60.dll_private:_void___thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Eos_unsigned_int_]
push ebx
call sub.MFC42u.DLL_operatordelete
add esp, 4
mov eax, dword [str.ksantispy.settings.webpageVersion__]
mov ebx, dword [sym.imp.MSVCRT.dll_wcslen]
push eax
mov esi, eax
call ebx
add esp, 4
lea ecx, [ebp - 0x20]
push eax
push 0
push esi
call dword [sym.imp.MSVCP60.dll_public:_unsigned_int___thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::find_unsigned_short_int_const___unsigned_int__unsigned_int_const]
mov edi, eax
mov eax, dword [str.ksantispy.settings.webpageVersion__]
push eax
call ebx
mov esi, eax
push 0x413cd0
add esi, edi
call ebx
add esp, 8
lea ecx, [ebp - 0x20]
push eax
push esi
push 0x413cd0
call dword [sym.imp.MSVCP60.dll_public:_unsigned_int___thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::find_unsigned_short_int_const___unsigned_int__unsigned_int_const]
test esi, esi
jl 0x405904
test eax, eax
jl 0x405904
sub eax, esi
lea ecx, [ebp - 0x40]
push eax
push esi
push ecx
lea ecx, [ebp - 0x20]
call dword [sym.imp.MSVCP60.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__::substr_unsigned_int__unsigned_int_]
mov edx, dword [sym.imp.MSVCP60.dll_unsigned_int_const_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::npos]
mov byte [ebp - 4], 2
mov ecx, dword [edx]
push ecx
push 0
push eax
lea ecx, [ebp - 0x30]
call dword [sym.imp.MSVCP60.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__::assign_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int___const___unsigned_int__unsigned_int_]
mov ecx, dword [ebp - 0x3c]
test ecx, ecx
je 0x405904
mov al, byte [ecx - 1]
test al, al
je 0x4058f8
cmp al, 0xff
je 0x4058f8
dec al
mov byte [ecx - 1], al
jmp 0x405904
lea eax, [ecx - 2]
push eax
call sub.MFC42u.DLL_operatordelete
add esp, 4
mov ecx, dword [ebp - 0x1c]
mov byte [ebp - 4], 0
test ecx, ecx
je 0x40592d
mov al, byte [ecx - 1]
test al, al
je 0x405921
cmp al, 0xff
je 0x405921
dec al
mov byte [ecx - 1], al
jmp 0x40592d
add ecx, 0xfffffffe
push ecx
call sub.MFC42u.DLL_operatordelete
add esp, 4
xor ebx, ebx
mov esi, dword [ebp + 8]
mov dl, byte [ebp - 0x30]
mov byte [esi], dl
mov dword [esi + 4], ebx
mov dword [esi + 8], ebx
mov dword [esi + 0xc], ebx
mov eax, dword [sym.imp.MSVCP60.dll_unsigned_int_const_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::npos]
lea edx, [ebp - 0x30]
mov ecx, dword [eax]
push ecx
push ebx
push edx
mov ecx, esi
call dword [sym.imp.MSVCP60.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__::assign_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int___const___unsigned_int__unsigned_int_]
mov ecx, dword [ebp - 0x2c]
cmp ecx, ebx
je 0x40597a
mov al, byte [ecx - 1]
test al, al
je 0x40596e
cmp al, 0xff
je 0x40596e
dec al
mov byte [ecx - 1], al
jmp 0x40597a
add ecx, 0xfffffffe
push ecx
call sub.MFC42u.DLL_operatordelete
add esp, 4
mov ecx, dword [ebp - 0xc]
lea esp, [ebp - 0x254]
mov eax, esi
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4