Function at 0x4f72e8
Capabilities:
Access the windows event log
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push eax
mov eax, 0xe
add esp, 0xfffff004
push eax
dec eax
jne 0x4f72f1
mov eax, dword [ebp - 4]
add esp, 0xfffff28c
push ebx
xor ebx, ebx
mov dword [ebp - 0xed78], ebx
mov dword [ebp - 0xed74], ebx
mov dword [ebp - 0xec70], ebx
mov dword [ebp - 0x24], ebx
mov dword [ebp - 0x28], ebx
mov dword [ebp - 0x2c], ebx
mov dword [ebp - 0xc], ecx
mov dword [ebp - 8], edx
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
call fcn.00405738
xor eax, eax
push ebp
push 0x4f76b7
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, dword [ebp - 0xc]
call fcn.00405278
mov eax, dword [ebp - 4]
call fcn.00405748
push eax
push 0
call sub.advapi32.dll_OpenEventLogA
mov dword [ebp - 0x40], eax
cmp dword [ebp - 0x40], 0
je 0x4f7679
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 0x10]
push eax
push 0xc388
lea eax, [ebp - 0xc3cc]
push eax
mov eax, dword [ebp - 8]
push eax
push 6
mov eax, dword [ebp - 0x40]
push eax
call sub.advapi32.dll_ReadEventLogA
test eax, eax
je 0x4f7679
push 0x4f76cc
push dword [ebp - 4]
push 0x4f7704
lea edx, [ebp - 0xec70]
lea eax, [ebp - 0xc394]
call fcn.0040b624
push dword [ebp - 0xec70]
lea eax, [ebp - 0x24]
mov edx, 4
call fcn.00405608
lea eax, [ebp - 0x28]
push eax
mov cl, 2
mov edx, 0x4f7710
mov eax, dword [ebp - 0x24]
call fcn.0049ee2c
lea eax, [ebp - 0x2c]
push eax
mov cl, 2
mov edx, 0x4f772c
mov eax, dword [ebp - 0x24]
call fcn.0049ee2c
push 0x2710
lea eax, [ebp - 0xeadc]
push eax
mov eax, dword [ebp - 0x28]
call fcn.00405748
push eax
call sub.kernel32.dll_ExpandEnvironmentStringsA
test eax, eax
je 0x4f7414
lea edx, [ebp - 0x28]
lea eax, [ebp - 0xeadc]
call fcn.0040b624
push 0x2710
lea eax, [ebp - 0xeadc]
push eax
mov eax, dword [ebp - 0x2c]
call fcn.00405748
push eax
call sub.kernel32.dll_ExpandEnvironmentStringsA
test eax, eax
je 0x4f7440
lea edx, [ebp - 0x2c]
lea eax, [ebp - 0xeadc]
call fcn.0040b624
push 1
push 0
mov eax, dword [ebp - 0x28]
call fcn.00405748
push eax
call sub.kernel32.dll_LoadLibraryExA_1
mov dword [ebp - 0x38], eax
cmp dword [ebp - 0x38], 0
je 0x4f7679
push 1
push 0
mov eax, dword [ebp - 0x2c]
call fcn.00405748
push eax
call sub.kernel32.dll_LoadLibraryExA_1
mov dword [ebp - 0x3c], eax
lea eax, [ebp - 0xec6c]
xor ecx, ecx
mov edx, 0x190
call fcn.00403450
xor eax, eax
mov dword [ebp - 0x30], eax
movzx eax, word [ebp - 0xc3b2]
test eax, eax
jle 0x4f7564
mov dword [ebp - 0x44], eax
mov dword [ebp - 0x18], 1
cmp dword [ebp - 0x30], 0
jne 0x4f74bb
lea eax, [ebp - 0xc3cc]
add eax, dword [ebp - 0xc3a8]
mov dword [ebp - 0x30], eax
jmp 0x4f74ca
mov eax, dword [ebp - 0x30]
call fcn.0040b40c
add eax, dword [ebp - 0x30]
inc eax
mov dword [ebp - 0x30], eax
lea edx, [ebp - 0x24]
mov eax, dword [ebp - 0x30]
call fcn.0040b624
mov edx, dword [ebp - 0x24]
mov eax, 0x4f774c
call fcn.0040588c
dec eax
jne 0x4f754b
cmp dword [ebp - 0x3c], 0
je 0x4f754b
lea eax, [ebp - 0x24]
mov ecx, 2
mov edx, 1
call fcn.004057e8
lea edx, [ebp - 0x20]
mov eax, dword [ebp - 0x24]
call fcn.004038a0
mov dword [ebp - 0x1c], eax
mov eax, 0x400
call fcn.0040b638
mov dword [ebp - 0x34], eax
push 0
push 0x400
mov eax, dword [ebp - 0x34]
push eax
push 0
mov eax, dword [ebp - 0x1c]
push eax
mov eax, dword [ebp - 0x3c]
push eax
push 0x1800
call sub.kernel32.dll_FormatMessageA
test eax, eax
jne 0x4f7545
mov eax, dword [ebp - 0x34]
call fcn.0040b684
jmp 0x4f754b
mov eax, dword [ebp - 0x34]
mov dword [ebp - 0x30], eax
mov eax, dword [ebp - 0x18]
mov edx, dword [ebp - 0x30]
mov dword [ebp + eax*4 - 0xec70], edx
inc dword [ebp - 0x18]
dec dword [ebp - 0x44]
jne 0x4f74a4
lea eax, [ebp - 0xeadc]
xor ecx, ecx
mov edx, 0x2710
call fcn.00403450
lea eax, [ebp - 0xec6c]
push eax
push 0x400
lea eax, [ebp - 0xeadc]
push eax
push 0
mov eax, dword [ebp - 0xc3b8]
push eax
mov eax, dword [ebp - 0x38]
push eax
push 0x3800
call sub.kernel32.dll_FormatMessageA
mov eax, dword [ebp - 0xc3b8]
and eax, 0xffff
xor edx, edx
push edx
push eax
lea eax, [ebp - 0xed70]
call fcn.00406608
lea edx, [ebp - 0xed70]
lea eax, [ebp - 0x28]
call fcn.004054ec
mov eax, dword [ebp - 0x38]
push eax
call sub.kernel32.dll_FreeLibrary_1
cmp dword [ebp - 0x3c], 0
je 0x4f75e0
mov eax, dword [ebp - 0x3c]
push eax
call sub.kernel32.dll_FreeLibrary_1
lea edx, [ebp - 0xed74]
lea eax, [ebp - 0xeadc]
call fcn.0040b624
mov eax, dword [ebp - 0xed74]
lea edx, [ebp - 0x24]
call fcn.0040a348
lea eax, [ebp - 0x2c]
call fcn.00405278
mov eax, dword [ebp - 0x24]
call fcn.00405548
test eax, eax
jle 0x4f7665
mov dword [ebp - 0x44], eax
mov dword [ebp - 0x1c], 1
mov eax, dword [ebp - 0x24]
mov edx, dword [ebp - 0x1c]
mov al, byte [eax + edx - 1]
sub al, 0x20
jae 0x4f763a
lea eax, [ebp - 0x2c]
mov edx, 0x4f7758
call fcn.00405550
jmp 0x4f765d
lea eax, [ebp - 0xed78]
mov edx, dword [ebp - 0x24]
mov ecx, dword [ebp - 0x1c]
mov dl, byte [edx + ecx - 1]
call fcn.00405460
mov edx, dword [ebp - 0xed78]
lea eax, [ebp - 0x2c]
call fcn.00405550
inc dword [ebp - 0x1c]
dec dword [ebp - 0x44]
jne 0x4f761d
mov edx, dword [ebp - 0xc]
mov eax, dword [ebp - 0x2c]
call fcn.0040a348
mov eax, dword [ebp - 0x40]
push eax
call sub.advapi32.dll_CloseEventLog
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4f76be
lea eax, [ebp - 0xed78]
mov edx, 2
call fcn.0040529c
lea eax, [ebp - 0xec70]
call fcn.00405278
lea eax, [ebp - 0x2c]
mov edx, 3
call fcn.0040529c
lea eax, [ebp - 4]
call fcn.00405278
ret