Function at 0x413a20
Capabilities:
Copy file
Link many functions at runtime
Timestomp file

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x420
mov eax, dword [0x47c554]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
lea eax, [ebp - 0x214]
push esi
mov esi, dword [ebp + 0xc]
push edi
push ebx
push 0x4b07dc
push str._sBlocDllBLOC_04u.DLL
push 0x105
push eax
mov dword [ebp - 0x380], ebx
mov dword [ebp - 0x388], esi
mov byte [ebp - 0x375], 0
call fcn.004038d0
push esi
push ebx
push 0x4b07dc
push str._sWorkBLOC_04u.DL_u
lea eax, [ebp - 0x10c]
push 0x105
push eax
call fcn.004038d0
add esp, 0x2c
lea eax, [ebp - 0x10c]
push 0
push eax
lea eax, [ebp - 0x214]
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileA]
mov ebx, dword [sym.imp.KERNEL32.dll_OpenFile]
lea eax, [ebp - 0x374]
push 0
push eax
lea eax, [ebp - 0x214]
push eax
call ebx
mov edi, dword [sym.imp.imagehlp.dll_MapAndLoad]
mov esi, eax
cmp esi, 0xffffffff
je 0x413b93
push 0
push 0
lea eax, [ebp - 0x394]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetFileTime]
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
push esi
call edi
push 2
lea eax, [ebp - 0x374]
push eax
lea eax, [ebp - 0x10c]
push eax
call ebx
mov esi, eax
cmp esi, 0xffffffff
je 0x413b13
push 0
push 0
lea eax, [ebp - 0x394]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_SetFileTime]
push esi
call edi
lea eax, [ebp - 0x2ec]
push eax
lea eax, [ebp - 0x394]
push eax
call dword [sym.imp.KERNEL32.dll_FileTimeToSystemTime]
mov ebx, dword [ebp - 0x380]
imul esi, ebx, 0x8c
lea eax, [esi + 0x4b852e]
push eax
lea eax, [ebp - 0x2ec]
push eax
push 0
call dword [sym.imp.KERNEL32.dll_SystemTimeToTzSpecificLocalTime]
mov edi, dword [sym.imp.imagehlp.dll_MapAndLoad]
lea eax, [ebp - 0x420]
push 1
push 1
push eax
push 0
lea eax, [ebp - 0x10c]
push eax
call edi
test eax, eax
je 0x413b87
mov eax, dword [ebp - 0x414]
mov eax, dword [eax + 8]
mov dword [esi + 0x4b8540], eax
lea eax, [ebp - 0x420]
push eax
call dword [sym.imp.imagehlp.dll_UnMapAndLoad]
jmp 0x413b99
mov dword [esi + 0x4b8540], 0
jmp 0x413b99
mov ebx, dword [ebp - 0x380]
lea eax, [ebp - 0x10c]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
imul esi, ebx, 0x16
add esi, dword [ebp - 0x388]
shl esi, 2
mov dword [ebp - 0x384], esi
mov dword [esi + 0x4c1908], eax
test eax, eax
je 0x413f70
push str.Grafcet
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.GetCurLng
push dword [esi + 0x4c1908]
mov dword [esi + 0x4c1910], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.DLLVersion
push dword [esi + 0x4c1908]
mov dword [esi + 0x4c1918], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.LinkData
push dword [esi + 0x4c1908]
mov dword [esi + 0x4c1920], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov ecx, dword [ebp - 0x384]
mov esi, eax
imul ebx, ebx, 0x8c
mov eax, dword [ecx + 0x4c1920]
mov byte [ebx + 0x4b84bb], 1
test eax, eax
je 0x413c56
lea ecx, [ebp - 0x3b8]
push ecx
lea ecx, [ebp - 0x3bc]
push ecx
lea ecx, [ebp - 0x3c0]
push ecx
call eax
mov ecx, dword [ebp - 0x384]
add esp, 0xc
cmp byte [ebx + 0x4b84bb], 1
jne 0x413fcd
cmp dword [ecx + 0x4c1910], 0
je 0x413fcd
test esi, esi
je 0x413fcd
lea eax, [ebp - 0x3b4]
mov dword [ebp - 0x3b4], 0x4c18b8
push eax
mov dword [ebp - 0x3b0], 0x42c720
mov dword [ebp - 0x3ac], 0x42ea90
mov dword [ebp - 0x3a8], 0x42f060
mov dword [ebp - 0x3a4], 0x42ede0
mov dword [ebp - 0x3a0], 0x42f210
mov dword [ebp - 0x39c], 0x42e8f0
mov dword [ebp - 0x398], 0x40e860
call esi
add esp, 4
mov byte [ebp - 0x375], 1
lea eax, [ebp - 0x3f0]
xor ebx, ebx
mov dword [ebp - 0x37c], ebx
push 1
push 1
push eax
push ebx
lea eax, [ebp - 0x10c]
push eax
call edi
test eax, eax
je 0x413de0
mov eax, dword [ebp - 0x3e4]
mov ecx, dword [eax + 0x78]
test ecx, ecx
je 0x413dd3
push ebx
mov ebx, dword [sym.imp.imagehlp.dll_ImageRvaToVa]
push ecx
push dword [ebp - 0x3e8]
push eax
call ebx
xor esi, esi
mov dword [ebp - 0x38c], eax
mov ecx, dword [eax + 0x18]
mov dword [ebp - 0x37c], ecx
test ecx, ecx
jle 0x413dcd
nop dword [eax + eax]
cmp esi, 0x32
jge 0x413dcd
push 0
push 0
push dword [eax + 0x20]
push dword [ebp - 0x3e8]
push dword [ebp - 0x3e4]
call ebx
mov eax, dword [eax + esi*4]
push eax
push dword [ebp - 0x3e8]
push dword [ebp - 0x3e4]
call ebx
mov ebx, eax
mov ecx, ebx
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x413d77
sub ecx, edx
lea eax, [ecx + 1]
push eax
push 8
push dword [0x47ceb8]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ecx, ebx
mov edx, eax
mov dword [ebp + esi*4 - 0x2dc], edx
lea edi, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x413da0
sub ecx, edi
push ebx
lea eax, [ecx + 1]
push eax
push edx
call fcn.0043f2f3
mov eax, dword [ebp - 0x38c]
inc esi
mov ebx, dword [sym.imp.imagehlp.dll_ImageRvaToVa]
add esp, 0xc
cmp esi, dword [eax + 0x18]
jl 0x413d40
mov ebx, dword [ebp - 0x37c]
lea eax, [ebp - 0x3f0]
push eax
call dword [sym.imp.imagehlp.dll_UnMapAndLoad]
imul edi, dword [ebp - 0x380], 0xb
add edi, dword [ebp - 0x388]
mov dword [edi*8 + 0x4c1930], 0
cmp ebx, 4
jle 0x413f87
mov eax, ebx
shl eax, 4
sub eax, 0x40
push eax
push 8
push dword [0x47ceb8]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov dword [edi*8 + 0x4c1934], eax
xor ebx, ebx
mov esi, dword [ebp + ebx*4 - 0x2dc]
mov ecx, str.Grafcet
mov eax, esi
nop
mov dl, byte [eax]
cmp dl, byte [ecx]
jne 0x413e50
test dl, dl
je 0x413e4c
mov dl, byte [eax + 1]
cmp dl, byte [ecx + 1]
jne 0x413e50
add eax, 2
add ecx, 2
test dl, dl
jne 0x413e30
xor eax, eax
jmp 0x413e55
sbb eax, eax
or eax, 1
test eax, eax
je 0x413f54
mov ecx, str.LinkData
mov eax, esi
mov dl, byte [eax]
cmp dl, byte [ecx]
jne 0x413e84
test dl, dl
je 0x413e80
mov dl, byte [eax + 1]
cmp dl, byte [ecx + 1]
jne 0x413e84
add eax, 2
add ecx, 2
test dl, dl
jne 0x413e64
xor eax, eax
jmp 0x413e89
sbb eax, eax
or eax, 1
test eax, eax
je 0x413f54
mov ecx, str.GetCurLng
mov eax, esi
mov dl, byte [eax]
cmp dl, byte [ecx]
jne 0x413eb8
test dl, dl
je 0x413eb4
mov dl, byte [eax + 1]
cmp dl, byte [ecx + 1]
jne 0x413eb8
add eax, 2
add ecx, 2
test dl, dl
jne 0x413e98
xor eax, eax
jmp 0x413ebd
sbb eax, eax
or eax, 1
test eax, eax
je 0x413f54
mov eax, str.DLLVersion
mov ecx, esi
nop dword [eax]
mov dl, byte [ecx]
cmp dl, byte [eax]
jne 0x413ef0
test dl, dl
je 0x413eec
mov dl, byte [ecx + 1]
cmp dl, byte [eax + 1]
jne 0x413ef0
add ecx, 2
add eax, 2
test dl, dl
jne 0x413ed0
xor eax, eax
jmp 0x413ef5
sbb eax, eax
or eax, 1
test eax, eax
je 0x413f54
mov eax, dword [ebp - 0x384]
push esi
push dword [eax + 0x4c1908]
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov ecx, dword [edi*8 + 0x4c1930]
mov edx, eax
mov eax, dword [edi*8 + 0x4c1934]
add ecx, ecx
mov dword [eax + ecx*8 + 8], edx
mov ecx, dword [edi*8 + 0x4c1930]
mov eax, dword [edi*8 + 0x4c1934]
shl ecx, 4
add eax, ecx
cmp dword [eax + 8], 0
jne 0x413f43
mov dword [eax], 0
jmp 0x413f4d
push eax
push esi
call fcn.004124f0
add esp, 8
inc dword [edi*8 + 0x4c1930]
push esi
push 0
push dword [0x47ceb8]
call dword [sym.imp.KERNEL32.dll_HeapFree]
inc ebx
cmp ebx, dword [ebp - 0x37c]
jl 0x413e21
mov al, byte [ebp - 0x375]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0043b572
mov esp, ebp
pop ebp
ret
xor esi, esi
mov dword [edi*8 + 0x4c1934], 0
test ebx, ebx
jle 0x413f70
mov edi, dword [sym.imp.KERNEL32.dll_HeapFree]
nop
push dword [ebp + esi*4 - 0x2dc]
push 0
push dword [0x47ceb8]
call edi
inc esi
cmp esi, ebx
jl 0x413fa0
mov al, byte [ebp - 0x375]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0043b572
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 4]
xor al, al
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0043b572
mov esp, ebp
pop ebp
ret