Function at 0x403150
Capabilities:
Extract resource via kernel32 functions

Disassembly:
sub esp, 0x20
push ebx
push ebp
push esi
push edi
push 0x40d1a0
call dword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
xor ebx, ebx
xor esi, esi
cmp dword [esp + 0x34], ebx
je 0x403178
push dword [esp + 0x34]
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov esi, eax
push 0x40ba7c
push 0x40ba78
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
cmp eax, ebx
je 0x4031a5
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
cmp eax, ebx
je 0x4031a5
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov dword [0x40d1b8], eax
mov eax, dword [0x40d1b8]
cmp eax, ebx
jne 0x4031be
push str.Panic:_Cant_find_bfs_section_n
call fcn.00401085
pop ecx
jmp 0x403509
push ebx
push 1
pop ebp
push ebp
push 0x40ba54
push eax
call fcn.0040462b
add esp, 0x10
test eax, eax
je 0x403230
push ebx
push ebx
push ebx
push 0x40d1e4
push ebx
push 0xd
push 0xc
lea eax, [esp + 0x40]
push 0x7d1
push eax
mov dword [esp + 0x48], 0x40ba4c
mov dword [esp + 0x4c], 0x40ba40
mov dword [esp + 0x50], ebx
call fcn.00402c8b
add esp, 0x24
sub eax, ebx
je 0x403230
dec eax
je 0x403220
dec eax
je 0x403219
push str.You_dont_seem_to_have_a_valid_license._nPlease_purchase_a_license_from_http:__www.ActiveState.com_PDK_n
jmp 0x403225
push str.Your_license_does_not_cover_this_version_of_the_Perl_Dev_Kit._nPlease_purchase_an_upgrade_from_http:__www.ActiveState.com_PDK_n
jmp 0x403225
push str.Your_trial_license_has_expired._nPlease_purchase_a_license_from_http:__www.ActiveState.com_PDK_n
call fcn.00401085
pop ecx
jmp 0x403560
mov esi, dword [sym.imp.MSVCRT.dll___p__environ]
call esi
cmp dword [eax], ebx
je 0x4033f7
mov dword [esp + 0x10], ebx
mov dword [esp + 0x1c], ebx
xor edi, edi
call esi
mov eax, dword [eax]
cmp dword [eax], ebx
je 0x40325c
inc edi
call esi
mov eax, dword [eax]
cmp dword [eax + edi*4], ebx
jne 0x403252
lea eax, [edi*4 + 4]
push str.env_kill
push eax
call fcn.0040358f
mov ebp, eax
pop ecx
cmp ebp, ebx
pop ecx
mov dword [esp + 0x20], ebp
je 0x403509
call esi
mov eax, dword [eax]
cmp dword [eax], ebx
je 0x40339e
mov dword [esp + 0x14], ebx
mov ebx, dword [sym.imp.MSVCRT.dll__strnicmp]
mov dword [esp + 0x18], ebp
call esi
mov eax, dword [eax]
mov ecx, dword [esp + 0x14]
push 4
mov edi, dword [eax + ecx]
push edi
push str.PERL
call ebx
add esp, 0xc
test eax, eax
jne 0x403385
push 9
push edi
push str.PERL5LIB
call ebx
add esp, 0xc
test eax, eax
jne 0x4032db
lea eax, [edi + 9]
push eax
call dword [sym.imp.MSVCRT.dll__strdup]
pop ecx
mov dword [0x40d1c4], eax
jmp 0x403330
push 8
push edi
push str.PERLLIB
call ebx
add esp, 0xc
test eax, eax
jne 0x4032fd
lea eax, [edi + 8]
push eax
call dword [sym.imp.MSVCRT.dll__strdup]
pop ecx
mov dword [esp + 0x10], eax
jmp 0x403330
push 9
push edi
push str.PERL5OPT
call ebx
add esp, 0xc
test eax, eax
je 0x403330
push 8
push edi
push str.PERL5DB
call ebx
add esp, 0xc
test eax, eax
je 0x403330
push 0xb
push edi
push str.PERL5SHELL
call ebx
add esp, 0xc
test eax, eax
jne 0x403385
push 0x3d
push edi
call dword [sym.imp.MSVCRT.dll_strchr]
push 1
mov esi, eax
pop eax
sub eax, edi
push str.env_kill_entry
add esi, eax
lea eax, [esi + 1]
push eax
call fcn.0040358f
mov ebp, eax
add esp, 0x10
test ebp, ebp
je 0x403509
push esi
push edi
push ebp
call sub.MSVCRT.dll_memcpy
mov eax, dword [esp + 0x24]
and byte [esi + ebp], 0
mov esi, dword [sym.imp.MSVCRT.dll___p__environ]
add esp, 0xc
inc dword [esp + 0x1c]
add dword [esp + 0x18], 4
mov dword [eax], ebp
mov ebp, dword [esp + 0x20]
add dword [esp + 0x14], 4
call esi
mov eax, dword [eax]
mov ecx, dword [esp + 0x14]
cmp dword [eax + ecx], 0
jne 0x403298
xor ebx, ebx
cmp dword [0x40d1c4], ebx
jne 0x4033b3
mov eax, dword [esp + 0x10]
mov dword [esp + 0x10], ebx
mov dword [0x40d1c4], eax
cmp dword [esp + 0x10], ebx
je 0x4033c4
push dword [esp + 0x10]
call dword [sym.imp.MSVCRT.dll_free]
pop ecx
mov eax, dword [esp + 0x1c]
dec eax
js 0x4033ec
lea esi, [ebp + eax*4]
lea ebx, [eax + 1]
mov edi, dword [esi]
push edi
call dword [sym.imp.MSVCRT.dll__putenv]
push edi
call dword [sym.imp.MSVCRT.dll_free]
pop ecx
sub esi, 4
dec ebx
pop ecx
jne 0x4033d2
xor ebx, ebx
push ebp
call dword [sym.imp.MSVCRT.dll_free]
pop ecx
push 1
pop ebp
push dword [esp + 0x34]
call fcn.00404800
mov dword [esp], str.tmpdir
push str.TMPDIR
mov dword [0x40d1bc], eax
call fcn.004035cc
push str.debugger_options
push str.DEBUG
mov dword [0x40d1c0], eax
call fcn.004035cc
push ebx
push 6
push str.CLEAN
mov esi, eax
push dword [0x40d1b8]
call fcn.0040462b
push ebx
push 6
push str.TAINT
mov dword [0x40d1d4], eax
push dword [0x40d1b8]
call fcn.0040462b
push str.scriptname
push str.SCRIPTNAME
mov dword [0x40d1dc], eax
call fcn.004035cc
add esp, 0x38
cmp eax, ebx
mov dword [0x40d1c8], eax
jne 0x403481
push str.Panic:_scriptname_not_defined
jmp 0x403225
push str.script
push eax
call fcn.004035cc
pop ecx
cmp eax, ebx
pop ecx
mov dword [0x40d1cc], eax
je 0x403560
cmp esi, ebx
je 0x403549
push 0x40b814
push 0xc8
call fcn.0040358f
mov edi, eax
pop ecx
cmp edi, ebx
pop ecx
je 0x403560
push dword [0x40b0c0]
push dword [0x40b0bc]
push str._ENVPERL5DB
push str.PERL5DBBEGIN___PerlApp::P_P___P0__delete__s__eval__s__s___die____if______P_PerlApp::P_BEGIN__require_perl5db.pl_
push edi
call dword [sym.imp.MSVCRT.dll_sprintf]
mov ebx, dword [sym.imp.MSVCRT.dll__putenv]
push edi
call ebx
add esp, 0x18
cmp byte [esi], 0x2d
je 0x403528
push str.PERLDB_OPTS
push esi
call sub.MSVCRT.dll_strlen
pop ecx
add eax, 0x10
push eax
call fcn.0040358f
mov edi, eax
pop ecx
test edi, edi
pop ecx
jne 0x40350e
push 1
pop eax
jmp 0x403587
push esi
push 0x40b768
push edi
call sub.MSVCRT.dll_strcpy
pop ecx
pop ecx
push eax
call sub.MSVCRT.dll_strcat
push edi
call ebx
add esp, 0xc
push esi
mov dword [0x40d1d0], 0x40b764
call dword [sym.imp.MSVCRT.dll_free]
pop ecx
mov dword [0x40d1d8], 1
push 1
pop ebp
jmp 0x40357f
push str.setup
push 0x50
call fcn.0040358f
pop ecx
cmp eax, ebx
pop ecx
mov dword [0x40d1d0], eax
jne 0x403564
mov eax, ebp
jmp 0x403587
push dword [0x40b0c0]
push dword [0x40b0bc]
push str._eBEGIN__eval__s__s___die____if____
push eax
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0x10
mov dword [0x40d1e0], ebp
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x20
ret