joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4814b0
Capabilities:
Access peb ldr_data
Get process heap flags

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x6188ee
mov eax, dword fs:[0]
push eax
sub esp, 8
push esi
push edi
mov eax, dword [0x69bd40]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov dword [ebp - 0x10], edi
mov dword [0x6a62f8], edi
lea edx, [edi + 4]
mov dword [ebp - 4], 0
mov dword [0x6ab858], edx
mov dword [edx], vtable.IAbstractCharacterManager.0
lea eax, [edi + 8]
mov dword [eax], vtable.IObjectManager.0
mov dword [0x6e5fb0], eax
lea esi, [edi + 0x20]
mov dword [edi], vtable.CPythonCharacterManager.0
mov dword [edx], vtable.CPythonCharacterManager.1.0
mov dword [eax], vtable.CPythonCharacterManager.2.0
push 0x18
mov byte [ebp - 4], 2
mov dword [ebp - 0x14], esi
mov dword [esi], 0
mov dword [esi + 4], 0
call fcn.0059df22
mov dword [eax], eax
mov dword [eax + 4], eax
mov dword [eax + 8], eax
mov word [eax + 0xc], 0x101
mov dword [esi], eax
push 0xc
mov byte [ebp - 4], 3
mov dword [edi + 0x28], 0
mov dword [edi + 0x2c], 0
call fcn.0059df22
add esp, 8
mov ecx, edi
mov dword [eax], eax
mov dword [eax + 4], eax
mov dword [edi + 0x28], eax
mov dword [edi + 0x30], 0
mov dword [edi + 0x34], 0
mov dword [edi + 0x38], 0
call fcn.004825f0
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x487560
Capabilities:
Access peb ldr_data
Get ntdll base address

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x618a80
mov eax, dword fs:[0]
push eax
push ecx
push esi
mov eax, dword [0x69bd40]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
mov dword [ebp - 0x10], esi
lea ecx, [esi + 0x3c]
mov dword [esi], vtable.CPythonChat::SChatLine.0
call fcn.00512bd0
lea ecx, [esi + 0xb8]
mov dword [ebp - 4], 0
call fcn.00511a60
mov dword [esi + 0xc], 0
mov eax, esi
mov dword [esi + 0x10], 0
mov dword [esi + 0x14], 0x3f800000
mov dword [esi + 0x18], 0x3f800000
mov dword [esi + 0x1c], 0
mov dword [esi + 0x20], 0
mov dword [esi + 0x24], 0x3f800000
mov dword [esi + 0x28], 0x3f800000
mov dword [esi + 0x2c], 0
mov dword [esi + 0x30], 0
mov dword [esi + 0x34], 0x3f800000
mov dword [esi + 0x38], 0x3f800000
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x4966d0
Capabilities:
Get common file path
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
add ecx, 4
pop ebp
jmp fcn.0051e040
Function at 0x4b2be0
Capabilities:
Access peb ldr_data
Get ntdll base address

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x619eb0
mov eax, dword fs:[0]
push eax
push ecx
push esi
push edi
mov eax, dword [0x69bd40]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov dword [ebp - 0x10], edi
lea ecx, [edi + 0x4c]
call fcn.00457290
xor eax, eax
mov dword [ebp - 4], 0
push 5
mov word [edi + 0x2c], ax
mov byte [edi + 0x34], al
mov dword [edi + 0x30], eax
mov dword [edi + 0x38], eax
lea eax, [edi + 0x40]
push 0x62d9d8
push eax
mov dword [edi + 4], 0
mov dword [edi], 0
mov dword [edi + 8], 0
mov dword [edi + 0xc], 0
mov dword [edi + 0x10], 0
mov dword [edi + 0x14], 0
mov dword [edi + 0x18], 0
mov dword [edi + 0x1c], 0
mov dword [edi + 0x20], 0
mov dword [edi + 0x24], 0
mov dword [edi + 0x28], 0
call fcn.005e5520
add esp, 0xc
mov dword [edi + 0x48], 0
lea ecx, [edi + 0x4c]
mov dword [edi + 0x54], 0
mov dword [edi + 0x58], 0
call fcn.004572a0
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret

Function at 0x4b8110
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push ecx
mov dword [ebp - 4], 0x58edadb9
xor ecx, ecx
cmp byte [ebp - 4], cl
jbe 0x4b814b
mov eax, dword [ebp - 4]
xor eax, 0x80164043
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
sub eax, 0x29e08a43
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
mov dword [ecx*4 + 0x6abd18], eax
inc ecx
movzx eax, byte [ebp - 4]
cmp ecx, eax
jb 0x4b8122
movups xmm0, xmmword [0x6abdb5]
push esi
xor esi, esi
movups xmmword [0x6abcf4], xmm0
nop dword [eax]
call fcn.004f7500
mov dword [esi + 0x6abcf4], eax
add esi, 4
cmp esi, 0x10
jb 0x4b8160
push 0x10
push 0x6abd3d
push 0x6abcf4
push 0x6abd04
call fcn.004f76c0
add esp, 0x10
pop esi
mov esp, ebp
pop ebp
ret

Function at 0x4b81a0
Capabilities:
Contain obfuscated stackstrings

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [0x69bd40]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword fs:[0x2c]
mov ecx, dword [0x6e9ef4]
mov dword [ebp - 0x14], 0x6f6d6173
mov dword [ebp - 0x10], 0x73617261
mov dword [ebp - 0xc], 0x63616661
mov ecx, dword [eax + ecx*4]
mov eax, dword [0x6adb60]
mov word [ebp - 8], 0x61
cmp eax, dword [ecx + 0x20]
jg 0x4b8211
push 0x3f5
push 0
push 0
push 0x689be0
push str.pack
call dword [sym.imp.python27.dll_Py_InitModule4]
mov ecx, dword [ebp - 4]
add esp, 0x14
xor ecx, ebp
call fcn.0059df60
mov esp, ebp
pop ebp
ret
push 0x6adb60
call fcn.0059e509
add esp, 4
cmp dword [0x6adb60], 0xffffffff
jne 0x4b81e7
push 0x63e18b
lea ecx, [ebp - 0x24]
call fcn.004b7f00
mov dword [0x689be0], eax
lea ecx, [ebp - 0x24]
lea eax, [ebp - 0x14]
mov dword [0x689bec], 0
push 0x6408cd
mov dword [0x689bf0], eax
mov dword [0x689bf4], 0x4b82c0
mov dword [0x689bf8], 1
mov dword [0x689bfc], 0
call fcn.004b7ec0
xorps xmm0, xmm0
mov dword [0x689c00], eax
push 0x6adb60
mov dword [0x689c04], 0x4b83c0
mov dword [0x689c08], 1
mov dword [0x689c0c], 0
movups xmmword [0x689c10], xmm0
call fcn.0059e4bf
add esp, 4
jmp 0x4b81e7
Function at 0x4da490
Capabilities:
Read file on windows

Disassembly:
push esi
push edi
push 0x62d3b8
push str.interface.cfg
mov edi, ecx
call fcn.005e927f
mov esi, eax
add esp, 8
test esi, esi
jne 0x4da4b1
pop edi
xor al, al
pop esi
ret
push esi
push 0xc8
lea eax, [edi + 0x2650]
push 1
push eax
call fcn.005e96fe
push esi
call fcn.005e9144
add esp, 0x14
mov al, 1
pop edi
pop esi
ret

Function at 0x4da6e0
Capabilities:
Write file on windows

Disassembly:
push esi
mov esi, ecx
cmp dword [esi + 0x264c], 0
je 0x4da74f
push edi
push 0x629cd4
call dword [sym.imp.python27.dll_Py_BuildValue]
push eax
push str.OnSaveInterfaceStatus
push dword [esi + 0x264c]
call fcn.005912c0
push 0x62d388
push str.interface.cfg
call fcn.005e927f
mov edi, eax
add esp, 0x18
test edi, edi
jne 0x4da731
push str.Cannot_open_interface.cfg
call fcn.004f6e90
add esp, 4
pop edi
pop esi
ret
push edi
push 0xc8
lea eax, [esi + 0x2650]
push 1
push eax
call fcn.005e94b5
push edi
call fcn.005e9144
add esp, 0x14
pop edi
pop esi
ret

