Function at 0x4122cb
Capabilities:
Accept command line arguments
Get file size
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffffc
pushal
pushfd
push esi
bt esi, 0xc
pop esi
pushal
call sub.KERNEL32.DLL_GetCurrentThread
popal
popfd
pushfd
std
pushal
call sub.KERNEL32.DLL_GetCommandLineA
popal
popfd
push 0
push 0x80
push 3
push 0
push 1
push 0x80000000
push dword [ebp + 8]
call sub.KERNEL32.DLL_CreateFileA
inc eax
je 0x412603
dec eax
mov ebx, eax
push 0
push ebx
call sub.KERNEL32.DLL_GetFileSize
mov dword [ebp - 4], eax
push 0
push 0
push 0
push 2
push 0
push ebx
call sub.KERNEL32.DLL_CreateFileMappingA
pushfd
push esi
rcr esi, 9
pop esi
pushal
call sub.KERNEL32.DLL_GetLastError
popal
popfd
push esi
call fcn.00412794
pop esi
jmp 0x412357
mov esi, eax
pushfd
push ebx
bt ebx, 0x18
pop ebx
pushal
call sub.KERNEL32.DLL_GetLastError
popal
popfd
push eax
push ecx
pushfd
cmovne eax, ecx
popfd
pop ecx
pop eax
pushal
pushfd
call sub.KERNEL32.DLL_GetLastError
popfd
popal
push 0
push 0
push 0
push 4
push esi
call sub.KERNEL32.DLL_MapViewOfFile
pushfd
push ecx
rcr ecx, 0xc
pop ecx
pushal
call sub.KERNEL32.DLL_GetCurrentProcessId
popal
popfd
pminsw mm0, mm1
pushal
pushfd
call sub.KERNEL32.DLL_GetTickCount
popfd
popal
mov edi, eax
pushfd
push ebx
btc ebx, 0x11
pop ebx
pushal
call sub.KERNEL32.DLL_GetCurrentThreadId
popal
popfd
pushfd
push eax
setg al
pop eax
pushal
call sub.KERNEL32.DLL_GetTickCount
popal
popfd
pushal
pushfd
push ecx
rol ecx, 8
pop ecx
pushal
call sub.KERNEL32.DLL_GetTickCount
popal
popfd
push esi
push edx
pushfd
cmovp esi, edx
popfd
pop edx
pop esi
pushal
pushfd
call sub.KERNEL32.DLL_GetLastError
popfd
popal
mov esi, edi
pushfd
push ebx
rcl ebx, 0x12
pop ebx
pushal
call sub.KERNEL32.DLL_GetCommandLineA
popal
popfd
punpckhbw mm0, mm1
pushal
pushfd
call sub.KERNEL32.DLL_GetCurrentProcessId
popfd
popal
mov ebx, dword [esi + 0x64]
pushfd
push ebx
shl ebx, 2
pop ebx
pushal
call sub.KERNEL32.DLL_GetCurrentThreadId
popal
popfd
wait
fnclex
pushal
pushfd
call sub.KERNEL32.DLL_GetCurrentProcessId
popfd
popal
or ebx, ebx
pushfd
push edx
btc edx, 0x1d
pop edx
pushal
call sub.KERNEL32.DLL_GetCurrentProcessId
popal
popfd
push esi
call fcn.00412794
pop esi
jmp 0x41244b
je 0x4125d3
pushfd
push edx
btc edx, 0x16
pop edx
pushal
call sub.KERNEL32.DLL_GetCurrentProcessId
popal
popfd
pushfd
push ecx
setnp cl
pop ecx
pushal
call sub.KERNEL32.DLL_GetCurrentProcess
popal
popfd
mov eax, dword [esi + 0x60]
cmp eax, dword [ebp - 4]
jg 0x4125d3
add esi, dword [esi + 0x60]
pushfd
push edx
ror edx, 4
pop edx
pushal
call sub.KERNEL32.DLL_GetCurrentThreadId
popal
popfd
paddsw mm0, mm1
pushal
pushfd
call sub.KERNEL32.DLL_GetCurrentProcess
popfd
popal
mov edi, dword [ebp + 0x10]
pushfd
push edx
rol edx, 0xa
pop edx
pushal
call sub.KERNEL32.DLL_GetCurrentProcess
popal
popfd
push eax
push eax
pushfd
cmp eax, eax
popfd
pop eax
pop eax
pushal
pushfd
call sub.KERNEL32.DLL_GetLastError
popfd
popal
mov edx, dword [ebp + 0x14]
jmp 0x4125ca
mov ecx, esi
lodsw ax, word [esi]
stosb byte es:[edi], al
pushfd
push eax
btr eax, 2
pop eax
pushal
call sub.KERNEL32.DLL_GetCurrentProcess
popal
popfd
push ecx
push ebx
pushfd
cmovp ecx, ebx
popfd
pop ebx
pop ecx
pushal
pushfd
call sub.KERNEL32.DLL_GetCurrentProcessId
popfd
popal
dec edx
pushfd
push ecx
rcr ecx, 9
pop ecx
pushal
call sub.KERNEL32.DLL_GetCurrentThread
popal
popfd
push edx
push esi
pushfd
cmovnp edx, esi
popfd
pop esi
pop edx
pushal
pushfd
call sub.KERNEL32.DLL_GetTickCount
popfd
popal
je 0x412642
pushfd
push ecx
bts ecx, 0x15
pop ecx
pushal
call sub.KERNEL32.DLL_GetCurrentThreadId
popal
popfd
push esi
call fcn.00412794
pop esi
jmp 0x41253d
or ax, ax
jne 0x4124c3
sub esi, ecx
pushfd
push ebx
shl ebx, 0x16
pop ebx
pushal
call sub.KERNEL32.DLL_GetCommandLineA
popal
popfd
psraw mm0, mm1
pushal
pushfd
call sub.KERNEL32.DLL_GetCurrentProcess
popfd
popal
shr esi, 1
pushfd
push esi
shl esi, 4
pop esi
pushal
call sub.KERNEL32.DLL_GetCommandLineA
popal
popfd
mov eax, dword [ebp + 0xc]
pushfd
push eax
rol eax, 0x1e
pop eax
pushal
call sub.KERNEL32.DLL_GetCurrentProcessId
popal
popfd
pushfd
push ecx
seta cl
pop ecx
pushal
call sub.KERNEL32.DLL_GetLastError
popal
popfd
add dword [eax], esi
pushfd
push eax
bt eax, 0x11
pop eax
pushal
call sub.KERNEL32.DLL_GetCurrentProcessId
popal
popfd
psrld mm0, mm1
pushal
pushfd
call sub.KERNEL32.DLL_GetCurrentThreadId
popfd
popal
add ecx, 0x44
mov esi, ecx
pushfd
push esi
shl esi, 9
pop esi
pushal
call sub.KERNEL32.DLL_GetLastError
popal
popfd
pcmpeqb mm0, mm1
pushal
pushfd
call sub.KERNEL32.DLL_GetCurrentThread
popfd
popal
dec ebx
cmp ebx, 0
ja 0x4124c1
popal
push edi
call sub.KERNEL32.DLL_UnmapViewOfFile
pushfd
push edx
bt edx, 4
pop edx
pushal
call sub.KERNEL32.DLL_GetCommandLineA
popal
popfd
pushfd
push eax
setp al
pop eax
pushal
call sub.KERNEL32.DLL_GetTickCount
popal
popfd
push esi
call sub.KERNEL32.DLL_CloseHandle
push ebx
call sub.KERNEL32.DLL_CloseHandle
pushfd
push ebx
ror ebx, 0x1f
pop ebx
pushal
call sub.KERNEL32.DLL_GetCurrentThread
popal
popfd
fsincos
pushal
pushfd
call sub.KERNEL32.DLL_GetCurrentProcess
popfd
popal
popal
pushfd
push edx
btc edx, 1
pop edx
pushal
call sub.KERNEL32.DLL_GetCurrentProcess
popal
popfd
push eax
push ecx
pushfd
cmovb eax, ecx
popfd
pop ecx
pop eax
pushal
pushfd
call sub.KERNEL32.DLL_GetCommandLineA
popfd
popal
leave
ret 0x10
mov byte [edi], 0
pushfd
push ecx
rol ecx, 0xd
pop ecx
pushal
call sub.KERNEL32.DLL_GetCurrentThread
popal
popfd
push eax
push edx
pushfd
cmovnp eax, edx
popfd
pop edx
pop eax
pushal
pushfd
call sub.KERNEL32.DLL_GetTickCount
popfd
popal
dec edi
pushfd
push ebx
shl ebx, 0x14
pop ebx
pushal
call sub.KERNEL32.DLL_GetTickCount
popal
popfd
paddsb mm0, mm1
pushal
pushfd
call sub.KERNEL32.DLL_GetCurrentProcess
popfd
popal
cmp byte [edi], 0
jne 0x412642
pushal
pushfd
push edx
sar edx, 0x16
pop edx
pushal
call sub.KERNEL32.DLL_GetCurrentThread
popal
popfd
paddb mm0, mm1
pushal
pushfd
call sub.KERNEL32.DLL_GetTickCount
popfd
popal
sub edi, dword [0x421160]
sub edi, 4
mov eax, dword [0x421160]
mov dword [eax], edi
push 0
push dword [ebp + 0xc]
call fcn.004127e5
pushfd
push eax
shl eax, 0x1d
pop eax
pushal
call sub.KERNEL32.DLL_GetCurrentProcessId
popal
popfd
pushfd
push ecx
setnp cl
pop ecx
pushal
call sub.KERNEL32.DLL_GetCurrentThread
popal
popfd
popal
pushfd
push ecx
sar ecx, 0x13
pop ecx
pushal
call sub.KERNEL32.DLL_GetCurrentProcessId
popal
popfd
psrad mm0, mm1
pushal
pushfd
call sub.KERNEL32.DLL_GetCurrentProcess
popfd
popal
mov esi, ecx
pushfd
push ecx
btc ecx, 0x11
pop ecx
pushal
call sub.KERNEL32.DLL_GetTickCount
popal
popfd
psubusb mm0, mm1
pushal
pushfd
call sub.KERNEL32.DLL_GetLastError
popfd
popal
push dword [ebp + 0xc]
pop dword [ebp + 0x10]
pushfd
push esi
bt esi, 0xe
pop esi
pushal
call sub.KERNEL32.DLL_GetCurrentThread
popal
popfd
pushfd
push ecx
setp cl
pop ecx
pushal
call sub.KERNEL32.DLL_GetLastError
popal
popfd
add dword [ebp + 0x10], 4
pushfd
push eax
bt eax, 0xc
pop eax
pushal
call sub.KERNEL32.DLL_GetCurrentThread
popal
popfd
mov eax, dword [ebp + 0xc]
mov dword [eax], 0
pushfd
push ebx
ror ebx, 0xf
pop ebx
pushal
call sub.KERNEL32.DLL_GetTickCount
popal
popfd
push eax
push eax
pushfd
cmovnp eax, eax
popfd
pop eax
pop eax
pushal
pushfd
call sub.KERNEL32.DLL_GetCurrentThreadId
popfd
popal
mov dword [ebp + 0x14], 0xf9ffc
pushfd
push eax
btr eax, 0xf
pop eax
pushal
call sub.KERNEL32.DLL_GetCurrentProcess
popal
popfd
pavgb mm0, mm1
pushal
pushfd
call sub.KERNEL32.DLL_GetCurrentThreadId
popfd
popal
jmp 0x41247d