joyce8/EMBER2024-capa huggingface dataset:
Function at 0x52e9df
Capabilities:
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [0x59e080]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [ebp + 8]
xor eax, eax
push 4
cmp byte [esi + 0x720], al
setne al
mov dword [ebp - 0x14], eax
lea eax, [ebp - 0x14]
push eax
push 8
push 0xffff
push dword [ebp + 0xc]
call dword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jns 0x52ea2e
push dword [ebp + 0xc]
push str.Failed_to_set_SO_KEEPALIVE_on_fd__d
push esi
call fcn.0052ccc0
add esp, 0xc
jmp 0x52ea9f
push dword [esi + 0x6b8]
mov dword [ebp - 0x10], 1
call fcn.0052ec04
push dword [esi + 0x6bc]
imul eax, eax, 0x3e8
mov dword [ebp - 0x14], eax
mov dword [ebp - 0xc], eax
call fcn.0052ec04
pop ecx
pop ecx
imul eax, eax, 0x3e8
xor ecx, ecx
push ecx
push ecx
mov dword [ebp - 0x14], eax
mov dword [ebp - 8], eax
lea eax, [ebp - 0x18]
push eax
push ecx
push ecx
push 0xc
lea eax, [ebp - 0x10]
push eax
push 0x98000004
push dword [ebp + 0xc]
call dword [sym.imp.WS2_32.dll_WSAIoctl]
test eax, eax
je 0x52ea9f
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push dword [ebp + 0xc]
push str.Failed_to_set_SIO_KEEPALIVE_VALS_on_fd__d:__d
push esi
call fcn.0052ccc0
add esp, 0x10
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.0051bf16
leave
ret

Function at 0x52eaac
Capabilities:
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x108
mov eax, dword [0x59e080]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [ebp + 8]
lea eax, [ebp - 0x108]
push 4
xor ecx, ecx
push eax
inc ecx
push ecx
push 6
push dword [ebp + 0xc]
mov dword [ebp - 0x108], ecx
call dword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jns 0x52eb0c
push 0x100
lea eax, [ebp - 0x104]
push eax
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
call fcn.0053cedc
push eax
push str.Could_not_set_TCP_NODELAY:__s
push esi
call fcn.0052ccc0
add esp, 0x18
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.0051bf16
leave
ret

Function at 0x52ebe8
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push dword [ebp + 0x10]
call fcn.0052ec11
push eax
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.005768dd
add esp, 0x10
pop ebp
ret
Function at 0x52ee3b
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
push 0x586188
xor esi, esi
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
mov dword [ebp - 4], eax
test eax, eax
je 0x52ef3e
push ebx
push edi
push 0x58619c
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov edi, dword [ebp + 8]
mov ebx, eax
push 0x5861ac
push edi
call fcn.0056ecd6
pop ecx
pop ecx
test eax, eax
je 0x52ee8d
test ebx, ebx
je 0x52ee84
push 8
jmp 0x52eea8
push edi
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
jmp 0x52eeac
test ebx, ebx
je 0x52eeb3
push str.AddDllDirectory
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x52eeb3
push 0x800
push esi
push edi
call ebx
mov esi, eax
jmp 0x52ef3a
push esi
push esi
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
mov dword [ebp - 4], eax
test eax, eax
je 0x52ef3a
push edi
call fcn.0056c33b
mov ecx, dword [ebp - 4]
add ecx, eax
lea ecx, [ecx*2 + 2]
push ecx
call dword [0x59e138]
mov edi, eax
pop ecx
pop ecx
test edi, edi
je 0x52ef32
push dword [ebp - 4]
push edi
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
test eax, eax
je 0x52ef32
push 0x581d84
push edi
call fcn.0056c33b
pop ecx
lea eax, [edi + eax*2]
push eax
call fcn.0056ecb4
pop ecx
pop ecx
push dword [ebp + 8]
push edi
call fcn.0056c33b
pop ecx
lea eax, [edi + eax*2]
push eax
call fcn.0056ecb4
pop ecx
pop ecx
test ebx, ebx
je 0x52ef29
push 8
push esi
push edi
call ebx
jmp 0x52ef30
push edi
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov esi, eax
push edi
call dword [0x59e13c]
pop ecx
pop edi
mov eax, esi
pop ebx
pop esi
leave
ret

