joyce8/EMBER2024-capa huggingface dataset:
Function at 0x403dbc
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
push edi
xor ecx, ecx
xor eax, eax
cmp dword [ebp + 8], 0xffffffff
mov dword [ebp - 0x18], ecx
lea edi, [ebp - 0x14]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
mov dword [ebp - 4], ecx
je 0x403e05
mov eax, dword [ebp + 0xc]
mov ecx, 0x200
mul ecx
mov dword [ebp - 0x10], eax
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 4]
push eax
push 0x400
push dword [ebp + 0x10]
mov dword [ebp - 0xc], edx
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov ecx, eax
mov eax, ecx
pop edi
leave
ret

Function at 0x403fee
Capabilities:
Get common file path

Disassembly:
cmp dword [esp + 4], 0
je 0x404005
push dword [esp + 8]
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
ret
push esi
mov esi, 0x104
push esi
push dword [esp + 0x10]
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
push 0x41fd34
push esi
push dword [esp + 0x14]
call fcn.00408e4e
add esp, 0xc
pop esi
ret

Function at 0x404148
Capabilities:
Get common file path
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x194]
sub esp, 0x214
mov eax, dword [0x422040]
xor eax, ebp
mov dword [ebp + 0x190], eax
push esi
xor eax, eax
push 0x206
push eax
mov word [ebp - 0x78], ax
lea eax, [ebp - 0x76]
push eax
xor esi, esi
call fcn.00411ad0
add esp, 0xc
test edi, edi
je 0x40420e
and dword [ebp - 0x7c], esi
mov ecx, 0x41fdb4
mov eax, ecx
lea esi, [eax + 2]
mov dx, word [eax]
inc eax
inc eax
test dx, dx
jne 0x404193
sub eax, esi
sar eax, 1
je 0x4041b7
push 0x41fdb8
push ecx
lea eax, [ebp - 0x7c]
push eax
call fcn.00409455
add esp, 0xc
jmp 0x4041eb
lea eax, [ebp - 0x78]
push eax
mov esi, 0x104
push esi
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
push 0x41fcf8
lea eax, [ebp - 0x78]
push esi
push eax
call fcn.00408e4e
push 0x41fdb8
lea eax, [ebp - 0x78]
push eax
lea eax, [ebp - 0x7c]
push eax
call fcn.00409455
add esp, 0x18
xor esi, esi
inc esi
cmp dword [ebp - 0x7c], 0
je 0x40420e
push dword [ebp - 0x7c]
push esi
push 0x200
push edi
call fcn.0040960a
push dword [ebp - 0x7c]
call fcn.00409703
add esp, 0x14
mov ecx, dword [ebp + 0x190]
mov eax, esi
xor ecx, ebp
pop esi
call fcn.00408e3f
add ebp, 0x194
leave
ret
Function at 0x404226
Capabilities:
Read file on windows
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push ebx
push edi
push 0x41fd2c
push dword [ebp + 8]
mov ebx, eax
lea eax, [ebp - 4]
xor edi, edi
push eax
mov dword [ebp - 4], edi
call fcn.00409455
add esp, 0xc
test eax, eax
je 0x404253
xor eax, eax
jmp 0x4042d3
push esi
push 2
push edi
push dword [ebp - 4]
call fcn.0040a7d2
push dword [ebp - 4]
call fcn.0040a6da
push edi
push edi
push dword [ebp - 4]
mov esi, eax
call fcn.0040a7d2
lea eax, [esi + ebx]
push eax
mov dword [ebp - 8], eax
call fcn.004091f6
push dword [ebp - 4]
mov edi, eax
push 1
push esi
push edi
call fcn.0040a2e8
push dword [ebp - 4]
call fcn.00409703
push ebx
lea ebx, [edi + esi]
call fcn.004042d7
push 0x41fdb8
push dword [ebp + 0xc]
lea eax, [ebp - 4]
push eax
call fcn.00409455
add esp, 0x44
pop esi
test eax, eax
jne 0x40424c
push dword [ebp - 4]
push 1
push dword [ebp - 8]
push edi
call fcn.0040960a
push dword [ebp - 4]
call fcn.00409703
xor eax, eax
add esp, 0x14
inc eax
pop edi
pop ebx
leave
ret
Function at 0x4047d3
Capabilities:
Get local ipv4 addresses
Get mac address on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push esi
xor esi, esi
push edi
mov dword [ebp - 8], esi
mov dword [ebp - 0xc], 0x3a98
push dword [ebp - 0xc]
push esi
call ebx
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov dword [ebp - 4], eax
cmp eax, esi
je 0x404852
lea ecx, [ebp - 0xc]
push ecx
push eax
push esi
push 0x10
push 2
call sub.IPHLPAPI.DLL_GetAdaptersAddresses
mov edi, eax
cmp edi, 0x6f
jne 0x404828
push dword [ebp - 4]
push esi
call ebx
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov dword [ebp - 4], esi
inc dword [ebp - 8]
cmp edi, 0x6f
jne 0x404857
cmp dword [ebp - 8], 3
jb 0x4047ee
push 0xfffffffffffffffd
pop edi
cmp dword [ebp - 4], esi
je 0x40484b
push dword [ebp - 4]
push esi
call ebx
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov eax, edi
pop edi
pop esi
pop ebx
leave
ret
or edi, 0xffffffff
jmp 0x40484b
cmp edi, esi
jne 0x404836
mov eax, dword [ebp - 4]
jmp 0x40486e
cmp dword [eax + 0x34], 6
jne 0x40486b
cmp dword [eax + 0x1c], esi
jne 0x404874
mov eax, dword [eax + 8]
cmp eax, esi
jne 0x404860
jmp 0x4048b1
mov edi, dword [ebp + 8]
lea esi, [eax + 0x2c]
movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
mov ecx, dword [eax + 0x10]
mov ecx, dword [ecx + 0xc]
mov cl, byte [ecx + 4]
mov esi, dword [ebp + 0xc]
mov byte [esi + 3], cl
mov ecx, dword [eax + 0x10]
mov ecx, dword [ecx + 0xc]
mov cl, byte [ecx + 5]
mov byte [esi + 2], cl
mov ecx, dword [eax + 0x10]
mov ecx, dword [ecx + 0xc]
mov cl, byte [ecx + 6]
mov byte [esi + 1], cl
mov eax, dword [eax + 0x10]
mov eax, dword [eax + 0xc]
mov al, byte [eax + 7]
mov byte [esi], al
xor esi, esi
xor edi, edi
jmp 0x404839
Function at 0x404b98
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
lea ebp, [esp - 0x39c]
sub esp, 0x41c
mov eax, dword [0x422040]
xor eax, ebp
mov dword [ebp + 0x398], eax
push dword [ebp + 0x3a4]
mov dword [ebp - 0x80], ecx
call fcn.00404cc5
pop ecx
mov dword [ebp - 0x7c], eax
test eax, eax
jne 0x404cb0
push ebx
push esi
push edi
mov esi, 0x206
push esi
push eax
mov word [ebp + 0x190], ax
lea eax, [ebp + 0x192]
push eax
call fcn.00411ad0
xor eax, eax
push esi
push eax
mov word [ebp - 0x78], ax
lea eax, [ebp - 0x76]
push eax
call fcn.00411ad0
lea edi, [ebp + 0x190]
call fcn.00404aa0
push 0x41fd34
mov esi, 0x104
mov eax, edi
push esi
push eax
call fcn.00408e4e
mov edi, 0x4241b0
add esp, 0x24
mov ebx, edi
cmp word [ebx], 0
je 0x404c48
lea eax, [ebp + 0x190]
push eax
lea eax, [ebp - 0x78]
push esi
push eax
call fcn.00408ed6
push ebx
lea eax, [ebp - 0x78]
push esi
push eax
call fcn.00408e4e
add esp, 0x18
add ebx, 0x118
cmp ebx, 0x424728
jl 0x404c23
cmp word [edi], 0
je 0x404c6e
push dword [ebp + 0x3a4]
mov ecx, edi
push dword [ebp - 0x80]
call fcn.00405449
pop ecx
pop ecx
add edi, 0x118
cmp edi, 0x424728
jl 0x404c56
push 0x424da0
lea eax, [ebp + 0x190]
push esi
push eax
call fcn.00408e4e
add esp, 0xc
lea eax, [ebp + 0x190]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
pop edi
pop esi
pop ebx
cmp eax, 0xffffffff
jne 0x404cad
mov dword [ebp - 0x7c], 2
mov eax, dword [ebp - 0x7c]
mov ecx, dword [ebp + 0x398]
xor ecx, ebp
call fcn.00408e3f
add ebp, 0x39c
leave
ret

