Function at 0x406a10
Capabilities:
Encode data using xor
Read file on windows
Write file on windows

Disassembly:
push 0xffffffffffffffff
push 0x447ef4
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x10
push ebx
push ebp
push esi
mov esi, dword [sym.imp.MSVCR71.dll_fseek]
push edi
mov edi, dword [esp + 0x30]
push 2
push 0
push edi
call esi
push edi
call dword [sym.imp.MSVCR71.dll_ftell]
push 0
push 0
push edi
mov ebp, eax
call esi
lea eax, [ebp + 0xc]
push eax
mov dword [esp + 0x3c], eax
call fcn.00427580
mov ebx, eax
mov eax, dword [esp + 0x54]
add esp, 0x20
xor esi, esi
push eax
lea ecx, [esp + 0x34]
mov dword [esp + 0x18], esi
call dword [sym.imp.MFC71.DLL_ATL::CStringT::CStringT_3]
push 0x2e
lea ecx, [esp + 0x34]
mov dword [esp + 0x2c], esi
call dword [sym.imp.MFC71.DLL_ATL::CStringT::ReverseFind]
lea ecx, [esp + 0x30]
mov esi, eax
call dword [sym.imp.MFC71.DLL_ATL::CSimpleStringT::GetLength]
sub eax, esi
push eax
lea ecx, [esp + 0x1c]
push ecx
lea ecx, [esp + 0x38]
call dword [sym.imp.MFC71.DLL_ATL::CStringT::Right]
push eax
lea ecx, [esp + 0x34]
mov byte [esp + 0x2c], 1
call dword [sym.imp.MFC71.DLL_ATL::CStringT::operator]
lea ecx, [esp + 0x18]
mov byte [esp + 0x28], 0
call dword [sym.imp.MFC71.DLL_ATL::CStringT::CStringT]
lea ecx, [esp + 0x30]
call dword [sym.imp.MFC71.DLL_ATL::CStringT::MakeLower]
lea ecx, [esp + 0x30]
mov esi, str..dds
call dword [sym.imp.MFC71.DLL_ATL::CSimpleStringT::operator_char_const_]
lea ebx, [ebx]
mov dl, byte [eax]
mov cl, dl
cmp dl, byte [esi]
jne 0x406b04
test cl, cl
je 0x406b00
mov dl, byte [eax + 1]
mov cl, dl
cmp dl, byte [esi + 1]
jne 0x406b04
add eax, 2
add esi, 2
test cl, cl
jne 0x406ae0
xor eax, eax
jmp 0x406b09
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
jne 0x406b16
mov dword [esp + 0x14], eax
jmp 0x406ba5
lea ecx, [esp + 0x30]
mov esi, str..tga
call dword [sym.imp.MFC71.DLL_ATL::CSimpleStringT::operator_char_const_]
mov dl, byte [eax]
mov cl, dl
cmp dl, byte [esi]
jne 0x406b49
test cl, cl
je 0x406b45
mov dl, byte [eax + 1]
mov cl, dl
cmp dl, byte [esi + 1]
jne 0x406b49
add eax, 2
add esi, 2
test cl, cl
jne 0x406b25
xor eax, eax
jmp 0x406b4e
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
jne 0x406b5c
mov dword [esp + 0x14], 1
jmp 0x406ba5
lea ecx, [esp + 0x30]
mov esi, str..bmp
call dword [sym.imp.MFC71.DLL_ATL::CSimpleStringT::operator_char_const_]
jmp 0x406b70
mov dl, byte [eax]
mov cl, dl
cmp dl, byte [esi]
jne 0x406b94
test cl, cl
je 0x406b90
mov dl, byte [eax + 1]
mov cl, dl
cmp dl, byte [esi + 1]
jne 0x406b94
add eax, 2
add esi, 2
test cl, cl
jne 0x406b70
xor eax, eax
jmp 0x406b99
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
jne 0x406ba5
mov dword [esp + 0x14], 2
mov eax, dword [esp + 0x14]
push edi
push ebp
lea esi, [ebx + 0xc]
push 1
push esi
mov dword [ebx], 0x100
mov dword [ebx + 4], ebp
mov dword [ebx + 8], eax
call dword [sym.imp.MSVCR71.dll_fread]
push edi
mov edi, dword [sym.imp.MSVCR71.dll_fclose]
call edi
add esp, 0x14
test ebp, ebp
jle 0x406be5
mov eax, esi
mov ecx, ebp
mov dl, byte [eax]
xor dl, 0x32
sub dl, 8
mov byte [eax], dl
inc eax
dec ecx
jne 0x406bd7
mov eax, dword [esp + 0x34]
push eax
lea ecx, [esp + 0x14]
call dword [sym.imp.MFC71.DLL_ATL::CStringT::CStringT_3]
push 0x2e
lea ecx, [esp + 0x14]
mov byte [esp + 0x2c], 2
call dword [sym.imp.MFC71.DLL_ATL::CStringT::ReverseFind]
push eax
lea ecx, [esp + 0x38]
push ecx
lea ecx, [esp + 0x18]
call dword [sym.imp.MFC71.DLL_ATL::CStringT::Left]
push eax
lea ecx, [esp + 0x14]
mov byte [esp + 0x2c], 3
call dword [sym.imp.MFC71.DLL_ATL::CStringT::operator]
lea ecx, [esp + 0x34]
mov byte [esp + 0x28], 2
call dword [sym.imp.MFC71.DLL_ATL::CStringT::CStringT]
push str..mtf
lea ecx, [esp + 0x14]
call dword [sym.imp.MFC71.DLL_ATL::CStringT::operator_2]
push 0x450c30
lea ecx, [esp + 0x14]
call dword [sym.imp.MFC71.DLL_ATL::CSimpleStringT::operator_char_const_]
push eax
call dword [sym.imp.MSVCR71.dll_fopen]
mov esi, eax
add esp, 8
test esi, esi
jne 0x406c96
push ebx
call sub.MFC71.DLL_operator_delete_1
add esp, 4
lea ecx, [esp + 0x10]
call dword [sym.imp.MFC71.DLL_ATL::CStringT::CStringT]
lea ecx, [esp + 0x30]
call dword [sym.imp.MFC71.DLL_ATL::CStringT::CStringT]
pop edi
pop esi
pop ebp
xor al, al
pop ebx
mov ecx, dword [esp + 0x10]
mov dword fs:[0], ecx
add esp, 0x1c
ret 8
mov edx, dword [esp + 0x1c]
push esi
push edx
push 1
push ebx
call dword [sym.imp.MSVCR71.dll_fwrite]
push esi
call edi
push ebx
call sub.MFC71.DLL_operator_delete_1
add esp, 0x18
lea ecx, [esp + 0x10]
call dword [sym.imp.MFC71.DLL_ATL::CStringT::CStringT]
lea ecx, [esp + 0x30]
call dword [sym.imp.MFC71.DLL_ATL::CStringT::CStringT]
mov ecx, dword [esp + 0x20]
pop edi
pop esi
pop ebp
mov al, 1
pop ebx
mov dword fs:[0], ecx
add esp, 0x1c
ret 8