joyce8/EMBER2024-capa huggingface dataset:
Function at 0x425430
Capabilities:
Hash data with crc32

Disassembly:
push esi
push edi
mov edi, dword [edx]
mov eax, dword [edx + 8]
movsx ebx, bl
mov ecx, edi
xor ecx, ebx
and ecx, 0xff
mov ecx, dword [ecx*4 + 0x5899e8]
shr edi, 8
xor ecx, edi
mov dword [edx], ecx
movzx ecx, cl
add ecx, dword [edx + 4]
mov esi, eax
imul ecx, ecx, 0x8088405
add ecx, 1
mov dword [edx + 4], ecx
shr ecx, 0x18
xor ecx, eax
shr eax, 8
and ecx, 0xff
xor eax, dword [ecx*4 + 0x5899e8]
and esi, 0xfffd
mov dword [edx + 8], eax
or esi, 2
mov eax, esi
xor eax, 1
imul eax, esi
shr eax, 8
pop edi
xor eax, ebx
pop esi
ret

Function at 0x4254a0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, dword [esp + 0xc]
push esi
push edi
mov edi, dword [esp + 0x10]
mov esi, ecx
cmp byte [esi + 0x2d], 0
mov eax, edi
je 0x42551e
mov eax, dword [esi + 0x3c]
test eax, eax
je 0x4254d1
cmp dword [esi + 0x40], ebp
jae 0x4254d1
push eax
call sub.MSVCR80.dll_void___cdecl_operator_delete_void__
add esp, 4
mov dword [esi + 0x3c], 0
cmp dword [esi + 0x3c], 0
jne 0x4254ea
lea eax, [ebp + ebp]
push eax
call sub.MSVCR80.dll_void____cdecl_operator_new_unsigned_int_
add esp, 4
mov dword [esi + 0x3c], eax
mov dword [esi + 0x40], ebp
mov ecx, dword [esi + 0x3c]
push ebp
push edi
push ecx
call sub.MSVCR80.dll_memcpy
add esp, 0xc
xor edi, edi
test ebp, ebp
jbe 0x42551b
lea edx, [esi + 0x30]
push ebx
mov eax, dword [esi + 0x3c]
mov bl, byte [edi + eax]
call fcn.00425430
mov ecx, dword [esi + 0x3c]
mov byte [edi + ecx], al
add edi, 1
cmp edi, ebp
jb 0x425502
pop ebx
mov eax, dword [esi + 0x3c]
mov edx, dword [esi + 0x20]
test edx, edx
je 0x425557
mov ecx, dword [esi + 0x24]
lea edi, [ecx + ebp]
cmp edi, dword [esi + 0x28]
jb 0x42553f
pop edi
mov dword [esi + 0x14], 0x30000
pop esi
xor eax, eax
pop ebp
ret 8
push ebp
push eax
add ecx, edx
push ecx
call sub.MSVCR80.dll_memcpy
add esp, 0xc
add dword [esi + 0x24], ebp
pop edi
pop esi
mov eax, ebp
pop ebp
ret 8
mov ecx, dword [esi + 4]
test ecx, ecx
je 0x425578
push 0
lea edx, [esp + 0x14]
push edx
push ebp
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [esp + 0x10]
pop edi
pop esi
pop ebp
ret 8
pop edi
mov dword [esi + 0x14], 0x1000000
pop esi
xor eax, eax
pop ebp
ret 8
Function at 0x425700
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
push edi
mov dword [ebp - 4], 0
cmp dword [ebp + 0xc], 0
jne 0x42571c
mov eax, dword [ebp - 4]
jmp 0x4257f7
mov esi, dword [ebp + 0xc]
mov ecx, dword [ebp + 0x10]
mov eax, dword [ebp + 8]
shr ecx, 3
xor eax, 0xffffffff
test ecx, ecx
je 0x4257d2
push ebp
mov ebp, ecx
xor edx, edx
xor ecx, ecx
mov edi, edi
mov ebx, dword [esi]
add esi, 4
mov dl, bl
mov cl, bh
xor dl, al
shr eax, 8
mov edi, dword [edx*4 + 0x589430]
shr ebx, 0x10
xor eax, edi
xor cl, al
shr eax, 8
mov edi, dword [ecx*4 + 0x589430]
mov dl, bl
xor eax, edi
xor dl, al
shr eax, 8
mov edi, dword [edx*4 + 0x589430]
mov cl, bh
xor eax, edi
mov ebx, dword [esi]
xor cl, al
shr eax, 8
mov edi, dword [ecx*4 + 0x589430]
add esi, 4
xor eax, edi
mov dl, bl
mov cl, bh
xor dl, al
shr eax, 8
mov edi, dword [edx*4 + 0x589430]
shr ebx, 0x10
xor eax, edi
xor cl, al
shr eax, 8
mov edi, dword [ecx*4 + 0x589430]
mov dl, bl
xor eax, edi
xor dl, al
shr eax, 8
mov edi, dword [edx*4 + 0x589430]
mov cl, bh
xor eax, edi
xor cl, al
shr eax, 8
xor eax, dword [ecx*4 + 0x589430]
dec ebp
jne 0x42573c
pop ebp
mov ecx, dword [ebp + 0x10]
xor edx, edx
and ecx, 7
je 0x4257ee
mov dl, byte [esi]
inc esi
xor dl, al
shr eax, 8
xor eax, dword [edx*4 + 0x589430]
dec ecx
jne 0x4257dc
xor eax, 0xffffffff
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x425800
Capabilities:
Get file size
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xfffffffffffffffe
push 0x5bde98
push 0x56a94d
mov eax, dword fs:[0]
push eax
sub esp, 0x14
push ebx
push esi
push edi
mov eax, dword [0x5d7050]
xor dword [ebp - 8], eax
xor eax, ebp
push eax
lea eax, [ebp - 0x10]
mov dword fs:[0], eax
xor edi, edi
mov dword [ebp - 0x24], edi
mov dword [ebp - 0x1c], edi
mov dword [ebp - 0x20], edi
mov dword [ebp - 4], edi
push edi
push 0x80
push 3
push edi
push 1
push SysReAllocString
mov eax, dword [ebp + 8]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebx, eax
mov dword [ebp - 0x24], ebx
cmp ebx, 0xffffffff
jne 0x425889
push 0xfffffffffffffffe
lea ecx, [ebp - 0x10]
push ecx
push 0x5d7050
call sub.MSVCR80.dll__local_unwind4
add esp, 0xc
xor eax, eax
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
lea edx, [ebp - 0x1c]
push edx
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
cmp esi, 0xffffffff
jne 0x4258c2
push 0xfffffffffffffffe
lea eax, [ebp - 0x10]
push eax
push 0x5d7050
call sub.MSVCR80.dll__local_unwind4
add esp, 0xc
xor eax, eax
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push edi
push edi
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
test eax, eax
jne 0x425862
cmp dword [ebp - 0x1c], edi
ja 0x4258dd
cmp esi, 0x200000
jbe 0x4258e2
mov esi, 0x200000
push esi
call dword [sym.imp.MSVCR80.dll_malloc]
add esp, 4
mov edi, eax
mov dword [ebp - 0x20], edi
test edi, edi
jne 0x42591c
push 0xfffffffffffffffe
lea edx, [ebp - 0x10]
push edx
push 0x5d7050
call sub.MSVCR80.dll__local_unwind4
add esp, 0xc
xor eax, eax
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push 0
lea eax, [ebp - 0x1c]
push eax
push esi
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x4258f5
cmp dword [ebp - 0x1c], esi
jne 0x4258f5
push esi
push edi
push 0
call fcn.00425700
add esp, 0xc
mov dword [ebp - 0x1c], eax
test eax, eax
je 0x425862
mov dword [ebp - 4], 0xfffffffe
call fcn.00425972
mov eax, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x4260b0
Capabilities:
Set socket configuration