Function at 0x404e9c
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Create tcp socket
Initialize winsock library
Resolve dns

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x9a8
mov eax, dword [0x422040]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
xor ebx, ebx
lea eax, [ebp - 0x804]
cmp ecx, ebx
je 0x404ebe
mov eax, ecx
xor ecx, ecx
mov word [eax], cx
lea eax, [ebp - 0x9a4]
push eax
push 0x101
mov dword [ebp - 0x9a8], ebx
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
je 0x404ee6
xor eax, eax
jmp 0x404f78
push 6
push 1
push 2
call dword [sym.imp.WS2_32.dll_socket]
mov dword [esi], eax
cmp eax, 0xffffffff
je 0x404edf
push edi
call dword [sym.imp.WS2_32.dll_gethostbyname]
test eax, eax
jne 0x404f26
push edi
call dword [sym.imp.WS2_32.dll_inet_addr]
push 2
mov dword [ebp - 0x9a8], eax
push 4
lea eax, [ebp - 0x9a8]
push eax
call dword [sym.imp.WS2_32.dll_gethostbyaddr]
test eax, eax
je 0x404f67
mov eax, dword [eax + 0xc]
mov eax, dword [eax]
mov eax, dword [eax]
push 2
mov dword [ebp - 0x810], eax
pop eax
push dword [ebp + 8]
mov word [ebp - 0x814], ax
call dword [sym.imp.WS2_32.dll_htons]
mov word [ebp - 0x812], ax
push 0x10
lea eax, [ebp - 0x814]
push eax
push dword [esi]
call dword [sym.imp.WS2_32.dll_connect]
test eax, eax
jne 0x404f67
xor ebx, ebx
inc ebx
jmp 0x404f76
mov eax, dword [esi]
test eax, eax
je 0x404f76
push eax
call dword [sym.imp.WS2_32.dll_closesocket]
and dword [esi], ebx
mov eax, ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.00408e3f
leave
ret
Function at 0x4050b1
Capabilities:
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
mov eax, dword [ebp + 8]
xor ecx, ecx
push ebx
mov dword [ebp - 8], ecx
cmp dword [eax], ecx
je 0x40512e
push esi
mov esi, dword [ebp + 0x10]
cmp esi, ecx
push edi
jle 0x4050d8
mov eax, dword [ebp + 0xc]
add eax, ecx
not byte [eax]
inc ecx
cmp ecx, esi
jl 0x4050cc
lea eax, [esi + 7]
push eax
mov dword [ebp - 4], eax
call fcn.0040932a
push dword [ebp + 0x10]
mov ebx, eax
push dword [ebp + 0xc]
add esi, 5
mov word [ebx], si
lea edi, [ebx + 2]
mov esi, 0x423064
movsd dword es:[edi], dword [esi]
lea eax, [ebx + 7]
push eax
movsb byte es:[edi], byte [esi]
call fcn.0040e950
mov eax, dword [ebp + 8]
add esp, 0x10
push 0
push dword [ebp - 4]
push ebx
push dword [eax]
call dword [sym.imp.WS2_32.dll_send]
pop edi
pop esi
cmp eax, 0xffffffff
je 0x405131
cmp eax, dword [ebp - 4]
jne 0x405131
mov dword [ebp - 8], 1
jmp 0x405131
mov ebx, dword [ebp + 8]
test ebx, ebx
je 0x40513c
push ebx
call fcn.00408ecb
pop ecx
mov eax, dword [ebp - 8]
pop ebx
leave
ret

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

