Function at 0x41fc70
Capabilities:
Delete file
Read .ini file
Write file on windows

Disassembly:
mov eax, 0x2138
call fcn.00466d30
mov eax, dword [0x4bc4a0]
xor eax, esp
mov dword [esp + 0x2134], eax
mov eax, dword [esp + 0x213c]
push ebx
mov ebx, dword [esp + 0x2144]
push ebp
push esi
push edi
push 0x103
lea ecx, [esp + 0x45]
push 0
push ecx
mov dword [esp + 0x24], eax
mov dword [esp + 0x20], ebx
mov byte [esp + 0x1f], 0
mov byte [esp + 0x4c], 0
call fcn.00466720
xor eax, eax
push 0x1fff
push eax
lea edx, [esp + 0x159]
push edx
mov byte [esp + 0x38], 0
mov dword [esp + 0x39], eax
mov dword [esp + 0x3d], eax
mov dword [esp + 0x41], eax
mov dword [esp + 0x45], eax
mov dword [esp + 0x49], eax
mov dword [esp + 0x4d], eax
mov dword [esp + 0x51], eax
mov word [esp + 0x55], ax
mov byte [esp + 0x57], al
mov byte [esp + 0x15c], al
call fcn.00466720
add esp, 0x18
jmp 0x41fd10
mov eax, dword [0x4bdcf8]
add eax, 0x6a
lea edx, [esp + 0x40]
sub edx, eax
mov edi, edi
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x41fd20
lea eax, [esp + 0x20]
push 0x10
push eax
call fcn.0040de10
push eax
call fcn.004688e8
lea eax, [esp + 0x2c]
add esp, 0xc
dec eax
mov cl, byte [eax + 1]
inc eax
test cl, cl
jne 0x41fd44
mov ecx, dword [str..dat]
mov dl, byte [0x49e304]
mov dword [eax], ecx
mov byte [eax + 4], dl
lea eax, [esp + 0x20]
mov edx, eax
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x41fd63
lea edi, [esp + 0x40]
sub eax, edx
dec edi
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x41fd71
mov ecx, eax
shr ecx, 2
mov esi, edx
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
lea eax, [esp + 0x40]
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
call fcn.0040d710
add esp, 4
test al, al
jne 0x41fd10
mov ecx, dword [0x4bdcf8]
add ecx, 0x28c
push ecx
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov ebp, dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
mov dword [ebx], 0xffffffff
mov edx, dword [0x4bdcf8]
add edx, 0x16e
push edx
push 0x10
lea eax, [esp + 0x28]
push eax
push 0x49c432
push str.AppNum
push 0x49e238
call ebp
mov esi, dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringA]
test eax, eax
jne 0x41fe3a
mov ecx, dword [0x4bdcf8]
add ecx, 0x16e
push ecx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov edx, dword [0x4bdcf8]
add edx, 0x16e
push edx
push 0x49e2a4
push str.AppNum
push 0x49e238
call esi
push 0xa
lea ecx, [esp + 0x24]
push ecx
push 1
call fcn.004688e8
mov ebp, dword [esp + 0x20]
mov dword [ebx], 0
jmp 0x41fefd
lea eax, [esp + 0x20]
push eax
call fcn.00467557
mov ebx, eax
add esp, 4
test ebx, ebx
jg 0x41fe84
mov ecx, dword [0x4bdcf8]
add ecx, 0x16e
push ecx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov edx, dword [0x4bdcf8]
add edx, 0x16e
push edx
push 0x49e2a4
push str.AppNum
push 0x49e238
call esi
mov ebx, dword [esp + 0x14]
jmp 0x41fe1d
xor edi, edi
push 0xa
lea eax, [esp + 0x24]
push eax
push edi
call fcn.004688e8
mov ecx, dword [0x4bdcf8]
add esp, 0xc
add ecx, 0x16e
push ecx
push 0x800
lea edx, [esp + 0x14c]
push edx
push 0x49c432
push 0x49e11c
lea eax, [esp + 0x34]
push eax
call ebp
test eax, eax
je 0x41fee9
inc edi
cmp edi, ebx
jl 0x41fe86
mov ebp, dword [esp + 0x14]
cmp dword [ebp], 0xffffffff
push 0xa
jne 0x41fef2
lea edx, [esp + 0x24]
push edx
lea eax, [ebx + 1]
push eax
call fcn.004688e8
mov dword [ebp], ebx
jmp 0x41fefd
mov ebp, dword [esp + 0x14]
mov dword [ebp], edi
jmp 0x41fece
lea ecx, [esp + 0x24]
push ecx
push ebx
call fcn.004688e8
mov edx, dword [0x4bdcf8]
add esp, 0xc
add edx, 0x16e
push edx
lea eax, [esp + 0x24]
push eax
push str.AppNum
push 0x49e238
call esi
test eax, eax
je 0x420024
mov edx, dword [ebp]
push 0xa
lea ecx, [esp + 0x24]
push ecx
push edx
call fcn.004688e8
mov eax, dword [0x4bdcf8]
mov ebp, dword [esp + 0x24]
add esp, 0xc
add eax, 0x16e
push eax
lea ecx, [ebp + 0x210]
push ecx
push 0x49e11c
lea edx, [esp + 0x2c]
push edx
call esi
mov eax, dword [0x4bdcf8]
mov edx, dword [ebp + 0xa64]
add eax, 0x16e
push eax
mov eax, dword [ebp + 0xa60]
push 0xa
lea ecx, [esp + 0x14c]
push ecx
push edx
push eax
call fcn.004689c2
add esp, 0x10
push eax
push str.size
lea ecx, [esp + 0x2c]
push ecx
call esi
mov edx, dword [0x4bdcf8]
add edx, 0x16e
push edx
lea eax, [ebp + 0xba8]
push eax
push 0x49e214
lea ecx, [esp + 0x2c]
push ecx
call esi
mov edx, dword [0x4bdcf8]
mov ecx, dword [ebp + 0xa14]
add edx, 0x16e
push edx
push 0xa
lea eax, [esp + 0x14c]
push eax
push ecx
call fcn.004688e8
add esp, 0xc
push eax
push 0x49e210
lea edx, [esp + 0x2c]
push edx
call esi
mov eax, dword [0x4bdcf8]
add eax, 0x16e
push eax
lea ecx, [ebp + 8]
push ecx
push str.file
lea edx, [esp + 0x2c]
push edx
call esi
mov eax, dword [0x4bdcf8]
add eax, 0x16e
push eax
lea ecx, [esp + 0x44]
push ecx
push 0x49e20c
lea edx, [esp + 0x2c]
push edx
call esi
mov byte [esp + 0x13], 1
jmp 0x420028
mov ebp, dword [esp + 0x18]
mov eax, dword [0x4bdcf8]
add eax, 0x28c
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
cmp byte [esp + 0x13], 0
jne 0x420052
push str.SaveData_check_err
call fcn.004168b0
add esp, 4
jmp 0x42035d
xor ebx, ebx
cmp dword [ebp + 0xa14], ebx
mov byte [esp + 0x144], 0
mov dword [esp + 0x14], ebx
jle 0x4202b1
mov edx, dword [ebp + 0xa18]
mov edx, dword [ebx + edx + 4]
push 0xa
lea ecx, [esp + 0x24]
push ecx
push edx
call fcn.004688e8
add esp, 0xc
mov ecx, eax
mov dl, byte [eax]
inc eax
test dl, dl
jne 0x420088
lea edi, [esp + 0x144]
sub eax, ecx
mov esi, ecx
dec edi
jmp 0x4200a0
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x4200a0
mov ecx, eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea edi, [esp + 0x144]
dec edi
mov edi, edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x4200c0
mov ax, word [0x49d0d4]
mov word [edi], ax
mov eax, dword [ebp + 0xa18]
mov edx, dword [ebx + eax + 0x14]
mov eax, dword [ebx + eax + 0x10]
push 0xa
lea ecx, [esp + 0x24]
push ecx
push edx
push eax
call fcn.004689c2
add esp, 0x10
mov ecx, eax
mov dl, byte [eax]
inc eax
test dl, dl
jne 0x4200f2
lea edi, [esp + 0x144]
sub eax, ecx
mov esi, ecx
dec edi
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x420105
mov ecx, eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea edi, [esp + 0x144]
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x420123
mov cx, word [0x49d0d4]
mov eax, dword [ebp + 0xa18]
push 0xa
lea edx, [esp + 0x24]
mov word [edi], cx
mov ecx, dword [ebx + eax + 0x18]
push edx
push ecx
call fcn.004688e8
add esp, 0xc
mov ecx, eax
mov dl, byte [eax]
inc eax
test dl, dl
jne 0x420151
lea edi, [esp + 0x144]
sub eax, ecx
mov esi, ecx
dec edi
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x420164
mov ecx, eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea edi, [esp + 0x144]
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x420182
mov dx, word [0x49d0d4]
mov ecx, dword [ebp + 0xa18]
push 0xa
lea eax, [esp + 0x24]
mov word [edi], dx
mov edx, dword [ebx + ecx + 0x1c]
push eax
push edx
call fcn.004688e8
add esp, 0xc
mov ecx, eax
mov dl, byte [eax]
inc eax
test dl, dl
jne 0x4201b0
lea edi, [esp + 0x144]
sub eax, ecx
mov esi, ecx
dec edi
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x4201c3
mov ecx, eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea edi, [esp + 0x144]
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x4201e1
mov ax, word [0x49d0d4]
mov edx, dword [ebp + 0xa18]
push 0x10
lea ecx, [esp + 0x24]
mov word [edi], ax
mov eax, dword [ebx + edx + 0xc]
push ecx
push eax
call fcn.004688e8
add esp, 0xc
mov ecx, eax
mov edi, edi
mov dl, byte [eax]
inc eax
test dl, dl
jne 0x420210
lea edi, [esp + 0x144]
sub eax, ecx
mov esi, ecx
dec edi
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x420223
mov ecx, eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea edi, [esp + 0x144]
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x420241
mov cx, word [0x49d0d4]
mov edx, dword [ebp + 0xa18]
lea eax, [esp + 0x144]
mov word [edi], cx
dec eax
cmp byte [ebx + edx + 0x20], 0
je 0x420280
mov cl, byte [eax + 1]
inc eax
test cl, cl
jne 0x420268
mov ecx, dword [str.1_r_n]
mov dword [eax], ecx
mov cl, byte [0x49e2b4]
jmp 0x420296
mov cl, byte [eax + 1]
inc eax
test cl, cl
jne 0x420280
mov ecx, dword [str.0_r_n]
mov dword [eax], ecx
mov cl, byte [0x49e2ac]
mov byte [eax + 4], cl
mov eax, dword [esp + 0x14]
inc eax
add ebx, 0x28
cmp eax, dword [ebp + 0xa14]
mov dword [esp + 0x14], eax
jl 0x420072
push 0
push 0x80
push 1
push 0
push 1
push 0x40000000
lea edx, [esp + 0x58]
push edx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
jne 0x4202e4
push str.SaveData_create_file_err
call fcn.004168b0
add esp, 4
jmp 0x42035d
lea eax, [esp + 0x144]
lea edx, [eax + 1]
mov edi, edi
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4202f0
sub eax, edx
push 0
mov edi, eax
lea eax, [esp + 0x20]
push eax
push edi
lea ecx, [esp + 0x150]
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push esi
mov ebp, eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test ebp, ebp
je 0x420345
cmp edi, dword [esp + 0x1c]
jne 0x420345
mov edx, dword [esp + 0x18]
lea eax, [esp + 0x40]
add edx, 0x10c
mov ecx, eax
sub edx, ecx
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x420337
mov al, 1
jmp 0x42035f
push str.SaveData_write_file_err
call fcn.004168b0
add esp, 4
lea edx, [esp + 0x40]
push edx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
xor al, al
mov ecx, dword [esp + 0x2144]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.00466555
add esp, 0x2138
ret