joyce8/EMBER2024-capa huggingface dataset:
Function at 0x414930
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
mov dword [ebp - 0x14], ecx
xor eax, eax
jne 0x414939
xor ecx, ecx
jne 0x414939
xor edx, edx
cmp dword [ebp + 0xc], 0
setne dl
mov dword [ebp - 0x10], edx
cmp dword [ebp - 0x10], 0
jne 0x41495a
mov eax, 0xd
jmp 0x4149b5
xor eax, eax
jne 0x414941
mov dword [ebp - 4], 0
mov ecx, dword [ebp + 0xc]
mov dword [ebp - 8], ecx
mov edx, dword [ebp - 8]
push edx
call dword [sym.imp.KERNEL32.dll_lstrlenW]
add eax, 1
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0xc]
mov ecx, dword [ebp - 8]
lea edx, [ecx + eax*2]
mov dword [ebp - 8], edx
mov eax, dword [ebp - 0xc]
mov ecx, dword [ebp - 4]
lea edx, [ecx + eax*2]
mov dword [ebp - 4], edx
cmp dword [ebp - 0xc], 1
jne 0x41496b
mov eax, dword [ebp - 4]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
push 7
push 0
mov edx, dword [ebp + 8]
push edx
mov eax, dword [ebp - 0x14]
mov ecx, dword [eax]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
mov esp, ebp
pop ebp
ret 8

Function at 0x415a10
Capabilities:
Hash data with crc32

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
mov dword [ebp - 4], 0
jmp 0x415a28
mov eax, dword [ebp - 4]
add eax, 1
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0x100
jae 0x415a7b
mov ecx, dword [ebp - 4]
mov dword [ebp - 8], ecx
mov dword [ebp - 0xc], 0
jmp 0x415a49
mov edx, dword [ebp - 0xc]
add edx, 1
mov dword [ebp - 0xc], edx
cmp dword [ebp - 0xc], 8
jge 0x415a6c
mov eax, dword [ebp - 8]
shr eax, 1
mov ecx, dword [ebp - 8]
and ecx, 1
sub ecx, 1
not ecx
and ecx, 0xedb88320
xor eax, ecx
mov dword [ebp - 8], eax
jmp 0x415a40
mov edx, dword [ebp - 4]
mov eax, dword [ebp - 8]
mov dword [edx*4 + 0x43e278], eax
jmp 0x415a1f
mov esp, ebp
pop ebp
ret

Function at 0x4169f0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
mov eax, dword [ebp + 0x10]
mov ecx, dword [eax]
mov dword [ebp - 4], ecx
cmp dword [ebp - 4], 0
jne 0x416a0b
xor eax, eax
jmp 0x416a93
mov edx, dword [ebp + 0x10]
mov dword [edx], 0
cmp dword [ebp - 4], 0x400000
jbe 0x416a26
mov dword [ebp - 0x14], 0x400000
jmp 0x416a2c
mov eax, dword [ebp - 4]
mov dword [ebp - 0x14], eax
mov ecx, dword [ebp - 0x14]
mov dword [ebp - 0xc], ecx
mov dword [ebp - 0x10], 0
push 0
lea edx, [ebp - 0x10]
push edx
mov eax, dword [ebp - 0xc]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp + 8]
mov eax, dword [edx]
push eax
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov dword [ebp - 8], eax
mov ecx, dword [ebp + 0xc]
add ecx, dword [ebp - 0x10]
mov dword [ebp + 0xc], ecx
mov edx, dword [ebp - 4]
sub edx, dword [ebp - 0x10]
mov dword [ebp - 4], edx
mov eax, dword [ebp + 0x10]
mov ecx, dword [eax]
add ecx, dword [ebp - 0x10]
mov edx, dword [ebp + 0x10]
mov dword [edx], ecx
cmp dword [ebp - 8], 0
jne 0x416a83
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x416a93
cmp dword [ebp - 0x10], 0
jne 0x416a8b
jmp 0x416a91
cmp dword [ebp - 4], 0
ja 0x416a14
xor eax, eax
mov esp, ebp
pop ebp
ret
Function at 0x416aa0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
mov eax, dword [ebp + 0x10]
mov ecx, dword [eax]
mov dword [ebp - 4], ecx
cmp dword [ebp - 4], 0
jne 0x416abb
xor eax, eax
jmp 0x416b43
mov edx, dword [ebp + 0x10]
mov dword [edx], 0
cmp dword [ebp - 4], 0x400000
jbe 0x416ad6
mov dword [ebp - 0x14], 0x400000
jmp 0x416adc
mov eax, dword [ebp - 4]
mov dword [ebp - 0x14], eax
mov ecx, dword [ebp - 0x14]
mov dword [ebp - 0xc], ecx
mov dword [ebp - 0x10], 0
push 0
lea edx, [ebp - 0x10]
push edx
mov eax, dword [ebp - 0xc]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp + 8]
mov eax, dword [edx]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov dword [ebp - 8], eax
mov ecx, dword [ebp + 0xc]
add ecx, dword [ebp - 0x10]
mov dword [ebp + 0xc], ecx
mov edx, dword [ebp - 4]
sub edx, dword [ebp - 0x10]
mov dword [ebp - 4], edx
mov eax, dword [ebp + 0x10]
mov ecx, dword [eax]
add ecx, dword [ebp - 0x10]
mov edx, dword [ebp + 0x10]
mov dword [edx], ecx
cmp dword [ebp - 8], 0
jne 0x416b33
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x416b43
cmp dword [ebp - 0x10], 0
jne 0x416b3b
jmp 0x416b41
cmp dword [ebp - 4], 0
ja 0x416ac4
xor eax, eax
mov esp, ebp
pop ebp
ret
Function at 0x41e150
Capabilities:
Hash data with md5

