Function at 0x40ed90
Capabilities:
Copy file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4dd8e2
mov eax, dword fs:[0]
push eax
sub esp, 0x64
mov eax, dword [0x53d9f8]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
lea eax, [ebp - 0x70]
push 0xd
push eax
call fcn.00416f00
lea eax, [ebp - 0x58]
mov dword [ebp - 4], 0
push eax
call fcn.00416e60
add esp, 0xc
mov eax, dword fs:[0x2c]
mov ecx, dword [0x5421c0]
mov byte [ebp - 4], 1
mov ecx, dword [eax + ecx*4]
mov eax, dword [0x540ff0]
cmp eax, dword [ecx + 4]
jg 0x40efb3
mov ebx, dword [sym.imp.KERNEL32.dll_CopyFileW]
mov esi, 0x53d12c
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, edi
push esi
lea eax, [ebp - 0x58]
push eax
lea eax, [ebp - 0x40]
push eax
call fcn.0040e780
push esi
lea eax, [ebp - 0x70]
mov byte [ebp - 4], 3
push eax
lea eax, [ebp - 0x28]
push eax
call fcn.0040e780
add esp, 0x18
lea ecx, [ebp - 0x28]
cmp dword [ebp - 0x14], 8
lea eax, [ebp - 0x40]
cmovae ecx, dword [ebp - 0x28]
cmp dword [ebp - 0x2c], 8
push 1
cmovae eax, dword [ebp - 0x40]
push ecx
push eax
call ebx
test eax, eax
jne 0x40ee76
call edi
cmp eax, 2
jne 0x40ee76
cmp dword [ebp - 0x2c], 8
lea ecx, [ebp - 0x40]
push 1
cmovae ecx, dword [ebp - 0x40]
lea eax, [ebp - 0x28]
cmp dword [ebp - 0x14], 8
push ecx
cmovae eax, dword [ebp - 0x28]
push eax
call ebx
mov edx, dword [ebp - 0x14]
cmp edx, 8
jb 0x40eeb0
mov ecx, dword [ebp - 0x28]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x40eea6
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40ef87
push edx
push ecx
call fcn.004bee2d
add esp, 8
mov edx, dword [ebp - 0x2c]
xor eax, eax
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x14], 7
mov word [ebp - 0x28], ax
mov byte [ebp - 4], 1
cmp edx, 8
jb 0x40ef02
mov ecx, dword [ebp - 0x40]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x40eef8
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40ef87
push edx
push ecx
call fcn.004bee2d
add esp, 8
add esi, 0x18
cmp esi, 0x53d15c
jl 0x40ee10
mov edx, dword [ebp - 0x44]
cmp edx, 8
jb 0x40ef47
mov ecx, dword [ebp - 0x58]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x40ef3d
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40ef87
push edx
push ecx
call fcn.004bee2d
add esp, 8
mov edx, dword [ebp - 0x5c]
xor eax, eax
mov dword [ebp - 0x48], 0
mov dword [ebp - 0x44], 7
mov word [ebp - 0x58], ax
cmp edx, 8
jb 0x40ef97
mov ecx, dword [ebp - 0x70]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x40ef8d
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x40ef8d
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push edx
push ecx
call fcn.004bee2d
add esp, 8
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004bee49
mov esp, ebp
pop ebp
ret
push 0x540ff0
call fcn.004bf206
add esp, 4
cmp dword [0x540ff0], 0xffffffff
jne 0x40edfd
push 0xb
push str.update.ini
mov ecx, 0x53d12c
call fcn.004033b0
push 0xf
xor eax, eax
mov byte [ebp - 4], 2
push str.updateself.exe
mov ecx, 0x53d144
mov dword [0x53d154], 0
mov dword [0x53d158], 7
mov word [0x53d144], ax
call fcn.004033b0
push 0x4ebe80
mov byte [ebp - 4], 1
call fcn.004bf0be
push 0x540ff0
call fcn.004bf1bc
add esp, 8
jmp 0x40edfd