Function at 0x52ef76
Capabilities:
Initialize winsock library

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x194
mov eax, dword [0x59e080]
xor eax, ebp
mov dword [ebp - 4], eax
test byte [ebp + 8], 2
je 0x52efc3
lea eax, [ebp - 0x194]
push eax
push 0x202
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
je 0x52efaa
push 2
pop eax
jmp 0x52f01b
mov eax, dword [ebp - 0x194]
cmp al, 2
jne 0x52efbb
shr eax, 8
cmp al, 2
je 0x52efc3
call dword [sym.imp.WS2_32.dll_WSACleanup]
jmp 0x52efa5
call fcn.00554a87
test eax, eax
jne 0x52f01b
push str.iphlpapi.dll
call fcn.0052ee3b
mov dword [0x5a0244], eax
pop ecx
test eax, eax
je 0x52eff5
push str.if_nametoindex
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x52eff5
mov dword [0x5a0240], eax
push 3
push 2
push 0
push 6
call fcn.00553ae3
add esp, 0x10
test al, al
setne byte [0x5a29f4]
push 0x5a29f8
call dword [sym.imp.KERNEL32.dll_QueryPerformanceFrequency]
xor eax, eax
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0051bf16
leave
ret

Function at 0x531175
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 8]
test esi, esi
je 0x531193
cmp dword [esi + 0x78], 0
je 0x531193
push 2
push 3
push esi
call fcn.0053098f
add esp, 0xc
push dword [ebp + 0xc]
call fcn.00530d10
pop ecx
test esi, esi
je 0x5311b0
cmp dword [esi + 0x78], 0
je 0x5311b0
push 3
push esi
call fcn.005309c8
pop ecx
pop ecx
pop esi
pop ebp
ret
Function at 0x53e2cc
Capabilities:
Move file

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
push ebx
push esi
lea eax, [ebp - 0x24]
push edi
push eax
call fcn.005309fe
push dword [ebp + 8]
mov esi, eax
lea edi, [ebp - 0x14]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
call fcn.0053d87a
push dword [ebp + 0xc]
mov esi, eax
mov dword [ebp - 4], esi
call fcn.0053d87a
add esp, 0xc
mov ebx, eax
jmp 0x53e343
lea eax, [ebp - 0x24]
push eax
call fcn.005309fe
sub esp, 0xc
lea esi, [ebp - 0x14]
mov edi, esp
sub esp, 0x10
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
mov esi, eax
mov edi, esp
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
call fcn.00530a8f
add esp, 0x20
test edx, edx
ja 0x53e36e
jb 0x53e338
cmp eax, 0x3e8
ja 0x53e36e
push 1
call dword [sym.imp.KERNEL32.dll_Sleep]
mov esi, dword [ebp - 4]
push 1
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
test eax, eax
je 0x53e303
test esi, esi
je 0x53e35c
push esi
call fcn.00561f7c
pop ecx
test ebx, ebx
je 0x53e367
push ebx
call fcn.00561f7c
pop ecx
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret
mov eax, dword [ebp - 4]
test eax, eax
je 0x53e37c
push eax
call fcn.00561f7c
pop ecx
test ebx, ebx
je 0x53e387
push ebx
call fcn.00561f7c
pop ecx
xor eax, eax
inc eax
jmp 0x53e369
Function at 0x53e38c
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Connect udp socket
Create tcp socket
Create udp socket
Get local ipv4 addresses
Get socket information
Set socket configuration
Start tcp server

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x34
mov eax, dword [0x59e080]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [sym.imp.WS2_32.dll_socket]
xor eax, eax
push esi
push edi
mov edi, dword [ebp + 0x14]
inc eax
push 6
push eax
push 2
mov dword [ebp - 0x2c], eax
pop eax
push eax
mov dword [ebp - 0x28], 0x10
call ebx
mov esi, eax
cmp esi, 0xffffffff
je 0x53e54b
push 0x10
lea eax, [ebp - 0x14]
push 0
push eax
call fcn.0055e280
add esp, 0xc
push 2
pop eax
push 0x7f000001
mov word [ebp - 0x14], ax
call dword [sym.imp.WS2_32.dll_htonl]
or dword [edi + 4], 0xffffffff
or dword [edi], 0xffffffff
mov dword [ebp - 0x10], eax
xor eax, eax
push 4
mov word [ebp - 0x12], ax
lea eax, [ebp - 0x2c]
push eax
push 4
push 0xffff
push esi
call dword [sym.imp.WS2_32.dll_setsockopt]
cmp eax, 0xffffffff
je 0x53e539
push 0x10
lea eax, [ebp - 0x14]
push eax
push esi
call dword [sym.imp.WS2_32.dll_bind]
cmp eax, 0xffffffff
je 0x53e539
lea eax, [ebp - 0x28]
push eax
lea eax, [ebp - 0x14]
push eax
push esi
call dword [sym.imp.WS2_32.dll_getsockname]
cmp eax, 0xffffffff
je 0x53e539
cmp dword [ebp - 0x28], 0x10
jl 0x53e539
push 1
push esi
call dword [sym.imp.WS2_32.dll_listen]
cmp eax, 0xffffffff
je 0x53e539
push 0
push 1
push 2
pop eax
push eax
call ebx
or ebx, 0xffffffff
mov dword [edi], eax
cmp eax, ebx
je 0x53e539
push 0x10
lea ecx, [ebp - 0x14]
push ecx
push eax
call dword [sym.imp.WS2_32.dll_connect]
cmp eax, ebx
je 0x53e539
push 1
push esi
call fcn.0055393b
pop ecx
pop ecx
test eax, eax
js 0x53e539
push 0
push 0x2710
lea eax, [ebp - 0x34]
mov dword [ebp - 0x34], esi
push 1
push eax
mov dword [ebp - 0x30], 0x300
call fcn.0053919f
add esp, 0x10
push 0
push 0
push esi
call dword [sym.imp.WS2_32.dll_accept]
mov dword [edi + 4], eax
cmp eax, ebx
je 0x53e539
lea eax, [ebp - 0x28]
mov dword [ebp - 0x28], 0x10
push eax
lea eax, [ebp - 0x14]
push eax
push dword [edi]
call dword [sym.imp.WS2_32.dll_getsockname]
cmp eax, ebx
je 0x53e539
push 0x10
pop eax
cmp dword [ebp - 0x28], eax
jl 0x53e539
mov dword [ebp - 0x28], eax
lea eax, [ebp - 0x28]
push eax
lea eax, [ebp - 0x24]
push eax
push dword [edi + 4]
call dword [sym.imp.WS2_32.dll_getpeername]
cmp eax, ebx
je 0x53e539
cmp dword [ebp - 0x28], 0x10
jl 0x53e539
mov ax, word [ebp - 0x14]
cmp ax, word [ebp - 0x24]
jne 0x53e539
mov eax, dword [ebp - 0x10]
cmp eax, dword [ebp - 0x20]
jne 0x53e539
mov ax, word [ebp - 0x12]
cmp ax, word [ebp - 0x22]
jne 0x53e539
push esi
call dword [sym.imp.WS2_32.dll_closesocket]
xor eax, eax
jmp 0x53e54e
push esi
mov esi, dword [sym.imp.WS2_32.dll_closesocket]
call esi
push dword [edi]
call esi
push dword [edi + 4]
call esi
or eax, 0xffffffff
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0051bf16
leave
ret
Function at 0x53e57c
Capabilities:
Resolve dns

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
mov eax, dword [ebp + 0x14]
push ebx
push edi
xor edi, edi
and dword [eax], edi
lea eax, [ebp - 4]
and dword [ebp - 0x10], edi
push eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.WS2_32.dll_getaddrinfo]
mov ebx, eax
test ebx, ebx
jne 0x53e6bc
push esi
mov esi, dword [ebp - 4]
test esi, esi
je 0x53e6a8
cmp dword [esi + 0x14], 0
je 0x53e5c9
push dword [esi + 0x14]
call fcn.0056c2b0
pop ecx
inc eax
jmp 0x53e5cb
xor eax, eax
cmp dword [esi + 4], 2
mov dword [ebp - 8], eax
jne 0x53e676
cmp dword [esi + 0x18], 0
je 0x53e676
cmp dword [esi + 0x10], 0
jbe 0x53e676
cmp dword [esi + 0x10], 0x10
jb 0x53e676
add eax, 0x30
push eax
call dword [0x59e138]
mov edx, eax
mov dword [ebp - 0xc], edx
pop ecx
test edx, edx
je 0x53e683
mov ecx, dword [esi]
mov dword [edx], ecx
mov ecx, dword [esi + 4]
mov dword [edx + 4], ecx
mov ecx, dword [esi + 8]
mov dword [edx + 8], ecx
mov eax, dword [esi + 0xc]
and dword [edx + 0x14], 0
and dword [edx + 0x1c], 0
push 0x10
pop ecx
mov dword [edx + 0xc], eax
lea eax, [edx + 0x20]
push ecx
mov dword [edx + 0x10], ecx
mov dword [edx + 0x18], eax
push dword [esi + 0x18]
push eax
call fcn.0055dd00
mov edx, dword [ebp - 8]
add esp, 0xc
test edx, edx
je 0x53e661
mov ecx, dword [ebp - 0xc]
push edx
mov eax, dword [ecx + 0x18]
add eax, 0x10
mov dword [ecx + 0x14], eax
push dword [esi + 0x14]
push eax
call fcn.0055dd00
add esp, 0xc
mov eax, dword [ebp - 0xc]
test edi, edi
mov ecx, dword [ebp - 0x10]
cmove edi, eax
test ecx, ecx
je 0x53e673
mov dword [ecx + 0x1c], eax
mov dword [ebp - 0x10], eax
mov esi, dword [esi + 0x1c]
test esi, esi
jne 0x53e5b7
jmp 0x53e686
push 8
pop ebx
cmp dword [ebp - 4], 0
je 0x53e695
push dword [ebp - 4]
call dword [sym.imp.WS2_32.dll_freeaddrinfo]
test ebx, ebx
je 0x53e6a4
push edi
call fcn.0053e55d
pop ecx
xor edi, edi
jmp 0x53e6b4
test edi, edi
jne 0x53e6b4
mov ebx, 0x2af9
push ebx
call dword [sym.imp.WS2_32.dll_WSASetLastError]
mov eax, dword [ebp + 0x14]
pop esi
mov dword [eax], edi
mov eax, ebx
pop edi
pop ebx
leave
ret

Function at 0x53e992
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
xor eax, eax
push eax
push eax
push dword [ebp + 0xc]
push dword [ebp + 8]
push eax
push eax
call fcn.005620eb
mov ecx, eax
add esp, 0x18
xor eax, eax
test ecx, ecx
je 0x53e9b7
cmp ecx, 0xffffffff
cmovne eax, ecx
pop ebp
ret
Function at 0x53ff6a
Capabilities:
Hash data via wincrypt
Initialize hashing via wincrypt

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
push esi
mov esi, dword [ebp + 0x14]
xor ebx, ebx
push edi
push 4
pop edi
push esi
push ebx
push dword [ebp + 0x10]
mov dword [ebp - 8], ebx
mov dword [ebp - 4], ebx
mov dword [ebp - 0xc], ebx
mov dword [ebp - 0x10], edi
mov dword [ebp + 0x14], esi
call fcn.0055e280
add esp, 0xc
lea eax, [ebp - 8]
push 0xf0000040
push dword [ebp + 0x18]
push ebx
push ebx
push eax
call dword [sym.imp.ADVAPI32.dll_CryptAcquireContextW]
test eax, eax
je 0x540023
lea eax, [ebp - 4]
push eax
push ebx
push ebx
push dword [ebp + 0x1c]
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_CryptCreateHash]
test eax, eax
je 0x540006
push ebx
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_CryptHashData]
test eax, eax
je 0x540006
push ebx
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 0xc]
push eax
push edi
push dword [ebp - 4]
mov edi, dword [sym.imp.ADVAPI32.dll_CryptGetHashParam]
call edi
test eax, eax
je 0x540006
cmp esi, dword [ebp - 0xc]
jb 0x540006
push ebx
lea eax, [ebp + 0x14]
push eax
push dword [ebp + 0x10]
push 2
push dword [ebp - 4]
call edi
cmp dword [ebp - 4], ebx
je 0x540014
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_CryptDestroyHash]
cmp dword [ebp - 8], ebx
je 0x540023
push ebx
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
pop edi
pop esi
pop ebx
leave
ret