Disassembly:
push ebp
mov ebp, esp
push ecx
mov dword [ebp - 4], ecx
mov eax, dword [ebp - 4]
mov byte [eax + 0x68], 0
mov ecx, dword [ebp - 4]
mov dword [ecx + 0x10], 0
mov edx, dword [ebp - 4]
mov dword [edx + 0x14], 0
mov eax, dword [ebp - 4]
mov dword [eax], 0x67452301
mov ecx, dword [ebp - 4]
mov dword [ecx + 4], 0xefcdab89
mov edx, dword [ebp - 4]
mov dword [edx + 8], 0x98badcfe
mov eax, dword [ebp - 4]
mov dword [eax + 0xc], 0x10325476
mov esp, ebp
pop ebp
ret

Function at 0x41eeb0
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x244
mov eax, dword [0x43ce30]
xor eax, ebp
mov dword [ebp - 4], eax
push 0x208
push 0
lea eax, [ebp - 0x228]
push eax
call fcn.00422790
add esp, 0xc
push 0
push 0x1a
lea ecx, [ebp - 0x228]
push ecx
push 0
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
push 0x43715c
lea edx, [ebp - 0x228]
push edx
lea ecx, [ebp - 0x244]
call fcn.00408fc0
push eax
lea eax, [ebp - 0x20]
push eax
call fcn.00421880
add esp, 0xc
lea ecx, [ebp - 0x244]
call fcn.00407330
lea ecx, [ebp - 0x20]
call fcn.00407350
push eax
push 0
call dword [sym.imp.SHELL32.dll_SHCreateDirectory]
lea ecx, [ebp - 0x20]
push ecx
mov ecx, dword [ebp + 8]
call fcn.00420070
lea ecx, [ebp - 0x20]
call fcn.00407330
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00422540
mov esp, ebp
pop ebp
ret

Function at 0x421d9f
Capabilities:
Allocate or change rwx memory
Execute shellcode via indirect call

Disassembly:
cmp dword [0x43e6b0], 0
push esi
jne 0x421d12
call fcn.00421c38
test eax, eax
je 0x421d55
mov eax, dword [0x43e6b0]
cmp eax, 1
jne 0x421d33
push 0xd
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
test eax, eax
je 0x421d55
pop esi
ret
push eax
call dword [0x43e6b8]
test eax, eax
jne 0x421d9d
push 0x40
mov eax, 0x1000
push eax
push eax
push 0
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov esi, eax
test esi, esi
jne 0x421d59
xor eax, eax
pop esi
ret
mov eax, dword [esi]
push edi
push dword [0x43e6b0]
call dword [0x43e6b8]
mov edi, eax
test edi, edi
je 0x421d7e
push 0x8000
push 0
push esi
call dword [sym.imp.KERNEL32.dll_VirtualFree]
jmp 0x421d9a
mov edi, esi
add esi, 0xff0
push edi
push dword [0x43e6b0]
call dword [0x43e6b4]
add edi, 0x10
cmp edi, esi
jb 0x421d86
mov eax, edi
pop edi
pop esi
ret
jmp 0x421cff

