Function at 0x51080168
Capabilities:
Copy file

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffa8
push ebx
push esi
push edi
mov dword [ebp - 0xc], ecx
mov dword [ebp - 8], edx
mov dword [ebp - 4], eax
mov eax, dword [ebp - 8]
call fcn.51004b7c
mov eax, dword [ebp - 0xc]
call fcn.51004b7c
xor eax, eax
push ebp
push 0x510806b6
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x14c]
call fcn.51005bf8
test eax, eax
jl 0x51080677
inc eax
mov dword [ebp - 0x40], eax
mov dword [ebp - 0x10], 0
mov eax, dword [ebp - 0x10]
imul eax, eax, 4
jno 0x510801c6
call fcn.5100380c
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14c]
lea eax, [edx + eax*8]
mov dword [ebp - 0x34], eax
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0xe0]
mov edx, dword [ebp - 0x10]
call fcn.5107534c
mov eax, dword [eax + 8]
add eax, 1
jno 0x510801f3
call fcn.5100380c
push eax
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0xe0]
mov edx, dword [ebp - 0x10]
call fcn.5107534c
mov eax, dword [eax + 0xc]
add eax, 1
jno 0x51080212
call fcn.5100380c
push eax
mov eax, dword [ebp - 0x34]
add eax, 0x14
mov ecx, 2
mov edx, dword [0x51078968]
call fcn.51005dac
add esp, 8
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0xe0]
mov edx, dword [ebp - 0x10]
call fcn.5107534c
mov eax, dword [eax + 0xc]
test eax, eax
jl 0x510802d3
inc eax
mov dword [ebp - 0x44], eax
mov dword [ebp - 0x1c], 0
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0xe0]
mov edx, dword [ebp - 0x10]
call fcn.5107534c
mov eax, dword [eax + 8]
test eax, eax
jl 0x510802cb
inc eax
mov dword [ebp - 0x48], eax
mov dword [ebp - 0x20], 0
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0xe0]
mov edx, dword [ebp - 0x10]
call fcn.5107534c
mov ecx, dword [ebp - 0x20]
mov edx, dword [ebp - 0x1c]
call fcn.510753c4
mov edx, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0x34]
mov ecx, dword [ecx + 0x14]
test ecx, ecx
je 0x510802a4
cmp edx, dword [ecx - 4]
jb 0x510802a9
call fcn.51003804
mov edx, dword [ecx + edx*4]
mov ecx, dword [ebp - 0x20]
imul ecx, ecx, 2
jno 0x510802b9
call fcn.5100380c
lea esi, [eax + 0x20]
lea edi, [edx + ecx*8]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
inc dword [ebp - 0x20]
dec dword [ebp - 0x48]
jne 0x51080276
inc dword [ebp - 0x1c]
dec dword [ebp - 0x44]
jne 0x51080253
xor eax, eax
mov dword [ebp - 0x14], eax
xor eax, eax
push ebp
push 0x51080654
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, dword [ebp - 0x10]
imul eax, eax, 4
jno 0x510802f3
call fcn.5100380c
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14c]
mov eax, dword [edx + eax*8 + 0x18]
mov edx, dword [ebp - 0x14]
test eax, eax
je 0x5108030c
cmp edx, dword [eax - 4]
jb 0x51080311
call fcn.51003804
mov eax, dword [eax + edx*4]
imul eax, eax, 5
jno 0x5108031e
call fcn.5100380c
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x148]
lea eax, [edx + eax*8]
mov dword [ebp - 0x24], eax
mov eax, dword [ebp - 0x10]
imul eax, eax, 4
jno 0x5108033a
call fcn.5100380c
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14c]
mov eax, dword [edx + eax*8 + 0x18]
mov edx, dword [ebp - 0x14]
add edx, 1
jno 0x51080354
call fcn.5100380c
and edx, 0x80000003
jns 0x51080361
dec edx
or edx, 0xfffffffc
inc edx
test eax, eax
je 0x5108036a
cmp edx, dword [eax - 4]
jb 0x5108036f
call fcn.51003804
mov eax, dword [eax + edx*4]
imul eax, eax, 5
jno 0x5108037c
call fcn.5100380c
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x148]
lea eax, [edx + eax*8]
mov dword [ebp - 0x28], eax
mov eax, dword [ebp - 0x10]
imul eax, eax, 4
jno 0x51080398
call fcn.5100380c
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14c]
mov eax, dword [edx + eax*8 + 0x1c]
mov edx, dword [ebp - 0x14]
test eax, eax
je 0x510803b1
cmp edx, dword [eax - 4]
jb 0x510803b6
call fcn.51003804
mov eax, dword [eax + edx*4]
mov dword [ebp - 0x18], eax
mov eax, dword [ebp - 0x10]
imul eax, eax, 4
jno 0x510803c9
call fcn.5100380c
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14c]
mov eax, dword [edx + eax*8 + 0x18]
mov edx, dword [ebp - 0x14]
test eax, eax
je 0x510803e2
cmp edx, dword [eax - 4]
jb 0x510803e7
call fcn.51003804
cmp dword [eax + edx*4], 0x25
je 0x51080435
mov eax, dword [ebp - 0x10]
imul eax, eax, 4
jno 0x510803fa
call fcn.5100380c
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14c]
mov eax, dword [edx + eax*8 + 0x18]
mov edx, dword [ebp - 0x14]
add edx, 1
jno 0x51080414
call fcn.5100380c
and edx, 0x80000003
jns 0x51080421
dec edx
or edx, 0xfffffffc
inc edx
test eax, eax
je 0x5108042a
cmp edx, dword [eax - 4]
jb 0x5108042f
call fcn.51003804
cmp dword [eax + edx*4], 0x25
jne 0x5108043a
call fcn.510699d8
cmp dword [ebp - 0x18], 0x3c
jne 0x51080445
call fcn.510699d8
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0xe0]
mov edx, dword [ebp - 0x10]
call fcn.5107534c
mov edx, dword [ebp - 0x14]
call fcn.51075418
mov dword [ebp - 0x38], eax
mov eax, dword [ebp - 0x18]
imul eax, eax, 0xb
jno 0x5108046e
call fcn.5100380c
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x150]
lea eax, [edx + eax*8]
mov dword [ebp - 0x30], eax
mov eax, dword [ebp - 0x10]
imul eax, eax, 4
jno 0x5108048a
call fcn.5100380c
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14c]
mov eax, dword [edx + eax*8 + 0x18]
mov edx, dword [ebp - 0x14]
test eax, eax
je 0x510804a3
cmp edx, dword [eax - 4]
jb 0x510804a8
call fcn.51003804
mov eax, dword [eax + edx*4]
mov edx, dword [ebp - 0x30]
cmp eax, dword [edx + 8]
setne byte [ebp - 0x39]
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0xf8]
mov edx, dword [ebp - 0x18]
call fcn.51018e04
mov edx, dword [0x5107257c]
call fcn.51003a7c
mov dword [ebp - 0x2c], eax
cmp dword [ebp - 0x2c], 0
je 0x51080529
xor eax, eax
imul eax, eax, 6
jno 0x510804e6
call fcn.5100380c
mov edx, dword [ebp - 0x2c]
mov edx, dword [edx + 0x18]
mov ecx, dword [ebp - 0x24]
mov ebx, dword [edx + eax*8 + 8]
mov dword [ecx + 0x18], ebx
mov ebx, dword [edx + eax*8 + 0xc]
mov dword [ecx + 0x1c], ebx
mov eax, dword [ebp - 0x2c]
mov eax, dword [eax + 0x18]
call fcn.51005bf8
imul eax, eax, 6
jno 0x51080512
call fcn.5100380c
mov edx, dword [ebp - 0x2c]
mov edx, dword [edx + 0x18]
mov ecx, dword [ebp - 0x28]
mov ebx, dword [edx + eax*8 + 8]
mov dword [ecx + 0x18], ebx
mov ebx, dword [edx + eax*8 + 0xc]
mov dword [ecx + 0x1c], ebx
mov eax, dword [ebp - 0x38]
call fcn.5106d994
mov edx, dword [ebp - 0x24]
lea esi, [eax + 0x20]
mov edi, edx
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
mov eax, dword [ebp - 0x30]
mov byte [eax + 0x14], 1
mov eax, dword [ebp - 0x38]
mov eax, dword [eax + 8]
push eax
mov eax, dword [ebp - 0x30]
add eax, 4
mov ecx, 1
mov edx, dword [0x510788f0]
call fcn.51005dac
add esp, 4
mov eax, dword [ebp - 0x38]
mov eax, dword [eax + 8]
sub eax, 1
jno 0x51080574
call fcn.5100380c
test eax, eax
jl 0x51080646
inc eax
mov dword [ebp - 0x44], eax
mov dword [ebp - 0x1c], 0
mov eax, dword [ebp - 0x10]
imul eax, eax, 4
jno 0x51080594
call fcn.5100380c
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14c]
mov eax, dword [edx + eax*8 + 0x18]
mov edx, dword [ebp - 0x14]
test eax, eax
je 0x510805ad
cmp edx, dword [eax - 4]
jb 0x510805b2
call fcn.51003804
mov eax, dword [eax + edx*4]
mov edx, dword [ebp - 0x18]
imul edx, edx, 0xb
jno 0x510805c2
call fcn.5100380c
mov ecx, dword [ebp - 4]
mov ecx, dword [ecx + 0x150]
cmp eax, dword [ecx + edx*8 + 8]
jne 0x510805fb
mov edx, dword [ebp - 0x1c]
mov eax, dword [ebp - 0x38]
call fcn.5106d9b0
mov edx, dword [ebp - 0x1c]
imul edx, edx, 2
jno 0x510805e9
call fcn.5100380c
mov ecx, dword [ebp - 0x30]
mov ecx, dword [ecx + 4]
lea esi, [eax + 0x20]
lea edi, [ecx + edx*8]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
jmp 0x5108063a
mov eax, dword [ebp - 0x38]
mov edx, dword [eax + 8]
sub edx, 1
jno 0x5108060b
call fcn.5100380c
sub edx, dword [ebp - 0x1c]
jno 0x51080615
call fcn.5100380c
mov eax, dword [ebp - 0x38]
call fcn.5106d9b0
mov edx, dword [ebp - 0x1c]
imul edx, edx, 2
jno 0x5108062a
call fcn.5100380c
mov ecx, dword [ebp - 0x30]
mov ecx, dword [ecx + 4]
lea esi, [eax + 0x20]
lea edi, [ecx + edx*8]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
inc dword [ebp - 0x1c]
dec dword [ebp - 0x44]
jne 0x51080587
cmp byte [ebp - 0x39], 0
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x5108065e
inc dword [ebp - 0x14]
cmp dword [ebp - 0x14], 4
jne 0x510802d8
inc dword [ebp - 0x10]
dec dword [ebp - 0x40]
jne 0x510801b9
push 0
mov eax, dword [ebp - 0xc]
call fcn.51004b8c
push eax
mov eax, dword [ebp - 8]
call fcn.51004b8c
push eax
call sub.kernel32.dll_CopyFileA
mov edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
call fcn.5107fbb8
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x510806bd
lea eax, [ebp - 0xc]
mov edx, 2
call fcn.51004700
ret