Disassembly:
push ebp
lea ebp, [esp - 0x70]
sub esp, 0x8e0
mov eax, dword [0x422040]
xor eax, ebp
mov dword [ebp + 0x6c], eax
mov eax, dword [ebp + 0x7c]
push ebx
push esi
push edi
mov edi, dword [ebp + 0x78]
xor ebx, ebx
mov dword [ebp - 0x870], eax
mov dword [ebp - 0x86c], ecx
mov dword [ebp - 0x868], edi
lea eax, [ebp - 0x85c]
cmp edx, ebx
je 0x405313
mov eax, edx
xor edx, edx
mov word [eax], dx
mov esi, dword [ecx]
mov dword [ebp - 0x864], ebx
cmp esi, ebx
je 0x405431
cmp edi, ebx
je 0x405431
push 0xc7
lea eax, [ebp - 0x5b]
push ebx
push eax
mov byte [ebp - 0x5c], dl
call fcn.00411ad0
add esp, 0xc
push ebx
push 2
lea eax, [ebp - 0x5c]
push eax
push esi
mov esi, dword [sym.imp.WS2_32.dll_recv]
call esi
cmp eax, 0xffffffff
je 0x405431
cmp eax, ebx
je 0x405431
movzx edi, word [ebp - 0x5c]
lea eax, [edi + 2]
push eax
call fcn.0040932a
pop ecx
mov dword [ebp - 0x860], eax
test edi, edi
jle 0x40541c
push 0
mov eax, edi
sub eax, ebx
push eax
mov eax, dword [ebp - 0x860]
add eax, ebx
push eax
mov eax, dword [ebp - 0x86c]
push dword [eax]
call esi
cmp eax, 0xffffffff
je 0x4053fa
test eax, eax
je 0x4053fa
add ebx, eax
cmp edi, ebx
jg 0x405382
push 5
pop ecx
cmp ebx, ecx
jl 0x40541c
mov edi, dword [ebp - 0x860]
sub ebx, ecx
mov esi, 0x423064
xor eax, eax
repe cmpsb byte [esi], byte es:[edi]
jne 0x40541c
mov ecx, dword [ebp - 0x860]
test ebx, ebx
jle 0x4053da
lea eax, [ecx + 5]
mov edx, ebx
not byte [eax]
inc eax
dec edx
jne 0x4053d4
mov esi, dword [ebp - 0x870]
mov eax, dword [esi]
add ecx, 5
cmp eax, ebx
jl 0x405402
push ebx
push ecx
push dword [ebp - 0x868]
call fcn.0040e950
mov dword [esi], ebx
jmp 0x40540f
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
jmp 0x40541c
push eax
push ecx
push dword [ebp - 0x868]
call fcn.0040e950
add esp, 0xc
mov dword [ebp - 0x864], 1
cmp dword [ebp - 0x860], 0
je 0x405431
push dword [ebp - 0x860]
call fcn.00408ecb
pop ecx
mov ecx, dword [ebp + 0x6c]
mov eax, dword [ebp - 0x864]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00408e3f
add ebp, 0x70
leave
ret
Function at 0x405682
Capabilities:
Download and write a file
Receive and write data from server to client
Receive data
Receive data on socket
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0xf90]
mov eax, 0x1010
call fcn.00413d70
mov eax, dword [0x422040]
xor eax, ebp
mov dword [ebp + 0xf8c], eax
mov eax, dword [ebp + 0xf98]
push ebx
push esi
mov esi, dword [sym.imp.WS2_32.dll_recv]
xor ebx, ebx
push ebx
mov dword [ebp - 0x7c], eax
push 4
lea eax, [ebp - 0x78]
push eax
push dword [edi]
call esi
cmp eax, 4
je 0x4056c8
xor eax, eax
jmp 0x405710
cmp dword [ebp - 0x78], ebx
jbe 0x4056ff
push 0
push 0x1000
lea eax, [ebp - 0x74]
push eax
push dword [edi]
call esi
mov dword [ebp - 0x80], eax
test eax, eax
je 0x4056ff
mov ecx, dword [ebp - 0x7c]
push dword [ecx]
push eax
lea eax, [ebp - 0x74]
push 1
push eax
call fcn.0040960a
add ebx, dword [ebp - 0x80]
add esp, 0x10
cmp ebx, dword [ebp - 0x78]
jb 0x4056cd
mov eax, dword [ebp - 0x7c]
push dword [eax]
call fcn.00409703
cmp ebx, dword [ebp - 0x78]
pop ecx
sbb eax, eax
inc eax
mov ecx, dword [ebp + 0xf8c]
pop esi
xor ecx, ebp
pop ebx
call fcn.00408e3f
add ebp, 0xf90
leave
ret

