joyce8/EMBER2024-capa huggingface dataset:
Function at 0x696a33
Capabilities:
Encode data using xor
Receive data
Receive data on socket
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x140
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
push 0
lea eax, [ebp - 0x100]
push 0xff
push eax
push dword [esi + 0x88]
call sub.wsock32.dll_recv
cmp eax, 0xffffffff
je 0x696bb8
and byte [ebp + eax - 0x100], 0
mov edi, str._secure_
lea eax, [ebp - 0x100]
push edi
push eax
call fcn.006a1c40
mov ebx, eax
pop ecx
test ebx, ebx
pop ecx
jne 0x696a8d
push 5
jmp 0x696bba
push edi
call fcn.006a3100
add ebx, eax
push 6
lea edi, [esi + 0x2c]
push ebx
push 6
push edi
call fcn.00699a8e
add esp, 0x14
xor eax, eax
mov cl, byte [edi + eax]
xor byte [ebx + eax], cl
inc eax
cmp eax, 6
jl 0x696aa8
lea eax, [ebp - 0x140]
push eax
push 6
push ebx
call fcn.006999d4
lea eax, [ebp - 0x140]
push eax
lea eax, [esi + 0x4c]
push 0x6d4ab8
push eax
lea eax, [ebp - 0x100]
push str.gamename_sgamever_slocation0_validate_senctype2_finalqueryid1.1_
push eax
call fcn.006a2173
add esp, 0x20
xor edi, edi
lea eax, [ebp - 0x100]
push edi
push eax
call fcn.006a3100
pop ecx
push eax
lea eax, [ebp - 0x100]
push eax
push dword [esi + 0x88]
call sub.wsock32.dll_send
cmp eax, 0xffffffff
je 0x696bb8
cmp eax, edi
je 0x696bb8
mov eax, dword [esi + 0x90]
cmp eax, 6
jne 0x696b33
mov eax, str.groups
mov dword [esi + 0x5b4], edi
jmp 0x696b44
cmp eax, 7
jne 0x696b3f
mov eax, str.info2
jmp 0x696b2b
mov eax, 0x6d4a54
cmp dword [ebp + 0xc], edi
je 0x696b67
push dword [ebp + 0xc]
lea ecx, [esi + 0xc]
push ecx
push eax
lea eax, [ebp - 0x100]
push str.list_sgamename_swhere_s_final_
push eax
call fcn.006a2173
add esp, 0x14
jmp 0x696b80
lea ecx, [esi + 0xc]
push ecx
push eax
lea eax, [ebp - 0x100]
push str.list_sgamename_s_final_
push eax
call fcn.006a2173
add esp, 0x10
lea eax, [ebp - 0x100]
push edi
push eax
call fcn.006a3100
pop ecx
push eax
lea eax, [ebp - 0x100]
push eax
push dword [esi + 0x88]
call sub.wsock32.dll_send
cmp eax, 0xffffffff
je 0x696bb8
cmp eax, edi
je 0x696bb8
push 1
push esi
call fcn.00696bc0
pop ecx
xor eax, eax
pop ecx
jmp 0x696bbb
push 3
pop eax
pop edi
pop esi
pop ebx
leave
ret
Function at 0x696cc2
Capabilities:
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
push ebx
push esi
push edi
push dword [ebp + 0xc]
call sub.wsock32.dll_inet_addr
push dword [ebp + 0x10]
mov esi, dword [ebp + 8]
mov ebx, eax
push ebx
push esi
call fcn.00696c33
add esp, 0xc
cmp dword [esi], 0
mov edi, eax
jne 0x696d79
push esi
call fcn.0069694e
test eax, eax
pop ecx
jne 0x696e04
cmp edi, 0xffffffff
je 0x696d38
push edi
push dword [esi + 4]
call fcn.0069975d
mov eax, dword [eax]
mov ecx, dword [ebp + 0x18]
mov dword [ebp + 0x10], eax
push edi
mov dword [eax + 8], ecx
mov eax, dword [ebp + 0x10]
mov word [eax + 6], 0x270f
push dword [esi + 4]
call fcn.00699821
lea eax, [ebp + 0x10]
push eax
push dword [esi + 4]
call fcn.0069976d
add esp, 0x18
jmp 0x696d48
push dword [ebp + 0x18]
push dword [ebp + 0x10]
push ebx
push esi
call fcn.00696bf8
add esp, 0x10
push dword [esi + 4]
call fcn.006977aa
and dword [esi + 0x74], 0
dec eax
push 3
push esi
mov dword [esi + 0x70], eax
call fcn.00696bc0
add esp, 0xc
cmp dword [ebp + 0x14], 0
jne 0x696e02
push esi
call fcn.00696bdb
pop ecx
jmp 0x696e02
cmp edi, 0xffffffff
jne 0x696da5
push dword [ebp + 0x18]
push dword [esi + 0x70]
push dword [ebp + 0x10]
push ebx
push esi
call fcn.00696e09
mov eax, dword [esi]
add esp, 0x14
cmp eax, 1
je 0x696d9d
cmp eax, 2
jne 0x696e02
inc dword [esi + 0x98]
jmp 0x696e02
push edi
push dword [esi + 4]
call fcn.0069975d
mov eax, dword [eax]
cmp edi, dword [esi + 0x70]
pop ecx
mov dword [ebp + 0x10], eax
pop ecx
jge 0x696e02
mov ecx, dword [ebp + 0x18]
mov dword [eax + 8], ecx
mov eax, dword [ebp + 0x10]
mov word [eax + 6], 0x270f
push dword [ebp + 0x10]
push esi
call fcn.00696c99
pop ecx
cmp eax, 0xffffffff
pop ecx
je 0x696de4
imul eax, eax, 0x1c
mov ecx, dword [esi + 8]
and dword [eax + ecx + 4], 0
push dword [esi + 0x70]
lea eax, [ebp + 0x10]
push eax
push dword [esi + 4]
call fcn.00699781
push edi
push dword [esi + 4]
call fcn.00699821
add esp, 0x14
dec dword [esi + 0x70]
xor eax, eax
pop edi
pop esi
pop ebx
pop ebp
ret
Function at 0x696e76
Capabilities:
Get socket status
Receive data
Receive data on socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x6fc
push ebx
xor ebx, ebx
push esi
mov esi, dword [ebp + 8]
mov dword [ebp - 0xc], ebx
mov dword [ebp - 8], ebx
mov dword [ebp - 4], 0x10
mov eax, dword [esi + 0x88]
mov dword [ebp - 0x120], 1
mov dword [ebp - 0x11c], eax
lea eax, [ebp - 0xc]
push eax
push ebx
lea eax, [ebp - 0x120]
push ebx
push eax
push 0x40
call sub.wsock32.dll_select
cmp eax, 0xffffffff
je 0x696f49
cmp eax, ebx
je 0x696f49
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x1c]
push eax
push ebx
lea eax, [ebp - 0x6fc]
push 0x5db
push eax
push dword [esi + 0x88]
call sub.wsock32.dll_recvfrom
cmp eax, 0xffffffff
je 0x696e93
lea eax, [ebp - 0x6fc]
push str._final_
push eax
mov byte [ebp - 0x121], bl
call fcn.006a1c40
pop ecx
test eax, eax
pop ecx
je 0x696e93
push dword [ebp - 0x1a]
call sub.wsock32.dll_ntohs
movzx eax, ax
push eax
push dword [ebp - 0x18]
push esi
call fcn.00696c33
add esp, 0xc
cmp eax, 0xffffffff
jne 0x696e93
push 5
push dword [ebp - 0x1a]
call sub.wsock32.dll_ntohs
push eax
push dword [ebp - 0x18]
push esi
call fcn.00696bf8
add esp, 0x10
jmp 0x696e93
call sub.kernel32.dll_GetTickCount
sub eax, dword [esi + 0x8c]
cmp eax, 0xbb8
jbe 0x696f77
push dword [esi + 0x88]
call sub.wsock32.dll_closesocket
or dword [esi + 0x88], 0xffffffff
push 3
push esi
call fcn.00696bc0
pop ecx
pop ecx
pop esi
xor eax, eax
pop ebx
leave
ret
Function at 0x6982f9
Capabilities:
Set socket configuration

