Function at 0x401000
Capabilities:
Extract resource via kernel32 functions
Inspect load icon resource
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0xb4
push ebx
push esi
push edi
push 0x8001
call dword [sym.imp.KERNEL32.dll_SetErrorMode]
push 0x4813f8
push 0
call fcn.0045aa61
push 0xfffffffffffffffd
call fcn.0045b188
add esp, 0xc
push 0
mov dword [0x49b1fc], 0x401670
call dword [sym.imp.ole32.dll_OleInitialize]
call fcn.0041d740
mov esi, dword [0x49b210]
test esi, esi
jne 0x40109a
call fcn.00420eb0
mov ebx, eax
test ebx, ebx
je 0x401066
mov eax, dword [ebx + 0x10]
mov dword [eax + 0x58], 0x420720
mov esi, dword [ebx + 0x10]
push 0
xor ecx, ecx
xor eax, eax
call fcn.0041cff0
add esp, 4
mov esi, ebx
call fcn.0041d350
mov esi, dword [ebx + 0x10]
push 0
mov ecx, 1
xor eax, eax
call fcn.0041cff0
mov esi, ebx
add esp, 4
mov dword [0x49b210], esi
mov ecx, dword [ebp + 0x10]
mov ebx, esi
test ecx, ecx
jne 0x4010b9
mov ecx, dword [esi + 8]
add esi, 8
mov dword [ecx + 8], 0
add dword [esi], 0x10
mov dword [esp + 0x10], esi
jmp 0x401107
lea edx, [ecx + 1]
lea esp, [esp]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x4010c0
mov eax, dword [esi + 0x10]
sub ecx, edx
mov edx, dword [eax + 0x44]
mov dword [esp + 0x14], ecx
cmp edx, dword [eax + 0x40]
jb 0x4010df
mov eax, esi
call fcn.0042c500
mov eax, dword [esp + 0x14]
mov ecx, dword [ebp + 0x10]
mov edi, dword [ebx + 8]
push eax
push ecx
lea esi, [ebx + 8]
push ebx
mov dword [esp + 0x1c], esi
call fcn.004320c0
add esp, 0xc
mov dword [edi], eax
mov dword [edi + 8], 4
add dword [esi], 0x10
push 8
push str._CMDLINE
lea edi, [ebx + 0x40]
push ebx
mov dword [esp + 0x20], edi
call fcn.004320c0
mov edx, dword [esi]
add esp, 0xc
sub edx, 0x10
push edx
mov dword [esp + 0xa4], eax
lea eax, [esp + 0xa4]
push eax
push edi
push ebx
mov dword [esp + 0xb8], 4
call fcn.0042ce50
add dword [esi], 0xfffffff0
add esp, 0x10
push 0x82
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call dword [sym.imp.USER32.dll_LoadIconA]
mov ecx, dword [esi]
test eax, eax
jne 0x40116a
mov dword [ecx + 8], eax
jmp 0x401173
mov dword [ecx], eax
mov dword [ecx + 8], 2
add dword [esi], 0x10
push 9
push 0x481408
push ebx
call fcn.004320c0
mov edx, dword [esi]
add esp, 0xc
sub edx, 0x10
push edx
mov dword [esp + 0x94], eax
lea eax, [esp + 0x94]
push eax
push edi
push ebx
mov dword [esp + 0xa8], 4
call fcn.0042ce50
mov ecx, dword [0x49a424]
add dword [esi], 0xfffffff0
push 0
push ecx
call fcn.0041c8c0
mov eax, 1
add esp, 0x18
mov dword [esp + 0xc], eax
cmp dword [0x49a424], eax
jle 0x40129f
mov edx, dword [0x49a428]
mov eax, dword [esp + 0xc]
mov eax, dword [edx + eax*4]
mov dword [esp + 0x20], eax
test eax, eax
jne 0x4011f2
mov ecx, dword [esi]
mov dword [ecx + 8], eax
jmp 0x401232
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4011f5
sub eax, edx
mov dword [esp + 0x18], eax
mov eax, dword [ebx + 0x10]
mov edx, dword [eax + 0x44]
cmp edx, dword [eax + 0x40]
jb 0x401214
mov eax, ebx
call fcn.0042c500
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x20]
mov edi, dword [esi]
push eax
push ecx
push ebx
call fcn.004320c0
add esp, 0xc
mov dword [edi], eax
mov dword [edi + 8], 4
add dword [esi], 0x10
mov edx, dword [esp + 0xc]
mov edi, dword [esi]
mov eax, dword [edi - 0x20]
push edx
push ebx
call fcn.0042a7a0
mov ecx, dword [edi - 0x10]
mov dword [eax], ecx
mov edx, dword [edi - 0xc]
mov dword [eax + 4], edx
mov ecx, dword [edi - 8]
mov dword [eax + 8], ecx
mov eax, dword [esi]
add esp, 8
cmp dword [eax - 8], 4
jl 0x401283
mov edx, dword [eax - 0x10]
test byte [edx + 5], 3
je 0x401283
mov edi, dword [edi - 0x20]
test byte [edi + 5], 4
je 0x401283
mov eax, dword [ebx + 0x10]
and byte [edi + 5], 0xfb
mov ecx, dword [eax + 0x28]
mov dword [edi + 0x18], ecx
mov dword [eax + 0x28], edi
mov eax, dword [esp + 0xc]
add dword [esi], 0xfffffff0
inc eax
mov dword [esp + 0xc], eax
cmp eax, dword [0x49a424]
jl 0x4011d6
mov edi, dword [esp + 0x14]
push 5
push str._ARGV
push ebx
call fcn.004320c0
mov edx, dword [esi]
add esp, 0xc
sub edx, 0x10
push edx
mov dword [esp + 0xb4], eax
lea eax, [esp + 0xb4]
push eax
push edi
push ebx
mov dword [esp + 0xc8], 4
call fcn.0042ce50
add dword [esi], 0xfffffff0
mov eax, dword [esi]
sub eax, dword [ebx + 0x20]
mov edx, str.import_preload_
mov dword [esp + 0x5c], edx
mov dword [esp + 0x58], edx
push eax
lea ecx, [esp + 0x60]
lea edx, [esp + 0x4c]
push edx
mov edx, dword [ebx + 0x6c]
mov dword [esp + 0x80], ecx
xor ecx, ecx
lea edi, [esp + 0x74]
push 0x430740
mov eax, ebx
mov dword [esp + 0x6c], 0xf
mov dword [esp + 0x88], ebx
mov dword [esp + 0x80], 0x420600
mov dword [esp + 0x78], ecx
mov dword [esp + 0x7c], ecx
mov dword [esp + 0x54], edi
mov dword [esp + 0x58], ecx
mov dword [esp + 0x60], ecx
call fcn.00430650
mov edi, dword [ebx + 0x10]
mov ecx, dword [edi + 0x10]
mov edx, dword [edi + 0xc]
add esp, 0x1c
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0x44]
push 0
push eax
mov dword [esp + 0x28], eax
mov eax, dword [esp + 0x44]
push eax
push ecx
call edx
mov ecx, dword [esp + 0x30]
sub dword [edi + 0x44], ecx
xor edi, edi
add esp, 0x10
mov dword [esp + 0x3c], eax
mov dword [esp + 0x44], edi
cmp dword [esp + 0x18], edi
jne 0x4013bc
mov eax, dword [esi]
sub eax, 0x10
mov dword [esp + 0x54], eax
sub eax, dword [ebx + 0x20]
lea edx, [esp + 0x54]
push eax
push edx
push 0x41cee0
xor edx, edx
mov eax, ebx
mov dword [esp + 0x64], 0xffffffff
call fcn.00430650
mov ecx, dword [ebx + 0x14]
mov edx, dword [esi]
add esp, 0xc
cmp edx, dword [ecx + 8]
jb 0x4013b4
mov dword [ecx + 8], edx
mov dword [esp + 0x18], edi
cmp eax, edi
je 0x4013c4
mov dword [esp + 0x18], 1
push edi
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push 0x48142c
mov edi, eax
push 0x481430
push edi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
mov dword [esp + 0x20], eax
test edi, edi
je 0x401513
test eax, eax
je 0x401513
push eax
push edi
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov dword [esp + 0x30], eax
test eax, eax
je 0x401513
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov dword [esp + 0x28], eax
test eax, eax
je 0x401513
mov eax, dword [esp + 0x20]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov dword [esp + 0xc], eax
mov eax, dword [ebx + 0x10]
mov ecx, dword [eax + 0x44]
cmp ecx, dword [eax + 0x40]
jb 0x40143b
mov eax, ebx
call fcn.0042c500
mov edx, dword [esp + 0xc]
mov eax, dword [esp + 0x28]
mov edi, dword [esi]
push edx
push eax
push ebx
call fcn.004320c0
mov ecx, dword [esp + 0x3c]
add esp, 0xc
mov dword [edi], eax
mov dword [edi + 8], 4
add dword [esi], 0x10
push ecx
call dword [sym.imp.KERNEL32.dll_FreeResource]
cmp dword [esp + 0xc], 0
je 0x401513
mov eax, dword [esi]
sub eax, 0x10
cmp dword [eax + 8], 4
je 0x4014af
mov esi, eax
mov edi, ebx
call fcn.0042c730
test eax, eax
jne 0x401490
mov esi, dword [esp + 0x10]
jmp 0x4014b4
mov eax, dword [ebx + 0x10]
mov edx, dword [eax + 0x44]
cmp edx, dword [eax + 0x40]
jb 0x4014a2
mov eax, ebx
call fcn.0042c500
mov eax, dword [esp + 0x10]
mov eax, dword [eax]
mov esi, dword [esp + 0x10]
sub eax, 0x10
mov eax, dword [eax]
add eax, 0x10
cmp dword [esp + 0x18], 0
jne 0x40151a
mov ecx, dword [esp + 0xc]
lea edx, [esp + 0x30]
mov dword [esp + 0x30], eax
mov eax, dword [0x49b20c]
mov dword [esp + 0x34], ecx
push edx
mov edx, 0x420600
mov ecx, ebx
call fcn.0041cf60
add esp, 4
test eax, eax
jne 0x40151a
mov eax, dword [esi]
sub eax, 0x10
mov dword [esp + 0x28], eax
sub eax, dword [ebx + 0x20]
xor edx, edx
push eax
lea eax, [esp + 0x2c]
push eax
push 0x41cee0
mov eax, ebx
mov dword [esp + 0x38], 1
call fcn.00430650
add esp, 0xc
test eax, eax
jmp 0x401518
cmp dword [esp + 0x18], 0
je 0x401530
mov ecx, dword [0x49b20c]
push ecx
mov eax, ebx
call fcn.0041db10
add esp, 4
or edi, 0xffffffff
jmp 0x401580
mov eax, dword [esi]
mov ecx, dword [eax - 8]
sub eax, 0x10
cmp ecx, 3
je 0x401570
cmp ecx, 4
jne 0x40165f
mov eax, dword [eax]
add eax, 0x10
lea edi, [esp + 0x20]
call fcn.00432330
test eax, eax
je 0x40165f
fld qword [esp + 0x20]
mov dword [esp + 0x78], 3
fstp qword [esp + 0x70]
lea eax, [esp + 0x70]
fld qword [eax]
fadd qword [0x4863e0]
fstp qword [esp + 0x18]
mov edi, dword [esp + 0x18]
push 0xe
push 0x481434
push ebx
call fcn.004320c0
mov edx, dword [esi]
mov ecx, dword [esp + 0x20]
add esp, 0xc
push edx
mov dword [esp + 0x84], eax
lea eax, [esp + 0x84]
push eax
push ecx
push ebx
mov dword [esp + 0x98], 4
call fcn.0042c910
add dword [esi], 0x10
mov eax, dword [esi]
add eax, 0xfffffff0
add esp, 0x10
cmp eax, 0x482990
je 0x4015dc
cmp dword [eax + 8], 6
jne 0x4015dc
push 0
push eax
push ebx
call fcn.00430460
add esp, 0xc
mov eax, ebx
call fcn.0042c690
mov eax, dword [0x49b210]
test eax, eax
je 0x4015fb
call fcn.00421000
mov dword [0x49b210], 0
mov esi, dword [sym.imp.KERNEL32.dll_DeleteCriticalSection]
push 0x49c8c0
call esi
push 0x49c8a0
call esi
push 0x49c8e0
call esi
mov eax, dword [0x49b214]
call fcn.00421000
mov eax, dword [0x49b208]
mov dword [0x49b214], 0
test eax, eax
je 0x40163c
push eax
call fcn.0045bf87
add esp, 4
mov eax, dword [0x49b204]
test eax, eax
je 0x40164e
push eax
call fcn.0045bf87
add esp, 4
call dword [sym.imp.ole32.dll_OleUninitialize]
mov eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x10
xor edi, edi
jmp 0x401580