Function at 0x4dbaa0
Capabilities:
Access peb ldr_data
Get process heap flags

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x61b819
mov eax, dword fs:[0]
push eax
sub esp, 8
push esi
push edi
mov eax, dword [0x69bd40]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov dword [ebp - 0x10], edi
mov dword [0x6ab790], edi
lea esi, [edi + 4]
mov dword [edi], vtable.CPythonTextTail.0
push 0x18
mov dword [ebp - 4], 0
mov dword [ebp - 0x14], esi
mov dword [esi], 0
mov dword [esi + 4], 0
call fcn.0059df22
mov dword [eax], eax
mov dword [eax + 4], eax
mov dword [eax + 8], eax
mov word [eax + 0xc], 0x101
mov dword [esi], eax
lea esi, [edi + 0xc]
mov byte [ebp - 4], 1
push 0x18
mov dword [ebp - 0x14], esi
mov dword [esi], 0
mov dword [esi + 4], 0
call fcn.0059df22
mov dword [eax], eax
mov dword [eax + 4], eax
mov dword [eax + 8], eax
mov word [eax + 0xc], 0x101
mov dword [esi], eax
lea esi, [edi + 0x14]
mov byte [ebp - 4], 2
push 0x18
mov dword [ebp - 0x14], esi
mov dword [esi], 0
mov dword [esi + 4], 0
call fcn.0059df22
mov dword [eax], eax
mov dword [eax + 4], eax
mov dword [eax + 8], eax
mov word [eax + 0xc], 0x101
mov dword [esi], eax
push 0xc
mov byte [ebp - 4], 3
mov dword [edi + 0x1c], 0
mov dword [edi + 0x20], 0
call fcn.0059df22
mov dword [eax], eax
mov dword [eax + 4], eax
mov dword [edi + 0x1c], eax
push 0xc
mov byte [ebp - 4], 4
mov dword [edi + 0x24], 0
mov dword [edi + 0x28], 0
call fcn.0059df22
add esp, 0x14
mov ecx, edi
mov dword [eax], eax
mov dword [eax + 4], eax
mov dword [edi + 0x24], eax
mov dword [edi + 0x2c], vtable.CDynamicPool_struct_CPythonTextTail::STextTail_.0
mov dword [edi + 0x30], 0
mov dword [edi + 0x34], 0
mov dword [edi + 0x38], 0
mov dword [edi + 0x3c], 0
mov dword [edi + 0x40], 0
mov dword [edi + 0x44], 0
mov dword [edi + 0x48], 0
mov dword [edi + 0x4c], 0
call fcn.004dcab0
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x4e1b60
Capabilities:
Get common file path
Read .ini file

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x404
mov eax, dword [0x69bd40]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [ebp + 0xc]
lea eax, [ebp - 0x104]
push edi
push eax
push 0x100
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
lea eax, [ebp - 0x104]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenA]
cmp byte [ebp + eax - 0x105], 0x5c
je 0x4e1bbb
lea edi, [ebp - 0x104]
dec edi
mov al, byte [edi + 1]
lea edi, [edi + 1]
test al, al
jne 0x4e1ba8
mov ax, word [0x63fbfc]
mov word [edi], ax
lea ecx, [ebp - 0x104]
dec ecx
mov al, byte [ecx + 1]
lea ecx, [ecx + 1]
test al, al
jne 0x4e1bc2
mov eax, dword [str.metin2client.dat]
mov dword [ecx], eax
mov eax, dword [0x63fc64]
mov dword [ecx + 4], eax
mov eax, dword [0x63fc68]
mov dword [ecx + 8], eax
mov eax, dword [0x63fc6c]
mov dword [ecx + 0xc], eax
mov al, byte [0x63fc70]
mov byte [ecx + 0x10], al
call fcn.0046d130
lea edx, [ebp - 0x404]
sub edx, eax
mov cl, byte [eax]
lea eax, [eax + 1]
mov byte [edx + eax - 1], cl
test cl, cl
jne 0x4e1c00
push 7
lea eax, [ebp - 0x404]
push str.locale_
push eax
call fcn.005ef848
add esp, 0xc
test eax, eax
jne 0x4e1c44
call fcn.0046d130
lea edx, [ebp - 0x404]
lea ecx, [eax + 7]
sub edx, ecx
mov al, byte [ecx]
lea ecx, [ecx + 1]
mov byte [edx + ecx - 1], al
test al, al
jne 0x4e1c37
mov edi, dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea eax, [ebp - 0x104]
push eax
push 0x1ff
lea eax, [ebp - 0x304]
push eax
push 0
push esi
lea eax, [ebp - 0x404]
push eax
call edi
cmp byte [ebp - 0x304], 0
jne 0x4e1cd1
push 0x1ff
lea eax, [ebp - 0x304]
push eax
push dword [ebp + 8]
push dword [0x6ade80]
call dword [sym.imp.USER32.dll_LoadStringA]
cmp byte [ebp - 0x304], 0
jne 0x4e1cd1
lea eax, [ebp - 0x104]
push eax
push 0x1ff
lea eax, [ebp - 0x304]
push eax
push 0
push esi
push 0x62d9d8
call edi
cmp byte [ebp - 0x304], 0
jne 0x4e1cd1
lea ecx, [ebp - 0x304]
sub ecx, esi
mov al, byte [esi]
lea esi, [esi + 1]
mov byte [ecx + esi - 1], al
test al, al
jne 0x4e1cc4
lea eax, [ebp + 8]
mov ecx, 0x6ade84
push eax
call fcn.004e0d80
lea ecx, [ebp - 0x304]
mov esi, eax
lea edx, [ecx + 1]
nop word [eax + eax]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x4e1cf0
sub ecx, edx
lea eax, [ebp - 0x304]
push ecx
push eax
mov ecx, esi
call fcn.00457160
mov ecx, dword [ebp - 4]
mov eax, esi
pop edi
xor ecx, ebp
pop esi
call fcn.0059df60
mov esp, ebp
pop ebp
ret
Function at 0x4f7570
Capabilities:
Encode data using xor
Encrypt data using xtea