Disassembly:
push ecx
lea eax, [esp]
push eax
push 0x8004667e
push ecx
mov dword [esp + 0xc], 1
call sub.WS2_32.dll_ioctlsocket
pop ecx
ret
Function at 0x4260d0
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Create tcp socket
Get local ipv4 addresses
Get socket information
Start tcp server

Disassembly:
sub esp, 0x1c
mov eax, dword [0x5d7050]
xor eax, esp
mov dword [esp + 0x14], eax
push ebx
xor eax, eax
push edi
mov dword [esp + 0xc], eax
push eax
mov dword [esp + 0xc], 0x10
xor ebx, ebx
mov dword [esi + 4], 0xffffffff
mov dword [esi], 0xffffffff
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], eax
mov dword [esp + 0x1c], eax
mov word [esp + 0x10], 2
call sub.WS2_32.dll_htons
push 0x7f000001
mov word [esp + 0x12], ax
call sub.WS2_32.dll_htonl
push ebx
push 1
push 2
mov dword [esp + 0x1c], eax
call sub.WS2_32.dll_socket
mov edi, eax
cmp edi, 0xffffffff
je 0x4261cf
mov eax, dword [esp + 8]
push eax
lea ecx, [esp + 0x10]
push ecx
push edi
call sub.WS2_32.dll_bind
test eax, eax
jne 0x4261cf
push 1
push edi
call sub.WS2_32.dll_listen
test eax, eax
jne 0x4261cf
lea edx, [esp + 8]
push edx
lea eax, [esp + 0x10]
push eax
push edi
call sub.WS2_32.dll_getsockname
test eax, eax
jne 0x4261cf
push 6
push 1
push 2
call sub.WS2_32.dll_socket
cmp eax, 0xffffffff
mov dword [esi], eax
je 0x4261dc
mov ecx, dword [esp + 8]
push ecx
lea edx, [esp + 0x10]
push edx
push eax
call sub.WS2_32.dll_connect
test eax, eax
jne 0x4261cf
lea eax, [esp + 8]
push eax
lea ecx, [esp + 0x10]
push ecx
push edi
call sub.WS2_32.dll_accept
cmp eax, 0xffffffff
mov dword [esi + 4], eax
je 0x4261cf
mov edx, dword [esi]
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_SetHandleInformation]
push 1
push edx
call ebx
mov eax, dword [esi + 4]
push 0
push 1
push eax
call ebx
mov ebx, 1
jmp 0x4261f7
mov eax, dword [esi]
cmp eax, 0xffffffff
je 0x4261dc
push eax
call sub.WS2_32.dll_closesocket
mov eax, dword [esi + 4]
cmp eax, 0xffffffff
je 0x4261ea
push eax
call sub.WS2_32.dll_closesocket
mov dword [esi + 4], 0xffffffff
mov dword [esi], 0xffffffff
push edi
call sub.WS2_32.dll_closesocket
mov ecx, dword [esp + 0x1c]
pop edi
mov eax, ebx
pop ebx
xor ecx, esp
call fcn.00569ed6
add esp, 0x1c
ret

