Function at 0x40848f
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
lea ebp, [esp - 0x64]
sub esp, 0x8c
push ebx
push esi
push edi
push 0x3c
lea eax, [ebp - 0x28]
xor esi, esi
push eax
mov dword [ebp + 0x5c], esi
mov dword [ebp + 0x54], esi
call fcn.004024d6
mov eax, dword [ebp + 0x78]
mov dword [ebp + 0x34], eax
cmp eax, esi
jne 0x40850f
push esi
push dword [ebp + 0x74]
call dword [sym.imp.KERNEL32.dll__lopen]
mov dword [ebp + 0x38], eax
cmp eax, 0xffffffff
jne 0x408535
mov dword [ebp + 0x58], 2
lea eax, [ebp - 0x28]
push eax
call fcn.00408075
push dword [ebp + 0x5c]
call fcn.00401019
push dword [ebp + 0x54]
call fcn.00401019
xor esi, esi
cmp dword [ebp + 0x78], esi
jne 0x408842
cmp dword [ebp + 0x38], 0xffffffff
je 0x408850
push dword [ebp + 0x38]
call dword [sym.imp.KERNEL32.dll__lclose]
jmp 0x408850
lea eax, [ebp + 0x3c]
push eax
push 0x4389d8
push dword [ebp + 0x74]
call fcn.00403066
mov dword [ebp + 0x40], eax
cmp eax, esi
je 0x4084cc
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov dword [ebp + 0x44], eax
cmp eax, esi
je 0x4084cc
push 0x400
call fcn.00401000
mov dword [ebp + 0x5c], eax
cmp eax, esi
jne 0x40854f
mov dword [ebp + 0x58], 4
jmp 0x4084d3
push 7
pop edi
lea eax, [ebp + 0x18]
push eax
push 0xd
pop eax
lea esi, [ebp + 0x34]
mov dword [ebp + 0x58], edi
call fcn.00407d44
cmp eax, 0xd
jne 0x4084d3
push 4
push str.GIF8
lea eax, [ebp + 0x18]
push eax
call fcn.0040143c
test eax, eax
jne 0x4084d3
mov al, byte [ebp + 0x1c]
add al, 0x20
cmp al, 0x57
je 0x408596
cmp al, 0x59
jne 0x4084d3
movzx ecx, byte [ebp + 0x22]
mov eax, dword [ebp + 0x6c]
and ecx, edi
inc ecx
xor edi, edi
inc edi
shl edi, cl
test byte [ebp + 0x22], 0x80
mov dword [ebp + 0x14], ecx
movsx ecx, word [ebp + 0x1e]
mov dword [eax + 8], ecx
movsx ecx, word [ebp + 0x20]
mov dword [eax + 0xc], ecx
je 0x4085f2
push dword [ebp + 0x5c]
mov ebx, edi
imul ebx, ebx, 3
mov eax, ebx
lea esi, [ebp + 0x34]
call fcn.00407d44
cmp eax, ebx
jne 0x4084d3
mov eax, edi
shl eax, 2
push eax
call fcn.00401000
mov dword [ebp + 0x54], eax
test eax, eax
je 0x4085f2
push edi
push dword [ebp + 0x5c]
push eax
call fcn.0040511a
lea eax, [ebp - 0x28]
push eax
call fcn.00408075
mov byte [ebp + 0x2a], 0
lea eax, [ebp + 0x63]
xor edi, edi
push eax
inc edi
mov eax, edi
lea esi, [ebp + 0x34]
call fcn.00407d44
cmp eax, edi
jne 0x4084d3
cmp byte [ebp + 0x63], 0x3b
je 0x408831
cmp byte [ebp + 0x63], 0x2c
je 0x4086ff
cmp byte [ebp + 0x63], 0x21
jne 0x4085ff
lea eax, [ebp + 0x63]
push eax
mov eax, edi
call fcn.00407d44
cmp eax, edi
jne 0x4084d3
movzx eax, byte [ebp + 0x63]
dec eax
je 0x4086e3
sub eax, 0xf8
je 0x4086cf
sub eax, 5
je 0x40867e
dec eax
jne 0x4084d3
mov eax, dword [ebp + 0x5c]
add eax, 0x300
push eax
push 0x11
pop eax
call fcn.00407d44
cmp eax, 0x11
je 0x4085ff
jmp 0x4084d3
lea eax, [ebp + 0x63]
push eax
xor eax, eax
inc eax
lea esi, [ebp + 0x34]
call fcn.00407d44
cmp eax, 1
jne 0x4084d3
cmp byte [ebp + 0x63], 0
je 0x4085ff
mov ebx, dword [ebp + 0x5c]
movzx eax, byte [ebp + 0x63]
movzx edi, byte [ebp + 0x63]
add ebx, 0x300
push ebx
call fcn.00407d44
cmp eax, edi
jne 0x4084d3
push ebx
lea eax, [ebp - 0x28]
push eax
mov byte [edi + ebx], 0
call fcn.00408172
jmp 0x40867e
lea eax, [ebp + 0x2a]
push eax
push 6
pop eax
lea esi, [ebp + 0x34]
call fcn.00407d44
cmp eax, 6
jmp 0x408677
mov eax, dword [ebp + 0x5c]
add eax, 0x300
push eax
push 0x12
pop eax
lea esi, [ebp + 0x34]
call fcn.00407d44
cmp eax, 0x12
jmp 0x408677
lea eax, [ebp + 0x49]
push eax
push 9
pop eax
lea esi, [ebp + 0x34]
call fcn.00407d44
cmp eax, 9
jne 0x4084d3
test byte [ebp + 0x51], 0x80
jne 0x408722
mov esi, dword [ebp + 0x14]
jmp 0x40872a
movzx esi, byte [ebp + 0x51]
and esi, 7
inc esi
push 4
pop ebx
xor eax, eax
cmp esi, ebx
setg al
lea eax, [eax*4 + 4]
push eax
mov dword [ebp + 0x30], eax
movsx eax, word [ebp + 0x4f]
push eax
movsx eax, word [ebp + 0x4d]
push eax
push dword [ebp + 0x6c]
call fcn.00408437
mov edi, eax
test edi, edi
je 0x40883a
movsx eax, word [ebp + 0x49]
mov dword [edi + 0x10], eax
movsx eax, word [ebp + 0x4b]
mov dword [edi + 0x14], eax
xor eax, eax
inc eax
mov ecx, esi
shl eax, cl
mov dword [edi + 0x20], eax
mov eax, dword [ebp]
mov dword [edi + 0x28], eax
and dword [ebp], 0
cmp byte [ebp + 0x2a], bl
jne 0x408796
mov al, byte [ebp + 0x2b]
mov byte [edi + 0x34], al
movzx eax, word [ebp + 0x2c]
mov dword [edi + 0x2c], eax
movzx eax, byte [ebp + 0x2e]
mov dword [edi + 0x30], eax
test byte [ebp + 0x51], 0x80
je 0x4087c7
mov ebx, dword [edi + 0x20]
push dword [ebp + 0x5c]
imul ebx, ebx, 3
mov eax, ebx
lea esi, [ebp + 0x34]
call fcn.00407d44
cmp eax, ebx
jne 0x4084d3
push dword [edi + 0x20]
push dword [ebp + 0x5c]
push dword [edi + 8]
call fcn.0040511a
jmp 0x4087df
cmp dword [ebp + 0x54], 0
je 0x4087df
mov eax, dword [edi + 0x20]
shl eax, 2
push eax
push dword [ebp + 0x54]
push dword [edi + 8]
call fcn.00402c5c
lea eax, [ebp + 0x62]
push eax
xor eax, eax
inc eax
lea esi, [ebp + 0x34]
call fcn.00407d44
cmp byte [ebp + 0x62], 8
ja 0x4084d3
mov al, byte [ebp + 0x51]
shr al, 6
and al, 1
movzx eax, al
push eax
movsx eax, word [ebp + 0x4d]
push dword [ebp + 0x30]
push eax
call fcn.004050da
push eax
movzx eax, byte [ebp + 0x62]
push eax
movsx eax, word [ebp + 0x4f]
push eax
movsx eax, word [ebp + 0x4d]
push eax
mov eax, esi
push eax
push dword [edi + 0xc]
call fcn.00407d82
jmp 0x4085f2
and dword [ebp + 0x58], 0
jmp 0x4084d3
mov dword [ebp + 0x58], ebx
jmp 0x4084d3
cmp dword [ebp + 0x40], esi
je 0x408850
push dword [ebp + 0x40]
call dword [sym.imp.KERNEL32.dll_FreeResource]
cmp dword [ebp + 0x7c], esi
je 0x4088a6
cmp dword [ebp + 0x58], esi
je 0x4088a6
push dword [ebp + 0x6c]
call fcn.00408405
mov eax, dword [ebp + 0x58]
dec eax
dec eax
je 0x408882
dec eax
dec eax
je 0x40887a
sub eax, 3
jne 0x4088a2
push esi
push 0x4389a0
jmp 0x40889a
push esi
push 0x43867c
jmp 0x40889a
push dword [ebp + 0x74]
push 0x438660
push dword [ebp + 0x5c]
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0xc
push esi
push dword [ebp + 0x5c]
push dword [ebp + 0x70]
call fcn.0040258f
xor eax, eax
jmp 0x4088a9
xor eax, eax
inc eax
pop edi
pop esi
pop ebx
add ebp, 0x64
leave
ret 0x14