joyce8/EMBER2024-capa huggingface dataset:
Function at 0x429d80
Capabilities:
Encrypt data using rc4 ksa
Encrypt data using rc4 prga

Disassembly:
sub esp, 0x110
xor eax, eax
lea ecx, [esp + 0x10]
mov byte [ecx], al
inc eax
inc ecx
cmp ax, 0x100
jl 0x429d8c
push ebx
mov ebx, dword [esp + 0x11c]
push ebp
push esi
push edi
mov byte [esp + 0x10], 0
xor esi, esi
lea edi, [esp + 0x20]
mov ebp, 0x100
mov eax, dword [esp + 0x10]
mov edx, dword [esp + 0x124]
and eax, 0xff
xor ecx, ecx
mov cl, byte [eax + edx]
xor edx, edx
mov dl, byte [edi]
add esi, ecx
add edx, esi
and edx, 0x800000ff
jns 0x429dde
dec edx
or edx, 0xffffff00
inc edx
inc eax
mov byte [esp + 0x14], dl
cdq
idiv ebx
mov esi, dword [esp + 0x14]
and esi, 0xff
lea eax, [esp + esi + 0x20]
push eax
push edi
mov byte [esp + 0x18], dl
call fcn.00429c80
add esp, 8
inc edi
dec ebp
jne 0x429db1
mov eax, dword [esp + 0x130]
xor ebp, ebp
cmp eax, ebp
mov dword [esp + 0x18], ebp
jle 0x429edc
xor esi, esi
xor edi, edi
mov ecx, dword [esp + 0x12c]
mov al, byte [ecx + ebp]
and eax, 0xff
lea edx, [eax + esi + 1]
and edx, 0x800000ff
jns 0x429e42
dec edx
or edx, 0xffffff00
inc edx
mov byte [esp + 0x10], dl
xor eax, eax
mov esi, dword [esp + 0x10]
and esi, 0xff
mov al, byte [esp + esi + 0x20]
lea ebx, [esp + esi + 0x20]
add eax, edi
and eax, 0x800000ff
jns 0x429e6a
dec eax
or eax, 0xffffff00
inc eax
mov byte [esp + 0x14], al
mov edi, dword [esp + 0x14]
and edi, 0xff
lea eax, [esp + edi + 0x20]
push eax
push ebx
mov dword [esp + 0x24], eax
call fcn.00429c80
mov eax, dword [esp + 0x24]
xor ecx, ecx
mov cl, byte [ebx]
xor edx, edx
mov dl, byte [eax]
add esp, 8
add ecx, edx
and ecx, 0x800000ff
jns 0x429ea8
dec ecx
or ecx, 0xffffff00
inc ecx
mov eax, dword [esp + 0x12c]
and ecx, 0xff
mov cl, byte [esp + ecx + 0x20]
mov dl, byte [eax + ebp]
xor cl, dl
mov byte [eax + ebp], cl
mov eax, dword [esp + 0x18]
inc eax
movsx ebp, ax
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0x130]
cmp ebp, eax
jl 0x429e1f
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x110
ret

Function at 0x42adc0
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 0x42b320
Capabilities:
Create udp socket
Get local ipv4 addresses
Get socket information