Disassembly:
push ebp
mov ebp, esp
push ebx
push esi
mov esi, dword [ebp + 0xc]
xor eax, eax
push edi
mov edi, dword [ebp + 8]
mov ebx, 0x20
mov edx, edi
mov ecx, edi
shl ecx, 4
dec ebx
shr edx, 5
xor edx, ecx
mov dword [ebp + 0xc], ebx
mov ebx, dword [ebp + 0x10]
mov ecx, eax
and ecx, 3
add edx, edi
mov ecx, dword [ebx + ecx*4]
add ecx, eax
sub eax, 0x61c88647
xor edx, ecx
add esi, edx
mov edx, esi
mov ecx, esi
shl ecx, 4
shr edx, 5
xor edx, ecx
mov ecx, eax
shr ecx, 0xb
add edx, esi
and ecx, 3
mov ecx, dword [ebx + ecx*4]
mov ebx, dword [ebp + 0xc]
add ecx, eax
xor edx, ecx
add edi, edx
test ebx, ebx
jne 0x4f7583
mov eax, dword [ebp + 0x14]
mov dword [eax], esi
mov dword [eax + 4], edi
pop edi
pop esi
pop ebx
pop ebp
ret

Function at 0x4f75e0
Capabilities:
Encode data using xor
Encrypt data using xtea

Disassembly:
push ebp
mov ebp, esp
push ebx
push esi
mov esi, dword [ebp + 0xc]
mov eax, 0xc6ef3720
push edi
mov edi, dword [ebp + 8]
mov ebx, 0x20
mov edx, esi
mov ecx, esi
shl ecx, 4
dec ebx
shr edx, 5
xor edx, ecx
mov dword [ebp + 0xc], ebx
mov ebx, dword [ebp + 0x10]
mov ecx, eax
shr ecx, 0xb
add edx, esi
and ecx, 3
mov ecx, dword [ebx + ecx*4]
add ecx, eax
add eax, 0x61c88647
xor edx, ecx
sub edi, edx
mov edx, edi
mov ecx, edi
shl ecx, 4
shr edx, 5
xor edx, ecx
mov ecx, eax
and ecx, 3
add edx, edi
mov ecx, dword [ebx + ecx*4]
mov ebx, dword [ebp + 0xc]
add ecx, eax
xor edx, ecx
sub esi, edx
test ebx, ebx
jne 0x4f75f6
mov eax, dword [ebp + 0x14]
mov dword [eax], esi
mov dword [eax + 4], edi
pop edi
pop esi
pop ebx
pop ebp
ret

Function at 0x4f7b00
Capabilities:
Create directory

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
mov esi, dword [ebp + 8]
test esi, esi
je 0x4f7ba9
cmp byte [esi], 0
je 0x4f7ba9
mov ecx, esi
lea edx, [ecx + 1]
nop
mov al, byte [ecx]
inc ecx
test al, al
jne 0x4f7b20
sub ecx, edx
cmp ecx, 3
jb 0x4f7b37
cmp byte [esi + 1], 0x3a
jne 0x4f7b37
add esi, 3
mov ecx, esi
mov dword [ebp + 8], esi
lea edx, [ecx + 1]
nop
mov al, byte [ecx]
inc ecx
test al, al
jne 0x4f7b40
sub ecx, edx
push edi
lea eax, [ecx + 1]
push eax
mov dword [ebp - 4], eax
call fcn.0059e15e
mov cl, byte [esi]
add esp, 4
mov edi, eax
test cl, cl
je 0x4f7b9f
push ebx
xor ebx, ebx
mov eax, esi
cmp cl, 0x2f
je 0x4f7b70
cmp cl, 0x5c
jne 0x4f7b92
push dword [ebp - 4]
push 0
push edi
call fcn.005dba00
push ebx
push esi
push edi
call fcn.005e5520
add esp, 0x18
push 0
push edi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
mov eax, dword [ebp + 8]
mov cl, byte [eax + 1]
inc eax
inc ebx
mov dword [ebp + 8], eax
test cl, cl
jne 0x4f7b66
pop ebx
push edi
call fcn.0059df91
add esp, 4
pop edi
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x4f8ac0
Capabilities:
Hash data with crc32

Disassembly:
push ebp
mov ebp, esp
mov edx, dword [ebp + 8]
or eax, 0xffffffff
push edi
mov edi, dword [ebp + 0xc]
cmp edi, 0x10
jb 0x4f8b52
mov ecx, edi
shr ecx, 4
push ebx
mov dword [ebp + 0xc], ecx
push esi
lea esi, [edx + 2]
mov ebx, 4
nop dword [eax + eax]
movsx ecx, byte [esi - 2]
lea esi, [esi + 4]
xor ecx, eax
shr eax, 8
movzx ecx, cl
xor eax, dword [ecx*4 + 0x68ba88]
movsx ecx, byte [esi - 5]
xor ecx, eax
shr eax, 8
movzx ecx, cl
xor eax, dword [ecx*4 + 0x68ba88]
movsx ecx, byte [esi - 4]
xor ecx, eax
shr eax, 8
movzx ecx, cl
xor eax, dword [ecx*4 + 0x68ba88]
movsx ecx, byte [esi - 3]
xor ecx, eax
shr eax, 8
movzx ecx, cl
xor eax, dword [ecx*4 + 0x68ba88]
sub ebx, 1
jne 0x4f8af0
add edx, 0x10
sub edi, 0x10
sub dword [ebp + 0xc], 1
jne 0x4f8ae0
pop esi
pop ebx
test edi, edi
je 0x4f8b70
movsx ecx, byte [edx]
lea edx, [edx + 1]
xor ecx, eax
shr eax, 8
movzx ecx, cl
xor eax, dword [ecx*4 + 0x68ba88]
sub edi, 1
jne 0x4f8b56
not eax
pop edi
pop ebp
ret
Function at 0x4f8e40
Capabilities:
Get file size

Disassembly:
push ebp
mov ebp, esp
push edi
push 0
push 0x80
push 3
push 0
push 1
push connect
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, 0xffffffff
jne 0x4f8e6b
xor eax, eax
pop edi
pop ebp
ret
push esi
push 0
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
push edi
mov esi, eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, esi
pop esi
pop edi
pop ebp
ret

Function at 0x4f8e90
Capabilities:
Get file size
Get system information on windows
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
push 0
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ebx, eax
lea eax, [ebp - 0x24]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemInfo]
push 0
push ebx
push 0
push 2
push 0
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileMappingA]
mov edi, eax
test edi, edi
je 0x4f8efe
push ebx
push 0
push 0
push 4
push edi
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov esi, eax
push ebx
push esi
call fcn.004f8ac0
add esp, 8
mov ebx, eax
test esi, esi
je 0x4f8eee
push esi
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
mov eax, ebx
pop ebx
mov esp, ebp
pop ebp
ret
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x4f9170
Capabilities:
Get system information on windows
Print debug messages
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 0x10]
sub esp, 0x24
mov edx, dword [ebp + 0xc]
push esi
mov esi, ecx
mov dword [esi + 0x130], edx
test eax, eax
jne 0x4f9193
mov eax, dword [esi + 0x114]
mov ecx, eax
jmp 0x4f9199
mov ecx, dword [esi + 0x114]
mov dword [esi + 0x134], eax
add eax, edx
cmp eax, ecx
jbe 0x4f91ae
xor eax, eax
pop esi
mov esp, ebp
pop ebp
ret 0xc
push ebx
push edi
lea eax, [ebp - 0x24]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemInfo]
mov edi, dword [esi + 0x130]
xor edx, edx
mov ecx, dword [ebp - 8]
mov eax, edi
div ecx
mov eax, dword [esi + 0x134]
mov ebx, edi
push 0
mov dword [ebp + 0x10], eax
sub ebx, edx
add eax, edi
mov dword [ebp + 0xc], ecx
push eax
push 0
push 2
push 0
push dword [esi + 0x110]
call dword [sym.imp.KERNEL32.dll_CreateFileMappingA]
mov ecx, eax
mov dword [esi + 0x12c], ecx
test ecx, ecx
jne 0x4f9212
push str.CMappedFile::Map__m_hFM_n
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
pop edi
pop ebx
xor eax, eax
pop esi
mov esp, ebp
pop ebp
ret 0xc
xor edx, edx
mov eax, edi
div dword [ebp + 0xc]
add edx, dword [ebp + 0x10]
push edx
push ebx
push 0
push 4
push ecx
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov dword [esi + 0x138], eax
test eax, eax
jne 0x4f9252
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.CMappedFile::Map__m_lpMapData__lu
call fcn.004f6e90
add esp, 8
xor eax, eax
pop edi
pop ebx
pop esi
mov esp, ebp
pop ebp
ret 0xc
sub eax, ebx
lea ecx, [eax + edi]
mov eax, dword [ebp + 8]
mov dword [esi + 0x13c], ecx
mov dword [eax], ecx
mov ecx, esi
push dword [esi + 0x13c]
mov dword [esi + 0x128], 0
push dword [esi + 0x134]
call fcn.004f9150
mov eax, dword [esi + 0x134]
pop edi
pop ebx
pop esi
mov esp, ebp
pop ebp
ret 0xc