Disassembly:
push esi
push 0x3a
push dword [esp + 0x10]
call fcn.006a3a20
mov esi, eax
pop ecx
test esi, esi
pop ecx
je 0x69832d
and byte [esi], 0
push edi
push dword [esp + 0x10]
call sub.wsock32.dll_inet_addr
mov edi, dword [esp + 0xc]
inc esi
push esi
mov dword [edi], eax
call fcn.006a34e3
pop ecx
mov word [edi + 4], ax
pop edi
pop esi
ret

Function at 0x698834
Capabilities:
Create udp socket
Get local ipv4 addresses
Get socket information

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
mov eax, dword [ebp + 8]
test eax, eax
je 0x698844
and dword [eax], 0
push ebx
push esi
push edi
call fcn.0069947e
push 0x11
push 2
push 2
call sub.wsock32.dll_socket
mov ebx, eax
cmp ebx, 0xffffffff
je 0x698929
mov esi, dword [ebp + 0x10]
lea edi, [esi + 0x64]
cmp esi, edi
jge 0x6988a7
lea eax, [ebp - 0x14]
push 0
push eax
push esi
push dword [ebp + 0xc]
call fcn.00698b7c
add esp, 0x10
push 0x7f000001
call sub.wsock32.dll_htonl
cmp dword [ebp - 0x10], eax
jne 0x698891
and dword [ebp - 0x10], 0
lea eax, [ebp - 0x14]
push 0x10
push eax
push ebx
call sub.wsock32.dll_bind
test eax, eax
mov dword [ebp + 0x10], eax
je 0x6988ad
inc esi
jmp 0x698868
cmp dword [ebp + 0x10], 0
jne 0x6988ca
test esi, esi
jne 0x6988d9
lea eax, [ebp - 4]
mov dword [ebp - 4], 0x10
push eax
lea eax, [ebp - 0x14]
push eax
push ebx
call sub.wsock32.dll_getsockname
test eax, eax
je 0x6988ce
push 2
jmp 0x69892b
push dword [ebp - 0x12]
call sub.wsock32.dll_ntohs
movzx esi, ax
push dword [ebp + 0x2c]
push dword [ebp + 0x28]
push dword [ebp + 0x24]
push dword [ebp + 0x20]
push dword [ebp + 0x1c]
push dword [ebp + 0x18]
push dword [ebp + 0x14]
push ebx
push ebx
push esi
push dword [ebp + 8]
call fcn.00698931
add esp, 0x2c
cmp dword [ebp + 8], 0
jne 0x698909
mov dword [ebp + 8], 0x6d4df4
mov eax, dword [ebp + 8]
mov eax, dword [eax]
add eax, 0xec
push eax
push 0x6cfc
push str.master.gamespy.com
push ebx
call fcn.00698b63
add esp, 0x10
jmp 0x69892c
push 1
pop eax
pop edi
pop esi
pop ebx
leave
ret

