Function at 0x1037421
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 0x103745e
test byte [eax + 0x1c], 4
je 0x103745e
cmp byte [eax + 0x19], 5
jb 0x103745e
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 0x10374a7
push eax
call dword [sym.imp.ADVAPI32.dll_IsValidSid]
test eax, eax
jne 0x10374a7
mov eax, dword [0x1075004]
cmp eax, edi
je 0x10374a0
test byte [eax + 0x1c], 4
je 0x10374a0
cmp byte [eax + 0x19], 2
jb 0x10374a0
push dword [esi + 0x18]
push 0x1002380
push 0x74
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.0102ca9d
xor eax, eax
jmp 0x1037abb
push ebx
push esi
call fcn.010351e8
mov edi, 0x590
add eax, edi
push eax
mov dword [ebp + 8], eax
call fcn.0105c544
mov ebx, eax
test ebx, ebx
je 0x1037aba
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.01009a5d
mov ecx, eax
mov dword [ebp - 0xc], ecx
test ecx, ecx
jge 0x10375aa
mov eax, dword [0x1075004]
cmp eax, 0x1075004
je 0x103758e
test byte [eax + 0x1c], 4
je 0x103758e
cmp byte [eax + 0x19], 2
jb 0x103758e
push ecx
push 0x1002380
push 0x75
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.0102ca9d
mov ecx, dword [ebp - 0xc]
mov eax, ecx
and eax, 0x1fff0000
cmp eax, 0x70000
jne 0x10375a2
and ecx, 0xffff
mov dword [ebp - 8], ecx
jmp 0x1037ab1
lea eax, [esi + 0x180]
push eax
push edi
lea eax, [ebx + 0x14c]
push eax
call fcn.01009a5d
mov edi, eax
test edi, edi
jge 0x103760b
mov eax, dword [0x1075004]
cmp eax, 0x1075004
je 0x10375ef
test byte [eax + 0x1c], 4
je 0x10375ef
cmp byte [eax + 0x19], 2
jb 0x10375ef
push edi
push 0x1002380
push 0x76
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.0102ca9d
mov eax, edi
and eax, 0x1fff0000
cmp eax, 0x70000
jne 0x1037603
and edi, 0xffff
mov dword [ebp - 8], edi
jmp 0x1037ab1
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 0x103765f
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 0x10376cf
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.0105d0ed
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.0105d0ed
mov eax, dword [esi + 0x1c]
cmp eax, 0x20
je 0x1037716
cmp eax, 8
jne 0x1037728
push edi
lea eax, [ebp - 4]
push eax
push ebx
lea eax, [ebx + 0x28]
push eax
push dword [esi + 0x34]
call fcn.0105d0ed
push edi
lea eax, [ebp - 4]
push eax
push ebx
lea eax, [ebx + 0x2c]
push eax
lea eax, [esi + 0x38]
push eax
call fcn.01034d1b
test eax, eax
jne 0x1037784
mov dword [ebp - 8], 0x7a
mov eax, dword [0x1075004]
cmp eax, 0x1075004
je 0x1037ab1
test byte [eax + 0x1c], 4
je 0x1037ab1
cmp byte [eax + 0x19], 2
jb 0x1037ab1
push dword [esi + 0x18]
push 0x1002380
push 0x77
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.0102ca9d
jmp 0x1037ab1
push edi
lea eax, [ebp - 4]
push eax
push ebx
lea eax, [ebx + 0x6c]
push eax
lea eax, [esi + 0x78]
push eax
call fcn.01034d75
test eax, eax
jne 0x10377d2
mov dword [ebp - 8], 0x7a
mov eax, dword [0x1075004]
cmp eax, 0x1075004
je 0x1037ab1
test byte [eax + 0x1c], 4
je 0x1037ab1
cmp byte [eax + 0x19], 2
jb 0x1037ab1
push dword [esi + 0x18]
push 0x1002380
push 0x78
jmp 0x1037774
push edi
lea eax, [ebp - 4]
push eax
push ebx
lea eax, [ebx + 0x88]
push eax
lea eax, [esi + 0x9c]
push eax
call fcn.01034de4
test eax, eax
jne 0x1037829
mov dword [ebp - 8], 0x7a
mov eax, dword [0x1075004]
cmp eax, 0x1075004
je 0x1037ab1
test byte [eax + 0x1c], 4
je 0x1037ab1
cmp byte [eax + 0x19], 2
jb 0x1037ab1
push dword [esi + 0x18]
push 0x1002380
push 0x79
jmp 0x1037774
push edi
lea eax, [ebp - 4]
push eax
push ebx
lea eax, [ebx + 0xe0]
push eax
push dword [esi + 0xf4]
call fcn.0105d0ed
push edi
lea eax, [ebp - 4]
push eax
push ebx
lea eax, [ebx + 0xfc]
push eax
lea eax, [esi + 0x118]
push eax
call fcn.01034de4
test eax, eax
jne 0x1037896
push 0x7a
pop ecx
mov dword [ebp - 8], ecx
mov eax, dword [0x1075004]
cmp eax, 0x1075004
je 0x1037ab1
test byte [eax + 0x1c], 4
je 0x1037ab1
cmp byte [eax + 0x19], 2
jb 0x1037ab1
push dword [esi + 0x18]
push 0x1002380
push ecx
jmp 0x1037774
cmp dword [esi + 0x1c], 8
jne 0x10378f9
push edi
lea eax, [ebp - 4]
push eax
push ebx
push esi
call fcn.01034f3e
mov dword [ebp - 8], eax
test eax, eax
jne 0x10378f9
mov eax, dword [0x1075004]
cmp eax, 0x1075004
je 0x1037ab1
test byte [eax + 0x1c], 4
je 0x1037ab1
cmp byte [eax + 0x19], 2
jb 0x1037ab1
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.010148b3
jmp 0x1037ab1
xor eax, eax
push eax
push 0x80000080
push 2
push eax
push eax
push 0x40000000
push dword [esi + 0x2c]
call fcn.0105e5e0
mov dword [ebp + 8], eax
cmp eax, 0xffffffff
jne 0x1037953
mov eax, dword [0x1075004]
cmp eax, 0x1075004
je 0x103794a
test byte [eax + 0x1c], 4
je 0x103794a
cmp byte [eax + 0x19], 2
jb 0x103794a
push dword [esi + 0x2c]
push dword [esi + 0x18]
push 0x1002380
push 0x7c
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01044210
and dword [ebp - 8], 0
jmp 0x1037ab1
push edi
push ebx
push eax
call fcn.0103651c
test eax, eax
je 0x1037a6f
cmp dword [ebp + 0xc], 0
je 0x1037a33
mov ecx, dword [0x1075004]
cmp ecx, 0x1075004
je 0x10379a3
test byte [ecx + 0x1c], 4
je 0x10379a3
cmp byte [ecx + 0x19], 2
jb 0x10379a3
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.01044197
jmp 0x10379a8
mov edi, 0x1002380
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test eax, eax
jne 0x10379ed
mov eax, dword [0x1075004]
cmp eax, 0x1075004
je 0x10379ed
test byte [eax + 0x1c], 4
je 0x10379ed
cmp byte [eax + 0x19], 2
jb 0x10379ed
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.01034367
push dword [esi + 0x2c]
or dword [ebp + 8], 0xffffffff
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
jne 0x1037a69
mov eax, dword [0x1075004]
cmp eax, 0x1075004
je 0x1037a69
test byte [eax + 0x1c], 4
je 0x1037a69
cmp byte [eax + 0x19], 2
jb 0x1037a69
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 0x1037a64
mov ecx, dword [0x1075004]
cmp ecx, 0x1075004
je 0x1037a69
test byte [ecx + 0x1c], 4
je 0x1037a69
cmp byte [ecx + 0x19], 2
jb 0x1037a69
push eax
push dword [esi + 0x2c]
push dword [esi + 0x18]
push 0x1002380
push 0x80
push dword [ecx + 0x14]
push dword [ecx + 0x10]
call fcn.01044197
and dword [ebp - 8], 0
jmp 0x1037aa2
mov eax, dword [0x1075004]
cmp eax, 0x1075004
je 0x1037aa2
test byte [eax + 0x1c], 4
je 0x1037aa2
cmp byte [eax + 0x19], 5
jb 0x1037aa2
push dword [esi + 0x2c]
push dword [esi + 0x18]
push 0x1002380
push 0x81
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01044210
cmp dword [ebp + 8], 0xffffffff
je 0x1037ab1
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push ebx
call fcn.0105c5dc
mov eax, dword [ebp - 8]
pop ebx
pop edi
pop esi
leave
ret 8