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

Disassembly:
push 0xffffffffffffffff
push 0x632198
mov eax, dword fs:[0]
push eax
sub esp, 0x14
push ebx
push ebp
push esi
push edi
mov eax, dword [0x70a308]
xor eax, esp
push eax
lea eax, [esp + 0x28]
mov dword fs:[0], eax
mov edi, ecx
mov eax, dword [edi + 0x18]
xor ebp, ebp
cmp eax, ebp
jne 0x510f65
lea eax, [edi + 0x1c]
push 0x6523b4
push eax
call fcn.005fb2bd
mov ebx, eax
add esp, 8
mov dword [esp + 0x20], ebx
cmp ebx, ebp
je 0x51114a
lea ecx, [esp + 0x24]
call fcn.004024e0
mov dword [esp + 0x30], ebp
mov eax, dword [edi + 0xc]
xor esi, esi
cmp eax, ebp
mov dword [esp + 0x18], esi
jle 0x511108
nop
lea ecx, [esp + 0x14]
call fcn.004024e0
mov byte [esp + 0x30], 1
test ebp, ebp
jl 0x51115e
cmp esi, dword [edi + 0xc]
jge 0x51115e
mov eax, dword [edi + 8]
push 0
push 0
push 0
push 0
add eax, ebp
mov eax, dword [eax + 8]
push 0xffffffffffffffff
push eax
push 0
push 0xfde9
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
mov esi, eax
test esi, esi
jle 0x5110ca
mov ecx, dword [esp + 0x14]
mov eax, dword [ecx - 8]
mov edx, 1
sub edx, dword [ecx - 4]
sub eax, esi
or eax, edx
jge 0x51100c
push esi
lea ecx, [esp + 0x18]
call fcn.004020a0
mov ecx, dword [esp + 0x14]
cmp esi, dword [ecx - 8]
mov ebx, ecx
jg 0x511163
mov dword [ecx - 0xc], esi
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x18]
mov byte [esi + eax], 0
cmp ecx, dword [edi + 0xc]
jge 0x51115e
mov eax, dword [edi + 8]
push 0
push 0
push esi
push ebx
add eax, ebp
mov eax, dword [eax + 8]
push 0xffffffffffffffff
push eax
push 0
push 0xfde9
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
test eax, eax
je 0x5110ca
lea ecx, [esp + 0x1c]
call fcn.004024e0
mov byte [esp + 0x30], 2
mov eax, dword [esp + 0x18]
cmp eax, dword [edi + 0xc]
jge 0x51115e
mov ecx, dword [edi + 8]
add ecx, ebp
cmp eax, dword [edi + 0xc]
jge 0x51115e
mov eax, dword [edi + 8]
mov edx, dword [ecx + 4]
push ebx
add eax, ebp
mov eax, dword [eax]
push edx
push eax
lea ecx, [esp + 0x28]
push str._ld__s_r_n_s_r_n
push ecx
call fcn.00402f60
mov edx, dword [esp + 0x30]
mov eax, edx
add esp, 0x14
lea esi, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x5110a2
mov ecx, dword [esp + 0x20]
push ecx
sub eax, esi
push eax
push 1
push edx
call fcn.005fb175
add esp, 0x10
mov byte [esp + 0x30], 1
lea ecx, [esp + 0x1c]
call fcn.00402550
mov byte [esp + 0x30], 0
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x5110ef
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov esi, dword [esp + 0x18]
inc esi
add ebp, 0xc
cmp esi, dword [edi + 0xc]
mov dword [esp + 0x18], esi
jl 0x510fa0
mov ebx, dword [esp + 0x20]
push ebx
call fcn.005faf97
mov eax, dword [edi + 0x24]
add esp, 4
test eax, eax
jne 0x51111b
lea eax, [edi + 0x28]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov dword [esp + 0x30], 0xffffffff
mov eax, dword [esp + 0x24]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x51114a
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [esp + 0x28]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x20
ret
call fcn.005cfbb9
push 0x80070057
call fcn.00401090
int3