Function at 0x6989f6
Capabilities:
Get socket status
Receive data
Receive data on socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x120
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
xor ebx, ebx
mov dword [ebp - 4], 0x10
cmp dword [edi + 0xe4], ebx
mov dword [ebp - 0xc], ebx
mov dword [ebp - 8], ebx
je 0x698a82
mov eax, dword [edi]
mov dword [ebp - 0x120], 1
mov dword [ebp - 0x11c], eax
mov esi, 0x8dcbb0
lea eax, [ebp - 0xc]
push eax
push ebx
lea eax, [ebp - 0x120]
push ebx
push eax
push 0x40
call sub.wsock32.dll_select
cmp eax, 0xffffffff
je 0x698a82
cmp eax, ebx
je 0x698a82
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x1c]
push eax
push ebx
push 0xff
push esi
push dword [edi]
call sub.wsock32.dll_recvfrom
cmp eax, 0xffffffff
je 0x698a33
lea ecx, [ebp - 0x1c]
mov byte [eax + 0x8dcbb0], bl
push ecx
push eax
push esi
push edi
call fcn.00698d6e
add esp, 0x10
jmp 0x698a33
pop edi
pop esi
pop ebx
leave
ret
Function at 0x698b7c
Capabilities:
Resolve dns
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 0x10]
push edi
push dword [ebp + 0xc]
mov word [esi], 2
call sub.wsock32.dll_htons
mov edi, dword [ebp + 8]
mov word [esi + 2], ax
test edi, edi
jne 0x698ba1
and dword [esi + 4], edi
jmp 0x698baa
push edi
call sub.wsock32.dll_inet_addr
mov dword [esi + 4], eax
cmp dword [esi + 4], 0xffffffff
jne 0x698bd7
push str.255.255.255.255
push edi
call fcn.006a1cc0
pop ecx
test eax, eax
pop ecx
je 0x698bd7
push edi
call sub.wsock32.dll_gethostbyname
test eax, eax
je 0x698be6
mov ecx, dword [eax + 0xc]
mov ecx, dword [ecx]
mov ecx, dword [ecx]
mov dword [esi + 4], ecx
jmp 0x698bda
mov eax, dword [ebp + 0x10]
mov ecx, dword [ebp + 0x14]
test ecx, ecx
je 0x698be3
mov dword [ecx], eax
push 1
pop eax
pop edi
pop esi
pop ebp
ret