Function at 0x546acf
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
mov eax, dword [0x59e080]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
lea ecx, [ebp - 0x18]
push ecx
lea ecx, [ebp - 0x14]
or esi, 0xffffffff
push ecx
mov ebx, dword [edi + 0xc]
mov eax, dword [ebx + 0x14c]
push eax
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x18], 0x10
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
jne 0x546b28
lea eax, [ebp - 0x18]
mov dword [ebp - 0x18], 0x10
push eax
lea eax, [ebp - 0x14]
push eax
push dword [ebp - 0x1c]
call dword [sym.imp.WS2_32.dll_accept]
mov esi, eax
push dword [ebp - 0x1c]
push ebx
push edi
call fcn.0052d372
add esp, 0xc
cmp esi, 0xffffffff
jne 0x546b4c
push str.Error_accept__ing_server_connect
push edi
call fcn.0052cc10
pop ecx
pop ecx
push 0x1e
pop eax
jmp 0x546bb6
push str.Connection_accepted_from_server
push edi
call fcn.0052ccc0
push 1
push esi
mov byte [ebx + 0x266], 0
mov dword [ebx + 0x14c], esi
call fcn.0055393b
add esp, 0x10
mov byte [ebx + 0x279], 1
cmp dword [edi + 0x1b8], 0
je 0x546bb4
push 1
push edi
call fcn.00520ac0
push 1
push esi
push dword [edi + 0x1bc]
call dword [edi + 0x1b8]
push 0
push edi
mov esi, eax
call fcn.00520ac0
add esp, 0x1c
test esi, esi
je 0x546bb4
push ebx
push edi
call fcn.00546f69
pop ecx
pop ecx
push 0x2a
jmp 0x546b49
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0051bf16
leave
ret
Function at 0x548b91
Capabilities:
Check http status code

