Function at 0x508946
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push edx
add edx, 0x12ffd
jmp 0x508655
sub edx, 0x2c07
and edx, 0x1092b
pop edx
push edi
push edx
add esp, 4
xor edi, 0x13c29
and edi, 0x11a3e
xor edi, 0x1070c
pop edi
lea edx, [ebp - 0x16cc]
mov dword [ebp - 0xc28], edx
mov eax, dword [ebp - 0x4d8]
mov ecx, dword [eax + 0x30]
mov dword [ebp - 0xc24], ecx
xor edx, edx
mov word [ebp - 0x1fc], dx
xor eax, eax
mov word [ebp - 0x104], ax
push eax
jmp 0x5086ad
pop eax
push edi
push edx
add esp, 4
call fcn.005086c3
add byte [edx + 0x4c], al
dec esp
cmp byte [0x4d3e4a4f], dh
xor al, 0x83
add esp, 4
invalid
out dx, eax
cmc
jne 0x5086cb
add esp, 4
sub edi, 0x75f5
pop edi
push esi
add byte [edi + 0x56], bl
push edx
add esp, 4
add esi, 0x15897
pop esi
mov ecx, dword [ebp - 0xc24]
mov dx, word [ecx]
mov word [ebp - 0xf82], dx
mov eax, dword [ebp - 0xc24]
add eax, 2
mov dword [ebp - 0xc24], eax
mov cx, word [ebp - 0xf82]
mov word [ebp - 0x1fc], cx
mov edx, dword [ebp - 0xc28]
mov ax, word [edx]
mov word [ebp - 0xf84], ax
mov ecx, dword [ebp - 0xc28]
add ecx, 2
mov dword [ebp - 0xc28], ecx
mov dx, word [ebp - 0xf84]
mov word [ebp - 0x104], dx
push edx
add edx, 0x17ceb
call 0x508749
add byte [esi + 0x38], al
inc edx
dec ecx
inc esi
xor bh, byte [edi]
add esp, 4
and edx, 0xa8eb
and edx, 0x22f3
pop edx
push esi
push edi
add esp, 4
add esi, 0x9c9e
pop esi
movzx eax, word [ebp - 0x104]
test eax, eax
jne 0x508788
movzx ecx, word [ebp - 0x1fc]
movzx edx, word [ebp - 0x104]
sub ecx, edx
mov dword [ebp - 0x14e4], ecx
jmp 0x5087eb
movzx eax, word [ebp - 0x1fc]
movzx ecx, word [ebp - 0x104]
cmp eax, ecx
je 0x5086a7
movzx edx, word [ebp - 0x1fc]
xor edx, 0x20
movzx eax, word [ebp - 0x104]
cmp edx, eax
je 0x5086a7
movzx ecx, word [ebp - 0x1fc]
movzx edx, word [ebp - 0x104]
cmp ecx, edx
jge 0x5087d5
mov dword [ebp - 0x14e0], 0xffffffff
jmp 0x5087df
mov dword [ebp - 0x14e0], 1
mov eax, dword [ebp - 0x14e0]
mov dword [ebp - 0x14e4], eax
cmp dword [ebp - 0x14e4], 0
jne 0x508834
push ebx
push edx
add esp, 4
add ebx, 0xed6e
pop ebx
push esi
push eax
add esp, 4
and esi, 0x1505
add esi, 0x8d5
add esi, 0x1638e
pop esi
push esi
or esi, 0xfd9a
xor esi, 0x22
pop esi
mov ecx, dword [ebp - 0x4d8]
mov dword [ebp - 0x6ec], ecx
jmp 0x50889c
push edx
push eax
add esp, 4
sub edx, 0x10e13
sub edx, 0x1153b
jmp 0x50884e
pop edx
push ebx
jmp 0x508859
xor ebx, 0x20fc
xor ebx, 0x587e
pop ebx
mov edx, dword [ebp - 0x4d8]
mov eax, dword [edx]
mov dword [ebp - 0x4d8], eax
mov ecx, dword [ebp - 0x4d8]
cmp ecx, dword [ebp - 0xc2c]
je 0x508892
mov edx, dword [ebp - 0x4d8]
cmp dword [edx + 0x30], 0
jne 0x508648
mov dword [ebp - 0x6ec], 0
push edi
push edx
add esp, 4
jmp 0x5088a9
pop edi
push ebx
push esi
add esp, 4
call 0x5088be
add byte [edx], dh
cmp dword [0x40454637], esi
aaa
cmp byte [ebx - 0x1c7efb3c], al
scasb al, byte es:[edi]
pop edx
add dword [eax], eax
or ebx, 0x150fc
pop ebx
cmp dword [ebp - 0x6ec], 0
jne 0x508918
push edi
push eax
add esp, 4
sub edi, 0x16d74
or edi, 0x26eb
xor edi, 0xf631
pop edi
push esi
jmp 0x5088f5
jmp 0x5088fd
add esi, 0x1723e
jmp 0x508908
pop esi
mov dword [ebp - 0x738], 0
jmp 0x50943f
push edx
xor edx, 0x9057
jmp 0x508925
add edx, 0x113ab
pop edx
push ebx
push ebx
add esp, 4
xor ebx, 0x1e46
call 0x508946
add byte [ebx], bh
xor eax, dword [ebx + 0x48]
cmp al, 0x4c
inc edx
inc esi
dec edi
add esp, 4
pop ebx
mov eax, dword [ebp - 0x6ec]
mov ecx, dword [eax + 0x18]
mov dword [ebp - 0x2f8], ecx
mov dword [ebp - 0x6fc], 0
mov edx, dword [ebp - 0x2f8]
mov dword [ebp - 0x14e8], edx
cmp dword [ebp - 0x14e8], 0
jne 0x508989
mov eax, dword [ebp - 0x6fc]
mov dword [ebp - 0x3c4], eax
jmp 0x508c7a
mov ecx, dword [ebp - 0x14e8]
mov edx, dword [ebp - 0x2f8]
add edx, dword [ecx + 0x3c]
mov dword [ebp - 0x14ec], edx
jne 0x5089b1
mov eax, dword [ebp - 0x6fc]
mov dword [ebp - 0x3c4], eax
jmp 0x508c7a
mov ecx, 8
imul edx, ecx, 0
mov eax, dword [ebp - 0x14ec]
mov ecx, dword [eax + edx + 0x78]
mov dword [ebp - 0x14f0], ecx
cmp dword [ebp - 0x14f0], 0
jne 0x5089e3
mov edx, dword [ebp - 0x6fc]
mov dword [ebp - 0x3c4], edx
jmp 0x508c7a
mov eax, dword [ebp - 0x2f8]
add eax, dword [ebp - 0x14f0]
mov dword [ebp - 0x6f0], eax
jne 0x508a08
mov ecx, dword [ebp - 0x6fc]
mov dword [ebp - 0x3c4], ecx
jmp 0x508c7a
mov edx, dword [ebp - 0x6f0]
mov eax, dword [ebp - 0x2f8]
add eax, dword [edx + 0x20]
mov dword [ebp - 0x18a0], eax
mov ecx, dword [ebp - 0x6f0]
mov edx, dword [ebp - 0x2f8]
add edx, dword [ecx + 0x24]
mov dword [ebp - 0x18a4], edx
mov eax, dword [ebp - 0x6f0]
mov ecx, dword [ebp - 0x2f8]
add ecx, dword [eax + 0x1c]
mov dword [ebp - 0x18a8], ecx
mov dword [ebp - 0x6f4], 0
jmp 0x508a62
mov edx, dword [ebp - 0x6f4]
add edx, 1
mov dword [ebp - 0x6f4], edx
mov eax, dword [ebp - 0x6f0]
mov ecx, dword [ebp - 0x6f4]
cmp ecx, dword [eax + 0x18]
jae 0x508c6e
mov edx, dword [ebp - 0x6f4]
mov eax, dword [ebp - 0x18a0]
mov ecx, dword [ebp - 0x2f8]
add ecx, dword [eax + edx*4]
mov dword [ebp - 0x6f8], ecx
mov edx, dword [ebp - 0x6f4]
mov eax, dword [ebp - 0x18a4]
movzx ecx, word [eax + edx*2]
mov edx, dword [ebp - 0x18a8]
mov eax, dword [ebp - 0x2f8]
add eax, dword [edx + ecx*4]
mov dword [ebp - 0x18ac], eax
mov dword [ebp - 0x180], 0
jmp 0x508ad2
mov ecx, dword [ebp - 0x180]
add ecx, 1
mov dword [ebp - 0x180], ecx
mov edx, dword [ebp - 0x6f8]
add edx, dword [ebp - 0x180]
movsx eax, byte [edx]
test eax, eax
je 0x508b84
mov ecx, dword [ebp - 0x180]
movsx edx, byte [ebp + ecx - 0x820]
test edx, edx
je 0x508b84
push eax
push esi
add esp, 4
and eax, 0xe32b
call 0x508b17
add byte [ebx], bh
aas
cmp byte [esi + 0x3c], cl
cmp edi, dword [eax]
add esp, 4
xor eax, 0x16b94
call 0x508b2d
add byte [ebx + eax*2 + 0x49], cl
inc ecx
inc eax
dec edx
add esp, 4
pop eax
mov eax, dword [ebp - 0x6f8]
add eax, dword [ebp - 0x180]
movsx ecx, byte [eax]
mov edx, dword [ebp - 0x180]
movsx eax, byte [ebp + edx - 0x820]
cmp ecx, eax
je 0x508b76
mov ecx, dword [ebp - 0x6f8]
add ecx, dword [ebp - 0x180]
movsx edx, byte [ecx]
xor edx, 0x20
mov eax, dword [ebp - 0x180]
movsx ecx, byte [ebp + eax - 0x820]
cmp edx, ecx
jne 0x508b7d
jmp 0x508ac3
jmp 0x508b84
push esi
or esi, 0xda0b
sub esi, 0x6692
or esi, 0x1306a
pop esi
push ebx
xor ebx, 0x5a38
pop ebx
push eax
add eax, 0xd6c
jmp 0x508baf
add eax, 0x169f0
pop eax
mov edx, dword [ebp - 0x6f8]
add edx, dword [ebp - 0x180]
movsx eax, byte [edx]
mov ecx, dword [ebp - 0x180]
movsx edx, byte [ebp + ecx - 0x820]
cmp eax, edx
jne 0x508be3
mov dword [ebp - 0xc30], 0
jmp 0x508c52
push edx
push eax
add esp, 4
add edx, 0x111d1
sub edx, 0x97d
and edx, 0x16b13
pop edx
push edx
and edx, 0x125d3
add edx, 0x526f
and edx, 0x171d2
or edx, 0xbb7f
pop edx
mov eax, dword [ebp - 0x6f8]
add eax, dword [ebp - 0x180]
movsx ecx, byte [eax]
or ecx, 0x20
mov edx, dword [ebp - 0x180]
movsx eax, byte [ebp + edx - 0x820]
or eax, 0x20
cmp ecx, eax
jge 0x508c48
mov dword [ebp - 0xc30], 0xffffffff
jmp 0x508c52
mov dword [ebp - 0xc30], 1
cmp dword [ebp - 0xc30], 0
jne 0x508c69
mov ecx, dword [ebp - 0x18ac]
mov dword [ebp - 0x3c4], ecx
jmp 0x508c7a
jmp 0x508a53
mov edx, dword [ebp - 0x6fc]
mov dword [ebp - 0x3c4], edx
cmp dword [ebp - 0x3c4], 0
je 0x508d55
push ecx
push eax
add esp, 4
sub ecx, 0x1605f
pop ecx
push edx
sub edx, 0x1049e
and edx, 0xd7cd
pop edx
push edi
push esi
add esp, 4
and edi, 0xcbb2
or edi, 0x768c
or edi, 0xe8e8
pop edi
mov eax, dword [ebp - 0x3c4]
mov dword [ebp - 0x18b0], eax
push ebx
push edx
add esp, 4
sub ebx, 0x16e2b
xor ebx, 0x14a0c
add ebx, 0x74aa
or ebx, 0x4f03
pop ebx
push ecx
xor ecx, 0x15c9b
and ecx, 0x51eb
add ecx, 0xd013
pop ecx
mov ecx, dword [ebp - 0x18b0]
mov dword [ebp - 0x18b4], ecx
lea edx, [ebp - 0x1628]
push edx
call dword [ebp - 0x18b4]
test eax, eax
jne 0x508d55
push ecx
push edi
add esp, 4
or ecx, 0x9afd
add ecx, 0x133de
xor ecx, 0x95c
add ecx, 0x1a63
pop ecx
push eax
xor eax, 0x1117
xor eax, 0x9a6a
or eax, 0xc528
pop eax
mov dword [ebp - 0x738], 0
jmp 0x50943f