Function at 0x422540
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x43ce30]
jne 0x42254a
repz ret
jmp fcn.00424851
Function at 0x42f6cb
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.004249c9
and dword [ebp - 4], 0
cmp dword [0x43f220], 0
mov ebx, eax
jne 0x42f77c
push str.USER32.DLL
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
test edi, edi
je 0x42f82d
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.MessageBoxA
push edi
call esi
test eax, eax
je 0x42f82d
push eax
call fcn.00424957
mov dword [esp], 0x438c7c
push edi
mov dword [0x43f220], eax
call esi
push eax
call fcn.00424957
mov dword [esp], str.GetLastActivePopup
push edi
mov dword [0x43f224], eax
call esi
push eax
call fcn.00424957
mov dword [esp], str.GetUserObjectInformationA
push edi
mov dword [0x43f228], eax
call esi
push eax
call fcn.00424957
pop ecx
mov dword [0x43f230], eax
test eax, eax
je 0x42f77c
push str.GetProcessWindowStation
push edi
call esi
push eax
call fcn.00424957
pop ecx
mov dword [0x43f22c], eax
mov eax, dword [0x43f22c]
cmp eax, ebx
je 0x42f7d4
cmp dword [0x43f230], ebx
je 0x42f7d4
push eax
call fcn.004249d2
push dword [0x43f230]
mov esi, eax
call fcn.004249d2
pop ecx
pop ecx
mov edi, eax
test esi, esi
je 0x42f7d4
test edi, edi
je 0x42f7d4
call esi
test eax, eax
je 0x42f7cb
lea ecx, [ebp - 8]
push ecx
push 0xc
lea ecx, [ebp - 0x14]
push ecx
push 1
push eax
call edi
test eax, eax
je 0x42f7cb
test byte [ebp - 0xc], 1
jne 0x42f7d4
or dword [ebp + 0x10], 0x200000
jmp 0x42f80d
mov eax, dword [0x43f224]
cmp eax, ebx
je 0x42f80d
push eax
call fcn.004249d2
pop ecx
test eax, eax
je 0x42f80d
call eax
mov dword [ebp - 4], eax
test eax, eax
je 0x42f80d
mov eax, dword [0x43f228]
cmp eax, ebx
je 0x42f80d
push eax
call fcn.004249d2
pop ecx
test eax, eax
je 0x42f80d
push dword [ebp - 4]
call eax
mov dword [ebp - 4], eax
push dword [0x43f220]
call fcn.004249d2
pop ecx
test eax, eax
je 0x42f82d
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [ebp - 4]
call eax
jmp 0x42f82f
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret
Function at 0x40100b
Capabilities:
Query or enumerate registry value

Disassembly:
call 0x40100b
push eax
call sub.KERNEL32.dll_ExitProcess
push ebp
mov ebp, esp
add esp, 0xfffffef0
jmp 0x40109c
lea eax, [ebp - 0x104]
push eax
call fcn.004011ec
push 0x401019
lea eax, [ebp - 0x104]
push eax
call sub.KERNEL32.dll_lstrcatA
push eax
call sub.KERNEL32.dll_LoadLibraryA
test eax, eax
jne 0x401165
lea eax, [ebp - 0x10c]
push eax
push 0x20019
push 0
push 0x401038
push 0x80000001
call sub.ADVAPI32.dll_RegOpenKeyExA
cmp eax, 0
jne 0x4011a5
mov dword [ebp - 0x110], 0x103
lea eax, [ebp - 0x110]
push eax
lea eax, [ebp - 0x104]
push eax
push 0
push 0
push 0x401052
push dword [ebp - 0x10c]
call sub.ADVAPI32.dll_RegQueryValueExA
push eax
push dword [ebp - 0x10c]
call sub.ADVAPI32.dll_RegCloseKey
pop eax
cmp eax, 0
jne 0x4011a5
lea eax, [ebp - 0x104]
push eax
call sub.KERNEL32.dll_lstrlenA
lea ebx, [ebp - 0x104]
add ebx, eax
dec ebx
cmp byte [ebx], 0x5c
je 0x40114a
mov word [ebx], 0x5c
push 0x401023
lea eax, [ebp - 0x104]
push eax
call sub.KERNEL32.dll_lstrcatA
push eax
call sub.KERNEL32.dll_LoadLibraryA
test eax, eax
je 0x4011a5
mov dword [ebp - 0x108], eax
push 0x40102d
push eax
call sub.KERNEL32.dll_GetProcAddress
test eax, eax
je 0x40119a
push 0x3e8
call eax
test eax, eax
je 0x40119a
call 0x40118a
add dword [esp], 0x1e76
call eax
push 0
call sub.KERNEL32.dll_ExitProcess
push dword [ebp - 0x108]
call sub.KERNEL32.dll_FreeLibrary
push 0x10
push 0x401096
push 0x401057
push 0
call sub.USER32.dll_MessageBoxA
mov eax, 0xffffffff
leave
ret