Disassembly:
push ebp
mov ebp, esp
mov ecx, dword [ebp + 0xc]
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
lea eax, [ecx - 0xc8]
xor edi, edi
mov ebx, dword [esi + 0xc]
cmp eax, 0x64
jb 0x548bbf
push str.Couldnt_set_desired_mode
push esi
call fcn.0052cc10
pop ecx
pop ecx
push 0x11
pop eax
jmp 0x548c12
cmp ecx, 0xc8
je 0x548bd6
push ecx
push str.Got_a__03d_response_code_instead_of_the_assumed_200
push esi
call fcn.0052ccc0
add esp, 0xc
mov eax, dword [ebp + 0x10]
cmp eax, 0x13
jne 0x548be8
push ebx
push esi
call fcn.005488ac
pop ecx
jmp 0x548c0d
cmp eax, 0x14
jne 0x548bf5
push esi
call fcn.00547a7a
jmp 0x548c0d
cmp eax, 0x15
jne 0x548c02
push esi
call fcn.00548898
jmp 0x548c0d
cmp eax, 0x16
jne 0x548c10
push esi
call fcn.00548a97
mov edi, eax
pop ecx
mov eax, edi
pop edi
pop esi
pop ebx
pop ebp
ret
Function at 0x54e58c
Capabilities:
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
mov ecx, dword [ebp + 0x10]
push ebx
mov ebx, dword [ebp + 0xc]
push esi
mov esi, dword [ebp + 8]
push 0
mov byte [ebp + 0xa], cl
lea ecx, [ebp + 8]
push 3
mov eax, dword [esi + 0xc]
push ecx
mov byte [ebp + 8], 0xff
mov byte [ebp + 9], bl
push dword [eax + 0x148]
call dword [sym.imp.WS2_32.dll_send]
test eax, eax
jns 0x54e5d4
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push str.Sending_data_failed___d_
push esi
call fcn.0052cc10
add esp, 0xc
push dword [ebp + 0x10]
push ebx
push str.SENT
push esi
call fcn.0054df40
add esp, 0x10
pop esi
pop ebx
pop ebp
ret

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

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
cmp dword [ebp + 0xc], 0x1f
push ebx
mov ebx, dword [ebp + 8]
mov ecx, dword [ebx + 0x134]
mov eax, dword [ebx + 0xc]
mov dword [ebp - 4], ecx
mov dword [ebp - 8], eax
jne 0x54e855
lea edx, [ecx + 0x1cb4]
push edi
lea edi, [ecx + 0x1eb4]
mov eax, edx
mov dword [edi], edx
cmp edx, edi
jae 0x54e734
lea eax, [edx + 1]
mov byte [edx], 0xff
mov dword [edi], eax
cmp eax, edi
jae 0x54e748
mov byte [eax], 0xfa
inc dword [edi]
mov eax, dword [edi]
cmp eax, edi
jae 0x54e748
mov byte [eax], 0x1f
inc dword [edi]
movzx eax, word [ecx + 0x1ca8]
push esi
mov esi, dword [sym.imp.WS2_32.dll_htons]
push eax
call esi
movzx eax, ax
mov dword [ebp + 8], eax
mov eax, dword [ebp - 4]
movzx eax, word [eax + 0x1caa]
push eax
call esi
mov edx, dword [ebp + 8]
movzx ecx, ax
mov eax, dword [edi]
cmp eax, edi
jae 0x54e7b4
mov byte [eax], dl
inc dword [edi]
mov eax, dword [edi]
cmp eax, edi
jae 0x54e7b4
mov byte [eax], dh
inc dword [edi]
mov eax, dword [edi]
cmp eax, edi
jae 0x54e7b4
mov byte [eax], cl
inc dword [edi]
mov eax, dword [edi]
cmp eax, edi
jae 0x54e7b4
shr ecx, 8
mov byte [eax], cl
inc dword [edi]
mov eax, dword [edi]
cmp eax, edi
jae 0x54e7b4
mov byte [eax], 0xff
inc dword [edi]
mov eax, dword [edi]
cmp eax, edi
jae 0x54e7b4
mov byte [eax], 0xf0
mov eax, dword [edi]
inc eax
mov esi, dword [ebp - 4]
mov dword [esi + 0x1eb8], eax
lea ecx, [esi + 0x1cb4]
sub eax, ecx
mov dword [edi], ecx
sub eax, 2
push eax
lea eax, [esi + 0x1cb6]
push eax
push 0x3e
push ebx
call fcn.0054e029
add esp, 0x10
lea eax, [esi + 0x1cb4]
push 0
push 3
push eax
mov eax, dword [ebp - 8]
push dword [eax + 0x148]
call dword [sym.imp.WS2_32.dll_send]
mov edi, dword [sym.imp.WS2_32.dll_WSAGetLastError]
test eax, eax
jns 0x54e812
call edi
push eax
push str.Sending_data_failed___d_
push ebx
call fcn.0052cc10
add esp, 0xc
push 4
lea eax, [esi + 0x1cb7]
push eax
push ebx
call fcn.0054e5ea
add esp, 0xc
lea eax, [esi + 0x1cbb]
push 0
push 2
push eax
mov eax, dword [ebp - 8]
push dword [eax + 0x148]
call dword [sym.imp.WS2_32.dll_send]
pop esi
test eax, eax
jns 0x54e854
call edi
push eax
push str.Sending_data_failed___d_
push ebx
call fcn.0052cc10
add esp, 0xc
pop edi
pop ebx
leave
ret
Function at 0x54f762
Capabilities:
Receive data
Receive data on socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x8c
mov eax, dword [0x59e080]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
mov eax, dword [ebx + 0xc]
mov edi, dword [eax + 0x438]
lea eax, [ebp - 0x88]
push eax
mov dword [ebp - 0x88], 0x80
lea eax, [ebp - 0x84]
push eax
mov eax, dword [edi + 0x13c]
lea esi, [edi + 0x148]
push 0
add eax, 4
push eax
push dword [esi]
push dword [edi + 0x14]
call dword [sym.imp.WS2_32.dll_recvfrom]
cmp dword [edi + 0x130], 0
mov dword [edi + 0x134], eax
jne 0x54f7f0
push dword [ebp - 0x88]
lea eax, [ebp - 0x84]
push eax
lea eax, [edi + 0xb0]
push eax
call fcn.0055dd00
mov eax, dword [ebp - 0x88]
add esp, 0xc
mov dword [edi + 0x130], eax
mov edx, dword [edi + 0x134]
cmp edx, 4
jge 0x54f820
push str.Received_too_short_packet
push ebx
call fcn.0052cc10
pop ecx
pop ecx
mov dword [edi + 0xc], 7
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0051bf16
leave
ret
push esi
call fcn.0054f424
movzx eax, ax
mov dword [edi + 0xc], eax
pop ecx
sub eax, 1
je 0x54f931
sub eax, 1
je 0x54f931
sub eax, 1
je 0x54f8c2
sub eax, 1
je 0x54f944
sub eax, 1
je 0x54f878
sub eax, 1
jne 0x54f931
lea eax, [edx - 2]
push eax
mov eax, dword [esi]
add eax, 2
push eax
push edi
call fcn.0054f583
add esp, 0xc
test eax, eax
je 0x54f944
jmp 0x54f811
mov eax, dword [esi]
lea esi, [edx - 4]
add eax, 4
mov dword [ebp - 0x8c], eax
lea eax, [edi + 0x148]
push eax
call fcn.0054f40b
push esi
push dword [ebp - 0x8c]
movzx eax, ax
mov dword [edi + 8], eax
call fcn.00550179
add esp, 0xc
cmp eax, esi
jae 0x54f944
push dword [ebp - 0x8c]
push str.TFTP_error:__s
push ebx
call fcn.0052ccc0
jmp 0x54f941
cmp edx, 4
jle 0x54f944
push esi
call fcn.0054f40b
pop ecx
movzx ecx, word [edi + 0x144]
inc ecx
cmp cx, ax
jne 0x54f944
lea eax, [edx - 4]
push eax
mov eax, dword [esi]
add eax, 4
push eax
push 1
push ebx
call fcn.0052cb77
mov esi, eax
add esp, 0x10
test esi, esi
je 0x54f907
push 5
push edi
call fcn.0055006d
pop ecx
pop ecx
mov eax, esi
jmp 0x54f811
mov eax, dword [edi + 0x134]
sub eax, 4
cdq
add dword [ebx + 0x90], eax
adc dword [ebx + 0x94], edx
push dword [ebx + 0x94]
push dword [ebx + 0x90]
push ebx
call fcn.005383ad
jmp 0x54f941
push str.Internal_error:_Unexpected_packet
push 0x584ac0
push ebx
call fcn.0052cc10
add esp, 0xc
push ebx
call fcn.0053864e
pop ecx
test eax, eax
je 0x54f80f
push 5
push edi
call fcn.0055006d
pop ecx
pop ecx
push 0x2a
pop eax
jmp 0x54f811