Disassembly:
mov eax, dword [esp + 4]
sub esp, 0x14
test eax, eax
je 0x42b331
mov dword [eax], 0
push ebx
push ebp
push esi
push edi
call fcn.0042adc0
push 0x11
push 2
push 2
call sub.WSOCK32.dll_socket
mov ebp, eax
cmp ebp, 0xffffffff
je 0x42b4fe
mov esi, dword [esp + 0x30]
lea ebx, [esi + 0x64]
cmp esi, ebx
jge 0x42b39e
mov edi, dword [esp + 0x2c]
lea eax, [esp + 0x14]
push 0
push eax
push esi
push edi
call fcn.0042b710
add esp, 0x10
push 0x7f000001
call sub.WSOCK32.dll_htonl
cmp dword [esp + 0x18], eax
jne 0x42b388
mov dword [esp + 0x18], 0
lea ecx, [esp + 0x14]
push 0x10
push ecx
push ebp
call sub.WSOCK32.dll_bind
test eax, eax
je 0x42b3ab
inc esi
cmp esi, ebx
jl 0x42b35f
pop edi
pop esi
pop ebp
mov eax, 2
pop ebx
add esp, 0x14
ret
test esi, esi
jne 0x42b3eb
lea edx, [esp + 0x10]
lea eax, [esp + 0x14]
push edx
push eax
push ebp
mov dword [esp + 0x1c], 0x10
call sub.WSOCK32.dll_getsockname
test eax, eax
je 0x42b3d8
pop edi
pop esi
pop ebp
mov eax, 2
pop ebx
add esp, 0x14
ret
mov ecx, dword [esp + 0x16]
push ecx
call sub.WSOCK32.dll_ntohs
mov si, ax
and esi, 0xffff
mov edi, dword [esp + 0x28]
test edi, edi
jne 0x42b3ff
mov dword [0x542c80], 0x542b90
jmp 0x42b413
push 0xf0
call fcn.00517660
mov dword [0x542c80], eax
add esp, 4
mov dword [edi], eax
mov edx, dword [0x542c80]
mov ecx, dword [esp + 0x34]
add edx, 8
mov al, byte [ecx]
inc ecx
mov byte [edx], al
inc edx
test al, al
jne 0x42b420
mov eax, dword [0x542c80]
mov ecx, dword [esp + 0x38]
lea edx, [eax + 0x48]
mov al, byte [ecx]
inc ecx
mov byte [edx], al
inc edx
test al, al
jne 0x42b436
mov ecx, dword [0x542c80]
xor eax, eax
push 0x6cfc
push str.master.gamespy.com
mov dword [ecx + 0xe4], esi
mov edx, dword [0x542c80]
push ebp
mov dword [edx + 0xd8], eax
mov ecx, dword [0x542c80]
mov dword [ecx + 4], ebp
mov edx, dword [0x542c80]
mov dword [edx], ebp
mov ecx, dword [0x542c80]
mov dword [ecx + 0xe0], eax
mov edx, dword [0x542c80]
mov eax, 1
mov dword [edx + 0xdc], eax
mov ecx, dword [0x542c80]
mov byte [ecx + 0xe8], al
mov edx, dword [0x542c80]
mov eax, dword [esp + 0x58]
mov dword [edx + 0xec], eax
mov ecx, dword [0x542c80]
mov edx, dword [esp + 0x48]
mov dword [ecx + 0xc8], edx
mov eax, dword [0x542c80]
mov ecx, dword [esp + 0x4c]
mov dword [eax + 0xcc], ecx
mov edx, dword [0x542c80]
mov eax, dword [esp + 0x54]
mov ecx, dword [esp + 0x50]
mov dword [edx + 0xd4], eax
mov edx, dword [0x542c80]
mov dword [edx + 0xd0], ecx
call fcn.0042b6f0
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x14
ret
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x14
ret

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

Disassembly:
mov eax, dword [esp + 4]
test eax, eax
jne 0x42b53d
mov eax, dword [0x542c80]
mov dword [esp + 4], eax
jmp fcn.0042b550
Function at 0x42b550
Capabilities:
Get socket status
Receive data
Receive data on socket

Disassembly:
sub esp, 0x120
push ebx
push esi
mov esi, dword [esp + 0x12c]
xor ebx, ebx
mov dword [esp + 8], 0x10
mov dword [esp + 0xc], ebx
mov eax, dword [esi]
mov dword [esp + 0x10], ebx
cmp eax, 0xffffffff
je 0x42b5dd
mov dword [esp + 0x28], eax
mov dword [esp + 0x24], 1
lea eax, [esp + 0xc]
lea ecx, [esp + 0x24]
push eax
push ebx
push ebx
push ecx
push 0x40
call sub.WSOCK32.dll_select
cmp eax, 0xffffffff
je 0x42b5dd
cmp eax, ebx
je 0x42b5dd
mov ecx, dword [esi]
lea edx, [esp + 8]
lea eax, [esp + 0x14]
push edx
push eax
push ebx
push 0xff
push 0x56df38
push ecx
call sub.WSOCK32.dll_recvfrom
cmp eax, 0xffffffff
je 0x42b584
lea edx, [esp + 0x14]
mov byte [eax + 0x56df38], bl
push edx
push 0x56df38
push esi
call fcn.0042b790
add esp, 0xc
jmp 0x42b584
pop esi
pop ebx
add esp, 0x120
ret