Function at 0x698c79
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10c
push ebx
push esi
push edi
xor ecx, ecx
lea eax, [ebp - 0x10c]
mov esi, 0x100
mov byte [eax], cl
inc ecx
inc eax
cmp cx, si
jl 0x698c92
and byte [ebp - 1], 0
xor edi, edi
lea ebx, [ebp - 0x10c]
mov dword [ebp - 8], esi
movzx ecx, byte [ebp - 1]
mov eax, dword [ebp + 8]
movzx edx, byte [ecx + eax]
movzx eax, byte [ebx]
add edi, edx
add eax, edi
mov edi, esi
cdq
idiv edi
lea eax, [ecx + 1]
mov byte [ebp - 2], dl
cdq
idiv dword [ebp + 0xc]
movzx edi, byte [ebp - 2]
lea eax, [ebp + edi - 0x10c]
push eax
push ebx
mov byte [ebp - 1], dl
call fcn.00699b83
pop ecx
inc ebx
dec dword [ebp - 8]
pop ecx
jne 0x698caa
xor eax, eax
cmp dword [ebp + 0x14], eax
mov dword [ebp + 8], eax
jle 0x698d69
mov dword [ebp + 0xc], eax
xor edi, edi
jmp 0x698cfc
mov eax, dword [ebp - 8]
mov ecx, dword [ebp + 0x10]
add edi, ecx
movzx ecx, byte [edi]
lea eax, [ecx + eax + 1]
mov ecx, esi
cdq
idiv ecx
movzx eax, dl
mov dword [ebp - 8], eax
lea ebx, [ebp + eax - 0x10c]
movzx eax, byte [ebp + eax - 0x10c]
add eax, dword [ebp + 0xc]
cdq
idiv ecx
movzx eax, dl
mov dword [ebp + 0xc], eax
lea eax, [ebp + eax - 0x10c]
push eax
push ebx
mov dword [ebp - 0xc], eax
call fcn.00699b83
mov eax, dword [ebp - 0xc]
pop ecx
pop ecx
movzx eax, byte [eax]
movzx ecx, byte [ebx]
add eax, ecx
mov ecx, esi
cdq
idiv ecx
movzx eax, dl
mov al, byte [ebp + eax - 0x10c]
xor byte [edi], al
inc dword [ebp + 8]
movsx edi, word [ebp + 8]
cmp edi, dword [ebp + 0x14]
jl 0x698cf9
pop edi
pop esi
pop ebx
leave
ret