Function at 0x4fd0f0
Capabilities:
Get file size

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
mov edi, ecx
call fcn.004fd190
push 0x104
push dword [ebp + 8]
lea eax, [edi + 8]
push eax
call fcn.005e5520
mov ebx, dword [ebp + 0xc]
add esp, 0xc
xor eax, eax
mov ecx, connect
cmp ebx, 1
setne al
push 0
add eax, 3
push 0x80
push eax
xor eax, eax
cmp ebx, 2
push 0
sete al
lea eax, [eax*2 + 1]
push eax
mov eax, 0xc0000000
cmovne eax, ecx
push eax
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [edi + 0x110], eax
cmp eax, 0xffffffff
je 0x4fd177
push 0
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov dword [edi + 0x114], eax
mov eax, 1
mov dword [edi + 4], ebx
pop edi
pop ebx
pop ebp
ret 8
mov dword [edi + 0x110], 0
xor eax, eax
pop edi
pop ebx
pop ebp
ret 8
Function at 0x505ab0
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Connect udp socket
Create tcp socket
Create udp socket
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
push edi
mov edi, ecx
call fcn.00505a30
mov eax, dword [ebp + 8]
lea esi, [edi + 0x70]
push 0
push 1
push 2
movups xmm0, xmmword [eax]
movups xmmword [esi], xmm0
call sub.WS2_32.dll_socket
mov dword [edi + 0x6c], eax
cmp eax, 0xffffffff
je 0x505b21
lea ecx, [ebp - 4]
mov dword [ebp - 4], 1
push ecx
push 0x8004667e
push eax
call sub.WS2_32.dll_ioctlsocket
mov ecx, esi
call fcn.00524e20
push eax
push esi
push dword [edi + 0x6c]
call sub.WS2_32.dll_connect
cmp eax, 0xffffffff
jne 0x505b39
call sub.WS2_32.dll_WSAGetLastError
cmp eax, 0x2733
je 0x505b39
push str.error___WSAEWOULDBLOCK
call fcn.004f7070
add esp, 4
mov ecx, edi
call fcn.00505a30
mov eax, dword [edi]
mov ecx, edi
call dword [eax + 8]
pop edi
xor al, al
pop esi
mov esp, ebp
pop ebp
ret 8
push 0
call fcn.005f167b
mov ecx, eax
add esp, 4
mov eax, dword [ebp + 0xc]
mov esi, edx
cdq
add ecx, eax
mov al, 1
mov dword [edi + 8], ecx
adc esi, edx
mov dword [edi + 0xc], esi
pop edi
pop esi
mov esp, ebp
pop ebp
ret 8

Function at 0x505d30
Capabilities:
Get socket status

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x214
mov eax, dword [0x69bd40]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, ecx
mov eax, dword [esi + 0x6c]
cmp eax, 0xffffffff
je 0x505e79
mov dword [ebp - 0x208], eax
mov dword [ebp - 0x104], eax
lea eax, [ebp - 0x214]
push eax
push 0
lea eax, [ebp - 0x108]
mov dword [ebp - 0x20c], 1
push eax
lea eax, [ebp - 0x20c]
mov dword [ebp - 0x108], 1
push eax
push 0
mov dword [ebp - 0x214], 0
mov dword [ebp - 0x210], 0
call sub.WS2_32.dll_select
cmp eax, 0xffffffff
je 0x505e79
cmp byte [esi + 0x48], 0
lea ecx, [ebp - 0x108]
mov eax, dword [esi + 0x6c]
push ecx
push eax
jne 0x505e18
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x505de1
mov eax, dword [esi]
mov ecx, esi
mov byte [esi + 0x48], 1
call dword [eax + 4]
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0059df60
mov esp, ebp
pop ebp
ret
push 0
call fcn.005f167b
add esp, 4
cmp edx, dword [esi + 0xc]
jl 0x505e79
jg 0x505dfb
cmp eax, dword [esi + 8]
jbe 0x505e79
mov ecx, esi
call fcn.00505a30
mov eax, dword [esi]
mov ecx, esi
call dword [eax + 8]
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0059df60
mov esp, ebp
pop ebp
ret
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x505e40
mov eax, dword [esi + 0x34]
cmp eax, dword [esi + 0x38]
jle 0x505e40
mov ecx, esi
call fcn.005061d0
test al, al
jne 0x505e40
call sub.WS2_32.dll_WSAGetLastError
cmp eax, 0x2733
jne 0x505e6b
lea eax, [ebp - 0x20c]
push eax
push dword [esi + 0x6c]
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x505e5e
mov ecx, esi
call fcn.005060b0
test al, al
je 0x505e6b
mov eax, dword [esi]
mov ecx, esi
mov eax, dword [eax + 0x14]
call eax
test al, al
jne 0x505e79
mov eax, dword [esi]
mov ecx, esi
call dword [eax + 0xc]
mov ecx, esi
call fcn.00505a30
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.0059df60
mov esp, ebp
pop ebp
ret