Function at 0x42b710
Capabilities:
Resolve dns
Set socket configuration

Disassembly:
mov eax, dword [esp + 8]
push ebx
mov ebx, dword [esp + 0x10]
push ebp
push esi
push eax
xor ebp, ebp
mov word [ebx], 2
call sub.WSOCK32.dll_htons
mov esi, dword [esp + 0x10]
mov word [ebx + 2], ax
cmp esi, ebp
jne 0x42b739
mov dword [ebx + 4], ebp
jmp 0x42b742
push esi
call sub.WSOCK32.dll_inet_addr
mov dword [ebx + 4], eax
cmp dword [ebx + 4], 0xffffffff
jne 0x42b778
push edi
mov edi, str.255.255.255.255
mov ecx, 0x10
xor edx, edx
repe cmpsb byte [esi], byte es:[edi]
pop edi
je 0x42b778
mov eax, dword [esp + 0x10]
push eax
call sub.WSOCK32.dll_gethostbyname
mov ebp, eax
test ebp, ebp
jne 0x42b76e
pop esi
pop ebp
pop ebx
ret
mov ecx, dword [ebp + 0xc]
mov edx, dword [ecx]
mov eax, dword [edx]
mov dword [ebx + 4], eax
mov eax, dword [esp + 0x1c]
test eax, eax
je 0x42b782
mov dword [eax], ebp
pop esi
pop ebp
mov eax, 1
pop ebx
ret

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

Disassembly:
sub esp, 0x50
or ecx, 0xffffffff
xor eax, eax
push ebp
mov ebp, dword [esp + 0x60]
push edi
mov edi, ebp
repne scasb al, byte es:[edi]
not ecx
dec ecx
je 0x42bb24
push ebx
mov ebx, dword [esp + 0x60]
push esi
lea ecx, [esp + 0x10]
mov edi, dword [ebx + 0xe0]
inc edi
mov eax, edi
mov dword [ebx + 0xe0], edi
push eax
mov eax, dword [ebx + 0xdc]
push eax
push str.queryid_d._d
push ecx
call fcn.00516c8e
lea edi, [esp + 0x20]
or ecx, 0xffffffff
xor eax, eax
add esp, 0x10
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push 0x10
mov esi, edi
mov edx, ecx
mov edi, ebp
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov eax, dword [esp + 0x6c]
mov ecx, edx
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
mov edi, ebp
or ecx, 0xffffffff
xor eax, eax
push 0
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
mov ecx, dword [ebx]
push ebp
push ecx
call sub.WSOCK32.dll_sendto
pop esi
mov byte [ebp], 0
pop ebx
pop edi
pop ebp
add esp, 0x50
ret
Function at 0x42bf70
Capabilities:
Send data
Send data on socket

Disassembly:
sub esp, 0x100
lea edx, [esp]
push esi
mov esi, dword [esp + 0x108]
push edi
mov ecx, dword [esi + 0xe4]
lea eax, [esi + 8]
push eax
push ecx
push str.heartbeat_dgamename_s
push edx
call fcn.00516c8e
mov eax, dword [esp + 0x120]
add esp, 0x10
test eax, eax
je 0x42bfdf
lea edi, [esp + 8]
or ecx, 0xffffffff
xor eax, eax
mov edx, dword [0x542d50]
repne scasb al, byte es:[edi]
mov eax, dword [str._statechanged_]
mov ecx, dword [0x542d4c]
dec edi
mov dword [edi], eax
mov ax, word [0x542d54]
mov dword [edi + 4], ecx
mov cl, byte [0x542d56]
mov dword [edi + 8], edx
mov word [edi + 0xc], ax
mov byte [edi + 0xe], cl
lea edi, [esp + 8]
or ecx, 0xffffffff
xor eax, eax
push 0x10
repne scasb al, byte es:[edi]
mov eax, dword [esi + 4]
push 0x56e240
not ecx
dec ecx
push 0
lea edx, [esp + 0x14]
push ecx
push edx
push eax
call sub.WSOCK32.dll_sendto
call sub.KERNEL32.dll_GetTickCount
mov dword [esi + 0xd8], eax
pop edi
pop esi
add esp, 0x100
ret
Function at 0x442b80
Capabilities:
Enumerate pe sections