Function at 0x699030
Capabilities:
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x50
push edi
mov edi, dword [ebp + 0x10]
push edi
call fcn.006a3100
test eax, eax
pop ecx
je 0x699097
push esi
mov esi, dword [ebp + 8]
inc dword [esi + 0xe0]
push dword [esi + 0xe0]
lea eax, [esi + 0xe0]
push dword [esi + 0xdc]
lea eax, [ebp - 0x50]
push str.queryid_d._d
push eax
call fcn.006a2173
lea eax, [ebp - 0x50]
push eax
push edi
call fcn.006a21e0
add esp, 0x18
push 0x10
push dword [ebp + 0xc]
push 0
push edi
call fcn.006a3100
pop ecx
push eax
push edi
push dword [esi]
call sub.wsock32.dll_sendto
and byte [edi], 0
pop esi
pop edi
leave
ret
Function at 0x6993e7
Capabilities:
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x100
push esi
mov esi, dword [ebp + 8]
lea eax, [esi + 8]
push eax
lea eax, [ebp - 0x100]
push dword [esi + 0xe4]
push str.heartbeat_dgamename_s
push eax
call fcn.006a2173
add esp, 0x10
cmp dword [ebp + 0xc], 0
je 0x69943d
push dword [ebp + 0xc]
lea eax, [ebp - 0x100]
push str._statechanged_d
push eax
call fcn.006a3100
pop ecx
lea eax, [ebp + eax - 0x100]
push eax
call fcn.006a2173
add esp, 0xc
lea eax, [esi + 0xec]
push 0x10
push eax
lea eax, [ebp - 0x100]
push 0
push eax
call fcn.006a3100
pop ecx
push eax
lea eax, [ebp - 0x100]
push eax
push dword [esi + 4]
call sub.wsock32.dll_sendto
call sub.kernel32.dll_GetTickCount
mov dword [esi + 0xd8], eax
pop esi
leave
ret

Function at 0x69947e
Capabilities:
Initialize winsock library

Disassembly:
sub esp, 0x190
lea eax, [esp]
push eax
push 0x101
call sub.wsock32.dll_WSAStartup
add esp, 0x190
ret

Function at 0x699a8e
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10c
push ebx
push esi
push edi
xor ecx, ecx
lea eax, [ebp - 0x10c]
mov esi, 0x100
mov byte [eax], cl
inc ecx
inc eax
cmp cx, si
jl 0x699aa7
and byte [ebp - 1], 0
xor edi, edi
lea ebx, [ebp - 0x10c]
mov dword [ebp - 8], esi
movzx ecx, byte [ebp - 1]
mov eax, dword [ebp + 8]
movzx edx, byte [ecx + eax]
movzx eax, byte [ebx]
add edi, edx
add eax, edi
mov edi, esi
cdq
idiv edi
lea eax, [ecx + 1]
mov byte [ebp - 2], dl
cdq
idiv dword [ebp + 0xc]
movzx edi, byte [ebp - 2]
lea eax, [ebp + edi - 0x10c]
push eax
push ebx
mov byte [ebp - 1], dl
call fcn.00699b83
pop ecx
inc ebx
dec dword [ebp - 8]
pop ecx
jne 0x699abf
xor eax, eax
cmp dword [ebp + 0x14], eax
mov dword [ebp + 8], eax
jle 0x699b7e
mov dword [ebp + 0xc], eax
xor edi, edi
jmp 0x699b11
mov eax, dword [ebp - 8]
mov ecx, dword [ebp + 0x10]
add edi, ecx
movzx ecx, byte [edi]
lea eax, [ecx + eax + 1]
mov ecx, esi
cdq
idiv ecx
movzx eax, dl
mov dword [ebp - 8], eax
lea ebx, [ebp + eax - 0x10c]
movzx eax, byte [ebp + eax - 0x10c]
add eax, dword [ebp + 0xc]
cdq
idiv ecx
movzx eax, dl
mov dword [ebp + 0xc], eax
lea eax, [ebp + eax - 0x10c]
push eax
push ebx
mov dword [ebp - 0xc], eax
call fcn.00699b83
mov eax, dword [ebp - 0xc]
pop ecx
pop ecx
movzx eax, byte [eax]
movzx ecx, byte [ebx]
add eax, ecx
mov ecx, esi
cdq
idiv ecx
movzx eax, dl
mov al, byte [ebp + eax - 0x10c]
xor byte [edi], al
inc dword [ebp + 8]
movsx edi, word [ebp + 8]
cmp edi, dword [ebp + 0x14]
jl 0x699b0e
pop edi
pop esi
pop ebx
leave
ret
Function at 0x699e1c
Capabilities:
Encode data using xor
Encrypt data using rc4 ksa
Encrypt data using rc4 prga

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push esi
push edi
mov edi, dword [ebp + 0x10]
mov ebx, 0x100
xor eax, eax
and dword [edi + 0x514], 0
and dword [ebp - 8], eax
mov ecx, ebx
rep stosd dword es:[edi], eax
mov eax, dword [ebp + 0x10]
xor ecx, ecx
mov edx, dword [eax]
shl edx, 8
add edx, ecx
inc ecx
mov dword [eax], edx
add eax, 4
cmp ecx, ebx
jl 0x699e42
mov edi, dword [ebp - 8]
mov dword [ebp - 0xc], 2
and dword [ebp - 4], 0
mov ecx, dword [ebp + 0x10]
mov eax, dword [ebp - 4]
xor edx, edx
div dword [ebp + 0xc]
mov eax, dword [ebp + 8]
mov esi, dword [ecx]
mov al, byte [edx + eax]
add eax, esi
add eax, edi
and eax, 0xff
inc dword [ebp - 4]
mov edi, eax
mov eax, dword [ebp + 0x10]
mov edx, dword [eax + edi*4]
lea eax, [eax + edi*4]
mov dword [ecx], edx
add ecx, 4
cmp dword [ebp - 4], ebx
mov dword [eax], esi
jl 0x699e64
dec dword [ebp - 0xc]
jne 0x699e5d
inc dword [ebp - 8]
cmp dword [ebp - 8], 4
jl 0x699e3d
mov eax, dword [ebp + 0x10]
xor ecx, ecx
xor dword [eax], ecx
inc ecx
add eax, 4
cmp ecx, ebx
jl 0x699eaa
push 0
push 0
push dword [ebp + 0x10]
call fcn.00699b96
add esp, 0xc
pop edi
pop esi
pop ebx
leave
ret