Function at 0x41343b
Capabilities:
Read file on windows

Disassembly:
mov eax, dword [esp + 0xc]
mov ecx, dword [esp + 8]
mov edx, dword [esp + 4]
push eax
push ecx
push edx
mov dword [0x459fa8], 0
call fcn.0043df50
mov ecx, dword [esp + 0x1c]
add esp, 0xc
mov dword [ecx], eax
mov eax, dword [0x459fa8]
ret 0x10

Function at 0x41356b
Capabilities:
Read file on windows

Disassembly:
push esi
mov esi, dword [esp + 8]
push edi
cmp word [esi + 4], 0
jne 0x41359c
mov eax, dword [esi + 6]
inc eax
push eax
push 0xff
call fcn.0041346b
test ax, ax
mov word [esi + 4], ax
jne 0x41359c
mov ecx, dword [esi + 6]
inc ecx
push ecx
push 4
call fcn.0041aeab
test byte [esi + 0xa], 8
je 0x4135cd
mov eax, dword [esi + 0xb]
lea edx, [esp + 0xc]
xor ecx, ecx
push edx
mov cx, word [esi + 4]
push 0
push eax
push ecx
call fcn.0041340b
test eax, eax
je 0x4135c9
mov edx, dword [esi + 6]
inc edx
push edx
push 4
call fcn.0041aeab
and byte [esi + 0xa], 0xf7
mov dword [0x459fa8], 0
mov ecx, dword [esi + 0x17]
xor eax, eax
xor edx, edx
mov ax, word [esi + 0x15]
mov dx, word [esi + 4]
add ecx, 0x200
push eax
push ecx
push edx
call fcn.0043df50
mov edi, eax
mov eax, dword [0x459fa8]
add esp, 0xc
test eax, eax
je 0x41360e
mov eax, dword [esi + 6]
inc eax
push eax
push 4
call fcn.0041aeab
mov eax, dword [esi + 0xb]
mov word [esi + 0x15], di
add eax, edi
pop edi
mov dword [esi + 0xb], eax
pop esi
ret 4
Function at 0x4153fb
Capabilities:
Terminate process

Disassembly:
mov eax, dword [esp + 4]
test eax, eax
jne 0x415454
mov al, byte [0x45985e]
push 0
test al, al
push 0
je 0x415438
push 0x445e70
push 0x445e78
push 0x445e7c
push 0x445e80
push 0
call fcn.0043e87e
add esp, 0x1c
test eax, eax
jne 0x415454
push eax
call fcn.0043d596
push 0x445e84
push 0x445e8c
push 0x445e90
push 0x445e94
call fcn.0043f1a9
add esp, 0x18
mov al, byte [0x45985c]
test al, al
jne 0x415462
call fcn.004153db
cmp byte [0x4447a4], 0xd
jne 0x415477
push 0x4447a4
call fcn.004137bb
jmp 0x415480
push 0
push 0
call fcn.0041548b
push 0
call fcn.0043d596
nop
nop
nop
nop
Function at 0x415f7b
Capabilities:
Terminate process