Function at 0x405727
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push edi
xor edi, edi
push edi
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push dword [ebp + 0xc]
mov ebx, eax
push dword [ebp + 8]
push ebx
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov dword [ebp - 4], eax
cmp eax, edi
je 0x405798
push esi
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_SizeofResource]
push dword [ebp - 4]
mov esi, eax
push ebx
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov ebx, eax
push ebx
call dword [sym.imp.KERNEL32.dll_LockResource]
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0x10]
push esi
mov dword [eax], esi
call fcn.0040932a
push esi
mov edi, eax
push 0
push edi
call fcn.00411ad0
push esi
push dword [ebp - 4]
push edi
call fcn.0040e950
add esp, 0x1c
push ebx
call dword [sym.imp.KERNEL32.dll_FreeResource]
pop esi
mov eax, edi
pop edi
pop ebx
leave
ret
Function at 0x40579e
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0xc
push ebx
push esi
push edi
push dword [ebp + 8]
xor ebx, ebx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x4057cb
push dword [ebp + 8]
call fcn.00405849
pop ecx
cmp eax, dword [ebp + 0x10]
jne 0x4057cb
inc ebx
jmp 0x405840
mov edi, 0x200000
push edi
call fcn.004091f6
pop ecx
mov esi, eax
push esi
push dword [ebp + 0x10]
mov dword [esp + 0x18], edi
push dword [ebp + 0xc]
lea edi, [esp + 0x1c]
call fcn.0040589e
add esp, 0xc
test eax, eax
je 0x405839
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push eax
call fcn.00408f45
pop ecx
push 0x32
mov eax, 0xc8
call fcn.004040a9
mov edi, dword [esp + 0x14]
pop ecx
push eax
lea ebx, [edi + esi]
mov dword [esp + 0x18], eax
call fcn.004042d7
add edi, dword [esp + 0x18]
pop ecx
push edi
push esi
push dword [ebp + 8]
call fcn.0040590c
add esp, 0xc
mov ebx, eax
dec ebx
neg ebx
sbb ebx, ebx
inc ebx
push esi
call fcn.00409119
pop ecx
pop edi
pop esi
mov eax, ebx
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x405849
Capabilities:
Get file size

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
push esi
push edi
xor eax, eax
push eax
push eax
push 3
push eax
push 3
push closesocket
push dword [ebp + 8]
or esi, 0xffffffff
mov ebx, esi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
cmp edi, esi
jne 0x405878
mov edx, esi
jmp 0x405897
lea eax, [ebp - 0xc]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
cmp eax, 1
jne 0x40588e
mov esi, dword [ebp - 0xc]
mov ebx, dword [ebp - 8]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edx, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret

Function at 0x40590c
Capabilities:
Check if file exists
Get file attributes
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push esi
push dword [ebp + 8]
xor esi, esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x40592c
mov eax, dword [ebp + 8]
call fcn.00405977
test eax, eax
je 0x405972
push edi
push esi
push esi
push 2
push esi
push 1
push 0x40000000
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
cmp edi, 0xffffffff
je 0x405971
push esi
lea eax, [ebp + 0xc]
push eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
neg eax
sbb eax, eax
and eax, dword [ebp + 0xc]
cmp eax, dword [ebp + 0x10]
jne 0x40596a
xor esi, esi
inc esi
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
mov eax, esi
pop esi
pop ebp
ret
Function at 0x405977
Capabilities:
Check if file exists
Delete file
Get file attributes
Set file attributes

Disassembly:
push esi
mov esi, eax
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x40598a
xor eax, eax
pop esi
ret
test al, 1
je 0x405991
xor eax, 1
test al, 4
je 0x405998
xor eax, 4
test al, 2
je 0x40599f
xor eax, 2
test al, 0x20
je 0x4059a6
xor eax, 0x20
push eax
push esi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov esi, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov eax, esi
pop esi
ret

Function at 0x407195
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
push edi
mov edi, edx
test ecx, ecx
jne 0x4071a0
xor eax, eax
pop edi
ret
push esi
not eax
mov edx, 0xff
cmp edi, 8
jb 0x407252
mov esi, edi
shr esi, 3
push ebx
movzx ebx, byte [ecx]
xor ebx, eax
and ebx, edx
shr eax, 8
xor eax, dword [ebx*4 + 0x41f0d8]
inc ecx
movzx ebx, byte [ecx]
xor ebx, eax
and ebx, edx
shr eax, 8
xor eax, dword [ebx*4 + 0x41f0d8]
inc ecx
movzx ebx, byte [ecx]
xor ebx, eax
and ebx, edx
shr eax, 8
xor eax, dword [ebx*4 + 0x41f0d8]
inc ecx
movzx ebx, byte [ecx]
xor ebx, eax
and ebx, edx
shr eax, 8
xor eax, dword [ebx*4 + 0x41f0d8]
inc ecx
movzx ebx, byte [ecx]
xor ebx, eax
and ebx, edx
shr eax, 8
xor eax, dword [ebx*4 + 0x41f0d8]
inc ecx
movzx ebx, byte [ecx]
xor ebx, eax
and ebx, edx
shr eax, 8
xor eax, dword [ebx*4 + 0x41f0d8]
inc ecx
movzx ebx, byte [ecx]
xor ebx, eax
and ebx, edx
shr eax, 8
xor eax, dword [ebx*4 + 0x41f0d8]
inc ecx
movzx ebx, byte [ecx]
xor ebx, eax
and ebx, edx
shr eax, 8
xor eax, dword [ebx*4 + 0x41f0d8]
inc ecx
sub edi, 8
dec esi
jne 0x4071b7
pop ebx
test edi, edi
je 0x40726b
movzx esi, byte [ecx]
xor esi, eax
and esi, edx
shr eax, 8
xor eax, dword [esi*4 + 0x41f0d8]
inc ecx
dec edi
jne 0x407256
pop esi
not eax
pop edi
ret