Function at 0x699f91
Capabilities:
Get socket status

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x31c
push ebx
push esi
push edi
xor ecx, ecx
cmp dword [ebp + 0xc], ecx
push 1
pop esi
je 0x699fbe
mov eax, dword [ebp + 8]
mov dword [ebp - 0x218], esi
mov dword [ebp - 0x214], eax
lea edi, [ebp - 0x218]
jmp 0x699fc3
mov eax, dword [ebp + 8]
xor edi, edi
cmp dword [ebp + 0x10], ecx
je 0x699fdf
lea edx, [ebp - 0x114]
mov dword [ebp - 0x110], eax
mov dword [ebp - 0x114], esi
mov dword [ebp - 4], edx
jmp 0x699fe2
mov dword [ebp - 4], ecx
cmp dword [ebp + 0x14], ecx
je 0x699ffe
mov dword [ebp - 0x318], eax
lea eax, [ebp - 0x31c]
mov dword [ebp - 0x31c], esi
mov dword [ebp - 8], eax
jmp 0x69a001
mov dword [ebp - 8], ecx
lea eax, [ebp - 0x10]
mov dword [ebp - 0x10], ecx
push eax
mov dword [ebp - 0xc], ecx
push dword [ebp - 8]
push dword [ebp - 4]
push edi
push 0x40
call sub.wsock32.dll_select
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x69a024
xor eax, eax
jmp 0x69a08c
cmp dword [ebp + 0xc], 0
je 0x69a048
test ebx, ebx
jle 0x69a042
push edi
push dword [ebp + 8]
call sub.wsock32.dll___WSAFDIsSet
test eax, eax
je 0x69a042
mov eax, dword [ebp + 0xc]
mov dword [eax], esi
jmp 0x69a048
mov eax, dword [ebp + 0xc]
and dword [eax], 0
mov edi, dword [ebp + 0x10]
test edi, edi
je 0x69a069
test ebx, ebx
jle 0x69a066
push dword [ebp - 4]
push dword [ebp + 8]
call sub.wsock32.dll___WSAFDIsSet
test eax, eax
je 0x69a066
mov dword [edi], esi
jmp 0x69a069
and dword [edi], 0
mov edi, dword [ebp + 0x14]
test edi, edi
je 0x69a08a
test ebx, ebx
jle 0x69a087
push dword [ebp - 8]
push dword [ebp + 8]
call sub.wsock32.dll___WSAFDIsSet
test eax, eax
je 0x69a087
mov dword [edi], esi
jmp 0x69a08a
and dword [edi], 0
mov eax, esi
pop edi
pop esi
pop ebx
leave
ret
Function at 0x69a091
Capabilities:
Receive data
Receive data on socket