Function at 0x4262e0
Capabilities:
Get local ipv4 addresses
Get socket information
Set socket configuration

Disassembly:
sub esp, 8
movzx eax, word [edi]
push esi
push 6
push 1
push eax
mov dword [esp + 0x14], 0x10
mov dword [esp + 0x10], 1
call sub.WS2_32.dll_socket
mov esi, eax
cmp esi, 0xffffffff
je 0x42635c
push 4
lea ecx, [esp + 8]
push ecx
push 4
push 0xffff
push esi
call sub.WS2_32.dll_setsockopt
test eax, eax
jne 0x426353
push 0x10
push edi
push esi
call sub.WS2_32.dll_bind
test eax, eax
jne 0x426353
push 5
push esi
call sub.WS2_32.dll_listen
test eax, eax
jne 0x426353
mov ecx, esi
call fcn.004260b0
lea edx, [esp + 8]
push edx
push edi
push esi
call sub.WS2_32.dll_getsockname
mov eax, esi
pop esi
add esp, 8
ret
push esi
call sub.WS2_32.dll_closesocket
or eax, 0xffffffff
pop esi
add esp, 8
ret
Function at 0x4263b0
Capabilities:
Set socket configuration

Disassembly:
sub esp, 0x24
mov eax, dword [0x5d7050]
xor eax, esp
mov dword [esp + 0x1c], eax
mov edx, dword [ebx + 0x14]
push esi
push edi
lea eax, [esp + 0x10]
push eax
lea ecx, [esp + 0x18]
push ecx
push edx
xor esi, esi
mov dword [esp + 0x1c], 0x10
call sub.WS2_32.dll_accept
mov edi, eax
cmp edi, 0xffffffff
jne 0x4263ea
push eax
jmp 0x426480
push 0x40
call dword [sym.imp.MSVCR80.dll_malloc]
mov esi, eax
add esp, 4
test esi, esi
je 0x42647f
push 0x40
push 0
push esi
call sub.MSVCR80.dll_memset
add esp, 0xc
test eax, eax
je 0x42647f
push 0
push 1
push edi
call dword [sym.imp.KERNEL32.dll_SetHandleInformation]
lea eax, [esp + 0xc]
push eax
push 0x8004667e
push edi
mov dword [esp + 0x18], 1
call sub.WS2_32.dll_ioctlsocket
or dword [esi + 0x38], 0x20
mov dword [esi + 8], ebx
mov dword [esi + 0x18], edi
mov ecx, dword [ebx + 0x18]
mov dword [esi + 4], ecx
mov dword [ebx + 0x18], esi
mov eax, dword [esi + 4]
test eax, eax
mov dword [esi], 0
je 0x426455
mov dword [eax], esi
mov edx, dword [esi + 8]
mov eax, dword [edx + 0x1c]
test eax, eax
je 0x426485
lea ecx, [esp + 0x14]
push ecx
push 1
push esi
call eax
add esp, 0xc
mov eax, esi
pop edi
pop esi
mov ecx, dword [esp + 0x1c]
xor ecx, esp
call fcn.00569ed6
add esp, 0x24
ret
push edi
call sub.WS2_32.dll_closesocket
mov ecx, dword [esp + 0x24]
pop edi
mov eax, esi
pop esi
xor ecx, esp
call fcn.00569ed6
add esp, 0x24
ret

