Function at 0x412590
Capabilities:
Set socket configuration

Disassembly:
sub esp, 0xb8
mov al, byte [0x490df5]
push ebx
push ebp
xor ebp, ebp
test al, al
push esi
push edi
mov dword [esp + 0x20], ebp
mov dword [esp + 0x18], ebp
mov dword [esp + 0x14], ebp
mov dword [esp + 0x10], ebp
jne 0x412c2d
push 0x45e898
call fcn.00440b1c
add esp, 4
test eax, eax
jne 0x412c2d
mov al, byte [0x490df4]
test al, al
jne 0x4125ff
mov eax, dword [str.csl_com.c]
push 0x232
push eax
push 0x45e8a0
call fcn.0040c9a0
add esp, 0xc
pop edi
pop esi
pop ebp
mov eax, 0x445c1
pop ebx
add esp, 0xb8
ret
mov esi, dword [esp + 0xcc]
cmp esi, 0x3e8
ja 0x412637
mov ecx, dword [str.csl_com.c]
push 0x233
push ecx
push 0x45e8ac
call fcn.0040c9a0
add esp, 0xc
pop edi
pop esi
pop ebp
mov eax, 0x445c1
pop ebx
add esp, 0xb8
ret
mov eax, dword [esp + 0xd0]
cmp eax, ebp
jg 0x41266b
mov edx, dword [str.csl_com.c]
push 0x234
push edx
push 0x45e8c0
call fcn.0040c9a0
add esp, 0xc
pop edi
pop esi
pop ebp
mov eax, 0x445c1
pop ebx
add esp, 0xb8
ret
cmp dword [0x490db8], 2
jne 0x41267d
push eax
call fcn.00413520
add esp, 4
push esi
call fcn.00415b50
add esp, 4
test eax, eax
je 0x4126b2
mov eax, dword [str.csl_com.c]
push 0x23e
push eax
push str.csl_validate_name_func_name___0
call fcn.0040c940
add esp, 0xc
pop edi
pop esi
pop ebp
mov eax, 0x445c1
pop ebx
add esp, 0xb8
ret
mov eax, dword [0x490de0]
cmp eax, 1
jne 0x4126c0
mov bl, al
jmp 0x4126cd
cmp eax, ebp
mov eax, dword [0x490ddc]
sete bl
dec ebx
and ebx, eax
mov edi, 0x45e5c8
mov ecx, dword [edi]
push ecx
push esi
call fcn.00405d90
add esp, 8
test eax, eax
je 0x4126ef
add edi, 0xc
cmp edi, 0x45e610
jl 0x4126d2
jmp 0x4126f1
xor bl, bl
lea edx, [esp + 0x20]
push edx
push esi
call fcn.004056d0
mov edi, eax
add esp, 8
cmp edi, ebp
je 0x412725
mov eax, dword [str.csl_com.c]
push 0x24f
push eax
call fcn.0040ca80
add esp, 8
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xb8
ret
xor eax, eax
test bl, bl
mov ecx, 0x29
lea edi, [esp + 0x24]
rep stosd dword es:[edi], eax
je 0x4128f3
cmp esi, ebp
je 0x412769
or ecx, 0xffffffff
mov edi, esi
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp ecx, 0x8c
jle 0x412769
mov ecx, dword [str.csl_com.c]
push 0x256
push ecx
push str._int_STRLEN_func_name____int___int_sizeof_mess_hdr.n.enc.name__
call fcn.0040c9a0
add esp, 0xc
push 0x8c
lea edx, [esp + 0x30]
push esi
push edx
call fcn.00405750
lea eax, [esp + 0x38]
add esp, 0xc
test eax, eax
je 0x412794
or ecx, 0xffffffff
xor eax, eax
lea edi, [esp + 0x2c]
repne scasb al, byte es:[edi]
not ecx
dec ecx
jmp 0x412796
xor ecx, ecx
lea esi, [esp + ecx + 0x30]
push 4
and esi, 0xfffffffc
push 0x490bb8
push esi
call fcn.00406ea0
call fcn.00444136
mov dword [0x490bb8], eax
lea ecx, [esp + 0x1c]
push ecx
lea eax, [esp + 0x3c]
lea edx, [esp + 0x28]
sub esi, eax
push edx
add esi, 4
lea ecx, [esp + 0x40]
push esi
push ecx
call fcn.00411790
mov esi, eax
add esp, 0x1c
cmp esi, ebp
je 0x4127e5
push 0x25f
jmp 0x41288f
mov eax, dword [esp + 0x10]
cmp eax, 0x8c
mov dword [esp + 0x24], ebp
jle 0x41281c
mov eax, dword [str.csl_com.c]
push 0x264
push eax
push str.enc_len___sizeof_mess_hdr.n.enc.name_
call fcn.0040c9a0
add esp, 0xc
pop edi
pop esi
pop ebp
mov eax, 0x445c1
pop ebx
add esp, 0xb8
ret
mov ecx, dword [esp + 0x18]
push eax
push ecx
lea edx, [esp + 0x34]
push edx
call fcn.00406ea0
mov eax, dword [esp + 0x1c]
mov dword [esp + 0x34], eax
mov eax, dword [esp + 0x24]
add esp, 0xc
cmp eax, ebp
je 0x41285a
mov ecx, dword [str.csl_com.c]
push 0x268
push ecx
push 1
push eax
call sym.gateway.exe_gen__mem_free
add esp, 0x10
mov dword [esp + 0x18], ebp
mov edi, dword [esp + 0xd8]
cmp edi, ebp
jle 0x41293e
mov ecx, dword [esp + 0xd4]
lea edx, [esp + 0x10]
push edx
lea eax, [esp + 0x18]
push eax
push edi
push ecx
call fcn.00411790
mov esi, eax
add esp, 0x10
cmp esi, ebp
je 0x4128ab
push 0x26d
mov edx, dword [str.csl_com.c]
push edx
call fcn.0040ca80
add esp, 8
pop edi
mov eax, esi
pop esi
pop ebp
pop ebx
add esp, 0xb8
ret
mov eax, dword [esp + 0x10]
cmp eax, ebp
jg 0x4128eb
mov eax, dword [str.csl_com.c]
push 0x270
push eax
push str.enc_len___0
call fcn.0040c9a0
push edi
push str.buf_len_d
push 0x45e970
call fcn.00408960
add esp, 0x18
pop edi
pop esi
pop ebp
mov eax, 0x445c1
pop ebx
add esp, 0xb8
ret
mov ebp, dword [esp + 0x14]
mov edi, eax
jmp 0x412945
cmp esi, ebp
je 0x412924
or ecx, 0xffffffff
xor eax, eax
mov edi, esi
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp ecx, 0x95
jle 0x412924
mov ecx, dword [str.csl_com.c]
push 0x277
push ecx
push str._int_STRLEN__func_name_____int___int___int_sizeof_mess_hdr.n.name__1__
call fcn.0040c9a0
add esp, 0xc
push 0x95
lea edx, [esp + 0x28]
push esi
push edx
call fcn.00405750
mov edi, dword [esp + 0xe4]
add esp, 0xc
mov ebp, dword [esp + 0xd4]
mov eax, dword [esp + 0x20]
mov dword [esp + 0xbc], edi
mov dword [esp + 0xc0], eax
call fcn.004108e0
lea ecx, [esp + 0x24]
cmp ecx, 0x3e8
mov dword [esp + 0xc4], eax
ja 0x41298f
mov edx, dword [str.csl_com.c]
push 0x27d
push edx
push 0x45e9c0
call fcn.0040c9a0
mov eax, dword [esp + 0xd0]
add esp, 0xc
mov ecx, dword [esp + 0xbc]
mov edx, ecx
shl edx, 0x10
mov esi, ecx
xor ebx, ebx
mov bh, byte [esp + 0xbe]
and esi, 0xff00
add edx, esi
shl edx, 8
shr ecx, 0x18
add edx, ebx
add edx, ecx
mov ecx, dword [esp + 0xc0]
mov dword [esp + 0xbc], edx
mov edx, ecx
mov esi, ecx
shl edx, 0x10
xor ebx, ebx
mov bh, byte [esp + 0xc2]
and esi, 0xff00
add edx, esi
shl edx, 8
shr ecx, 0x18
add edx, ebx
add edx, ecx
mov dword [esp + 0xc0], edx
mov ecx, eax
shl ecx, 0x10
mov edx, eax
and edx, 0xff00
add ecx, edx
xor edx, edx
mov dh, byte [esp + 0xc6]
shl ecx, 8
shr eax, 0x18
add ecx, edx
add ecx, eax
mov eax, dword [esp + 0x24]
test eax, eax
mov dword [esp + 0xc4], ecx
jne 0x412a47
mov eax, dword [esp + 0x28]
mov ecx, eax
shl ecx, 0x10
mov edx, eax
and edx, 0xff00
add ecx, edx
xor edx, edx
mov dh, byte [esp + 0x2a]
shl ecx, 8
shr eax, 0x18
add ecx, edx
add ecx, eax
mov dword [esp + 0x28], ecx
mov eax, dword [str.csl_com.c]
push 0x280
push eax
lea ebx, [edi + 0xa4]
push 1
push ebx
call sym.gateway.exe_gen__mem_malloc
mov esi, eax
add esp, 0x10
cmp esi, 0x3e8
ja 0x412a96
mov ecx, dword [str.csl_com.c]
push 0x281
push ecx
push str.L_PTR_data_
call fcn.0040c9a0
add esp, 0xc
pop edi
pop esi
pop ebp
mov eax, 0x445c4
pop ebx
add esp, 0xb8
ret
push 0xa4
lea edx, [esp + 0x28]
push edx
push esi
call fcn.00406ea0
add esp, 0xc
test edi, edi
jle 0x412b09
cmp ebp, 0x3e8
ja 0x412af8
mov eax, dword [str.csl_com.c]
push 0x286
push eax
push 0x45ea08
call fcn.0040c9a0
add esp, 0xc
test esi, esi
je 0x412ae8
mov ecx, dword [str.csl_com.c]
push 0x286
push ecx
push 1
push esi
call sym.gateway.exe_gen__mem_free
add esp, 0x10
pop edi
pop esi
pop ebp
mov eax, 0x445c1
pop ebx
add esp, 0xb8
ret
push edi
lea edx, [esi + 0xa4]
push ebp
push edx
call fcn.00406ea0
add esp, 0xc
mov eax, dword [esp + 0x14]
test eax, eax
je 0x412b30
mov ecx, dword [str.csl_com.c]
push 0x28a
push ecx
push 1
push eax
call sym.gateway.exe_gen__mem_free
add esp, 0x10
mov dword [esp + 0x14], 0
mov al, byte [0x45e628]
test al, al
jne 0x412b77
mov ebp, dword [esp + 0xd0]
lea edx, [esp + 0x1c]
push edx
push 0x8004667e
push ebp
mov dword [esp + 0x28], 1
call sub.WS2_32.dll_ioctlsocket
cmp eax, 0xffffffff
jne 0x412b7e
mov eax, dword [str.csl_com.c]
push 0x293
push eax
push str.ioctl_sd__FIONBIO__1_
call fcn.0040ca20
add esp, 0xc
jmp 0x412b7e
mov ebp, dword [esp + 0xd0]
push ebx
push esi
push ebp
call fcn.004092b0
mov edi, eax
mov al, byte [0x45e628]
add esp, 0xc
test al, al
jne 0x412bca
lea ecx, [esp + 0x1c]
push ecx
push 0x8004667e
push ebp
mov dword [esp + 0x28], 0
call sub.WS2_32.dll_ioctlsocket
cmp eax, 0xffffffff
jne 0x412bca
mov edx, dword [str.csl_com.c]
push 0x2a4
push edx
push str.ioctl_sd__FIONBIO__0_
call fcn.0040ca20
add esp, 0xc
cmp edi, 0x1392
jne 0x412c05
push ebp
call fcn.00414c80
mov ecx, dword [0x490de4]
lea eax, [ebp*8]
sub eax, ebp
shl eax, 6
add eax, ecx
mov ecx, dword [eax + 0xd4]
add esp, 4
test ecx, ecx
je 0x412c05
add eax, 0xd8
push eax
push ebp
call ecx
add esp, 8
test esi, esi
je 0x412c20
mov edx, dword [str.csl_com.c]
push 0x2af
push edx
push 1
push esi
call sym.gateway.exe_gen__mem_free
add esp, 0x10
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xb8
ret
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0xb8
ret