Function at 0x407270
Capabilities:
Generate random numbers using the delphi lcg
Hash data with crc32

Disassembly:
mov eax, dword [ecx]
movsx edx, dl
xor edx, eax
push esi
mov esi, 0xff
and edx, esi
mov edx, dword [edx*4 + 0x41f0d8]
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 [edx*4 + 0x41f0d8]
pop esi
mov dword [ecx + 8], eax
ret

Function at 0x4078e5
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push edi
mov edi, dword [ebp + 0xc]
imul edi, dword [ebp + 0x10]
cmp byte [esi], 0
je 0x407915
push 0
lea eax, [ebp + 0x10]
push eax
push edi
push dword [ebp + 8]
push dword [esi + 2]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x407910
mov byte [esi + 6], 1
mov eax, dword [ebp + 0x10]
jmp 0x40793d
mov ecx, dword [esi + 0x14]
mov eax, dword [esi + 0x10]
lea edx, [ecx + edi]
cmp edx, eax
jbe 0x407926
sub eax, ecx
mov edi, eax
mov eax, dword [esi + 0xc]
push edi
add eax, ecx
push eax
push dword [ebp + 8]
call fcn.0040e950
add esp, 0xc
add dword [esi + 0x14], edi
mov eax, edi
xor edx, edx
div dword [ebp + 0xc]
pop edi
pop ebp
ret
Function at 0x4085e4
Capabilities:
Get common file path

