Function at 0x402100
Capabilities:
Delete file
Write file on windows

Disassembly:
push 0xffffffffffffffff
push 0x4392c6
mov eax, dword fs:[0]
push eax
sub esp, 0x450
mov eax, dword [0x449cd0]
xor eax, esp
mov dword [esp + 0x44c], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x449cd0]
xor eax, esp
push eax
lea eax, [esp + 0x464]
mov dword fs:[0], eax
mov esi, dword [esp + 0x478]
mov dword [esp + 0x2c], esi
call fcn.00410194
xor ecx, ecx
xor ebx, ebx
cmp eax, ebx
setne cl
cmp ecx, ebx
jne 0x402162
push 0x80004005
call fcn.00401330
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
lea ebp, [eax + 0x10]
mov dword [esp + 0x18], ebp
mov dword [esp + 0x46c], ebx
call fcn.00410194
xor ecx, ecx
cmp eax, ebx
setne cl
cmp ecx, ebx
jne 0x402193
push 0x80004005
call fcn.00401330
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [esp + 0x14], eax
push 0x10e
lea ecx, [esp + 0x14c]
push ebx
push ecx
mov byte [esp + 0x478], 1
mov dword [esp + 0x30], ebx
mov dword [esp + 0x34], ebx
mov dword [esp + 0x28], ebx
call fcn.0041ec20
push 0x118
lea edx, [esp + 0x40]
push ebx
push edx
call fcn.0041ec20
push 0x104
lea eax, [esp + 0x378]
push ebx
push eax
call fcn.0041ec20
mov eax, dword [esp + 0x498]
lea ecx, [esp + 0x380]
add esp, 0x24
sub ecx, eax
mov dl, byte [eax]
mov byte [ecx + eax], dl
inc eax
cmp dl, bl
jne 0x402200
lea eax, [esp + 0x35c]
dec eax
mov cl, byte [eax + 1]
inc eax
cmp cl, bl
jne 0x402212
mov ecx, dword [str.LdCab.ldind]
mov edx, dword [0x43b588]
mov dword [eax], ecx
mov ecx, dword [0x43b58c]
mov dword [eax + 4], edx
mov dl, byte [0x43b590]
mov dword [eax + 8], ecx
mov byte [eax + 0xc], dl
lea eax, [esp + 0x35c]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
lea ecx, [esp + 0x35c]
push 0x43b580
push ecx
call fcn.0041e83b
mov edi, eax
add esp, 8
mov dword [esp + 0x20], edi
cmp edi, ebx
jne 0x4022e4
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea edx, [esp + 0x18]
push str.WriteFileSummaryToLdind_fail_in_fopen_error_code:__d
push edx
call fcn.00401ce0
mov esi, dword [esp + 0x20]
add esp, 0xc
push ebx
push esi
mov ecx, 0x44b3c5
call fcn.0040aa20
lea eax, [esi - 0x10]
mov byte [esp + 0x46c], bl
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4022b6
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea eax, [ebp - 0x10]
mov dword [esp + 0x46c], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4022dd
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
xor al, al
jmp 0x4025cd
mov dx, word [0x43b57c]
mov ecx, dword [str.LDIND]
mov word [esp + 0x14c], dx
mov eax, 0x10e
mov edx, 1
mov word [esp + 0x152], dx
mov dword [esp + 0x148], ecx
mov word [esp + 0x14e], ax
mov eax, dword [esp + 0x47c]
xor ecx, ecx
lea edx, [esp + 0x154]
mov word [esp + 0x150], cx
sub edx, eax
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
cmp cl, bl
jne 0x402334
mov eax, dword [esi + 0xc]
push edi
push 1
mov word [esp + 0x25c], ax
lea eax, [esp + 0x150]
push 0x10e
push eax
call fcn.0041e3d0
mov ebp, dword [esi + 4]
add esp, 0x10
cmp ebp, ebx
je 0x4024de
push 0x118
lea ecx, [esp + 0x34]
push ebx
push ecx
call fcn.0041ec20
push 0x104
lea edx, [esp + 0x268]
push ebx
push edx
call fcn.0041ec20
add esp, 0x18
mov eax, ebp
cmp ebp, ebx
je 0x402541
mov ebp, dword [ebp]
add eax, 8
push eax
lea ecx, [esp + 0x1c]
call fcn.00401c60
mov eax, dword [esp + 0x484]
lea edx, [esp + 0x258]
sub edx, eax
lea esp, [esp]
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
cmp cl, bl
jne 0x4023c0
lea edi, [esp + 0x258]
dec edi
mov al, byte [edi + 1]
inc edi
cmp al, bl
jne 0x4023d2
mov ax, word [0x43b574]
mov word [edi], ax
mov eax, dword [esp + 0x18]
mov ecx, eax
lea esp, [esp]
mov dl, byte [eax]
inc eax
cmp dl, bl
jne 0x4023f0
lea edi, [esp + 0x258]
sub eax, ecx
mov esi, ecx
dec edi
mov cl, byte [edi + 1]
inc edi
cmp cl, bl
jne 0x402403
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 ecx, [esp + 0x258]
push ecx
call fcn.00407e00
add esp, 4
test eax, eax
je 0x402438
or dword [esp + 0x13c], 0x80000000
mov edx, dword [esp + 0x480]
or dword [esp + 0x13c], edx
lea eax, [esp + 0x134]
push eax
lea ecx, [esp + 0x25c]
push ebx
push ecx
call fcn.00407b90
mov esi, dword [esp + 0x30]
lea edx, [esp + 0x264]
push edx
mov dword [esp + 0x150], esi
call fcn.00407c90
add esp, 0x10
mov dword [esp + 0x130], eax
cmp eax, 0xffffffff
je 0x402546
mov dword [esp + 0x144], eax
mov eax, dword [esp + 0x18]
lea edx, [esp + 0x30]
sub edx, eax
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
cmp cl, bl
jne 0x402498
mov eax, dword [esp + 0x20]
push eax
push 1
lea ecx, [esp + 0x38]
push 0x118
push ecx
call fcn.0041e3d0
inc dword [esp + 0x2c]
add esp, 0x10
add esi, dword [esp + 0x130]
adc dword [esp + 0x28], ebx
mov dword [esp + 0x24], esi
cmp ebp, ebx
jne 0x40236c
mov edi, dword [esp + 0x20]
mov esi, dword [esp + 0x2c]
mov ecx, dword [esp + 0x1c]
cmp ecx, dword [esi + 0xc]
je 0x402574
push str.WriteFileSummaryToLdind_failed_in_iHandFile_var
lea ecx, [esp + 0x18]
call fcn.004020c0
mov esi, dword [esp + 0x14]
push ebx
push esi
mov ecx, 0x44b3c5
call fcn.0040aa20
push edi
call fcn.0041e1f2
lea eax, [esi - 0x10]
add esp, 4
mov byte [esp + 0x46c], bl
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x402535
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
jmp 0x4022b9
call fcn.0040feea
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea edx, [esp + 0x18]
push str.WriteFileSummaryToLdind_fail_in_GetFileSize:__d
push edx
call fcn.00401ce0
mov esi, dword [esp + 0x20]
add esp, 0xc
push ebx
push esi
mov ecx, 0x44b3c5
call fcn.0040aa20
lea eax, [esi - 0x10]
jmp 0x402584
push edi
call fcn.0041e1f2
mov eax, dword [esp + 0x18]
add esp, 4
add eax, 0xfffffff0
or edx, 0xffffffff
lea ecx, [eax + 0xc]
mov byte [esp + 0x46c], bl
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4025a4
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
or edx, 0xffffffff
lea ecx, [eax + 0xc]
mov dword [esp + 0x46c], edx
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4025cb
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov al, 1
mov ecx, dword [esp + 0x464]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x44c]
xor ecx, esp
call fcn.0041d4f4
add esp, 0x45c
ret