Disassembly:
push ebx
push ebp
mov ebx, dword [esp + 0x14]
push esi
push edi
mov edi, dword [esp + 0x24]
mov edx, dword [esp + 0x20]
xor eax, eax
mov al, byte [edi]
shr eax, 7
lea ecx, [ebx + eax*8]
lea eax, [edx + ecx*8]
xor edx, edx
mov dx, word [eax*8 + 0xed1560]
xor ecx, ecx
lea eax, [eax*8 + 0xed1560]
mov esi, edx
and esi, 1
mov ebp, esi
mov cx, word [eax + 4]
shl ebp, 6
sub ebp, esi
xor esi, esi
mov si, word [eax + 2]
add ebp, esi
xor esi, esi
mov si, word [edi + ebp*2 + 0x34]
and esi, edx
mov edx, ecx
and esi, 0xfffffffe
neg esi
sbb esi, esi
and edx, 1
mov ebp, edx
and esi, 2
shl ebp, 6
sub ebp, edx
xor edx, edx
mov dx, word [eax + 6]
xor eax, eax
add ebp, edx
mov ax, word [edi + ebp*2 + 0x34]
pop edi
and eax, ecx
mov ecx, dword [esp + 0x1c]
and al, 0xfe
neg eax
sbb eax, eax
add ebx, ecx
mov ecx, dword [esp + 0x10]
and eax, 4
or esi, eax
and ebx, 1
or esi, ebx
mov eax, dword [esi*4 + 0x546ff8]
pop esi
pop ebp
cmp eax, 2
mov dword [ecx + 0x20], eax
pop ebx
jne 0x442c4f
mov eax, dword [esp + 8]
fld dword [ecx + 8]
fmul dword [eax + 8]
fld dword [ecx + 4]
fmul dword [eax + 4]
faddp st(1)
fld dword [ecx]
fmul dword [eax]
faddp st(1)
fcomp dword [ecx + 0xc]
fnstsw ax
test ah, 5
jp 0x442c70
mov dword [ecx + 0x20], 1
ret
cmp eax, 5
je 0x442c59
cmp eax, 6
jne 0x442c70
mov edx, dword [ecx + 0x10]
mov eax, dword [ecx + 0x14]
mov dword [ecx], edx
mov edx, dword [ecx + 0x18]
mov dword [ecx + 4], eax
mov eax, dword [ecx + 0x1c]
mov dword [ecx + 8], edx
mov dword [ecx + 0xc], eax
ret
Function at 0x44aa20
Capabilities:
Terminate process

Disassembly:
mov eax, dword [0xec9504]
test eax, eax
jne 0x44aa4c
push str.Server_quit_n
call fcn.00474c20
call fcn.00437840
call fcn.0047ce70
call fcn.0044c4e0
push 1
call fcn.00451350
add esp, 8
jmp 0x47e1f0
push 1
call dword [sym.imp.WINMM.dll_timeEndPeriod]
call fcn.0050df20
call fcn.0050dc70
call fcn.0050c970
call fcn.004568b0
call fcn.0047c450
call fcn.004850e0
call fcn.0045b260
mov eax, dword [0x7b9b5c]
test eax, eax
jne 0x47e229
call fcn.00425e40
push 0
call fcn.0051a164

Function at 0x45a430
Capabilities:
Hash data with md5

Disassembly:
mov eax, dword [esp + 4]
xor ecx, ecx
mov dword [eax + 0x14], ecx
mov dword [eax + 0x10], ecx
mov dword [eax], 0x67452301
mov dword [eax + 4], 0xefcdab89
mov dword [eax + 8], 0x98badcfe
mov dword [eax + 0xc], 0x10325476
ret
Function at 0x47dc30
Capabilities:
Get memory capacity