Disassembly:
mov eax, dword [esp + 0xc]
push ebx
push esi
mov esi, dword [esp + 0xc]
push edi
mov edi, dword [eax]
dec edi
cmp dword [esi + 0xf4], 0
je 0x69a0d0
call sub.kernel32.dll_GetTickCount
mov edx, dword [esi + 0xf8]
lea ecx, [esi + 0xf8]
add edx, dword [0x6d4eec]
cmp eax, edx
jb 0x69a10f
mov dword [ecx], eax
mov eax, dword [0x6d4ee8]
cmp edi, eax
jl 0x69a0d0
mov edi, eax
push 0
push edi
mov edi, dword [esp + 0x1c]
push edi
push dword [esi + 0x40]
call sub.wsock32.dll_recv
push 1
cmp eax, 0xffffffff
pop ebx
jne 0x69a114
call sub.wsock32.dll_WSAGetLastError
cmp eax, 0x2733
je 0x69a10f
cmp eax, 0x2734
je 0x69a10f
mov dword [esi + 0xbc], ebx
mov dword [esi + 0x30], 5
mov dword [esi + 0x44], eax
push 3
jmp 0x69a11a
push 1
pop eax
jmp 0x69a12f
test eax, eax
jne 0x69a123
push 2
pop eax
mov dword [esi + 0xf0], ebx
jmp 0x69a12f
mov ecx, dword [esp + 0x18]
and byte [eax + edi], 0
mov dword [ecx], eax
xor eax, eax
pop edi
pop esi
pop ebx
ret

Function at 0x69a133
Capabilities:
Send data
Send data on socket

Disassembly:
push esi
mov esi, dword [esp + 8]
push 0
push dword [esp + 0x14]
push dword [esp + 0x14]
push dword [esi + 0x40]
call sub.wsock32.dll_send
cmp eax, 0xffffffff
jne 0x69a178
call sub.wsock32.dll_WSAGetLastError
cmp eax, 0x2733
jne 0x69a15f
xor eax, eax
pop esi
ret
mov dword [esi + 0xbc], 1
mov dword [esi + 0x30], 5
mov dword [esi + 0x44], eax
or eax, 0xffffffff
pop esi
ret
cmp dword [esi + 0xc], 3
jne 0x69a184
add dword [esi + 0x108], eax
pop esi
ret

Function at 0x69b049
Capabilities:
Resolve dns
Set socket configuration

