Function at 0x40c370
Capabilities:
Copy file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5496b9
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x624
push ebx
push esi
push edi
mov edi, dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
mov dword [ebp - 0x10], esp
lea eax, [ebp - 0x120]
push 0x104
push eax
mov esi, ecx
push 0
mov dword [ebp - 4], 0
call edi
test eax, eax
jne 0x40c3ec
lea ecx, [ebp - 0x228]
call fcn.00459300
push 1
push str.Error_bi200001_r_n
lea ecx, [ebp - 0x228]
mov byte [ebp - 4], 1
call fcn.004593e0
lea ecx, [ebp - 0x228]
mov byte [ebp - 4], 0
call fcn.004593d0
jmp 0x40c518
lea ecx, [ebp - 0x530]
lea edx, [ebp - 0x630]
push ecx
lea eax, [ebp - 0x328]
push edx
lea ecx, [ebp - 0x1c]
push eax
lea edx, [ebp - 0x120]
push ecx
push edx
call fcn.0051d13a
add esp, 0x14
lea eax, [ebp - 0x328]
lea ecx, [ebp - 0x1c]
lea edx, [ebp - 0x120]
push str.NPIDMan1.dll
push eax
push ecx
push 0x59879c
push edx
call fcn.0051d0e8
mov eax, dword [0x5b5ecc]
add esp, 0x14
mov dword [ebp - 0x14], eax
mov eax, dword [ebp + 0xc]
mov byte [ebp - 4], 2
test eax, eax
je 0x40c484
mov eax, dword [ebp + 8]
test eax, eax
jl 0x40c50c
cmp eax, dword [esi + 0x58]
jge 0x40c50c
mov ecx, dword [esi + 0x54]
lea edx, [ecx + eax*4]
lea ecx, [ebp - 0x14]
push edx
call fcn.00537c3d
mov eax, dword [ebp - 0x14]
xor ecx, ecx
mov ebx, 3
mov eax, dword [eax - 8]
test eax, eax
setg cl
mov eax, ecx
jmp case.default.0x40c495
mov edx, dword [ebp + 8]
mov ebx, 3
xor eax, eax
lea ecx, [edx - 1]
cmp ecx, ebx
ja case.default.0x40c495
jmp dword [ecx*4 + 0x40c668]
lea eax, [ebp - 0x14]
mov ecx, esi
push eax
call fcn.0040b8a0
jmp case.default.0x40c495
lea ecx, [ebp - 0x14]
push ecx
mov ecx, esi
call fcn.0040b620
jmp case.default.0x40c495
lea edx, [ebp - 0x14]
mov ecx, esi
push edx
call fcn.0040c860
jmp case.default.0x40c495
lea eax, [ebp - 0x14]
mov ecx, esi
push eax
call fcn.0040c680
test eax, eax
je 0x40c50c
lea ecx, [ebp - 0x14]
push str.NPIDMan1.dll
lea edx, [ebp - 0x18]
push ecx
push edx
call fcn.00537d99
mov eax, dword [ebp - 0x18]
mov esi, dword [sym.imp.KERNEL32.dll_CopyFileA]
push 0
lea ecx, [ebp - 0x120]
push eax
push ecx
mov byte [ebp - 4], bl
call esi
test eax, eax
jne 0x40c52d
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x18]
call fcn.00537b04
lea ecx, [ebp - 0x14]
mov byte [ebp - 4], 0
call fcn.00537b04
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
lea edx, [ebp - 0x120]
push 0x104
push edx
push 0
call edi
test eax, eax
jne 0x40c572
lea ecx, [ebp - 0x228]
call fcn.00459300
push 1
push str.Error_bi200001_r_n
lea ecx, [ebp - 0x228]
mov byte [ebp - 4], 4
call fcn.004593e0
lea ecx, [ebp - 0x228]
mov byte [ebp - 4], bl
call fcn.004593d0
jmp 0x40c500
lea eax, [ebp - 0x630]
lea ecx, [ebp - 0x530]
push eax
lea edx, [ebp - 0x328]
push ecx
lea eax, [ebp + 8]
push edx
lea ecx, [ebp - 0x120]
push eax
push ecx
call fcn.0051d13a
add esp, 0x14
lea edx, [ebp - 0x328]
lea eax, [ebp + 8]
lea ecx, [ebp - 0x120]
push str.NPIDMan2.dll
push edx
push eax
push 0x59879c
push ecx
call fcn.0051d0e8
add esp, 0x14
lea edx, [ebp - 0x14]
lea eax, [ebp + 8]
push str.NPIDMan2.dll
push edx
push eax
call fcn.00537d99
push eax
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 5
call fcn.00537c3d
lea ecx, [ebp + 8]
mov byte [ebp - 4], bl
call fcn.00537b04
mov ecx, dword [ebp - 0x18]
push 0
lea edx, [ebp - 0x120]
push ecx
push edx
call esi
test eax, eax
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x18]
je 0x40c507
call fcn.00537b04
lea ecx, [ebp - 0x14]
mov byte [ebp - 4], 0
call fcn.00537b04
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov eax, 1
mov dword fs:[0], ecx
pop ebx
mov esp, ebp
pop ebp
ret 8