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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20c
push ebx
mov ebx, dword [ebp + 8]
mov eax, dword [ebx]
mov eax, dword [eax + 0x34c]
test eax, eax
jne 0x1002ec67
mov eax, str.unknown
push 0x1004e591
push eax
lea eax, [ebp - 0x20c]
push str._s___s_
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
lea eax, [ebp - 0x20c]
add esp, 0x10
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x1002ec8b
mov ecx, dword [ebx + 0x75d8]
sub eax, edx
lea eax, [ecx + eax + 0xd]
cmp eax, 0x7530
jbe 0x1002ecb4
mov eax, ebx
call fcn.10031325
test eax, eax
je 0x1002ed68
xor eax, eax
mov word [ebp - 0xc], ax
mov word [ebp - 0xa], ax
lea eax, [ebp - 0x20c]
mov dword [ebp - 4], 0x300feff
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x1002ecce
sub eax, edx
lea ecx, [eax + 1]
shr ecx, 8
and ecx, 0xff
inc eax
shl eax, 8
xor ecx, eax
push esi
xor eax, eax
mov word [ebp - 6], ax
mov eax, dword [ebx + 0x75d8]
push edi
mov word [ebp - 8], cx
lea edi, [eax + ebx + 0xa8]
lea esi, [ebp - 0xc]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
add dword [ebx + 0x75d8], 0xc
mov esi, dword [ebx + 0x75d8]
lea eax, [ebp - 0x20c]
lea edi, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x1002ed1e
sub eax, edi
inc eax
push eax
lea eax, [ebp - 0x20c]
push eax
lea eax, [esi + ebx + 0xa8]
push eax
call sub.ntdll.dll_memcpy
lea eax, [ebp - 0x20c]
add esp, 0xc
lea esi, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x1002ed49
sub eax, esi
inc eax
add dword [ebx + 0x75d8], eax
mov eax, ebx
call fcn.10031325
neg eax
sbb eax, eax
pop edi
neg eax
pop esi
pop ebx
leave
ret
Function at 0x1002f1c7
Capabilities:
Delete file
Get socket status
Read file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x4524
call sub.ntdll.dll__chkstk
push ebx
push esi
mov esi, ecx
mov eax, dword [esi]
xor ebx, ebx
mov dword [ebp - 4], ebx
mov eax, dword [eax + 0x324]
push edi
mov dword [ebp - 0xc], 0x2400
cmp eax, ebx
je 0x1002f1fe
push esi
call eax
pop ecx
cmp eax, 1
jne 0x1002f2a5
cmp dword [esi + 0x7638], 0xffffffff
je 0x1002f2a5
xor ecx, ecx
inc ecx
cmp dword [esi + 0x764c], ecx
jne 0x1002f2a5
mov eax, dword [esi + 0x14]
mov dword [ebp - 0x120], ecx
lea ecx, [ebp - 0x14]
push ecx
push ebx
lea ecx, [ebp - 0x120]
push ecx
mov dword [ebp - 0x11c], eax
push ebx
inc eax
push eax
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0x10], ebx
call sub.WS2_32.dll_select
test eax, eax
jle 0x1002f2a5
mov dword [ebp - 8], ebx
push ebx
lea eax, [ebp - 4]
push eax
push 0x2000
lea eax, [ebp - 0x2120]
push eax
push dword [esi + 0x7638]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x1002f26f
or dword [ebp - 4], 0xffffffff
mov edi, dword [ebp - 4]
cmp edi, 0xffffffff
je 0x1002f345
cmp edi, ebx
je 0x1002f2f7
cmp dword [esi + 0x763c], ebx
jne 0x1002f2ad
lea eax, [ebp - 0x2120]
push eax
push ebx
push esi
xor eax, eax
mov cl, 5
call fcn.1002ed9f
add esp, 0xc
inc dword [ebp - 8]
cmp dword [ebp - 8], 0x20
jl 0x1002f24a
xor eax, eax
inc eax
pop edi
pop esi
pop ebx
leave
ret
lea eax, [ebp - 0x4520]
push edi
push eax
lea eax, [ebp - 0x2120]
lea ecx, [ebp - 0xc]
call fcn.100426e1
pop ecx
pop ecx
test eax, eax
jne 0x1002f2e9
mov edi, dword [ebp - 0xc]
cmp edi, dword [ebp - 4]
jae 0x1002f2e9
lea eax, [ebp - 0x4520]
push eax
xor eax, eax
inc eax
push ebx
push esi
mov cl, 5
call fcn.1002ed9f
add esp, 0xc
jmp 0x1002f2a8
mov edi, dword [ebp - 4]
lea eax, [ebp - 0x2120]
push eax
xor eax, eax
jmp 0x1002f2db
mov cl, 6
push ebx
push ebx
xor edi, edi
xor eax, eax
push esi
call fcn.1002ed9f
add esp, 0xc
push dword [esi + 0x7638]
mov edi, eax
call fcn.1002d67f
or dword [esi + 0x7638], 0xffffffff
pop ecx
mov dword [esi + 0x764c], ebx
mov dword [esi + 0x7648], ebx
cmp dword [esi + 0x7650], ebx
je 0x1002f33e
add esi, 0x7654
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov eax, edi
jmp 0x1002f2a8
mov cl, 7
jmp 0x1002f2f9
Function at 0x10030f66
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x34
xor eax, eax
cmp dword [ebp + 0x14], eax
push ebx
mov ebx, dword [ebp + 8]
setg al
xor ecx, ecx
cmp dword [ebp + 0x10], ecx
push esi
setg cl
push edi
mov edi, eax
mov eax, dword [ebp + 0xc]
push ecx
call fcn.10032fcb
mov edx, dword [ebx + 4]
pop ecx
push dword [ebp + 0x10]
mov ecx, dword [ebx]
mov dword [ebp - 8], eax
mov eax, edx
call fcn.10037594
add esp, 4
push dword [ebp + 0x14]
mov dword [ebp + 0x10], eax
mov eax, edx
call fcn.10037594
mov dword [ebp + 0x14], eax
mov eax, dword [ebp - 8]
add esp, 4
lea edi, [ebp - 0x30]
call fcn.10033047
test eax, eax
je 0x100310ca
mov dword [ebp - 0x18], 0x1000000
mov eax, dword [ebp - 0x30]
mov edx, dword [ebp - 0x28]
mov ecx, dword [ebp - 0x2c]
sub edx, eax
mov dword [ebp + 8], eax
mov eax, dword [ebp - 0x24]
sub eax, ecx
mov dword [ebp - 0x10], eax
lea eax, [ebp - 4]
push eax
lea eax, [ebp + 8]
push eax
push dword [ebx]
mov eax, dword [ebx + 4]
mov dword [ebp - 4], ecx
lea edi, [ebp - 0x10]
lea ecx, [ebp - 0xc]
mov dword [ebp - 0xc], edx
call fcn.100375e2
mov ecx, dword [ebp + 8]
mov edx, dword [ebp + 8]
sar ecx, 8
shl edx, 8
mov eax, 0xff
and ecx, eax
xor ecx, edx
mov edx, dword [ebp - 4]
mov word [ebp - 0x20], cx
mov ecx, dword [ebp - 4]
sar ecx, 8
and ecx, eax
shl edx, 8
xor ecx, edx
mov word [ebp - 0x1e], cx
mov ecx, dword [ebp - 0xc]
mov edx, ecx
shl ecx, 8
sar edx, 8
and edx, eax
xor edx, ecx
mov ecx, dword [ebp - 0x10]
mov word [ebp - 0x1c], dx
mov edx, ecx
shl ecx, 8
sar edx, 8
and edx, eax
xor edx, ecx
mov ecx, dword [ebx + 0x75d8]
lea edi, [ebx + ecx + 0xa8]
mov ecx, dword [ebp + 8]
sub ecx, dword [ebp + 0x10]
mov word [ebp - 0x1a], dx
lea esi, [ebp - 0x20]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
add dword [ebx + 0x75d8], 0xc
mov edx, dword [ebx + 0x75d8]
mov esi, ecx
sar esi, 8
and esi, eax
shl ecx, 8
xor esi, ecx
mov ecx, dword [ebp - 4]
sub ecx, dword [ebp + 0x14]
mov word [ebp - 0x14], si
mov esi, ecx
sar esi, 8
and esi, eax
shl ecx, 8
xor esi, ecx
mov word [ebp - 0x12], si
mov eax, dword [ebp - 0x14]
mov dword [ebx + edx + 0xa8], eax
mov eax, dword [ebp - 8]
add dword [ebx + 0x75d8], 4
add esp, 0xc
lea edi, [ebp - 0x30]
call fcn.10033047
test eax, eax
jne 0x10030fd0
mov edi, dword [ebp - 8]
call fcn.10033146
pop edi
xor eax, eax
pop esi
inc eax
pop ebx
leave
ret
Function at 0x1003156a
Capabilities:
Receive data
Receive data on socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
push esi
mov esi, eax
push edi
mov edi, dword [esi + 0x2a4]
test edi, edi
je 0x10031634
cmp dword [edi + 0x2c], 0
jne 0x10031634
push 0
push 0x14
lea eax, [ebp - 0x14]
push eax
push dword [esi + 0x2a0]
call sub.WS2_32.dll_recv
test eax, eax
jle 0x100315af
movzx ecx, byte [ebp - 0x14]
sub ecx, 4
je 0x100315f7
dec ecx
je 0x100315b8
mov eax, esi
call fcn.10033977
jmp 0x10031634
cmp eax, 6
jne 0x100315af
movzx eax, word [ebp - 0x10]
mov ecx, eax
mov esi, 0xff
and ecx, esi
shr eax, 8
shl ecx, 8
or ecx, eax
movzx eax, word [ebp - 0x12]
mov edx, eax
and edx, esi
push edi
shr eax, 8
push ecx
movzx ecx, byte [ebp - 0x13]
shl edx, 8
or edx, eax
mov eax, dword [edi]
push edx
push ecx
call dword [eax + 0x30c]
add esp, 0x10
jmp 0x10031634
cmp eax, 8
jne 0x100315af
mov ecx, dword [ebp - 0x10]
mov eax, ecx
mov edx, ecx
shr edx, 0x10
and eax, 0xff0000
or eax, edx
mov edx, ecx
and edx, 0xff00
shl ecx, 0x10
or edx, ecx
mov ecx, dword [edi]
shr eax, 8
shl edx, 8
or eax, edx
push edi
push eax
movzx eax, byte [ebp - 0x13]
push eax
call dword [ecx + 0x304]
add esp, 0xc
pop edi
pop esi
leave
ret
Function at 0x10033a45
Capabilities:
Send data
Send data on socket
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push edi
push dword [ebp + 0xc]
xor ebx, ebx
push dword [ebp + 8]
inc ebx
push esi
mov dword [ebp - 4], ebx
call fcn.10033d3f
mov edi, eax
add esp, 0xc
test edi, edi
jns 0x10033a7a
mov dword [esi + 0x290], 2
or eax, 0xffffffff
jmp 0x10033b1f
push 4
lea eax, [ebp - 4]
push eax
push ebx
push 6
push edi
call dword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jns 0x10033aa0
push edi
mov dword [esi + 0x290], 2
call sub.WS2_32.dll_closesocket
jmp 0x10033a72
lea eax, [esi + 0x4c]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push 5
movzx ebx, ax
pop eax
push 0
mov word [ebp - 0xc], ax
push 4
lea eax, [ebp - 0xc]
push eax
push edi
mov word [ebp - 0xa], bx
mov byte [ebp - 8], 1
call sub.WS2_32.dll_send
cmp eax, 4
jne 0x10033a8e
push 0
push 1
lea eax, [ebp - 8]
push eax
push edi
call sub.WS2_32.dll_send
cmp eax, 1
jne 0x10033a8e
push 0
push ebx
lea eax, [esi + 0x4c]
push eax
push edi
call sub.WS2_32.dll_send
cmp eax, ebx
jne 0x10033a8e
mov ecx, dword [esi + 0x18c]
cmp ecx, 0x40
jae 0x10033b0b
mov dword [esi + ecx*4 + 0x190], edi
inc dword [esi + 0x18c]
mov ecx, dword [esi + 0x188]
cmp edi, ecx
jle 0x10033b17
mov ecx, edi
mov dword [esi + 0x188], ecx
mov eax, edi
pop edi
pop ebx
leave
ret

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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x118
push edi
jmp 0x10033ba4
push 0
push dword [ebp + 0xc]
push dword [ebp + 8]
push esi
call sub.WS2_32.dll_recv
mov edi, eax
test edi, edi
jle 0x10033b4b
add dword [ebp + 8], edi
sub dword [ebp + 0xc], edi
jmp 0x10033ba4
je 0x10033bb0
call sub.WS2_32.dll_WSAGetLastError
cmp eax, 0x2714
je 0x10033ba4
cmp eax, 0x2733
jne 0x10033bb4
mov eax, dword [ebp + 0x10]
cdq
mov ecx, 0x3e8
idiv ecx
mov dword [ebp - 0x110], esi
mov dword [ebp - 0x114], 1
mov dword [ebp - 0xc], eax
imul edx, edx, 0x3e8
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 0x114]
push eax
push 0
push eax
lea eax, [esi + 1]
push eax
mov dword [ebp - 8], edx
call sub.WS2_32.dll_select
test eax, eax
js 0x10033bad
je 0x10033bb8
cmp dword [ebp + 0xc], 0
jg 0x10033b2f
xor eax, eax
inc eax
pop edi
leave
ret
xor eax, eax
jmp 0x10033bad
mov eax, edi
jmp 0x10033bad
or eax, 0xffffffff
jmp 0x10033bad
Function at 0x10033beb
Capabilities:
Get socket status
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x11c
push ebx
push esi
mov esi, dword [eax + 0x14]
mov eax, dword [eax]
xor ebx, ebx
push edi
mov dword [ebp - 4], ebx
cmp eax, ebx
je 0x10033c16
mov eax, dword [eax + 0x2bc]
mov dword [ebp - 8], eax
cmp eax, ebx
jne 0x10033c9c
mov dword [ebp - 8], 0x4e20
jmp 0x10033c9c
push ebx
push dword [ebp + 0xc]
push dword [ebp + 8]
push esi
call sub.WS2_32.dll_send
mov edi, eax
cmp edi, ebx
jle 0x10033c3a
add dword [ebp + 8], edi
sub dword [ebp + 0xc], edi
jmp 0x10033c9c
je 0x10033cad
call sub.WS2_32.dll_WSAGetLastError
cmp eax, 0x2714
je 0x10033c9c
cmp eax, 0x2733
jne 0x10033cb1
lea eax, [ebp - 0x10]
push eax
push ebx
lea eax, [ebp - 0x118]
push eax
push ebx
lea eax, [esi + 1]
push eax
mov dword [ebp - 0x114], esi
mov dword [ebp - 0x118], 1
mov dword [ebp - 0x10], 5
mov dword [ebp - 0xc], ebx
call sub.WS2_32.dll_select
cmp eax, ebx
jl 0x10033ca8
jne 0x10033c99
add dword [ebp - 4], 0x1388
mov eax, dword [ebp - 4]
cmp eax, dword [ebp - 8]
jl 0x10033c9c
or eax, 0xffffffff
jmp 0x10033ca8
mov dword [ebp - 4], ebx
cmp dword [ebp + 0xc], ebx
jg 0x10033c1f
xor eax, eax
inc eax
pop edi
pop esi
pop ebx
leave
ret
xor eax, eax
jmp 0x10033ca8
mov eax, edi
jmp 0x10033ca8

