Function at 0x1037014
Capabilities:
Delete file

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0xc
push esi
push edi
mov dword [ebp - 8], 1
mov eax, dword [0x1075004]
mov edi, 0x1075004
cmp eax, edi
je 0x1037051
test byte [eax + 0x1c], 4
je 0x1037051
cmp byte [eax + 0x19], 5
jb 0x1037051
push 0x1002380
push 0x73
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.010090c5
mov esi, dword [ebp + 8]
mov eax, dword [esi + 0xf8]
test eax, eax
je 0x103709a
push eax
call dword [sym.imp.ADVAPI32.dll_IsValidSid]
test eax, eax
jne 0x103709a
mov eax, dword [0x1075004]
cmp eax, edi
je 0x1037093
test byte [eax + 0x1c], 4
je 0x1037093
cmp byte [eax + 0x19], 2
jb 0x1037093
push dword [esi + 0x18]
push 0x1002380
push 0x74
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.0101463a
xor eax, eax
jmp 0x10376ae
push ebx
push esi
call fcn.01034ddb
mov edi, 0x590
add eax, edi
push eax
mov dword [ebp + 8], eax
call fcn.0105c184
mov ebx, eax
test ebx, ebx
je 0x10376ad
push dword [ebp + 8]
push 0
push ebx
call sub.msvcrt.dll_memset
mov dword [ebp - 4], edi
mov dword [ebx], edi
mov eax, dword [esi + 8]
mov dword [ebx + 8], eax
mov eax, dword [esi + 0xc]
mov dword [ebx + 0xc], eax
mov eax, dword [esi + 0x10]
mov dword [ebx + 0x10], eax
mov eax, dword [esi + 0x14]
mov dword [ebx + 0x14], eax
mov eax, dword [esi + 0x100]
mov dword [ebx + 0xe8], eax
mov eax, dword [esi + 0x104]
mov dword [ebx + 0xec], eax
mov eax, dword [esi + 0x108]
mov dword [ebx + 0xf0], eax
mov eax, dword [esi + 0x10c]
mov dword [ebx + 0xf4], eax
mov eax, dword [esi + 0x1c]
mov dword [ebx + 0x18], eax
mov eax, dword [esi + 0x5e8]
mov dword [ebx + 0x20], eax
mov eax, dword [esi + 0x590]
add esp, 0xc
mov dword [ebx + 0x588], eax
lea eax, [esi + 0x390]
push eax
mov edi, 0x100
push edi
lea eax, [ebx + 0x388]
push eax
call fcn.010676d2
mov ecx, eax
mov dword [ebp - 0xc], ecx
test ecx, ecx
jge 0x103719d
mov eax, dword [0x1075004]
cmp eax, 0x1075004
je 0x1037181
test byte [eax + 0x1c], 4
je 0x1037181
cmp byte [eax + 0x19], 2
jb 0x1037181
push ecx
push 0x1002380
push 0x75
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.0101463a
mov ecx, dword [ebp - 0xc]
mov eax, ecx
and eax, 0x1fff0000
cmp eax, 0x70000
jne 0x1037195
and ecx, 0xffff
mov dword [ebp - 8], ecx
jmp 0x10376a4
lea eax, [esi + 0x180]
push eax
push edi
lea eax, [ebx + 0x14c]
push eax
call fcn.010676d2
mov edi, eax
test edi, edi
jge 0x10371fe
mov eax, dword [0x1075004]
cmp eax, 0x1075004
je 0x10371e2
test byte [eax + 0x1c], 4
je 0x10371e2
cmp byte [eax + 0x19], 2
jb 0x10371e2
push edi
push 0x1002380
push 0x76
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.0101463a
mov eax, edi
and eax, 0x1fff0000
cmp eax, 0x70000
jne 0x10371f6
and edi, 0xffff
mov dword [ebp - 8], edi
jmp 0x10376a4
mov eax, dword [esi + 0x30]
mov dword [ebx + 0x24], eax
mov eax, dword [esi + 0x98]
mov dword [ebx + 0x84], eax
mov eax, dword [esi + 0xe4]
mov dword [ebx + 0xd0], eax
mov eax, dword [esi + 0xe0]
mov dword [ebx + 0xcc], eax
mov eax, dword [esi + 0xec]
mov dword [ebx + 0xd4], eax
cmp dword [esi + 0x1c], 2
jne 0x1037252
mov eax, dword [esi + 0x15c]
mov ecx, dword [eax + 8]
mov dword [ebx + 0x140], ecx
mov eax, dword [eax + 0xc]
mov dword [ebx + 0x144], eax
mov eax, dword [esi + 0x160]
mov dword [ebx + 0x148], eax
mov eax, dword [esi + 0x380]
mov dword [ebx + 0x378], eax
mov eax, dword [esi + 0x384]
mov dword [ebx + 0x37c], eax
mov eax, dword [esi + 0x388]
mov dword [ebx + 0x380], eax
mov eax, dword [esi + 0x38c]
mov dword [ebx + 0x384], eax
mov eax, dword [esi + 0xf8]
test eax, eax
je 0x10372c2
push eax
call dword [sym.imp.ADVAPI32.dll_GetLengthSid]
mov edi, eax
mov eax, dword [ebp - 4]
mov dword [ebx + 0xe4], eax
mov eax, dword [ebp - 4]
push edi
push dword [esi + 0xf8]
add eax, ebx
push eax
call sub.msvcrt.dll_memcpy
add esp, 0xc
add dword [ebp - 4], edi
push dword [ebp + 8]
lea eax, [ebp - 4]
push eax
push ebx
lea eax, [ebx + 0xf8]
push eax
push dword [esi + 0x114]
call fcn.0105cd2d
xor eax, eax
lea edi, [ebx + 0x368]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
mov edi, dword [ebp + 8]
push edi
lea ecx, [ebp - 4]
push ecx
push ebx
lea eax, [ebx + 0x1c]
push eax
push dword [esi + 0x2c]
call fcn.0105cd2d
mov eax, dword [esi + 0x1c]
cmp eax, 0x20
je 0x1037309
cmp eax, 8
jne 0x103731b
push edi
lea eax, [ebp - 4]
push eax
push ebx
lea eax, [ebx + 0x28]
push eax
push dword [esi + 0x34]
call fcn.0105cd2d
push edi
lea eax, [ebp - 4]
push eax
push ebx
lea eax, [ebx + 0x2c]
push eax
lea eax, [esi + 0x38]
push eax
call fcn.0103490e
test eax, eax
jne 0x1037377
mov dword [ebp - 8], 0x7a
mov eax, dword [0x1075004]
cmp eax, 0x1075004
je 0x10376a4
test byte [eax + 0x1c], 4
je 0x10376a4
cmp byte [eax + 0x19], 2
jb 0x10376a4
push dword [esi + 0x18]
push 0x1002380
push 0x77
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.0101463a
jmp 0x10376a4
push edi
lea eax, [ebp - 4]
push eax
push ebx
lea eax, [ebx + 0x6c]
push eax
lea eax, [esi + 0x78]
push eax
call fcn.01034968
test eax, eax
jne 0x10373c5
mov dword [ebp - 8], 0x7a
mov eax, dword [0x1075004]
cmp eax, 0x1075004
je 0x10376a4
test byte [eax + 0x1c], 4
je 0x10376a4
cmp byte [eax + 0x19], 2
jb 0x10376a4
push dword [esi + 0x18]
push 0x1002380
push 0x78
jmp 0x1037367
push edi
lea eax, [ebp - 4]
push eax
push ebx
lea eax, [ebx + 0x88]
push eax
lea eax, [esi + 0x9c]
push eax
call fcn.010349d7
test eax, eax
jne 0x103741c
mov dword [ebp - 8], 0x7a
mov eax, dword [0x1075004]
cmp eax, 0x1075004
je 0x10376a4
test byte [eax + 0x1c], 4
je 0x10376a4
cmp byte [eax + 0x19], 2
jb 0x10376a4
push dword [esi + 0x18]
push 0x1002380
push 0x79
jmp 0x1037367
push edi
lea eax, [ebp - 4]
push eax
push ebx
lea eax, [ebx + 0xe0]
push eax
push dword [esi + 0xf4]
call fcn.0105cd2d
push edi
lea eax, [ebp - 4]
push eax
push ebx
lea eax, [ebx + 0xfc]
push eax
lea eax, [esi + 0x118]
push eax
call fcn.010349d7
test eax, eax
jne 0x1037489
push 0x7a
pop ecx
mov dword [ebp - 8], ecx
mov eax, dword [0x1075004]
cmp eax, 0x1075004
je 0x10376a4
test byte [eax + 0x1c], 4
je 0x10376a4
cmp byte [eax + 0x19], 2
jb 0x10376a4
push dword [esi + 0x18]
push 0x1002380
push ecx
jmp 0x1037367
cmp dword [esi + 0x1c], 8
jne 0x10374ec
push edi
lea eax, [ebp - 4]
push eax
push ebx
push esi
call fcn.01034b31
mov dword [ebp - 8], eax
test eax, eax
jne 0x10374ec
mov eax, dword [0x1075004]
cmp eax, 0x1075004
je 0x10376a4
test byte [eax + 0x1c], 4
je 0x10376a4
cmp byte [eax + 0x19], 2
jb 0x10376a4
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push dword [esi + 0x18]
mov eax, dword [0x1075004]
push 0x1002380
push 0x7b
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.0100a693
jmp 0x10376a4
xor eax, eax
push eax
push 0x80000080
push 2
push eax
push eax
push 0x40000000
push dword [esi + 0x2c]
call fcn.0105e220
mov dword [ebp + 8], eax
cmp eax, 0xffffffff
jne 0x1037546
mov eax, dword [0x1075004]
cmp eax, 0x1075004
je 0x103753d
test byte [eax + 0x1c], 4
je 0x103753d
cmp byte [eax + 0x19], 2
jb 0x103753d
push dword [esi + 0x2c]
push dword [esi + 0x18]
push 0x1002380
push 0x7c
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.010090eb
and dword [ebp - 8], 0
jmp 0x10376a4
push edi
push ebx
push eax
call fcn.0103610f
test eax, eax
je 0x1037662
cmp dword [ebp + 0xc], 0
je 0x1037626
mov ecx, dword [0x1075004]
cmp ecx, 0x1075004
je 0x1037596
test byte [ecx + 0x1c], 4
je 0x1037596
cmp byte [ecx + 0x19], 2
jb 0x1037596
push eax
push dword [esi + 0x2c]
mov edi, 0x1002380
push dword [esi + 0x18]
push edi
push 0x7d
push dword [ecx + 0x14]
push dword [ecx + 0x10]
call fcn.01043dbf
jmp 0x103759b
mov edi, 0x1002380
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test eax, eax
jne 0x10375e0
mov eax, dword [0x1075004]
cmp eax, 0x1075004
je 0x10375e0
test byte [eax + 0x1c], 4
je 0x10375e0
cmp byte [eax + 0x19], 2
jb 0x10375e0
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push dword [ebp + 8]
mov eax, dword [0x1075004]
push dword [ebx + 0x1c]
push edi
push 0x7e
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01033f5a
push dword [esi + 0x2c]
or dword [ebp + 8], 0xffffffff
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
jne 0x103765c
mov eax, dword [0x1075004]
cmp eax, 0x1075004
je 0x103765c
test byte [eax + 0x1c], 4
je 0x103765c
cmp byte [eax + 0x19], 2
jb 0x103765c
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push dword [esi + 0x2c]
mov eax, dword [0x1075004]
push dword [esi + 0x18]
push edi
push 0x7f
push dword [eax + 0x14]
push dword [eax + 0x10]
jmp 0x1037657
mov ecx, dword [0x1075004]
cmp ecx, 0x1075004
je 0x103765c
test byte [ecx + 0x1c], 4
je 0x103765c
cmp byte [ecx + 0x19], 2
jb 0x103765c
push eax
push dword [esi + 0x2c]
push dword [esi + 0x18]
push 0x1002380
push 0x80
push dword [ecx + 0x14]
push dword [ecx + 0x10]
call fcn.01043dbf
and dword [ebp - 8], 0
jmp 0x1037695
mov eax, dword [0x1075004]
cmp eax, 0x1075004
je 0x1037695
test byte [eax + 0x1c], 4
je 0x1037695
cmp byte [eax + 0x19], 5
jb 0x1037695
push dword [esi + 0x2c]
push dword [esi + 0x18]
push 0x1002380
push 0x81
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.010090eb
cmp dword [ebp + 8], 0xffffffff
je 0x10376a4
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push ebx
call fcn.0105c21c
mov eax, dword [ebp - 8]
pop ebx
pop edi
pop esi
leave
ret 8