Disassembly:
mov al, byte [0x45983d]
test al, al
je 0x415f9b
mov eax, dword [0x459860]
test eax, eax
je 0x415f9b
mov eax, dword [0x46ba08]
test eax, eax
je 0x415f9b
call fcn.0042cdfb
mov eax, dword [0x4598ae]
test eax, eax
je 0x415fc1
mov eax, dword [0x46ba00]
test eax, eax
je 0x415fc1
push eax
call fcn.00423f9b
mov eax, dword [0x4598ae]
push eax
call fcn.0043e5f7
add esp, 4
mov eax, dword [0x4598ba]
test eax, eax
je 0x415fe8
mov eax, dword [0x46ba5c]
test eax, eax
je 0x415fe8
push eax
call fcn.00423f9b
mov ecx, dword [0x4598ba]
push ecx
call fcn.0043e5f7
add esp, 4
mov eax, dword [0x46ba08]
test eax, eax
je 0x415ff7
push eax
call fcn.00423f9b
push 1
call fcn.0043d596
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov byte [0x45985f], 0xff
ret
Function at 0x43bc9b
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push ecx
push ebx
mov ebx, dword [esp + 0x10]
test bl, bl
mov byte [esp + 7], 0
jne 0x43bcb1
xor eax, eax
pop ebx
pop ecx
ret 8
xor ax, ax
push ebp
push esi
mov esi, dword [esp + 0x14]
mov al, bl
push eax
push esi
call fcn.0043a31b
mov cx, word [0x45a27c]
xor eax, eax
mov al, ch
xor al, cl
cmp word [0x46ba80], 0
mov byte [esp + 0x18], al
je 0x43bcf2
mov edx, dword [0x46ce78]
mov ebp, dword [edx + 0x2b]
test ebp, ebp
je 0x43bcf2
mov byte [esp + 0xf], 0xff
jmp 0x43bd02
shr ecx, 2
and ecx, 0x1ff
mov ebp, dword [ecx*4 + 0x46bb00]
test ebp, 0xfffffff0
mov byte [0x46ce4c], 0
je 0x43be2c
jmp 0x43bd1b
mov al, byte [esp + 0x18]
cmp byte [ebp + 4], al
jne 0x43bde3
mov al, byte [ebp + 5]
cmp al, bl
jne 0x43bde3
mov cl, byte [0x45b758]
cmp cl, 0xff
mov ecx, ebx
jne 0x43bd55
and eax, 0xff
mov edx, ebp
and ecx, 0xff
sub edx, eax
push ecx
push edx
push esi
call fcn.0043f5bb
jmp 0x43bd6c
and eax, 0xff
mov edx, ebp
and ecx, 0xff
sub edx, eax
push ecx
push edx
push esi
call fcn.0043f50b
add esp, 0xc
test eax, eax
jne 0x43bde3
cmp byte [ebp + 6], 0xb
jne 0x43bd95
mov ax, word [ebp + 0x1b]
cmp ax, word [0x46c890]
je 0x43be1c
test ah, 0x80
jne 0x43be1c
jmp 0x43bde3
cmp word [0x46c890], 0
je 0x43bda8
mov al, byte [0x46c370]
test al, al
je 0x43bde3
mov byte [0x46ce4c], 0
mov al, byte [ebp + 6]
cmp al, 3
jne 0x43bdcb
test byte [ebp + 0x29], 8
je 0x43be25
mov ax, word [ebp + 0x2b]
cmp ax, word [0x46ba80]
je 0x43be2c
jmp 0x43bddc
cmp al, 9
jne 0x43be2c
mov cx, word [ebp + 0x1d]
cmp cx, word [0x46ba80]
je 0x43be2c
mov byte [0x46ce4c], 1
mov al, byte [esp + 0xf]
mov ebp, dword [ebp]
test al, al
je 0x43be0e
test ebp, ebp
jne 0x43be0e
mov dx, word [0x45a27c]
mov byte [esp + 0xf], 0
shr edx, 2
and edx, 0x1ff
mov ebp, dword [edx*4 + 0x46bb00]
test ebp, 0xfffffff0
jne 0x43bd17
jmp 0x43be2c
mov byte [0x46ce4c], 0
jmp 0x43be2c
mov byte [0x46ce4c], 2
test ebp, ebp
je 0x43beb6
mov al, byte [0x444691]
test al, al
je 0x43be4e
mov al, byte [0x459843]
test al, al
je 0x43be4e
push 4
push ebp
call fcn.0043c4fb
mov dl, byte [ebp + 7]
mov al, dl
and al, 3
cmp al, 3
jne 0x43beb6
mov al, byte [0x46ce88]
cmp al, 2
jae 0x43beb6
mov cl, byte [0x46ce5c]
test cl, cl
jne 0x43beb6
mov cl, byte [0x46c477]
test cl, cl
jne 0x43beb6
test al, al
jne 0x43beb0
cmp byte [0x46c8ce], 0x58
jne 0x43beb0
mov al, byte [ebp + 5]
mov cx, word [0x46c8e6]
movzx si, al
cmp cx, si
jne 0x43beb0
mov esi, dword [0x46c8e2]
push edi
and eax, 0xff
mov edi, ebp
movsx ecx, cx
sub edi, eax
xor eax, eax
repe cmpsb byte [esi], byte es:[edi]
pop edi
je 0x43beb6
or dl, 0x80
mov byte [ebp + 7], dl
mov eax, ebp
pop esi
pop ebp
pop ebx
pop ecx
ret 8
Function at 0x5e5680
Capabilities:
Packed with generic packer