Disassembly:
push esi
mov esi, dword [esp + 8]
push 0
push 0
push esi
call fcn.0069afdd
call fcn.0069947e
push esi
call fcn.0069b0cc
add esp, 0x10
test eax, eax
jne 0x69b07d
mov dword [esi + 0xbc], 1
mov dword [esi + 0x30], 3
pop esi
ret
push dword [esi + 0x14]
call sub.wsock32.dll_inet_addr
cmp eax, 0xffffffff
mov dword [esi + 0x18], eax
jne 0x69b0b6
push dword [esi + 0x14]
call sub.wsock32.dll_gethostbyname
test eax, eax
jne 0x69b0ac
mov dword [esi + 0xbc], 1
mov dword [esi + 0x30], 4
pop esi
ret
mov eax, dword [eax + 0xc]
mov eax, dword [eax]
mov eax, dword [eax]
mov dword [esi + 0x18], eax
push 0
push 0
push esi
mov dword [esi + 0xc], 1
call fcn.0069afdd
add esp, 0xc
pop esi
ret
Function at 0x69b18e
Capabilities:
Connect socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
push 6
cmp dword [esi + 0x40], 0xffffffff
pop ebx
push 1
pop edi
jne 0x69b249
push ebx
push edi
push 2
call sub.wsock32.dll_socket
cmp eax, 0xffffffff
mov dword [esi + 0x40], eax
je 0x69b1c9
push 0
push eax
call fcn.006994d0
pop ecx
test eax, eax
pop ecx
jne 0x69b1db
mov dword [esi + 0xbc], edi
mov dword [esi + 0x30], 5
jmp 0x69b28f
cmp dword [esi + 0xf4], 0
je 0x69b1f4
push dword [0x6d4ee8]
push dword [esi + 0x40]
call fcn.006994f6
pop ecx
pop ecx
push 0x10
lea eax, [ebp - 0x14]
push 0
push eax
call fcn.006a10b0
mov ax, word [esi + 0x1c]
add esp, 0xc
mov word [ebp - 0x12], ax
mov eax, dword [esi + 0x18]
mov dword [ebp - 0x10], eax
lea eax, [ebp - 0x14]
push 0x10
push eax
push dword [esi + 0x40]
mov word [ebp - 0x14], 2
call sub.wsock32.dll_connect
cmp eax, 0xffffffff
jne 0x69b249
call sub.wsock32.dll_WSAGetLastError
cmp eax, 0x2733
je 0x69b249
cmp eax, 0x2734
je 0x69b249
mov dword [esi + 0xbc], edi
mov dword [esi + 0x30], ebx
jmp 0x69b294
lea eax, [ebp + 8]
push eax
lea eax, [ebp - 4]
push eax
push 0
push dword [esi + 0x40]
call fcn.00699f91
xor ecx, ecx
add esp, 0x10
cmp eax, ecx
je 0x69b282
cmp dword [ebp + 8], ecx
jne 0x69b282
cmp dword [ebp - 4], ecx
je 0x69b297
push ecx
push ecx
push esi
mov dword [esi + 0xc], 2
call fcn.0069afdd
add esp, 0xc
jmp 0x69b297
cmp eax, ecx
mov dword [esi + 0xbc], edi
mov dword [esi + 0x30], ebx
jne 0x69b297
call sub.wsock32.dll_WSAGetLastError
mov dword [esi + 0x44], eax
pop edi
pop esi
pop ebx
leave
ret

Function at 0x69cc70
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Connect udp socket
Create tcp socket
Create udp socket
Resolve dns
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push esi
mov esi, dword [ebp + 8]
push edi
push 0xff
push dword [ebp + 0xc]
lea eax, [esi + 8]
push eax
call fcn.006a2670
add esp, 0xc
push dword [ebp + 0xc]
call sub.wsock32.dll_inet_addr
mov edi, eax
cmp edi, 0xffffffff
jne 0x69ccb1
push dword [ebp + 0xc]
call sub.wsock32.dll_gethostbyname
test eax, eax
je 0x69cd19
mov eax, dword [eax + 0xc]
mov eax, dword [eax]
mov edi, dword [eax]
push 0x10
lea eax, [ebp - 0x10]
push 0
push eax
call fcn.006a10b0
add esp, 0xc
mov word [ebp - 0x10], 2
mov dword [ebp - 0xc], edi
push dword [ebp + 0x10]
call sub.wsock32.dll_htons
push 0
push 1
pop edi
mov word [ebp - 0xe], ax
push edi
push 2
call sub.wsock32.dll_socket
cmp eax, 0xffffffff
mov dword [esi], eax
je 0x69cd19
lea ecx, [ebp + 8]
push 4
push ecx
push 8
push 0xffff
push eax
mov dword [ebp + 8], edi
call sub.wsock32.dll_setsockopt
lea eax, [ebp - 0x10]
push 0x10
push eax
push dword [esi]
call sub.wsock32.dll_connect
cmp eax, 0xffffffff
jne 0x69cd1d
push dword [esi]
call sub.wsock32.dll_closesocket
xor eax, eax
jmp 0x69cd22
mov dword [esi + 4], edi
mov eax, edi
pop edi
pop esi
leave
ret