Function at 0x10033cb5
Capabilities:
Create udp socket
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
push esi
push edi
push 0x10
pop ecx
xor al, al
push 2
lea edi, [ebp - 0x14]
rep stosb byte es:[edi], al
pop eax
push dword [ebp + 8]
xor esi, esi
inc esi
mov dword [ebp - 4], esi
mov word [ebp - 0x14], ax
call sub.WS2_32.dll_htons
push 0
mov word [ebp - 0x12], ax
mov eax, dword [ebp + 0xc]
push esi
push 2
mov dword [ebp - 0x10], eax
call sub.WS2_32.dll_socket
mov esi, eax
or edi, 0xffffffff
cmp esi, edi
jne 0x10033cfd
mov eax, edi
jmp 0x10033d3b
push 4
lea eax, [ebp - 4]
push eax
push 4
push 0xffff
push esi
call dword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jns 0x10033d1d
push esi
call sub.WS2_32.dll_closesocket
jmp 0x10033cf9
push 0x10
lea eax, [ebp - 0x14]
push eax
push esi
call sub.WS2_32.dll_bind
test eax, eax
js 0x10033d15
push 0x20
push esi
call sub.WS2_32.dll_listen
test eax, eax
js 0x10033d15
mov eax, esi
pop edi
pop esi
leave
ret
Function at 0x10033d3f
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Connect udp socket
Create tcp socket
Create udp socket
Resolve dns

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push esi
push edi
push 0x10
pop ecx
xor al, al
push 2
lea edi, [ebp - 0x10]
rep stosb byte es:[edi], al
pop eax
push dword [ebp + 0x10]
mov word [ebp - 0x10], ax
call sub.WS2_32.dll_htons
push dword [ebp + 0xc]
mov word [ebp - 0xe], ax
call sub.WS2_32.dll_inet_addr
or esi, 0xffffffff
push esi
mov dword [ebp - 0xc], eax
call dword [sym.imp.WS2_32.dll_htonl]
cmp dword [ebp - 0xc], eax
jne 0x10033d98
push dword [ebp + 0xc]
call sub.WS2_32.dll_gethostbyname
test eax, eax
jne 0x10033d8e
mov eax, esi
jmp 0x10033dd7
mov eax, dword [eax + 0xc]
mov eax, dword [eax]
mov eax, dword [eax]
mov dword [ebp - 0xc], eax
push ebx
push 0
push 1
push 2
call sub.WS2_32.dll_socket
mov ebx, eax
test ebx, ebx
js 0x10033dc0
push 0x10
lea eax, [ebp - 0x10]
push eax
push ebx
call sub.WS2_32.dll_connect
test eax, eax
jns 0x10033dc4
push ebx
call sub.WS2_32.dll_closesocket
mov eax, esi
jmp 0x10033dd6
mov edi, dword [ebp + 8]
add edi, 0x168
lea esi, [ebp - 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 eax, ebx
pop ebx
pop edi
pop esi
leave
ret

Function at 0x10033ddb
Capabilities:
Create tcp socket
Create udp socket
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
push esi
push edi
push 0x10
pop ecx
xor al, al
push 2
lea edi, [ebp - 0x14]
rep stosb byte es:[edi], al
pop eax
push dword [ebp + 8]
mov dword [ebp - 4], 1
mov word [ebp - 0x14], ax
call sub.WS2_32.dll_htons
push 0
mov word [ebp - 0x12], ax
mov eax, dword [ebp + 0xc]
push 2
push 2
mov dword [ebp - 0x10], eax
call sub.WS2_32.dll_socket
mov esi, eax
test esi, esi
jns 0x10033e23
or eax, 0xffffffff
jmp 0x10033e4d
push 4
lea eax, [ebp - 4]
push eax
push 4
push 0xffff
push esi
call dword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
js 0x10033e1e
push 0x10
lea eax, [ebp - 0x14]
push eax
push esi
call sub.WS2_32.dll_bind
test eax, eax
js 0x10033e1e
mov eax, esi
pop edi
pop esi
leave
ret
Function at 0x1003e4d5
Capabilities:
Encrypt data using des

Disassembly:
push ebp
lea ebp, [esp - 0x74]
sub esp, 0xf4
push ebx
push esi
xor ebx, ebx
push edi
xor ecx, ecx
movzx eax, byte [ecx + str.80_]
mov esi, dword [ebp + 0x7c]
mov edx, eax
sar edx, 3
mov dl, byte [edx + esi]
and eax, 7
test byte [eax*2 + 0x10052540], dl
setne al
mov byte [ebp + ecx], al
inc ecx
cmp ecx, 0x38
jl 0x1003e4e7
mov dword [ebp + 0x70], ebx
mov edi, dword [ebp + 0x70]
lea eax, [edi + edi]
lea ecx, [ebp + eax*4 - 0x7c]
lea esi, [ebp + eax*4 - 0x80]
movzx eax, byte [edi + 0x100525e8]
mov dword [ecx], ebx
mov dword [esi], ebx
xor edx, edx
mov edi, eax
cmp edi, 0x1c
jge 0x1003e53b
mov bl, byte [ebp + edi]
jmp 0x1003e53f
mov bl, byte [ebp + edi - 0x1c]
mov byte [ebp + edx + 0x38], bl
inc edx
inc edi
cmp edx, 0x1c
jl 0x1003e530
push 0x1c
pop edi
add eax, edi
cmp eax, 0x38
jge 0x1003e55a
mov dl, byte [ebp + eax]
jmp 0x1003e55e
mov dl, byte [ebp + eax - 0x1c]
mov byte [ebp + edi + 0x38], dl
inc edi
inc eax
cmp edi, 0x38
jl 0x1003e54f
xor ebx, ebx
xor eax, eax
movzx edi, byte [eax + 0x100525f8]
cmp byte [ebp + edi + 0x38], bl
je 0x1003e583
mov edi, dword [eax*4 + 0x10052550]
or dword [esi], edi
movzx edx, byte [eax + 0x10052610]
cmp byte [ebp + edx + 0x38], bl
je 0x1003e599
mov edx, dword [eax*4 + 0x10052550]
or dword [ecx], edx
inc eax
cmp eax, 0x18
jl 0x1003e56d
inc dword [ebp + 0x70]
cmp dword [ebp + 0x70], 0x10
jl 0x1003e513
lea eax, [ebp - 0x80]
push eax
call fcn.1003e5be
pop ecx
pop edi
pop esi
pop ebx
add ebp, 0x74
leave
ret
Function at 0x1003e70b
Capabilities:
Encode data using xor
Encrypt data using des

Disassembly:
push ecx
push ecx
push ebx
mov ebx, dword [esp + 0x10]
mov edx, dword [ebx]
mov ecx, dword [ebx + 4]
mov eax, edx
shr eax, 4
xor eax, ecx
and eax, 0xf0f0f0f
xor ecx, eax
shl eax, 4
xor edx, eax
mov eax, edx
shr eax, 0x10
xor eax, ecx
and eax, 0xffff
xor ecx, eax
shl eax, 0x10
xor edx, eax
mov eax, ecx
shr eax, 2
xor eax, edx
and eax, 0x33333333
xor edx, eax
shl eax, 2
xor ecx, eax
mov eax, ecx
shr eax, 8
xor eax, edx
and eax, 0xff00ff
xor edx, eax
shl eax, 8
xor eax, ecx
rol eax, 1
mov ecx, eax
xor ecx, edx
and ecx, 0xaaaaaaaa
push ebp
xor eax, ecx
xor ecx, edx
push esi
rol ecx, 1
push edi
mov edi, 0x1005a230
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x10], 8
mov edx, eax
ror edx, 4
xor edx, dword [edi]
push 0x3f
mov ecx, edx
shr ecx, 0x18
and ecx, 0x3f
mov esi, dword [ecx*4 + 0x10052628]
mov ebp, edx
shr ebp, 0x10
and ebp, 0x3f
or esi, dword [ebp*4 + 0x10052828]
mov ecx, edx
shr ecx, 8
and ecx, 0x3f
or esi, dword [ecx*4 + 0x10052a28]
and edx, 0x3f
or esi, dword [edx*4 + 0x10052c28]
mov edx, dword [edi + 4]
xor edx, eax
mov ecx, edx
shr ecx, 0x18
and ecx, 0x3f
mov ecx, dword [ecx*4 + 0x10052728]
mov ebp, edx
shr ebp, 0x10
and ebp, 0x3f
or ecx, dword [ebp*4 + 0x10052928]
mov ebp, edx
shr ebp, 8
and ebp, 0x3f
or ecx, dword [ebp*4 + 0x10052b28]
add edi, 0x10
mov ebp, ecx
pop ecx
and edx, ecx
or ebp, dword [edx*4 + 0x10052d28]
or ebp, esi
xor dword [esp + 0x1c], ebp
mov edx, dword [esp + 0x1c]
ror edx, 4
xor edx, dword [edi - 8]
mov esi, edx
shr esi, 0x18
and esi, ecx
mov esi, dword [esi*4 + 0x10052628]
mov ebp, edx
shr ebp, 0x10
and ebp, ecx
or esi, dword [ebp*4 + 0x10052828]
mov ebp, edx
shr ebp, 8
and ebp, ecx
or esi, dword [ebp*4 + 0x10052a28]
and edx, ecx
or esi, dword [edx*4 + 0x10052c28]
mov edx, dword [edi - 4]
xor edx, dword [esp + 0x1c]
mov ebp, edx
shr ebp, 0x18
and ebp, ecx
mov ebp, dword [ebp*4 + 0x10052728]
mov ecx, edx
shr ecx, 0x10
and ecx, 0x3f
or ebp, dword [ecx*4 + 0x10052928]
mov ecx, edx
shr ecx, 8
and ecx, 0x3f
or ebp, dword [ecx*4 + 0x10052b28]
and edx, 0x3f
or ebp, dword [edx*4 + 0x10052d28]
or ebp, esi
xor eax, ebp
dec dword [esp + 0x10]
jne 0x1003e789
ror eax, 1
mov edx, eax
xor edx, dword [esp + 0x1c]
pop edi
and edx, 0xaaaaaaaa
xor eax, edx
xor edx, dword [esp + 0x18]
ror edx, 1
mov ecx, edx
shr ecx, 8
xor ecx, eax
and ecx, 0xff00ff
xor eax, ecx
shl ecx, 8
xor edx, ecx
mov ecx, edx
shr ecx, 2
xor ecx, eax
and ecx, 0x33333333
xor eax, ecx
shl ecx, 2
xor edx, ecx
mov ecx, eax
shr ecx, 0x10
xor ecx, edx
and ecx, 0xffff
xor edx, ecx
shl ecx, 0x10
xor eax, ecx
mov ecx, eax
shr ecx, 4
xor ecx, edx
and ecx, 0xf0f0f0f
mov esi, ecx
shl esi, 4
xor esi, eax
mov dword [ebx], esi
pop esi
xor ecx, edx
pop ebp
mov dword [ebx + 4], ecx
pop ebx
pop ecx
pop ecx
ret
Function at 0x1003f3fb
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x3c
push ebx
push esi
mov esi, eax
push edi
mov byte [ebp - 1], 0
test esi, esi
je 0x1003f58e
cmp byte [esi], 1
jne 0x1003f58e
cmp dword [ebp + 8], 0
je 0x1003f58e
cmp dword [ebp + 0xc], 0
je 0x1003f58e
push dword [ebp + 0xc]
mov edi, dword [sym.imp.KERNEL32.dll_lstrlenW]
call edi
mov ebx, 0x103
mov dword [ebp - 0x14], eax
cmp eax, ebx
jge 0x1003f596
push dword [ebp + 8]
call edi
cmp eax, ebx
jge 0x1003f596
push dword [ebp - 0x14]
push dword [ebp + 0xc]
call fcn.10041067
pop ecx
pop ecx
mov dword [ebp - 0x14], eax
test eax, eax
je 0x1003f584
mov ebx, 0x1400
mov ecx, ebx
call fcn.10040e76
mov dword [ebp - 0xc], eax
test eax, eax
je 0x1003f584
and dword [ebp - 0x38], 0
push 8
xor eax, eax
pop ecx
push dword [ebp + 8]
lea edi, [ebp - 0x34]
rep stosd dword es:[edi], eax
lea eax, [ebp - 0x20]
mov byte [esi + 0x111], 0
call fcn.10040eb9
xor eax, eax
and dword [ebp - 0x10], eax
pop ecx
cmp byte [esi + 0xc], al
je 0x1003f4c6
lea eax, [ebp - 0x10]
push eax
push dword [ebp - 0xc]
push dword [ebp + 8]
call fcn.10040f12
add esp, 0xc
lea eax, [esi + 0xd]
mov ecx, dword [esi + 8]
test ecx, ecx
jle 0x1003f4d2
push 8
pop edx
jmp 0x1003f4d4
xor edx, edx
push dword [ebp - 0x10]
mov edi, dword [esi + 4]
push eax
push ecx
push edx
lea eax, [ebp - 0x38]
push eax
push dword [ebp - 0x14]
call fcn.1004010b
add esp, 0x18
test eax, eax
jne 0x1003f57c
xor edi, edi
push edi
push edi
push 3
push edi
push edi
push 0x80000000
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x10], eax
cmp eax, 0xffffffff
je 0x1003f57c
mov dword [ebp - 8], edi
jmp 0x1003f519
xor edi, edi
push 0
lea eax, [ebp - 8]
push eax
push ebx
push dword [ebp - 0xc]
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_ReadFile]
cmp dword [ebp - 8], ebx
jae 0x1003f541
push dword [ebp - 0x10]
call fcn.10040e8c
pop ecx
test al, al
jne 0x1003f541
or edi, 0xffffffff
cmp dword [ebp - 8], 0
jbe 0x1003f559
push dword [ebp - 8]
mov eax, dword [esi + 4]
push dword [ebp - 0xc]
call fcn.100401bd
pop ecx
pop ecx
mov edi, eax
test edi, edi
jne 0x1003f562
cmp dword [ebp - 8], edi
ja 0x1003f517
push dword [ebp - 0x10]
call fcn.1002d67f
pop ecx
test edi, edi
js 0x1003f57c
push dword [esi + 4]
call fcn.10040760
pop ecx
mov byte [ebp - 1], 1
mov esi, dword [ebp - 0xc]
call fcn.1000e820
mov esi, dword [ebp - 0x14]
call fcn.1000e820
jmp 0x1003f596
push 5
pop eax
call fcn.10040e70
mov al, byte [ebp - 1]
pop edi
pop esi
pop ebx
leave
ret

Function at 0x1003f709
Capabilities:
Generate random numbers using the delphi lcg

Disassembly:
mov eax, dword [ecx]
mov edx, eax
xor edx, dword [esp + 4]
push esi
mov esi, 0xff
and edx, esi
mov edx, dword [edi + edx*4]
shr eax, 8
xor edx, eax
mov eax, dword [ecx + 8]
mov dword [ecx], edx
movzx edx, dl
add edx, dword [ecx + 4]
imul edx, edx, 0x8088405
inc edx
mov dword [ecx + 4], edx
shr edx, 0x18
xor edx, eax
and edx, esi
shr eax, 8
xor eax, dword [edi + edx*4]
pop esi
mov dword [ecx + 8], eax
mov eax, dword [esp + 4]
ret