Disassembly:
push ecx
cmp dword [ebx], 0
push esi
push edi
jne 0x40868a
cmp dword [ebx + 4], 0xffffffff
jne 0x40868a
lea esi, [ebx + 0x244]
push esi
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
mov eax, esi
lea edx, [eax + 2]
mov cx, word [eax]
inc eax
inc eax
test cx, cx
jne 0x408611
sub eax, edx
sar eax, 1
movzx eax, word [ebx + eax*2 + 0x242]
cmp ax, 0x5c
je 0x408648
cmp ax, 0x2f
je 0x408648
dec esi
dec esi
mov ax, word [esi + 2]
inc esi
inc esi
test ax, ax
jne 0x408635
mov edi, esi
mov esi, 0x41fd34
movsd dword es:[edi], dword [esi]
push 0x18
call fcn.0040932a
and dword [eax + 0x14], 0
and dword [eax + 7], 0
pop ecx
mov ecx, dword [esp + 0x10]
mov dword [eax + 0xc], ecx
mov ecx, dword [esp + 0x14]
push eax
mov byte [eax], 0
mov byte [eax + 1], 1
mov byte [eax + 0xb], 0
mov dword [eax + 0x10], ecx
call fcn.00407b5e
mov dword [ebx], eax
neg eax
sbb eax, eax
and eax, 0xfffffe00
pop ecx
add eax, 0x200
jmp 0x40868f
mov eax, 0x1000000
pop edi
pop esi
pop ecx
ret 8

Function at 0x408e3f
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x422040]
jne 0x408e49
repz ret
jmp fcn.0040ab76

Function at 0x412c82
Capabilities:
Link many functions at runtime

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
push esi
push edi
call fcn.0040aed6
and dword [ebp - 4], 0
cmp dword [0x423ee8], 0
mov ebx, eax
jne 0x412d33
push 0x41cc00
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
test edi, edi
je 0x412de4
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x41cbf4
push edi
call esi
test eax, eax
je 0x412de4
push eax
call fcn.0040ae64
mov dword [esp], 0x41cbe4
push edi
mov dword [0x423ee8], eax
call esi
push eax
call fcn.0040ae64
mov dword [esp], 0x41cbd0
push edi
mov dword [0x423eec], eax
call esi
push eax
call fcn.0040ae64
mov dword [esp], 0x41cbb4
push edi
mov dword [0x423ef0], eax
call esi
push eax
call fcn.0040ae64
pop ecx
mov dword [0x423ef8], eax
test eax, eax
je 0x412d33
push 0x41cb9c
push edi
call esi
push eax
call fcn.0040ae64
pop ecx
mov dword [0x423ef4], eax
mov eax, dword [0x423ef4]
cmp eax, ebx
je 0x412d8b
cmp dword [0x423ef8], ebx
je 0x412d8b
push eax
call fcn.0040aedf
push dword [0x423ef8]
mov esi, eax
call fcn.0040aedf
pop ecx
pop ecx
mov edi, eax
test esi, esi
je 0x412d8b
test edi, edi
je 0x412d8b
call esi
test eax, eax
je 0x412d82
lea ecx, [ebp - 8]
push ecx
push 0xc
lea ecx, [ebp - 0x14]
push ecx
push 1
push eax
call edi
test eax, eax
je 0x412d82
test byte [ebp - 0xc], 1
jne 0x412d8b
or dword [ebp + 0x10], 0x200000
jmp 0x412dc4
mov eax, dword [0x423eec]
cmp eax, ebx
je 0x412dc4
push eax
call fcn.0040aedf
pop ecx
test eax, eax
je 0x412dc4
call eax
mov dword [ebp - 4], eax
test eax, eax
je 0x412dc4
mov eax, dword [0x423ef0]
cmp eax, ebx
je 0x412dc4
push eax
call fcn.0040aedf
pop ecx
test eax, eax
je 0x412dc4
push dword [ebp - 4]
call eax
mov dword [ebp - 4], eax
push dword [0x423ee8]
call fcn.0040aedf
pop ecx
test eax, eax
je 0x412de4
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [ebp - 4]
call eax
jmp 0x412de6
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret