Function at 0x402bda
Capabilities:
Read and send data from client to server
Read file on windows
Send data
Send data on socket
Send http request

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x958
lea rbp, [rsp + 0x80]
mov qword [rbp + 0x900], rcx
mov qword [rbp + 0x908], rdx
mov qword [rbp + 0x910], r8
mov dword [rbp + 0x8b8], 0
mov dword [rbp + 0x8cc], 0
mov dword [rbp + 0x8b4], 0
mov dword [rbp + 0x8b0], 0
mov dword [rbp + 0x8c8], 0
mov dword [rbp + 0x8ac], 0
lea rdx, [rbp + 0x3c0]
mov eax, 0
mov ecx, 0x40
mov rdi, rdx
rep stosq qword [rdi], rax
lea rax, [rbp + 0x82c]
mov rcx, rax
call fcn.00449570
mov rax, qword [rbp + 0x900]
lea rdx, [rax + 0x408]
lea rcx, [rbp + 0x82c]
lea rax, [rbp + 0x820]
mov r8, rcx
mov rcx, rax
call sym.std::basic_string_char__std::char_traits_char___std::allocator_char___::basic_string_char_const__std::allocator_char__const_
lea rax, [rbp + 0x82c]
mov rcx, rax
call sym.std::allocator_char_::allocator__
lea rax, [rbp + 0x810]
lea rdx, [rbp + 0x820]
mov r8, rdx
lea rdx, str.._www_
mov rcx, rax
call method.std::basic_string_char__std::char_traits_char___std::allocator_char____std::operator_char__std::char_traits_char___std.allocator_char____char_const__std::basic_string_char__std::char_traits_char___std::allocator_char____const_
lea rax, [rbp + 0x800]
lea rdx, [rbp + 0x810]
lea r8, str.index.html
mov rcx, rax
call method.std::basic_string_char__std::char_traits_char___std::allocator_char____std::operator_char__std::char_traits_char___std.allocator_char____std::basic_string_char__std::char_traits_char___std::allocator_char____const__char_const_
lea rax, [rbp + 0x82d]
mov rcx, rax
call fcn.00449570
lea rdx, [rbp + 0x82d]
lea rax, [rbp + 0x7f0]
mov r8, rdx
lea rdx, [0x0048e019]
mov rcx, rax
call sym.std::basic_string_char__std::char_traits_char___std::allocator_char___::basic_string_char_const__std::allocator_char__const_
lea rax, [rbp + 0x82d]
mov rcx, rax
call sym.std::allocator_char_::allocator__
lea rax, [rbp + 0x82e]
mov rcx, rax
call fcn.00449570
lea rdx, [rbp + 0x82e]
lea rax, [rbp + 0x7e0]
mov r8, rdx
lea rdx, [0x0048e019]
mov rcx, rax
call sym.std::basic_string_char__std::char_traits_char___std::allocator_char___::basic_string_char_const__std::allocator_char__const_
lea rax, [rbp + 0x82e]
mov rcx, rax
call sym.std::allocator_char_::allocator__
lea rax, [rbp + 0x82f]
mov rcx, rax
call fcn.00449570
lea rdx, [rbp + 0x82f]
lea rax, [rbp + 0x7d0]
mov r8, rdx
lea rdx, str.200_OK
mov rcx, rax
call sym.std::basic_string_char__std::char_traits_char___std::allocator_char___::basic_string_char_const__std::allocator_char__const_
lea rax, [rbp + 0x82f]
mov rcx, rax
call sym.std::allocator_char_::allocator__
lea rax, [rbp + 0x820]
lea rdx, [0x0048e019]
mov rcx, rax
call method.bool_std::operator_char__std::char_traits_char___std.allocator_char____std::basic_string_char__std::char_traits_char___std::allocator_char____const__char_const_
test al, al
je 0x402ded
lea rax, [rbp + 0x830]
lea rdx, [rbp + 0x810]
lea r8, str._index.html
mov rcx, rax
call method.std::basic_string_char__std::char_traits_char___std::allocator_char____std::operator_char__std::char_traits_char___std.allocator_char____std::basic_string_char__std::char_traits_char___std::allocator_char____const__char_const_
lea rdx, [rbp + 0x830]
lea rax, [rbp + 0x800]
mov rcx, rax
call method.std::string.operator_std::string_
lea rax, [rbp + 0x830]
mov rcx, rax
call fcn.00452c00
lea rdx, str.GET__
mov rcx, qword [0x00492ad0]
call method.std::basic_ostream_char__std::char_traits_char____std::operator____std.char_traits_char____std::basic_ostream_char__std::char_traits_char_____char_const_
mov rcx, rax
lea rax, [rbp + 0x820]
mov rdx, rax
call method.std::basic_ostream_char__std::char_traits_char____std::operator____char__std::char_traits_char___std.allocator_char____std::basic_ostream_char__std::char_traits_char_____std::basic_string_char__std::char_traits_char___std::allocator_char____const
mov rdx, qword [method.std::basic_ostream_char__std::char_traits_char____std::endl_char__std.char_traits_char____std::basic_ostream_char__std::char_traits_char____]
mov rcx, rax
call method.std::ostream.operator___std::ostream____std::ostream__
lea rax, str.HTTP_1.1__s_r_nDate:__s_r_nServer:_WMWebServer__s_r_nAccept_Ranges:_bytes_r_nContent_Length:__d_r_nConnection:_close_r_nContent_Type:__s_r_n_r_n
mov qword [rbp + 0x8a0], rax
lea rax, [rbp + 0x7c0]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_GetLocalTime]
call rax
mov qword [rbp - 0x30], 0
mov qword [rbp - 0x28], 0
mov qword [rbp - 0x20], 0
mov qword [rbp - 0x18], 0
mov qword [rbp - 0x10], 0
movzx eax, word [rbp + 0x7c4]
movzx r11d, ax
movzx eax, word [rbp + 0x7ce]
movzx r10d, ax
movzx eax, word [rbp + 0x7cc]
movzx r9d, ax
movzx eax, word [rbp + 0x7ca]
movzx r8d, ax
movzx eax, word [rbp + 0x7c8]
movzx ecx, ax
movzx eax, word [rbp + 0x7c6]
movzx edx, ax
movzx eax, word [rbp + 0x7c2]
movzx esi, ax
movzx eax, word [rbp + 0x7c0]
movzx ebx, ax
lea rax, [rbp - 0x30]
mov dword [rsp + 0x48], r11d
mov dword [rsp + 0x40], r10d
mov dword [rsp + 0x38], r9d
mov dword [rsp + 0x30], r8d
mov dword [rsp + 0x28], ecx
mov dword [rsp + 0x20], edx
mov r9d, esi
mov r8d, ebx
lea rdx, str._4d__02d__02d__02d:_02d:_02d._03d
mov rcx, rax
call sym.sprintf
lea rdx, [rbp + 0x810]
mov rax, rbp
mov r8d, 4
mov rcx, rax
call sym.std::basic_ifstream_char__std::char_traits_char___::basic_ifstream_std::string_const__std::_Ios_Openmode_
lea rdx, [rbp + 0x800]
lea rax, [rbp + 0x1e0]
mov r8d, 4
mov rcx, rax
call sym.std::basic_ifstream_char__std::char_traits_char___::basic_ifstream_std::string_const__std::_Ios_Openmode_
mov rax, rbp
add rax, 0xd0
mov rcx, rax
call method.std::basic_ios_char__std::char_traits_char___.operator____const
test al, al
je 0x4030f3
lea rax, [rbp + 0x1e0]
add rax, 0xd0
mov rcx, rax
call method.std::basic_ios_char__std::char_traits_char___.operator____const
test al, al
je 0x40305b
lea rax, [rbp + 0x820]
lea rdx, [0x0048e019]
mov rcx, rax
call method.bool_std::operator_char__std::char_traits_char___std.allocator_char____std::basic_string_char__std::char_traits_char___std::allocator_char____const__char_const_
test al, al
je 0x40304b
lea rax, [rbp + 0x7d0]
lea rdx, str.200_OK
mov rcx, rax
call fcn.00452c80
mov dword [rbp + 0x8c8], 1
lea rax, [rbp + 0x7e0]
lea rdx, str.text_html
mov rcx, rax
call fcn.00452c80
lea rax, [rbp + 0x7f0]
lea rdx, str.Welcome_to_WMWebServer_
mov rcx, rax
call fcn.00452c80
lea rax, [rbp + 0x840]
lea rdx, [rbp + 0x7f0]
lea r8, [0x0048e13d]
mov rcx, rax
call method.std::basic_string_char__std::char_traits_char___std::allocator_char____std::operator_char__std::char_traits_char___std.allocator_char____std::basic_string_char__std::char_traits_char___std::allocator_char____const__char_const_
lea rdx, [rbp + 0x840]
lea rax, [rbp + 0x7f0]
mov rcx, rax
call method.std::string.operator_std::string_
lea rax, [rbp + 0x840]
mov rcx, rax
call fcn.00452c00
lea rax, [rbp + 0x850]
lea rdx, [rbp + 0x7f0]
lea r8, [0x0048e148]
mov rcx, rax
call method.std::basic_string_char__std::char_traits_char___std::allocator_char____std::operator_char__std::char_traits_char___std.allocator_char____std::basic_string_char__std::char_traits_char___std::allocator_char____const__char_const_
lea rdx, [rbp + 0x850]
lea rax, [rbp + 0x7f0]
mov rcx, rax
call method.std::string.operator_std::string_
lea rax, [rbp + 0x850]
mov rcx, rax
call fcn.00452c00
mov qword [rbp + 0x8c0], 0
jmp 0x403155
lea rax, [rbp + 0x7d0]
lea rdx, str.200_OK
mov rcx, rax
call fcn.00452c80
lea rax, [rbp + 0x7e0]
lea rdx, str.text_html
mov rcx, rax
call fcn.00452c80
lea rax, [rbp + 0x800]
mov rcx, rax
call method.std::string.data___const
lea rdx, [0x0048e14b]
mov rcx, rax
call sym.fopen
mov qword [rbp + 0x8c0], rax
lea rax, [rbp + 0x1e0]
mov r8d, 2
mov edx, 0
mov rcx, rax
call method.std::istream.seekg_long_long__std::_Ios_Seekdir_
lea rax, [rbp + 0x860]
lea rdx, [rbp + 0x1e0]
mov rcx, rax
call method.std::istream.tellg__
lea rax, [rbp + 0x860]
mov rcx, rax
call method.std::fpos_int_.operator_long_long___const
mov dword [rbp + 0x8cc], eax
jmp 0x403155
lea rax, [rbp + 0x810]
mov rcx, rax
call method.std::string.data___const
lea rdx, [0x0048e14b]
mov rcx, rax
call sym.fopen
mov qword [rbp + 0x8c0], rax
mov rax, rbp
mov r8d, 2
mov edx, 0
mov rcx, rax
call method.std::istream.seekg_long_long__std::_Ios_Seekdir_
lea rax, [rbp + 0x870]
mov rdx, rbp
mov rcx, rax
call method.std::istream.tellg__
lea rax, [rbp + 0x870]
mov rcx, rax
call method.std::fpos_int_.operator_long_long___const
mov dword [rbp + 0x8cc], eax
lea rax, [rbp + 0x820]
lea rdx, [0x0048e019]
mov rcx, rax
call method.bool_std::operator__char__std::char_traits_char___std.allocator_char____std::basic_string_char__std::char_traits_char___std::allocator_char____const__char_const_
test al, al
je 0x403180
cmp qword [rbp + 0x8c0], 0
jne 0x403180
mov eax, 1
jmp 0x403185
mov eax, 0
test al, al
je 0x40325d
lea rax, [rbp + 0x7d0]
lea rdx, str.404_Not_Found
mov rcx, rax
call fcn.00452c80
mov dword [rbp + 0x8c8], 1
lea rax, [rbp + 0x7e0]
lea rdx, str.text_html
mov rcx, rax
call fcn.00452c80
lea rax, [rbp + 0x7f0]
lea rdx, str._html__head__title_404_Not_Found__title___head__body__center__h1_404_Not_Found__h1___center__hr__center_WMWebServer_
mov rcx, rax
call fcn.00452c80
lea rax, [rbp + 0x880]
lea rdx, [rbp + 0x7f0]
lea r8, [0x0048e13d]
mov rcx, rax
call method.std::basic_string_char__std::char_traits_char___std::allocator_char____std::operator_char__std::char_traits_char___std.allocator_char____std::basic_string_char__std::char_traits_char___std::allocator_char____const__char_const_
lea rdx, [rbp + 0x880]
lea rax, [rbp + 0x7f0]
mov rcx, rax
call method.std::string.operator_std::string_
lea rax, [rbp + 0x880]
mov rcx, rax
call fcn.00452c00
lea rax, [rbp + 0x890]
lea rdx, [rbp + 0x7f0]
lea r8, str.__center___body___html_
mov rcx, rax
call method.std::basic_string_char__std::char_traits_char___std::allocator_char____std::operator_char__std::char_traits_char___std.allocator_char____std::basic_string_char__std::char_traits_char___std::allocator_char____const__char_const_
lea rdx, [rbp + 0x890]
lea rax, [rbp + 0x7f0]
mov rcx, rax
call method.std::string.operator_std::string_
lea rax, [rbp + 0x890]
mov rcx, rax
call fcn.00452c00
lea rax, [rbp + 0x7e0]
lea rdx, [0x0048e019]
mov rcx, rax
call method.bool_std::operator_char__std::char_traits_char___std.allocator_char____std::basic_string_char__std::char_traits_char___std::allocator_char____const__char_const_
test al, al
je 0x403320
mov dword [rbp + 0x8bc], 0
jmp 0x4032e7
mov eax, dword [rbp + 0x8bc]
cdqe
shl rax, 4
mov rdx, rax
lea rax, [0x004ae040]
lea rcx, [rdx + rax]
mov rax, qword [rbp + 0x910]
mov rdx, rax
call method.__gnu_cxx::__enable_if_std::__is_char_char_::__value__bool_::__type_std.operator_char__std::basic_string_char__std::char_traits_char___std::allocator_char____const__std::basic_string_char__std::char_traits_char___std::allocator_char____const_
test al, al
je 0x4032e0
mov eax, dword [rbp + 0x8bc]
cdqe
shl rax, 4
mov rdx, rax
lea rax, [0x004ae040]
add rax, rdx
lea rdx, [rax + 8]
lea rax, [rbp + 0x7e0]
mov rcx, rax
call method.std::string.operator_std::string_const_
add dword [rbp + 0x8bc], 1
cmp dword [rbp + 0x8bc], 8
jle 0x403287
lea rax, [rbp + 0x7e0]
lea rdx, [0x0048e019]
mov rcx, rax
call method.bool_std::operator_char__std::char_traits_char___std.allocator_char____std::basic_string_char__std::char_traits_char___std::allocator_char____const__char_const_
test al, al
je 0x403320
mov rdx, qword [rbp + 0x910]
lea rax, [rbp + 0x7e0]
mov rcx, rax
call method.std::string.operator_std::string_const_
cmp dword [rbp + 0x8cc], 0
jne 0x403353
cmp dword [rbp + 0x8c8], 1
jne 0x403349
lea rax, [rbp + 0x7f0]
mov rcx, rax
call method.std::string.length___const
mov dword [rbp + 0x8cc], eax
jmp 0x403353
mov dword [rbp + 0x8cc], 0xffffffff
lea rdx, [rbp + 0x5c0]
mov eax, 0
mov ecx, 0x40
mov rdi, rdx
rep stosq qword [rdi], rax
lea rax, [rbp + 0x7e0]
mov rcx, rax
call method.std::string.data___const
mov rbx, rax
lea rax, [rbp + 0x7d0]
mov rcx, rax
call method.std::string.data___const
mov r10, rax
lea r8, [rbp - 0x30]
mov rdx, qword [rbp + 0x8a0]
lea rax, [rbp + 0x5c0]
mov qword [rsp + 0x30], rbx
mov ecx, dword [rbp + 0x8cc]
mov dword [rsp + 0x28], ecx
lea rcx, [0x0048e13d]
mov qword [rsp + 0x20], rcx
mov r9, r8
mov r8, r10
mov rcx, rax
call sym.sprintf
mov dword [rbp + 0x8b8], eax
mov ecx, dword [rbp + 0x8b8]
lea rdx, [rbp + 0x5c0]
mov rax, qword [rbp + 0x908]
mov r9d, 0
mov r8d, ecx
mov rcx, rax
mov rax, qword [sym.imp.WS2_32.dll_send]
call rax
mov dword [rbp + 0x8b4], eax
cmp dword [rbp + 0x8b4], 0xffffffff
jne 0x403432
mov rax, qword [rbp + 0x8c0]
mov rcx, rax
call sym.fclose
mov rax, qword [sym.imp.WS2_32.dll_WSAGetLastError]
call rax
mov edx, eax
lea rcx, str._WebService__Fail_to_send__error__d_n
call sym.printf
jmp 0x40357f
cmp dword [rbp + 0x8c8], 1
jne 0x403477
lea rax, [rbp + 0x7f0]
mov rcx, rax
call method.std::string.data___const
mov rcx, rax
mov edx, dword [rbp + 0x8cc]
mov rax, qword [rbp + 0x908]
mov r9d, 0
mov r8d, edx
mov rdx, rcx
mov rcx, rax
mov rax, qword [sym.imp.WS2_32.dll_send]
call rax
jmp 0x40353b
cmp dword [rbp + 0x8c8], 0
jne 0x403515
mov rdx, qword [rbp + 0x8c0]
lea rax, [rbp + 0x3c0]
mov r9, rdx
mov r8d, 0x200
mov edx, 1
mov rcx, rax
call sym.fread
mov dword [rbp + 0x8b0], eax
cmp dword [rbp + 0x8b0], 0
jle 0x4034f2
mov ecx, dword [rbp + 0x8b0]
lea rdx, [rbp + 0x3c0]
mov rax, qword [rbp + 0x908]
mov r9d, 0
mov r8d, ecx
mov rcx, rax
mov rax, qword [sym.imp.WS2_32.dll_send]
call rax
mov dword [rbp + 0x8b4], eax
mov eax, dword [rbp + 0x8b0]
sub dword [rbp + 0x8cc], eax
cmp dword [rbp + 0x8b0], 0
jle 0x403504
cmp dword [rbp + 0x8cc], 0
jg 0x403484
mov rax, qword [rbp + 0x8c0]
mov rcx, rax
call sym.fclose
jmp 0x40353b
mov rax, qword [rbp + 0x908]
mov r9d, 0
mov r8d, 0
lea rdx, [0x0048e019]
mov rcx, rax
mov rax, qword [sym.imp.WS2_32.dll_send]
call rax
lea rax, [rbp + 0x7d0]
mov rdx, rax
mov rcx, qword [0x00492ad0]
call method.std::basic_ostream_char__std::char_traits_char____std::operator____char__std::char_traits_char___std.allocator_char____std::basic_ostream_char__std::char_traits_char_____std::basic_string_char__std::char_traits_char___std::allocator_char____const
lea rdx, [0x0048e215]
mov rcx, rax
call method.std::basic_ostream_char__std::char_traits_char____std::operator____std.char_traits_char____std::basic_ostream_char__std::char_traits_char_____char_const_
mov rcx, rax
lea rax, [rbp - 0x30]
mov rdx, rax
call method.std::basic_ostream_char__std::char_traits_char____std::operator____std.char_traits_char____std::basic_ostream_char__std::char_traits_char_____char_const_
mov rdx, qword [method.std::basic_ostream_char__std::char_traits_char____std::endl_char__std.char_traits_char____std::basic_ostream_char__std::char_traits_char____]
mov rcx, rax
call method.std::ostream.operator___std::ostream____std::ostream__
nop
lea rax, [rbp + 0x1e0]
mov rcx, rax
call fcn.00460bd0
mov rax, rbp
mov rcx, rax
call fcn.00460bd0
lea rax, [rbp + 0x7d0]
mov rcx, rax
call fcn.00452c00
lea rax, [rbp + 0x7e0]
mov rcx, rax
call fcn.00452c00
lea rax, [rbp + 0x7f0]
mov rcx, rax
call fcn.00452c00
lea rax, [rbp + 0x800]
mov rcx, rax
call fcn.00452c00
lea rax, [rbp + 0x810]
mov rcx, rax
call fcn.00452c00
lea rax, [rbp + 0x820]
mov rcx, rax
call fcn.00452c00
jmp 0x403755
add rsp, 0x958
pop rbx
pop rsi
pop rdi
pop rbp
ret