Function at 0x45a8e0
Capabilities:
Extract resource via kernel32 functions
Read file on windows

Disassembly:
mov eax, dword [esp + 4]
sub esp, 0x43c
test eax, eax
push ebx
push ebp
push esi
push edi
je 0x45ab7e
mov ebx, dword [esp + 0x458]
test ebx, ebx
je 0x45ab7e
mov ebp, dword [esp + 0x454]
test ebp, ebp
je 0x45ab7e
mov dword [ebp], 0
xor esi, esi
lea edi, [esp + 0x4d]
mov eax, esi
add edi, 4
shr eax, 5
and eax, 7
mov ecx, eax
shl ecx, 8
sub ecx, eax
mov eax, 0x24924925
mul ecx
sub ecx, edx
mov eax, esi
shr ecx, 1
add ecx, edx
shr eax, 2
shr ecx, 2
and eax, 7
mov byte [edi - 5], cl
mov ecx, eax
shl ecx, 8
sub ecx, eax
mov eax, 0x24924925
mul ecx
sub ecx, edx
mov eax, esi
shr ecx, 1
add ecx, edx
and eax, 3
shr ecx, 2
mov byte [edi - 4], cl
mov ecx, eax
shl ecx, 8
sub ecx, eax
mov eax, 0xaaaaaaab
mul ecx
shr edx, 1
mov byte [edi - 3], dl
mov byte [edi - 2], 0
inc esi
cmp esi, 0x100
jb 0x45a921
push 2
push ebx
push 0
call dword [sym.imp.KERNEL32.dll_FindResourceA]
test eax, eax
je 0x45aa57
push eax
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
test eax, eax
jne 0x45a9c4
pop edi
pop esi
pop ebp
mov eax, 0x80004005
pop ebx
add esp, 0x43c
ret
mov ecx, dword [eax]
cmp ecx, 0x28
lea edx, [ecx + eax]
jb 0x45a9ec
mov cx, word [eax + 0xe]
cmp cx, 8
ja 0x45a9ec
mov eax, dword [eax + 0x20]
test eax, eax
jne 0x45a9e8
mov ebx, 1
shl ebx, cl
jmp 0x45a9ee
mov ebx, eax
jmp 0x45a9ee
xor ebx, ebx
test ebx, ebx
jbe 0x45aa35
lea esi, [esp + 0x4c]
lea edi, [esp + 0x4d]
lea ebp, [esp + 0x4e]
sub esi, edx
sub edi, edx
lea eax, [edx + 1]
sub ebp, edx
lea ecx, [esp + 0x4c]
mov edx, ebx
mov bl, byte [eax + 1]
add eax, 4
mov byte [ecx], bl
mov bl, byte [eax - 4]
mov byte [esi + eax - 4], bl
mov bl, byte [eax - 5]
mov byte [edi + eax - 4], bl
mov byte [eax + ebp - 4], 0
add ecx, 4
dec edx
jne 0x45aa0d
mov ebp, dword [esp + 0x454]
mov eax, dword [esp + 0x450]
push 0
lea ecx, [esp + 0x50]
push ebp
mov edx, dword [eax]
push ecx
push 4
push eax
call dword [edx + 0x14]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x43c
ret
push 0
push 0
push 3
push 0
push 0
push closesocket
push ebx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
je 0x45ab5c
mov edi, dword [sym.imp.KERNEL32.dll_ReadFile]
lea edx, [esp + 0x10]
push 0
push edx
lea eax, [esp + 0x44]
push 0xe
push eax
push esi
call edi
cmp dword [esp + 0x10], 0xe
je 0x45aaad
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
mov eax, 0x80004005
pop ebx
add esp, 0x43c
ret
lea ecx, [esp + 0x10]
push 0
mov ebx, 0x28
push ecx
lea edx, [esp + 0x1c]
push ebx
push edx
push esi
call edi
cmp dword [esp + 0x10], ebx
je 0x45aadf
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
mov eax, 0x80004005
pop ebx
add esp, 0x43c
ret
lea eax, [esp + 0x10]
push 0
push eax
lea ecx, [esp + 0x54]
push 0x400
push ecx
push esi
call edi
mov eax, dword [esp + 0x10]
push esi
cmp eax, 0x400
je 0x45ab15
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
mov eax, 0x80004005
pop ebx
add esp, 0x43c
ret
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [esp + 0x14], ebx
je 0x45ab25
xor edx, edx
jmp 0x45ab42
mov ecx, dword [esp + 0x22]
cmp cx, 8
jbe 0x45ab33
xor edx, edx
jmp 0x45ab42
mov edx, dword [esp + 0x34]
test edx, edx
jne 0x45ab44
mov edx, 1
shl edx, cl
test edx, edx
jbe 0x45ab5c
lea eax, [esp + 0x4e]
mov esi, edx
mov dl, byte [eax]
mov cl, byte [eax - 2]
mov byte [eax - 2], dl
mov byte [eax], cl
add eax, 4
dec esi
jne 0x45ab4c
mov eax, dword [esp + 0x450]
push 0
lea edx, [esp + 0x50]
push ebp
mov ecx, dword [eax]
push edx
push 4
push eax
call dword [ecx + 0x14]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x43c
ret
pop edi
pop esi
pop ebp
mov eax, 0x80070057
pop ebx
add esp, 0x43c
ret