Disassembly:
mov eax, dword [0xc85e88]
sub esp, 0x20
mov ecx, dword [eax + 0x20]
test ecx, ecx
jne 0x47dc48
mov eax, 1
add esp, 0x20
ret
lea ecx, [esp]
push ecx
call dword [sym.imp.KERNEL32.dll_GlobalMemoryStatus]
mov edx, dword [0xc85e88]
mov eax, dword [edx + 0x20]
mov edx, dword [esp + 8]
shl eax, 0x14
cmp eax, edx
sbb eax, eax
inc eax
add esp, 0x20
ret

Function at 0x47dc70
Capabilities:
Get disk size

Disassembly:
sub esp, 0x14
lea eax, [esp + 0xc]
lea ecx, [esp + 8]
push eax
lea edx, [esp + 8]
push ecx
lea eax, [esp + 8]
push edx
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetDiskFreeSpaceA]
mov ecx, dword [esp]
mov edx, dword [esp + 4]
mov eax, dword [esp + 8]
mov dword [esp + 0xc], ecx
mov dword [esp + 0x10], 0
fild qword [esp + 0xc]
mov dword [esp + 0xc], edx
mov dword [esp + 0x10], 0
fimul dword [esp + 0xc]
mov dword [esp + 0xc], eax
mov dword [esp + 0x10], 0
fimul dword [esp + 0xc]
fmul dword [0x5319e4]
fcomp dword [0x5319e8]
fnstsw ax
test ah, 5
jp 0x47dce7
mov eax, 1
add esp, 0x14
ret
xor eax, eax
add esp, 0x14
ret

Function at 0x47e2d0
Capabilities:
Set registry value

Disassembly:
mov eax, dword [esp + 4]
test eax, eax
je 0x47e2e9
lea eax, [esp + 4]
push eax
push str.Software2015MOHAA
push bind
jmp 0x47e2f8
lea ecx, [esp + 4]
push ecx
push str.Software2015MOHAA
push reloc.WSOCK32.dll_bind
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyA]
test eax, eax
je 0x47e305
xor eax, eax
ret
mov edx, dword [esp + 0x14]
mov ecx, dword [esp + 0xc]
xor eax, eax
push esi
test edx, edx
mov edx, dword [esp + 0x14]
sete al
push edx
mov edx, dword [esp + 0x10]
lea eax, [eax + eax + 1]
push ecx
push eax
mov eax, dword [esp + 0x14]
push 0
push edx
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov ecx, dword [esp + 8]
mov esi, eax
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
test esi, esi
sete al
pop esi
ret

Function at 0x47e350
Capabilities:
Query or enumerate registry value

Disassembly:
push ecx
push esi
mov esi, dword [esp + 0x18]
test esi, esi
jne 0x47e35e
lea esi, [esp + 0xc]
mov eax, dword [esp + 0xc]
test eax, eax
je 0x47e377
lea eax, [esp + 0x18]
push eax
push str.Software2015MOHAA
push bind
jmp 0x47e386
lea ecx, [esp + 0x18]
push ecx
push str.Software2015MOHAA
push reloc.WSOCK32.dll_bind
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
test eax, eax
je 0x47e395
xor eax, eax
pop esi
pop ecx
ret
mov edx, dword [esp + 0x14]
mov ecx, dword [esp + 0x10]
push esi
lea eax, [esp + 8]
push edx
mov edx, dword [esp + 0x20]
push eax
push 0
push ecx
push edx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov esi, eax
mov eax, dword [esp + 0x18]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
test esi, esi
sete al
pop esi
pop ecx
ret
Function at 0x47e8b0
Capabilities:
Get disk information

