Function at 0x4eb140
Capabilities:
Create thread
Resolve function by parsing pe exports

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x5af008
push eax
mov dword fs:[0], esp
sub esp, 0x44
push ebx
push ebp
push esi
mov esi, ecx
xor ebp, ebp
push edi
mov dword [esi + 0x403c], ebp
mov dword [esi + 0x4038], ebp
mov dword [esi + 0x4034], ebp
mov dword [esi + 0x8048], ebp
mov dword [esi + 0x8044], ebp
mov dword [esi + 0x8040], ebp
mov edi, dword [sym.imp.KERNEL32.dll_CreateEventA]
push ebp
push ebp
push 1
push ebp
mov dword [esi + 0x8068], ebp
mov dword [esi + 0x806c], ebp
mov dword [esi + 0x8054], ebp
mov dword [esi + 0x8058], ebp
mov dword [esi + 0x28], 0xffffffff
call edi
cmp eax, ebp
mov dword [esi + 0x805c], eax
jne 0x4eb1c4
mov eax, 1
jmp 0x4eb4c3
push ebp
push ebp
push 1
push ebp
call edi
cmp eax, ebp
mov dword [esi + 0x8070], eax
jne 0x4eb1e6
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, 2
jmp 0x4eb4c3
mov eax, dword [0x614cb0]
mov dword [esp + 0x10], eax
mov eax, dword [esp + 0x64]
mov dword [esp + 0x5c], ebp
cmp eax, 0xa
push eax
jge 0x4eb209
lea ecx, [esp + 0x14]
push str.COM_i
push ecx
jmp 0x4eb213
lea edx, [esp + 0x14]
push str..COM_i
push edx
call fcn.0056d732
mov edi, dword [sym.imp.KERNEL32.dll_CreateFileA]
add esp, 0xc
mov dword [esp + 0x18], 0xc
mov dword [esp + 0x1c], ebp
mov dword [esp + 0x20], 1
xor ebx, ebx
mov ecx, dword [esp + 0x10]
push ebp
push 0x40000080
lea eax, [esp + 0x20]
push 3
push eax
push ebp
push 0xc0000000
push ecx
call edi
cmp eax, 0xffffffff
mov dword [esi + 0x24], eax
jne 0x4eb267
push 0x64
call dword [sym.imp.KERNEL32.dll_Sleep]
inc ebx
cmp ebx, 0x1e
jl 0x4eb237
cmp ebx, 0x1e
jne 0x4eb287
lea ecx, [esp + 0x10]
mov dword [esp + 0x5c], 0xffffffff
call fcn.00575ae8
mov eax, 3
jmp 0x4eb4c3
mov edx, dword [esi + 0x24]
mov edi, 1
push edi
push edx
call dword [sym.imp.KERNEL32.dll_SetCommMask]
mov eax, dword [esi + 0x24]
push 0x1000
push 0x1000
push eax
call dword [sym.imp.KERNEL32.dll_SetupComm]
mov ecx, dword [esi + 0x24]
push 0xf
push ecx
call dword [sym.imp.KERNEL32.dll_PurgeComm]
mov eax, 0x3e8
lea edx, [esp + 0x24]
mov dword [esp + 0x2c], eax
mov dword [esp + 0x34], eax
mov eax, dword [esi + 0x24]
push edx
push eax
mov dword [esp + 0x2c], 0xffffffff
mov dword [esp + 0x30], edi
mov dword [esp + 0x38], edi
call dword [sym.imp.KERNEL32.dll_SetCommTimeouts]
mov edx, dword [esi + 0x24]
lea ecx, [esp + 0x38]
push ecx
push edx
mov dword [esp + 0x40], 0x1c
call dword [sym.imp.KERNEL32.dll_GetCommState]
mov eax, dword [esp + 0x68]
mov cl, byte [esp + 0x6c]
mov dl, byte [esp + 0x70]
mov dword [esp + 0x3c], eax
mov al, byte [esp + 0x74]
mov byte [esp + 0x4a], cl
mov ecx, dword [esp + 0x78]
mov byte [esp + 0x4c], al
mov eax, dword [esp + 0x40]
mov byte [esp + 0x4b], dl
and al, 0xf7
cmp ecx, 2
jne 0x4eb32f
and al, 0xef
or al, 0x20
jmp 0x4eb33b
cmp ecx, edi
jne 0x4eb339
and al, 0xdf
or al, 0x10
jmp 0x4eb33b
and al, 0xcf
mov ebp, dword [esp + 0x7c]
xor ecx, ecx
cmp ebp, 2
sete cl
and ecx, 1
and al, 0xfb
shl ecx, 2
or ecx, eax
cmp ebp, 1
jne 0x4eb35e
and ch, 0xdf
or ch, 0x10
jmp 0x4eb36e
cmp ebp, 2
jne 0x4eb36b
and ch, 0xef
or ch, 0x20
jmp 0x4eb36e
and ch, 0xcf
mov edi, dword [esp + 0x80]
mov edx, dword [esi + 0x24]
test edi, edi
setne al
and eax, 1
and ch, 0xfe
shl eax, 8
or eax, ecx
mov byte [esp + 0x4d], 0x11
mov ecx, eax
and eax, 0x100
shl eax, 1
and ch, 0xfd
mov byte [esp + 0x4e], 0x13
or eax, ecx
mov ecx, 0x64
mov word [esp + 0x46], cx
mov word [esp + 0x48], cx
and al, 0xfd
lea ecx, [esp + 0x38]
or al, 1
push ecx
push edx
mov dword [esp + 0x48], eax
call dword [sym.imp.KERNEL32.dll_SetCommState]
test eax, eax
je 0x4eb4a3
mov ebx, dword [sym.imp.KERNEL32.dll_CreateThread]
lea eax, [esp + 0x14]
push eax
push 0
push esi
push 0x4ebb10
push 0
push 0
call ebx
lea ecx, [esp + 0x14]
mov dword [esi + 0x30], eax
push ecx
push 0
push esi
push 0x4eb910
push 0
push 0
call ebx
test eax, eax
mov dword [esi + 0x2c], eax
jne 0x4eb426
mov edx, dword [esi + 0x24]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea ecx, [esp + 0x10]
mov dword [esp + 0x5c], 0xffffffff
call fcn.00575ae8
mov eax, 4
jmp 0x4eb4c3
test byte [esp + 0x40], 0x30
je 0x4eb435
mov eax, dword [esi + 0x24]
push 5
push eax
jmp 0x4eb43b
mov ecx, dword [esi + 0x24]
push 6
push ecx
mov ebx, dword [sym.imp.KERNEL32.dll_EscapeCommFunction]
call ebx
mov eax, dword [esp + 0x40]
test ah, 0x30
je 0x4eb454
mov edx, dword [esi + 0x24]
push 3
push edx
jmp 0x4eb45a
mov eax, dword [esi + 0x24]
push 4
push eax
call ebx
mov ecx, dword [esp + 0x68]
mov eax, dword [esp + 0x64]
mov edx, dword [esp + 0x6c]
mov dword [esi + 4], ecx
mov ecx, dword [esp + 0x74]
mov dword [esi + 0x28], eax
mov dword [esi], eax
mov eax, dword [esp + 0x70]
mov dword [esi + 8], edx
mov edx, dword [esp + 0x78]
mov dword [esi + 0x10], ecx
lea ecx, [esp + 0x10]
mov dword [esi + 0xc], eax
mov dword [esi + 0x14], edx
mov dword [esi + 0x18], ebp
mov dword [esi + 0x1c], edi
mov dword [esp + 0x5c], 0xffffffff
call fcn.00575ae8
xor eax, eax
jmp 0x4eb4c3
mov eax, dword [esi + 0x24]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea ecx, [esp + 0x10]
mov dword [esp + 0x5c], 0xffffffff
call fcn.00575ae8
mov eax, 5
mov ecx, dword [esp + 0x54]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x50
ret 0x20