Disassembly:
pushal
mov esi, 0x54c015
lea edi, [esi - 0x14b015]
mov dword [edi + 0x14fbd0], 0x7376e0a8
push edi
or ebp, 0xffffffff
jmp 0x5e56aa
mov al, byte [esi]
inc esi
mov byte [edi], al
inc edi
add ebx, ebx
jne 0x5e56b1
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x5e56a0
mov eax, 1
add ebx, ebx
jne 0x5e56c3
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
add ebx, ebx
jae 0x5e56d4
jne 0x5e56f3
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x5e56f3
dec eax
add ebx, ebx
jne 0x5e56e0
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
jmp 0x5e56b8
add ebx, ebx
jne 0x5e56ef
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
jmp 0x5e5745
xor ecx, ecx
sub eax, 3
jb 0x5e570b
shl eax, 8
mov al, byte [esi]
inc esi
xor eax, 0xffffffff
je 0x5e577a
sar eax, 1
mov ebp, eax
jmp 0x5e5716
add ebx, ebx
jne 0x5e5716
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x5e56e4
inc ecx
add ebx, ebx
jne 0x5e5724
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x5e56e4
add ebx, ebx
jne 0x5e5731
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
jae 0x5e5726
jne 0x5e5742
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jae 0x5e5726
add ecx, 2
cmp ebp, 0xfffffb00
adc ecx, 2
lea edx, [edi + ebp]
cmp ebp, 0xfffffffc
jbe 0x5e5764
mov al, byte [edx]
inc edx
mov byte [edi], al
inc edi
dec ecx
jne 0x5e5756
jmp 0x5e56a6
mov eax, dword [edx]
add edx, 4
mov dword [edi], eax
add edi, 4
sub ecx, 4
ja 0x5e5764
add edi, ecx
jmp 0x5e56a6
pop esi
mov edi, esi
mov ecx, 0x8e03
mov al, byte [edi]
inc edi
sub al, 0xe8
cmp al, 1
ja 0x5e5782
cmp byte [edi], 0x22
jne 0x5e5782
mov eax, dword [edi]
mov bl, byte [edi + 4]
shr ax, 8
rol eax, 0x10
xchg ah, al
sub eax, edi
sub bl, 0xe8
add eax, esi
mov dword [edi], eax
add edi, 5
mov al, bl
loop 0x5e5787
lea edi, [esi + 0x1e2000]
mov eax, dword [edi]
or eax, eax
je 0x5e57f6
mov ebx, dword [edi + 4]
lea eax, [eax + esi + 0x2019c4]
add ebx, esi
push eax
add edi, 8
call dword [esi + 0x201a78]
xchg ebp, eax
mov al, byte [edi]
inc edi
or al, al
je 0x5e57b4
mov ecx, edi
push edi
dec eax
repne scasb al, byte es:[edi]
push ebp
call dword [esi + 0x201a7c]
or eax, eax
je 0x5e57f0
mov dword [ebx], eax
add ebx, 4
jmp 0x5e57d1
call dword [esi + 0x201a8c]
mov ebp, dword [esi + 0x201a80]
lea edi, [esi - 0x1000]
mov ebx, 0x1000
push eax
push esp
push 4
push ebx
push edi
call ebp
lea eax, [edi + 0x19f]
and byte [eax], 0x7f
and byte [eax + 0x28], 0x7f
pop eax
push eax
push esp
push eax
push ebx
push edi
call ebp
pop eax
lea ebx, [esi - 0x1000]
lea edi, [ebx + 0x1e5851]
push edi
xor eax, eax
stosb byte es:[edi], al
pop ecx
dec ecx
push eax
push 1
push ebx
call ecx
popal
lea eax, [esp - 0x80]
push 0
cmp esp, eax
jne 0x5e5842
sub esp, 0xffffff80
jmp 0x5463c0
Function at 0x402ae0
Capabilities:
Accept command line arguments

Disassembly:
push ebx
push esi
push edi
add esp, 0xfffffef8
mov ebx, edx
mov esi, eax
mov eax, ebx
call fcn.00404980
test esi, esi
jne 0x402b16
push 0x105
lea eax, [esp + 4]
push eax
push 0
call sub.kernel32.dll_GetModuleFileNameA
mov ecx, eax
mov edx, esp
mov eax, ebx
call fcn.00404a70
jmp 0x402b34
call sub.kernel32.dll_GetCommandLineA
mov edi, eax
mov edx, ebx
mov eax, edi
call fcn.00402994
mov edi, eax
test esi, esi
je 0x402b34
cmp dword [ebx], 0
je 0x402b34
dec esi
jmp 0x402b1d
add esp, 0x108
pop edi
pop esi
pop ebx
ret

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

Disassembly:
push ebx
xor ebx, ebx
imul edx, dword [ebx + 0x479008], 0x8088405
inc edx
mov dword [ebx + 0x479008], edx
mul edx
mov eax, edx
pop ebx
ret

Function at 0x40390c
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff4
movzx eax, word [0x479024]
mov dword [ebp - 8], eax
lea eax, [ebp - 4]
push eax
push 1
push 0
push 0x4039a4
push 0x80000002
call sub.advapi32.dll_RegOpenKeyExA
test eax, eax
jne 0x403984
xor eax, eax
push ebp
push 0x40397d
push dword fs:[eax]
mov dword fs:[eax], esp
mov dword [ebp - 0xc], 4
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 8]
push eax
push 0
push 0
push 0x4039c0
mov eax, dword [ebp - 4]
push eax
call sub.advapi32.dll_RegQueryValueExA
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x403984
mov eax, dword [ebp - 4]
push eax
call sub.advapi32.dll_RegCloseKey
ret
mov ax, word [0x479024]
and ax, 0xffc0
mov dx, word [ebp - 8]
and dx, 0x3f
or ax, dx
mov word [0x479024], ax
mov esp, ebp
pop ebp
ret

Function at 0x404780
Capabilities:
Write file on windows

Disassembly:
push ecx
cmp byte [0x47c04c], 0
je 0x4047e1
cmp word [0x47c220], 0xd7b2
jne 0x4047a9
cmp dword [0x47c228], 0
jbe 0x4047a9
mov eax, 0x47c21c
call dword [0x47c238]
push 0
lea eax, [esp + 4]
push eax
push 0x1e
push 0x479094
push 0xfffffffffffffff5
call sub.kernel32.dll_GetStdHandle
push eax
call sub.kernel32.dll_WriteFile
push 0
lea eax, [esp + 4]
push eax
push 2
push 0x404808
push 0xfffffffffffffff5
call sub.kernel32.dll_GetStdHandle
push eax
call sub.kernel32.dll_WriteFile
pop edx
ret
cmp byte [0x479034], 0
jne 0x4047fd
push 0
push 0x47908c
push 0x479094
push 0
call sub.user32.dll_MessageBoxA
pop edx
ret

Function at 0x404934
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push ebx
push esi
push edi
mov edi, ecx
mov esi, edx
mov ebx, eax
mov eax, 8
call fcn.0040276c
mov dword [eax], edi
mov edx, dword [ebp + 0x10]
mov dword [eax + 4], edx
mov byte [0x47c04d], 1
mov edx, dword [ebp + 8]
push edx
mov edx, dword [ebp + 0xc]
push edx
push eax
mov eax, 0x4048fc
push eax
push esi
push ebx
call sub.kernel32.dll_CreateThread
pop edi
pop esi
pop ebx
pop ebp
ret 0xc