Function at 0x426500
Capabilities:
Receive data
Receive data on socket

Disassembly:
sub esp, 0x810
mov eax, dword [0x5d7050]
xor eax, esp
mov dword [esp + 0x80c], eax
test byte [ebx + 0x38], 8
mov dword [esp], 0
je 0x426592
mov edx, dword [ebx + 0x18]
lea eax, [esp + 8]
push eax
lea ecx, [esp + 8]
push ecx
push 0x1007
push 0xffff
push edx
mov dword [esp + 0x18], 1
mov dword [esp + 0x1c], 4
call sub.WS2_32.dll_getsockopt
and dword [ebx + 0x38], 0xfffffff7
cmp dword [esp + 4], 0
mov eax, dword [ebx + 0x38]
je 0x426562
or eax, 0x10
mov dword [ebx + 0x38], eax
mov eax, dword [ebx + 8]
mov eax, dword [eax + 0x1c]
test eax, eax
je 0x4265ff
lea ecx, [esp + 4]
push ecx
push 2
push ebx
call eax
add esp, 0xc
mov ecx, dword [esp + 0x80c]
xor ecx, esp
call fcn.00569ed6
add esp, 0x810
ret
mov eax, dword [ebx + 0x18]
push 0
push 0x800
lea edx, [esp + 0x14]
push edx
push eax
call sub.WS2_32.dll_recv
mov dword [esp], eax
call fcn.004264a0
test eax, eax
je 0x4265cc
or dword [ebx + 0x38], 0x10
mov ecx, dword [esp + 0x80c]
xor ecx, esp
call fcn.00569ed6
add esp, 0x810
ret
push edi
mov edi, dword [esp + 4]
test edi, edi
jle 0x4265fe
push esi
lea ecx, [esp + 0x14]
push ecx
lea esi, [ebx + 0x1c]
call fcn.00425e10
mov edx, dword [ebx + 8]
mov eax, dword [edx + 0x1c]
add esp, 4
test eax, eax
pop esi
je 0x4265fe
lea ecx, [esp + 4]
push ecx
push 3
push ebx
call eax
add esp, 0xc
pop edi
mov ecx, dword [esp + 0x80c]
xor ecx, esp
call fcn.00569ed6
add esp, 0x810
ret
Function at 0x426620
Capabilities:
Send data
Send data on socket

Disassembly:
mov eax, dword [esi + 0x2c]
mov ecx, dword [esi + 0x28]
mov edx, dword [esi + 0x18]
push edi
push 0
push eax
push ecx
push edx
call sub.WS2_32.dll_send
mov edi, eax
call fcn.004264a0
test eax, eax
je 0x426645
or dword [esi + 0x38], 0x10
jmp 0x426667
test edi, edi
jle 0x426667
mov eax, dword [esi + 0x2c]
cmp edi, eax
jg 0x426667
mov ecx, dword [esi + 0x28]
sub eax, edi
push eax
lea eax, [ecx + edi]
push eax
push ecx
call dword [sym.imp.MSVCR80.dll_memmove]
add esp, 0xc
sub dword [esi + 0x2c], edi
cmp dword [esi + 0x2c], 0
pop edi
jne 0x42667b
mov eax, dword [esi + 0x38]
test al, 1
je 0x42667b
or eax, 0x10
mov dword [esi + 0x38], eax
mov ecx, dword [esi + 8]
mov eax, dword [ecx + 0x1c]
test eax, eax
je 0x42668f
push 0
push 4
push esi
call eax
add esp, 0xc
ret
Function at 0x426960
Capabilities:
Set socket configuration

Disassembly:
push ecx
push esi
push 0x40
call dword [sym.imp.MSVCR80.dll_malloc]
mov esi, eax
add esp, 4
test esi, esi
je 0x4269d0
push 0x40
push 0
push esi
call sub.MSVCR80.dll_memset
add esp, 0xc
lea eax, [esp + 4]
push eax
push 0x8004667e
push ebx
mov dword [esp + 0x10], 1
call sub.WS2_32.dll_ioctlsocket
mov ecx, dword [esp + 0xc]
push 0
mov dword [esi + 0x18], ebx
mov dword [esi + 0xc], ecx
mov dword [esi + 8], edi
call dword [sym.imp.MSVCR80.dll__time64]
mov dword [esi + 0x10], eax
mov dword [esi + 0x14], edx
mov edx, dword [edi + 0x18]
mov dword [esi + 4], edx
mov dword [edi + 0x18], esi
mov eax, dword [esi + 4]
add esp, 4
test eax, eax
mov dword [esi], 0
je 0x4269ce
mov dword [eax], esi
mov eax, esi
pop esi
pop ecx
ret

Function at 0x4269e0
Capabilities:
Initialize winsock library

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x19c
mov eax, dword [0x5d7050]
xor eax, esp
mov dword [esp + 0x198], eax
push esi
push 0x30
push 0
push edi
call sub.MSVCR80.dll_memset
mov eax, dword [ebp + 8]
add esp, 0xc
lea ecx, [esp + 8]
push ecx
lea esi, [edi + 0x28]
push 0x202
mov dword [edi + 0x2c], 0xffffffff
mov dword [esi], 0xffffffff
mov dword [edi + 0x14], 0xffffffff
mov dword [edi], eax
mov dword [edi + 0x1c], fcn.0042e320
call sub.WS2_32.dll_WSAStartup
lea ebx, [ebx]
call fcn.004260d0
cmp dword [esi], 0xffffffff
je 0x426a40
mov ecx, dword [esp + 0x19c]
pop esi
xor ecx, esp
call fcn.00569ed6
mov esp, ebp
pop ebp
ret
Function at 0x42a900
Capabilities:
Hash data using sha1

Disassembly:
sub esp, 0x290
mov eax, dword [0x5d7050]
xor eax, esp
mov dword [esp + 0x28c], eax
mov eax, dword [esp + 0x298]
push ebp
mov ebp, dword [esp + 0x298]
push esi
push edi
push str.258EAFA5_E914_47DA_95CA_C5AB0DC85B11
push eax
push 0x58f2a8
mov esi, 0x1f4
lea edi, [esp + 0xb0]
call fcn.00426df0
mov eax, edi
add esp, 0xc
mov dword [esp + 0xc], 0x67452301
mov dword [esp + 0x10], 0xefcdab89
mov dword [esp + 0x14], 0x98badcfe
mov dword [esp + 0x18], 0x10325476
mov dword [esp + 0x1c], 0xc3d2e1f0
mov dword [esp + 0x24], 0
mov dword [esp + 0x20], 0
lea edx, [eax + 1]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x42a981
lea ecx, [esp + 0xa4]
sub eax, edx
push ecx
lea esi, [esp + 0x10]
call fcn.0042a660
mov ecx, esi
lea edi, [esp + 0x6c]
call fcn.0042a700
lea edx, [esp + 0x80]
push edx
mov eax, edi
push eax
call fcn.0042a810
push str._r_n_r_n
lea ecx, [esp + 0x8c]
push ecx
push str.HTTP_1.1_101_Switching_Protocols_r_nUpgrade:_websocket_r_nConnection:_Upgrade_r_nSec_WebSocket_Accept:
push str._s_s_s
mov esi, 0x1f4
lea edi, [esp + 0xc0]
call fcn.00426df0
mov eax, edi
add esp, 0x1c
lea edx, [eax + 1]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x42a9e8
mov esi, dword [ebp - 4]
sub eax, edx
lea edx, [esp + 0xa4]
push edx
add esi, 0x28
mov edi, eax
call fcn.00425e10
mov ecx, dword [esp + 0x29c]
add esp, 4
pop edi
pop esi
pop ebp
xor ecx, esp
call fcn.00569ed6
add esp, 0x290
ret
Function at 0x42aa30
Capabilities:
Encode data using xor
Encrypt data using rc4 prga

Disassembly:
sub esp, 8
mov eax, dword [esp + 0xc]
mov eax, dword [eax]
push ebx
push ebp
push esi
mov esi, dword [eax + 0x1c]
push edi
mov edi, dword [eax + 0x20]
xor ebx, ebx
xor ebp, ebp
xor eax, eax
cmp edi, 2
mov dword [esp + 0x10], ebx
jl 0x42aac0
movzx ecx, byte [esi + 1]
mov edx, ecx
shr ecx, 5
and ecx, 4
and edx, 0x7f
cmp edx, 0x7e
mov ebx, ecx
mov dword [esp + 0x10], ebx
jge 0x42aa7a
cmp edi, ebx
jl 0x42aa77
mov eax, edx
lea ebp, [ebx + 2]
jmp 0x42aac0
cmp edx, 0x7e
jne 0x42aa94
lea ecx, [ebx + 4]
cmp edi, ecx
jl 0x42aa94
movzx eax, byte [esi + 2]
mov ebp, ecx
movzx ecx, byte [esi + 3]
shl eax, 8
add eax, ecx
jmp 0x42aac0
lea ecx, [ebx + 0xa]
cmp edi, ecx
jl 0x42aac0
mov edx, dword [esi + 2]
push edx
mov ebp, ecx
call sub.WS2_32.dll_htonl
xor edx, edx
mov cl, 0x20
call fcn.0056baa0
mov dword [esp + 0x14], eax
mov eax, dword [esi + 6]
push eax
call sub.WS2_32.dll_htonl
add eax, dword [esp + 0x14]
lea ecx, [eax + ebp]
test ecx, ecx
mov dword [esp + 0x14], ecx
jle 0x42aacf
cmp ecx, edi
jle 0x42aad9
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 8
ret
test ebx, ebx
mov ecx, dword [esp + 0x1c]
mov edx, ecx
lea edi, [esi + ebp]
mov dword [ecx + 0x144], eax
mov dword [edx + 0x140], edi
movzx ecx, byte [esi]
mov dword [edx + 0x150], ecx
jle 0x42ab1a
xor ecx, ecx
test eax, eax
jle 0x42ab1a
mov ebx, ecx
and ebx, 3
sub ebx, dword [esp + 0x10]
add ecx, 1
add ebx, ebp
mov bl, byte [ebx + esi]
xor byte [edi + ecx - 1], bl
cmp ecx, eax
jl 0x42ab01
mov eax, dword [edx + 0x15c]
test eax, eax
je 0x42ab3e
mov eax, dword [eax + 0x40]
test eax, eax
je 0x42ab3e
add edx, 4
push 0x67
push edx
call eax
mov edx, dword [esp + 0x24]
add esp, 8
test eax, eax
jne 0x42ab44
mov eax, dword [edx]
or dword [eax + 0x38], 1
mov esi, dword [edx]
mov eax, dword [esi + 0x20]
mov edi, dword [esp + 0x14]
add esi, 0x1c
cmp edi, eax
jg 0x42ab6a
mov ecx, dword [esi]
sub eax, edi
push eax
lea edx, [ecx + edi]
push edx
push ecx
call dword [sym.imp.MSVCR80.dll_memmove]
add esp, 0xc
sub dword [esi + 4], edi
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 8
ret
Function at 0x42b9a0
Capabilities:
Check if file exists
Get file attributes

Disassembly:
mov eax, 0x4004
call fcn.0056a4b0
mov eax, dword [0x5d7050]
xor eax, esp
mov dword [esp + 0x4000], eax
push esi
push edi
mov esi, ecx
xor edi, edi
test esi, esi
jne 0x42b9e6
push 0xa0
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov eax, edi
pop edi
pop esi
mov ecx, dword [esp + 0x4000]
xor ecx, esp
call fcn.00569ed6
add esp, 0x4004
ret
push ebx
push 0x2254
call dword [sym.imp.MSVCR80.dll_malloc]
mov ebx, eax
add esp, 4
test ebx, ebx
jne 0x42ba1d
push 8
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov eax, ebx
pop ebx
pop edi
pop esi
mov ecx, dword [esp + 0x4000]
xor ecx, esp
call fcn.00569ed6
add esp, 0x4004
ret
push esi
mov esi, 0x2000
lea edi, [esp + 0x10]
call fcn.00426ad0
add esp, 4
mov eax, edi
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x42ba97
test al, 0x10
je 0x42ba97
mov eax, edi
add eax, 0xfffffffe
mov cx, word [eax + 2]
add eax, 2
test cx, cx
jne 0x42ba46
mov ecx, dword [0x58f4fc]
mov dx, word [0x58f500]
mov dword [eax], ecx
mov word [eax + 4], dx
lea eax, [ebx + 4]
push eax
lea ecx, [esp + 0x10]
push ecx
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov dword [ebx], eax
mov byte [ebx + 0x254], 0
mov eax, ebx
pop ebx
pop edi
pop esi
mov ecx, dword [esp + 0x4000]
xor ecx, esp
call fcn.00569ed6
add esp, 0x4004
ret
push ebx
call dword [sym.imp.MSVCR80.dll_free]
mov ecx, dword [esp + 0x4010]
add esp, 4
pop ebx
pop edi
pop esi
xor ecx, esp
xor eax, eax
call fcn.00569ed6
add esp, 0x4004
ret

Function at 0x42c320
Capabilities:
Create directory

Disassembly:
cmp dword [ebx + 0x144], 0
push esi
push edi
mov esi, 0x1f4
jbe 0x42c345
mov esi, 0x19f
push 0
push esi
mov ecx, ebx
call fcn.004271d0
add esp, 8
pop edi
pop esi
ret
push eax
call dword [sym.imp.MSVCR80.dll__mkdir]
add esp, 4
test eax, eax
jne 0x42c367
push eax
mov esi, 0xc9
push esi
mov ecx, ebx
call fcn.004271d0
add esp, 8
pop edi
pop esi
ret
mov edi, dword [sym.imp.MSVCR80.dll__errno]
call edi
cmp dword [eax], 0x11
jne 0x42c389
mov esi, 0x195
push 0
push esi
mov ecx, ebx
call fcn.004271d0
add esp, 8
pop edi
pop esi
ret
call edi
cmp dword [eax], 0xd
jne 0x42c3a5
mov esi, 0x193
push 0
push esi
mov ecx, ebx
call fcn.004271d0
add esp, 8
pop edi
pop esi
ret
call edi
cmp dword [eax], 2
jne 0x42c3b1
mov esi, 0x199
push 0
push esi
mov ecx, ebx
call fcn.004271d0
add esp, 8
pop edi
pop esi
ret
Function at 0x42c3d0
Capabilities:
Delete directory
Delete file

Disassembly:
mov eax, 0x2048
call fcn.0056a4b0
mov eax, dword [0x5d7050]
xor eax, esp
mov dword [esp + 0x2044], eax
push ebx
push ebp
mov ebp, dword [esp + 0x2054]
push esi
push edi
mov ecx, ebp
call fcn.0042b9a0
mov ebx, eax
test ebx, ebx
mov dword [esp + 0x14], ebx
je 0x42c4a4
mov esi, ebx
call fcn.0042bb00
test eax, eax
je 0x42c48e
mov edi, 0x58f1ac
mov esi, eax
mov ecx, 2
xor edx, edx
repe cmpsb byte [esi], byte es:[edi]
je 0x42c483
mov edi, 0x58f504
mov esi, eax
mov ecx, 3
xor edx, edx
repe cmpsb byte [esi], byte es:[edi]
je 0x42c483
push eax
push 0x2f
push ebp
push str._s_c_s
mov esi, 0x2000
lea edi, [esp + 0x60]
call fcn.00426df0
mov eax, edi
push eax
lea ebx, [esp + 0x2c]
call fcn.00426bf0
add esp, 0x14
test dword [esp + 0x1e], 0x4000
je 0x42c471
mov ecx, edi
push ecx
call fcn.0042c3d0
jmp 0x42c47c
lea edx, [esp + 0x50]
push edx
call dword [sym.imp.MSVCR80.dll_remove]
mov ebx, dword [esp + 0x18]
add esp, 4
mov esi, ebx
call fcn.0042bb00
test eax, eax
jne 0x42c413
mov edi, ebx
call fcn.0042bac0
push ebp
call dword [sym.imp.MSVCR80.dll__rmdir]
add esp, 4
mov eax, 1
mov ecx, dword [esp + 0x2054]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.00569ed6
add esp, 0x2048
ret

Function at 0x42c4c0
Capabilities:
Delete file

Disassembly:
sub esp, 0x40
push ebx
push esi
lea ebx, [esp + 0xc]
call fcn.00426bf0
add esp, 4
test eax, eax
je 0x42c4eb
push 0
push 0x194
mov ecx, edi
call fcn.004271d0
add esp, 8
pop ebx
add esp, 0x40
ret
test dword [esp + 0xe], 0x4000
push esi
je 0x42c514
call fcn.0042c3d0
add esp, 4
push 0
push 0xcc
mov ecx, edi
call fcn.004271d0
add esp, 8
pop ebx
add esp, 0x40
ret
call dword [sym.imp.MSVCR80.dll_remove]
add esp, 4
test eax, eax
push 0
jne 0x42c500
push 0x1a7
mov ecx, edi
call fcn.004271d0
add esp, 8
pop ebx
add esp, 0x40
ret

Function at 0x42ccd0
Capabilities:
Read file on windows

Disassembly:
mov eax, 0x2004
call fcn.0056a4b0
mov eax, dword [0x5d7050]
xor eax, esp
mov dword [esp + 0x2000], eax
push ebp
mov ebp, dword [esp + 0x200c]
push ebx
push 0x2000
lea eax, [esp + 0xc]
push 1
push eax
call dword [sym.imp.MSVCR80.dll_fread]
add esp, 0x10
test eax, eax
jle 0x42cd3e
push esi
push edi
lea esp, [esp]
mov esi, dword [ebp - 4]
lea ecx, [esp + 0xc]
push ecx
add esi, 0x28
mov edi, eax
call fcn.00425e10
push ebx
push 0x2000
lea edx, [esp + 0x18]
push 1
push edx
call dword [sym.imp.MSVCR80.dll_fread]
add esp, 0x14
test eax, eax
jg 0x42cd10
pop edi
pop esi
mov ecx, dword [esp + 0x2004]
pop ebp
xor ecx, esp
call fcn.00569ed6
add esp, 0x2004
ret
Function at 0x42df80
Capabilities:
Read file on windows

Disassembly:
mov eax, 0x200c
call fcn.0056a4b0
mov eax, dword [0x5d7050]
xor eax, esp
mov dword [esp + 0x2004], eax
mov eax, dword [ebx + 0x160]
cmp eax, 0x1f
push esi
push edi
jbe 0x42dfaf
mov dword [ebx + 0x160], 0xffffffff
mov edx, dword [ebx + 0x160]
cmp edx, 0xffffffff
je 0x42e030
mov eax, dword [ebx + 0x17c]
test eax, eax
mov ecx, dword [ebx + 0x178]
jl 0x42e030
jg 0x42dfd0
test ecx, ecx
jbe 0x42e030
test eax, eax
jg 0x42dfe2
jl 0x42dfde
cmp ecx, 0x2000
jae 0x42dfe2
mov eax, ecx
jmp 0x42dfe7
mov eax, 0x2000
push eax
lea eax, [esp + 0xc]
push eax
push edx
call dword [sym.imp.MSVCR80.dll__read]
mov edi, eax
add esp, 0xc
test edi, edi
jle 0x42e030
mov esi, dword [ebx]
cdq
sub dword [ebx + 0x178], eax
lea ecx, [esp + 8]
push ecx
sbb dword [ebx + 0x17c], edx
add esi, 0x28
call fcn.00425e10
add esp, 4
cmp dword [ebx + 0x17c], 0
jg 0x42e039
jl 0x42e030
cmp dword [ebx + 0x178], 0
ja 0x42e039
push ebx
call fcn.0042dde0
add esp, 4
mov ecx, dword [esp + 0x200c]
pop edi
pop esi
xor ecx, esp
call fcn.00569ed6
add esp, 0x200c
ret