Disassembly:
sub esp, 0x108
lea eax, [esp + 4]
push ebx
push eax
xor ebx, ebx
push 0x7b9a08
push str.PATH
push ebx
mov byte [0x7b9a08], bl
mov dword [esp + 0x18], 0x100
call fcn.0047e350
add esp, 0x10
test eax, eax
je 0x47e9b5
push 0x5518d0
push 0x7b9a08
push 0x5518ac
lea ecx, [esp + 0x18]
push 0x100
push ecx
call fcn.00462da0
lea edx, [esp + 0x20]
push 0x5518cc
push edx
call fcn.005186fd
add esp, 0x1c
cmp eax, ebx
je 0x47e9af
mov cl, byte [0x7b9a08]
push eax
mov byte [esp + 8], cl
mov byte [esp + 9], 0x3a
mov byte [esp + 0xa], 0x5c
mov byte [esp + 0xb], bl
call fcn.0051864f
add esp, 4
lea edx, [esp + 4]
push edx
call dword [sym.imp.KERNEL32.dll_GetDriveTypeA]
cmp eax, 5
jne 0x47e9af
push edi
mov edi, 0x7b9a08
or ecx, 0xffffffff
xor eax, eax
xor edx, edx
repne scasb al, byte es:[edi]
not ecx
dec ecx
je 0x47e988
cmp byte [edx + 0x7b9a08], 0x5c
jne 0x47e974
mov byte [edx + 0x7b9a08], 0x2f
mov edi, 0x7b9a08
or ecx, 0xffffffff
xor eax, eax
inc edx
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp edx, ecx
jb 0x47e964
dec edx
pop edi
cmp edx, ebx
jle 0x47e99c
cmp byte [edx + 0x7b9a08], 0x2f
jne 0x47e99c
dec edx
cmp edx, ebx
jg 0x47e98e
mov byte [edx + 0x7b9a09], bl
mov eax, 0x7b9a08
pop ebx
add esp, 0x108
ret
mov byte [0x7b9a08], bl
mov eax, 0x7b9a08
pop ebx
add esp, 0x108
ret

Function at 0x47f750
Capabilities:
Check mutex on windows

Disassembly:
mov eax, dword [esp + 4]
push eax
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateMutexA]
test eax, eax
mov dword [0x7b9b58], eax
je 0x47f797
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
jne 0x47f792
mov ecx, dword [0x7b9b58]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [0x7b9b58], 0
mov eax, 1
ret
mov eax, dword [0x7b9b58]
xor edx, edx
test eax, eax
sete dl
mov eax, edx
ret

Function at 0x47f7b0
Capabilities:
Check os version

Disassembly:
sub esp, 0x94
lea eax, [esp]
mov dword [esp], 0x94
push eax
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
test eax, eax
je 0x47f7e7
cmp dword [esp + 4], 5
jb 0x47f7e7
cmp dword [esp + 0x10], 2
jne 0x47f7e7
mov eax, 1
add esp, 0x94
ret
xor eax, eax
add esp, 0x94
ret
Function at 0x480180
Capabilities:
Receive data
Receive data on socket

Disassembly:
sub esp, 0x14
push ebx
push ebp
mov ebp, dword [esp + 0x24]
xor eax, eax
push esi
push edi
mov dword [esp + 0x10], eax
mov esi, dword [0x7bad20]
test eax, eax
je 0x4801a1
mov esi, dword [0x7b9b60]
test esi, esi
je 0x480308
mov edx, dword [0xc78644]
lea eax, [esp + 0x2c]
inc edx
lea ecx, [esp + 0x14]
mov dword [0xc78644], edx
mov edx, dword [ebp + 0x10]
push eax
mov eax, dword [ebp + 0xc]
push ecx
push 0
push edx
push eax
push esi
mov dword [esp + 0x44], 0x10
call dword [sym.imp.WSOCK32.dll_recvfrom]
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x480214
call dword [sym.imp.WSOCK32.dll_WSAGetLastError]
cmp eax, 0x2733
je 0x480308
cmp eax, 0x2746
je 0x480308
call fcn.0047fb80
push eax
push str.NET_GetPacket:__s_n
call fcn.0044a560
add esp, 8
jmp 0x480308
mov eax, dword [0x7bad20]
cmp esi, eax
jne 0x480227
xor ecx, ecx
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x20], ecx
mov ecx, dword [0x7bad78]
test ecx, ecx
je 0x4802c7
cmp esi, eax
jne 0x4802c7
mov ecx, dword [esp + 0x2c]
mov edi, 0x7bad04
lea esi, [esp + 0x14]
xor edx, edx
repe cmpsb byte [esi], byte es:[edi]
jne 0x4802c7
cmp ebx, 0xa
jl 0x480308
mov eax, dword [ebp + 0xc]
cmp byte [eax], 0
jne 0x480308
mov cl, byte [eax + 1]
test cl, cl
jne 0x480308
mov cl, byte [eax + 2]
test cl, cl
jne 0x480308
cmp byte [eax + 3], 1
jne 0x480308
mov esi, dword [esp + 0x28]
mov dword [esi], 4
mov eax, dword [ebp + 0xc]
mov cl, byte [eax + 4]
mov byte [esi + 4], cl
mov edx, dword [ebp + 0xc]
mov al, byte [edx + 5]
mov byte [esi + 5], al
mov ecx, dword [ebp + 0xc]
mov dl, byte [ecx + 6]
mov byte [esi + 6], dl
mov eax, dword [ebp + 0xc]
mov cl, byte [eax + 7]
mov byte [esi + 7], cl
mov edx, dword [ebp + 0xc]
mov ax, word [edx + 8]
mov word [esi + 0x12], ax
mov dword [ebp + 0x18], 0xa
jmp 0x4802e4
mov ecx, dword [esp + 0x28]
lea edx, [esp + 0x14]
push ecx
push edx
call fcn.0047fe80
mov esi, dword [esp + 0x30]
add esp, 8
mov dword [ebp + 0x18], 0
cmp ebx, dword [ebp + 0x10]
jne 0x480324
sub esp, 0x14
mov ecx, 5
mov edi, esp
rep movsd dword es:[edi], dword [esi]
call fcn.0045e520
push eax
push str.Oversize_packet_from__s_n
call fcn.0044a560
add esp, 0x1c
mov eax, dword [esp + 0x10]
inc eax
cmp eax, 2
mov dword [esp + 0x10], eax
jl 0x480191
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x14
ret
pop edi
mov dword [ebp + 0x14], ebx
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x14
ret
Function at 0x480340
Capabilities:
Send data
Send data on socket

Disassembly:
sub esp, 0x10
push ebp
push esi
mov esi, dword [esp + 0x24]
cmp esi, 3
jne 0x480356
mov ebp, dword [0x7bad20]
jmp 0x480377
cmp esi, 4
jne 0x480363
mov ebp, dword [0x7bad20]
jmp 0x480377
cmp esi, 5
je 0x480371
cmp esi, 6
jne 0x480464
mov ebp, dword [0x7b9b60]
test ebp, ebp
je 0x480473
lea eax, [esp + 8]
lea ecx, [esp + 0x24]
push eax
push ecx
call fcn.0047fdd0
mov eax, dword [0x7bad78]
add esp, 8
test eax, eax
je 0x48040e
cmp esi, 4
jne 0x48040e
mov ax, word [esp + 0xa]
mov edx, dword [esp + 0xc]
mov esi, dword [esp + 0x20]
mov word [0x7b9d08], ax
mov eax, dword [esp + 0x1c]
mov dword [0x7b9d04], edx
mov ecx, eax
push edi
mov edx, ecx
mov edi, 0x7b9d0a
shr ecx, 2
mov byte [0x7b9d00], 0
mov byte [0x7b9d01], 0
mov byte [0x7b9d02], 0
mov byte [0x7b9d03], 1
rep movsd dword es:[edi], dword [esi]
push 0x10
mov ecx, edx
push 0x7bad04
add eax, 0xa
push 0
and ecx, 3
push eax
push 0x7b9d00
rep movsb byte es:[edi], byte [esi]
push ebp
call dword [sym.imp.WSOCK32.dll_sendto]
mov esi, dword [esp + 0x28]
pop edi
jmp 0x480428
mov ecx, dword [esp + 0x1c]
mov edx, dword [esp + 0x20]
lea eax, [esp + 8]
push 0x10
push eax
push 0
push ecx
push edx
push ebp
call dword [sym.imp.WSOCK32.dll_sendto]
cmp eax, 0xffffffff
jne 0x480473
call dword [sym.imp.WSOCK32.dll_WSAGetLastError]
cmp eax, 0x2733
je 0x480473
cmp eax, 0x2741
jne 0x48044b
cmp esi, 3
je 0x480473
cmp esi, 6
je 0x480473
call fcn.0047fb80
push eax
push str.NET_SendPacket:__s_n
call fcn.0044a560
add esp, 8
pop esi
pop ebp
add esp, 0x10
ret
push str.Sys_SendPacket:_bad_address_type
push 0
call fcn.0044a830
add esp, 8
pop esi
pop ebp
add esp, 0x10
ret
Function at 0x480600
Capabilities:
Create udp socket
Set socket configuration

Disassembly:
sub esp, 0x18
push ebp
mov ebp, dword [esp + 0x24]
push esi
push edi
mov edi, dword [esp + 0x28]
mov eax, 1
test edi, edi
mov dword [esp + 0xc], eax
mov dword [esp + 0x10], eax
push ebp
je 0x480630
push edi
push str.Opening_IP_socket:__s:_i_n
call fcn.0044a560
add esp, 0xc
jmp 0x48063d
push str.Opening_IP_socket:_localhost:_i_n
call fcn.0044a560
add esp, 8
push 0x11
push 2
push 2
call dword [sym.imp.WSOCK32.dll_socket]
mov esi, eax
cmp esi, 0xffffffff
jne 0x480679
call dword [sym.imp.WSOCK32.dll_WSAGetLastError]
cmp eax, 0x273f
je 0x480670
call fcn.0047fb80
push eax
push str.WARNING:_UDP_OpenSocket:_socket:__s
call fcn.0044a560
add esp, 8
pop edi
pop esi
xor eax, eax
pop ebp
add esp, 0x18
ret
lea eax, [esp + 0xc]
push eax
push 0x8004667e
push esi
call dword [sym.imp.WSOCK32.dll_ioctlsocket]
cmp eax, 0xffffffff
jne 0x4806ab
call fcn.0047fb80
push eax
push str.WARNING:_UDP_OpenSocket:_ioctl_FIONBIO:__s_n
call fcn.0044a560
add esp, 8
xor eax, eax
pop edi
pop esi
pop ebp
add esp, 0x18
ret
lea ecx, [esp + 0x10]
push 4
push ecx
push 0x20
push 0xffff
push esi
call dword [sym.imp.WSOCK32.dll_setsockopt]
cmp eax, 0xffffffff
jne 0x4806e1
call fcn.0047fb80
push eax
push str.WARNING:_UDP_OpenSocket:_setsockopt_SO_BROADCAST:__s_n
call fcn.0044a560
add esp, 8
xor eax, eax
pop edi
pop esi
pop ebp
add esp, 0x18
ret
test edi, edi
je 0x48070c
cmp byte [edi], 0
je 0x48070c
push str.localhost
push edi
call fcn.00518070
add esp, 8
test eax, eax
je 0x48070c
lea edx, [esp + 0x14]
push edx
push edi
call fcn.0047fee0
add esp, 8
jmp 0x480714
mov dword [esp + 0x18], 0
cmp ebp, 0xffffffff
jne 0x480722
mov word [esp + 0x16], 0
jmp 0x48072e
push ebp
call dword [sym.imp.WSOCK32.dll_htons]
mov word [esp + 0x16], ax
lea eax, [esp + 0x14]
push 0x10
push eax
push esi
mov word [esp + 0x20], 2
call dword [sym.imp.WSOCK32.dll_bind]
cmp eax, 0xffffffff
jne 0x48076b
call fcn.0047fb80
push eax
push str.WARNING:_UDP_OpenSocket:_bind:__s_n
call fcn.0044a560
add esp, 8
push esi
call dword [sym.imp.WSOCK32.dll_closesocket]
pop edi
pop esi
xor eax, eax
pop ebp
add esp, 0x18
ret
mov eax, esi
pop edi
pop esi
pop ebp
add esp, 0x18
ret