Function at 0x403ae0
Capabilities:
Receive data
Receive data on socket
Send data
Send data on socket
Send http request
Terminate process

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xfc
push ebx
push esi
mov esi, ecx
mov dword [ebp - 4], 0x4000
push edi
mov eax, dword [esi + 0x402c]
lea edi, [esi + 4]
test eax, eax
jne 0x403bbd
push eax
push 0x4000
push edi
push dword [esi]
call dword [sym.imp.WS2_32.dll_recv]
mov dword [esi + 0x402c], eax
test eax, eax
jne 0x403bbd
push dword [esi]
call dword [sym.imp.WS2_32.dll_closesocket]
push 0x4000
push 0
push edi
mov dword [esi], 0
mov dword [esi + 0x4004], 0
call fcn.00409220
add esp, 0xc
mov dword [esi + 0x402c], 0
lea eax, [ebp - 8]
mov byte [0x438d81], 0
mov byte [0x43d404], 0
push eax
push 0x3e8
push 0
push 0
push 0xff
push dword [0x438fa4]
push 0xffff
call dword [sym.imp.USER32.dll_SendMessageTimeoutA]
push str.recv_failed
mov byte [0x437a50], 0
call fcn.0040ff1a
add esp, 4
push str.recv_failed
push 0x4390c8
call fcn.00401180
add esp, 8
mov ecx, 0x4390c8
call fcn.00403950
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
cmp eax, 0x4000
jle 0x403bdb
push 0x90
push str.D:AkhilWebSocketFPEventServer_server.cpp
push str.client__readedLength___BUF_LEN
call fcn.00410aa6
add esp, 0xc
mov eax, dword [esi + 0x4004]
cmp eax, 3
ja case.default.0x403bf0
mov ebx, dword [sym.imp.WS2_32.dll_closesocket]
jmp dword [eax*4 + 0x404198]
lea eax, [ebp - 4]
mov edx, edi
push eax
push dword [esi + 0x402c]
lea ecx, [ebp - 0xf8]
call fcn.00405610
add esp, 8
cmp dword [ebp - 0x50], 0xf3
je 0x403ccb
mov eax, dword [esi]
push 0
push dword [ebp - 4]
mov dword [ebp - 8], eax
push edi
push eax
call dword [sym.imp.WS2_32.dll_send]
mov ebx, dword [sym.imp.WS2_32.dll_closesocket]
cmp eax, 0xffffffff
jne 0x403c47
push dword [ebp - 8]
call ebx
push str.send_failed
jmp 0x403c56
cmp eax, dword [ebp - 4]
je 0x403c5e
push dword [ebp - 8]
call ebx
push str.written_not_all_bytes
call fcn.0040ff1a
add esp, 4
push dword [esi]
call ebx
push 0x4000
push 0
push edi
mov dword [esi], 0
mov dword [esi + 0x4004], 0
call fcn.00409220
add esp, 0xc
mov dword [esi + 0x402c], 0
lea eax, [ebp - 8]
mov byte [0x438d81], 0
mov byte [0x43d404], 0
push eax
push 0x3e8
push 0
push 0
push 0xff
push dword [0x438fa4]
push 0xffff
call dword [sym.imp.USER32.dll_SendMessageTimeoutA]
mov byte [0x437a50], 0
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, str._fpeventserver
lea eax, [ebp - 0xf4]
mov dl, byte [eax]
cmp dl, byte [ecx]
jne 0x403cf6
test dl, dl
je 0x403cf2
mov dl, byte [eax + 1]
cmp dl, byte [ecx + 1]
jne 0x403cf6
add eax, 2
add ecx, 2
test dl, dl
jne 0x403cd6
xor eax, eax
jmp 0x403cfb
sbb eax, eax
or eax, 1
test eax, eax
je 0x403d5a
push str.HTTP_1.1_404_Not_Found_r_n_r_n
push edi
call fcn.00401180
mov ebx, dword [esi]
add esp, 8
mov dword [ebp - 8], eax
push 0
push eax
push edi
push ebx
call dword [sym.imp.WS2_32.dll_send]
cmp eax, 0xffffffff
jne 0x403d30
push ebx
call dword [sym.imp.WS2_32.dll_closesocket]
push str.send_failed
jmp 0x403d41
cmp eax, dword [ebp - 8]
je 0x403d49
push ebx
call dword [sym.imp.WS2_32.dll_closesocket]
push str.written_not_all_bytes
call fcn.0040ff1a
add esp, 4
mov dword [esi + 0x4004], 2
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov ebx, dword [esi]
push 0
push dword [ebp - 4]
push edi
push ebx
call dword [sym.imp.WS2_32.dll_send]
cmp eax, 0xffffffff
jne 0x403d89
push ebx
call dword [sym.imp.WS2_32.dll_closesocket]
push str.send_failed
call fcn.0040ff1a
add esp, 4
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
cmp eax, dword [ebp - 4]
je 0x403da9
push ebx
call dword [sym.imp.WS2_32.dll_closesocket]
push str.written_not_all_bytes
call fcn.0040ff1a
add esp, 4
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
pop edi
mov dword [esi + 0x4004], 1
mov dword [esi + 0x402c], 0
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push dword [esi + 0x402c]
lea ecx, [esi + 0x4008]
mov edx, edi
call fcn.00405160
add esp, 4
push dword [esi + 0x4020]
push str.received_fr.type_0x_X_n
call fcn.00403aa0
push dword [esi + 0x4020]
push str.received_fr.type_0x_X
push 0x4390c8
call fcn.00401180
add esp, 0x14
mov ecx, 0x4390c8
call fcn.00403950
mov eax, dword [esi + 0x4020]
cmp eax, 0xf1
jne 0x403e52
push str.Error_or_reserved_frame_received...
call fcn.00403aa0
add esp, 4
push str.Error_or_reserved_frame_received...
push 0x4390c8
call fcn.00401180
add esp, 8
mov ecx, 0x4390c8
call fcn.00403950
mov eax, dword [esi + 0x4020]
mov dword [esi + 0x402c], 0
cmp eax, 1
jne 0x403f5e
mov ecx, dword [esi + 0x4018]
mov eax, dword [esi + 0x4010]
mov byte [ecx + eax], 0
push dword [esi + 0x4010]
push str.Payload__s_n
call fcn.00403aa0
push dword [esi + 0x4010]
push str.Payload__s
push 0x4390c8
call fcn.00401180
add esp, 0x14
mov ecx, 0x4390c8
call fcn.00403950
push dword [esi + 0x401c]
push dword [esi + 0x4018]
push dword [esi + 0x4010]
push str.make_frame__s_len__lu__n
call fcn.00403aa0
push dword [esi + 0x401c]
push dword [esi + 0x4018]
push dword [esi + 0x4010]
push str.make_frame__s_len__lu
push 0x4390c8
call fcn.00401180
add esp, 0x24
mov ecx, 0x4390c8
call fcn.00403950
mov edx, dword [esi + 0x4010]
mov ecx, edx
lea ebx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x403ef2
sub ecx, ebx
mov dword [ebp - 0x40], edx
lea eax, [ebp - 4]
mov dword [ebp - 0x38], ecx
push eax
mov edx, edi
mov dword [ebp - 0x34], 0
lea ecx, [ebp - 0x48]
mov dword [ebp - 0x30], 1
call fcn.00405080
mov ebx, dword [esi]
add esp, 4
push 0
push dword [ebp - 4]
push edi
push ebx
call dword [sym.imp.WS2_32.dll_send]
cmp eax, 0xffffffff
jne 0x403f45
push ebx
call dword [sym.imp.WS2_32.dll_closesocket]
mov eax, str.send_failed
jmp 0x40415e
cmp eax, dword [ebp - 4]
jne 0x404152
mov eax, dword [esi + 0x4020]
mov dword [esi + 0x402c], 0
cmp eax, 2
jne 0x403fc4
xor ebx, ebx
cmp dword [esi + 0x401c], ebx
jb 0x403fad
ja 0x403f80
cmp dword [esi + 0x4018], ebx
jbe 0x403fad
nop word [eax + eax]
mov eax, dword [esi + 0x4010]
movzx eax, byte [ebx + eax]
push eax
push str._0x_x
call fcn.00403aa0
xor eax, eax
add esp, 8
inc ebx
cmp eax, dword [esi + 0x401c]
jb 0x403f80
ja 0x403fad
cmp ebx, dword [esi + 0x4018]
jb 0x403f80
push 0x433aa0
call fcn.00403aa0
add esp, 4
mov dword [esi + 0x402c], 0
cmp dword [esi + 0x4020], 8
jne 0x403cc4
push str.Close_frame__n
mov dword [esi + 0x4004], 2
call fcn.00403aa0
add esp, 4
push str.Close_frame_
push 0x4390c8
call fcn.00401180
mov ecx, 0x4390c8
call fcn.00403950
lea eax, [ebp - 4]
mov dword [ebp - 0x20], 0
xorps xmm0, xmm0
mov dword [ebp - 0x10], 8
push eax
mov edx, edi
movlpd qword [ebp - 0x18], xmm0
lea ecx, [ebp - 0x28]
call fcn.00405080
mov eax, dword [esi]
add esp, 0xc
mov dword [ebp - 8], eax
push 0
push dword [ebp - 4]
push edi
push eax
call dword [sym.imp.WS2_32.dll_send]
mov ebx, dword [sym.imp.WS2_32.dll_closesocket]
cmp eax, 0xffffffff
jne 0x404051
push dword [ebp - 8]
call ebx
push str.send_failed
jmp 0x404060
cmp eax, dword [ebp - 4]
je 0x404068
push dword [ebp - 8]
call ebx
push str.written_not_all_bytes
call fcn.0040ff1a
add esp, 4
push str.Frame_closed_n
call fcn.00403aa0
add esp, 4
push str.Frame_closed
push 0x4390c8
call fcn.00401180
add esp, 8
mov ecx, 0x4390c8
call fcn.00403950
jmp 0x403c5e
push str.Close_frame__n
call fcn.00403aa0
add esp, 4
push str.case_CLOSING:Close_frame_
push 0x4390c8
call fcn.00401180
mov ecx, 0x4390c8
call fcn.00403950
lea eax, [ebp - 4]
mov dword [ebp - 0x20], 0
xorps xmm0, xmm0
mov dword [ebp - 0x10], 8
push eax
mov edx, edi
movlpd qword [ebp - 0x18], xmm0
lea ecx, [ebp - 0x28]
call fcn.00405080
mov eax, dword [esi]
add esp, 0xc
mov dword [ebp - 8], eax
push 0
push dword [ebp - 4]
push edi
push eax
call dword [sym.imp.WS2_32.dll_send]
cmp eax, 0xffffffff
jne 0x404106
push dword [ebp - 8]
call ebx
push str.send_failed
jmp 0x404115
cmp eax, dword [ebp - 4]
je 0x40411d
push dword [ebp - 8]
call ebx
push str.written_not_all_bytes
call fcn.0040ff1a
add esp, 4
mov dword [esi + 0x4004], 3
push str.Frame_closed_n
call fcn.00403aa0
add esp, 4
push str.case_CLOSED:case_CLOSING:Frame_closed
jmp 0x40407a
push str.Unknown_state_
call fcn.00403aa0
add esp, 4
push str.Unknown_state_
jmp 0x404179
push ebx
call dword [sym.imp.WS2_32.dll_closesocket]
mov eax, str.written_not_all_bytes
push eax
call fcn.0040ff1a
add esp, 4
push str.send
call fcn.0040ff1a
add esp, 4
push str.send_error
push 0x4390c8
call fcn.00401180
add esp, 8
mov ecx, 0x4390c8
call fcn.00403950
push 0xffffffffffffffff
call fcn.0040fd26
nop
idiv dword [ebx]
inc eax
add ah, al
cmp eax, 0x40960040
inc eax
add byte [edi], ah
inc ecx
inc eax
add ah, cl
int3