joyce8/EMBER2024-capa huggingface dataset:
Function at 0x641d8b
Capabilities:
Access peb ldr_data
Get kernel32 base address
Get process heap flags

Disassembly:
mov eax, 0x680957
call fcn.005e4714
push ecx
push ebx
push esi
mov esi, ecx
push edi
mov dword [ebp - 0x10], esi
call fcn.00620a86
mov eax, dword [ebp + 0x18]
lea ebx, [esi + 0x24]
mov dword [esi + 0x1c], eax
mov eax, dword [0x6ed544]
xor edi, edi
mov dword [ebx], eax
mov dword [ebp - 4], edi
push dword [ebp + 0x10]
lea ecx, [esi + 0xc]
mov byte [ebp - 4], 1
mov dword [esi], vtable.CInternetFile.0
call fcn.006199fa
push dword [ebp + 0x14]
mov ecx, ebx
call fcn.006199fa
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 0xc]
mov dword [esi + 0x14], eax
mov eax, dword [ebp + 0x1c]
mov dword [esi + 0x18], eax
mov dword [esi + 0x3c], edi
mov dword [esi + 0x30], edi
mov dword [esi + 0x34], edi
mov dword [esi + 0x38], edi
mov dword [esi + 0x28], edi
mov dword [esi + 0x2c], edi
mov dword [esi + 0x40], edi
mov eax, esi
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret 0x18

Function at 0x641e27
Capabilities:
Access peb ldr_data
Get kernel32 base address

Disassembly:
mov eax, 0x68097f
call fcn.005e4714
push ecx
push ebx
push esi
mov esi, ecx
push edi
mov dword [ebp - 0x10], esi
call fcn.00620a86
mov eax, dword [0x6ed544]
lea ebx, [esi + 0x24]
xor edi, edi
mov dword [ebp - 4], edi
mov dword [ebx], eax
mov eax, dword [ebp + 0x10]
mov dword [esi], vtable.CInternetFile.0
mov ecx, 0x6f4e88
mov byte [ebp - 4], 1
push dword [eax + 0xc]
push dword [ebp + 8]
call fcn.006418b1
push dword [ebp + 0xc]
lea ecx, [esi + 0xc]
call fcn.006199fa
mov ecx, dword [ebp + 0x10]
mov eax, dword [ecx + 8]
mov dword [esi + 0x1c], eax
lea eax, [ebp + 0x10]
push eax
call fcn.005da545
push eax
mov ecx, ebx
mov byte [ebp - 4], 2
call fcn.006199aa
lea ecx, [ebp + 0x10]
mov byte [ebp - 4], 1
call fcn.00619871
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 0xc]
mov dword [esi + 0x14], eax
mov eax, dword [ebp + 0x14]
mov dword [esi + 0x18], eax
mov dword [esi + 0x3c], edi
mov dword [esi + 0x30], edi
mov dword [esi + 0x34], edi
mov dword [esi + 0x38], edi
mov dword [esi + 0x28], edi
mov dword [esi + 0x2c], edi
mov dword [esi + 0x40], edi
mov eax, esi
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret 0x10
Function at 0x647e83
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push esi
mov dword [ebp - 8], ecx
call fcn.00646245
mov esi, dword [eax + 0xc]
push 0xf1
push dword [ebp + 8]
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
test eax, eax
je 0x647ec0
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
je 0x647ec0
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov esi, eax
test esi, esi
jne 0x647ec4
xor eax, eax
jmp 0x647f42
movzx eax, word [esi + 6]
push ebx
push edi
shl eax, 2
push eax
call fcn.00619f42
and dword [ebp - 4], 0
cmp word [esi + 6], 0
pop ecx
mov ebx, eax
jbe 0x647efc
mov ecx, ebx
lea eax, [esi + 8]
movzx edx, word [eax]
inc dword [ebp - 4]
mov dword [ecx], edx
movzx edx, word [esi + 6]
inc eax
add ecx, 4
inc eax
cmp dword [ebp - 4], edx
jl 0x647ee6
movzx eax, word [esi + 6]
mov ecx, dword [ebp - 8]
push eax
push ebx
call fcn.00648047
push ebx
mov edi, eax
call fcn.00619f6b
test edi, edi
pop ecx
je 0x647f3e
movzx ecx, word [esi + 4]
movzx eax, word [esi + 2]
lea esi, [ecx + 7]
push ecx
mov ecx, dword [ebp - 8]
lea edx, [eax + 7]
push eax
push esi
push edx
call fcn.00647d99
push dword [ebp + 8]
mov ecx, dword [ebp - 8]
call fcn.00647f47
mov edi, eax
mov eax, edi
pop edi
pop ebx
pop esi
leave
ret 4
Function at 0x65baa3
Capabilities:
Receive data
Receive data on socket

Disassembly:
push dword [esp + 0xc]
push dword [esp + 0xc]
push dword [esp + 0xc]
push dword [ecx + 4]
call sub.WSOCK32.dll_recv
ret 0xc

Function at 0x65bb21
Capabilities:
Send data
Send data on socket

Disassembly:
push dword [esp + 0xc]
push dword [esp + 0xc]
push dword [esp + 0xc]
push dword [ecx + 4]
call sub.WSOCK32.dll_send
ret 0xc
Function at 0x101ffc86
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x1c
mov eax, dword [ebp + 0x10]
mov ecx, dword [ebp + 0xc]
mov edx, dword [ebp + 8]
xor esi, esi
mov dword [0x1021e66c], 0
mov byte [0x1021e670], 0
mov dword [0x1021e664], 0x247e
mov dword [0x1021e668], 0
mov dword [ebp - 0x10], eax
mov dword [ebp - 0x14], ecx
mov dword [ebp - 0x18], edx
mov dword [ebp - 0x1c], esi
jmp 0x101ffcf0
mov dword [0x1021e660], 0x71f
add esp, 0x1c
pop esi
pop edi
pop ebx
pop ebp
ret
mov dword [0x1021e668], 0
xor eax, eax
mov dword [ebp - 0x20], eax
jmp 0x101ffd18
mov eax, dword [ebp - 0x1c]
mov ecx, eax
mov dl, cl
mov ecx, dword [ebp - 0x18]
mov byte [ecx + eax], dl
mov eax, dword [0x1021e668]
add eax, 1
mov dword [0x1021e668], eax
cmp eax, 0x100
mov dword [ebp - 0x1c], eax
jl 0x101ffcf0
jmp 0x101ffcdf
mov eax, dword [ebp - 0x20]
mov ecx, 0x100
mov dword [0x1021e674], 0
mov edx, dword [0x1021e660]
mov esi, edx
add esi, 0xffffd965
mov dword [0x1021e664], esi
mov esi, dword [0x1021e66c]
mov edi, dword [ebp - 0x18]
movzx ebx, byte [edi + eax]
add ebx, esi
mov dword [ebp - 0x24], eax
xor esi, esi
mov dword [ebp - 0x28], edx
mov edx, esi
mov esi, dword [ebp - 0x10]
div esi
mov esi, dword [ebp - 0x14]
movzx edx, byte [esi + edx]
add ebx, edx
mov dword [0x1021e674], ebx
mov dword [0x1021e664], 0x162a
mov eax, ebx
cdq
idiv ecx
mov dword [0x1021e66c], edx
mov ecx, dword [ebp - 0x28]
add ecx, 0x26f4
mov dword [0x1021e660], ecx
mov ecx, dword [ebp - 0x24]
mov cl, byte [edi + ecx]
mov byte [0x1021e670], cl
mov dword [0x1021e660], 0x8fc
mov cl, byte [edi + edx]
mov edx, dword [ebp - 0x24]
mov byte [edi + edx], cl
mov dword [0x1021e660], 0x721
mov cl, byte [0x1021e670]
mov ebx, dword [0x1021e66c]
mov byte [edi + ebx], cl
mov dword [0x1021e664], 0x15d4
mov ebx, dword [0x1021e668]
add ebx, 1
mov dword [0x1021e668], ebx
cmp ebx, 0x100
mov dword [ebp - 0x20], ebx
jl 0x101ffd18
jmp 0x101ffccd
Function at 0x101ffdf7
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x60
mov eax, dword [ebp + 8]
mov dword [0x1021e664], 0x26bd
mov dword [0x1021e660], 0xe95
mov dword [ebp - 0x30], eax
xor eax, eax
mov ecx, eax
mov dword [ebp - 0x34], ecx
mov dword [ebp - 0x38], eax
jmp 0x101ffe26
mov eax, dword [ebp - 0x38]
mov ecx, dword [ebp - 0x34]
lea edx, section..data
imul esi, eax, 0x9c
mov edi, edx
add edi, esi
add edi, 0x98
mov esi, dword [edi]
imul edi, eax, 0x9c
add edx, edi
add edx, 0x54
movzx edx, word [edx]
xor edx, esi
add edx, ecx
add eax, 1
cmp eax, 0x2b5
mov ecx, edx
mov dword [ebp - 0x3c], edx
mov dword [ebp - 0x34], ecx
mov dword [ebp - 0x38], eax
jne 0x101ffe26
lea eax, [0x102032a3]
mov ecx, 0xe
lea edx, [ebp - 0x2c]
mov dword [0x1021e664], 0x130b
mov dword [0x1021e660], 0x1346
mov dword [esp], edx
mov dword [esp + 4], eax
mov dword [esp + 8], 0xe
mov dword [ebp - 0x40], edx
mov dword [ebp - 0x44], ecx
call fcn.102000ef
mov dword [0x1021e664], 0xb5d
mov dword [0x1021e660], 0x6c2
call fcn.1020001b
mov dword [esp], eax
mov eax, dword [ebp - 0x40]
mov dword [esp + 4], eax
call fcn.1020027e
mov ecx, eax
mov dword [0x1021e680], eax
mov eax, esp
mov edx, dword [ebp - 0x3c]
mov dword [eax + 4], edx
mov dword [eax + 0xc], 4
mov dword [eax + 8], 0x1000
mov dword [eax], 0
call ecx
sub esp, 0x10
xor ecx, ecx
mov edx, ecx
mov dword [ebp - 0x48], eax
mov dword [ebp - 0x4c], edx
mov dword [ebp - 0x50], ecx
mov eax, dword [ebp - 0x50]
mov ecx, dword [ebp - 0x4c]
lea edx, section..data
imul esi, eax, 0x9c
mov edi, edx
add edi, esi
add edi, 0x98
mov esi, dword [edi]
imul edi, eax, 0x9c
mov ebx, edx
add ebx, edi
add ebx, 0x18
mov edi, dword [ebx]
imul ebx, eax, 0x9c
add edx, ebx
add edx, 0x54
movzx edx, word [edx]
xor edx, esi
mov esi, dword [ebp - 0x48]
add esi, ecx
mov dword [esp], esi
mov dword [esp + 4], edi
mov dword [esp + 8], edx
mov dword [ebp - 0x54], eax
mov dword [ebp - 0x58], ecx
mov dword [ebp - 0x5c], edx
call fcn.10200c66
mov eax, dword [ebp - 0x5c]
mov ecx, dword [ebp - 0x58]
add eax, ecx
mov edx, dword [ebp - 0x54]
add edx, 1
cmp edx, 0x2b5
mov dword [ebp - 0x4c], eax
mov dword [ebp - 0x50], edx
jne 0x101fff09
mov dword [0x1021e664], 0x9b1
mov eax, dword [ebp - 0x48]
mov dword [esp], eax
mov dword [esp + 4], eax
mov ecx, dword [ebp - 0x3c]
mov dword [esp + 8], ecx
call fcn.1020019c
xor eax, eax
mov ecx, dword [ebp - 0x48]
add ecx, 0x8886d
mov edx, dword [ebp - 0x30]
mov dword [edx], ecx
mov ecx, dword [0x1021e660]
add ecx, 0x183c
mov dword [0x1021e660], ecx
mov dword [edx + 4], 0x13e400
mov dword [0x1021e664], 0x13e1
mov ecx, dword [ebp - 0x48]
add ecx, 0x6b149
mov dword [edx + 8], ecx
mov ecx, dword [0x1021e660]
add ecx, 0x1510
mov dword [0x1021e660], ecx
mov dword [edx + 0xc], 0x20c0
mov ecx, dword [0x1021e664]
add ecx, 0xfffff7d7
mov dword [0x1021e664], ecx
add esp, 0x60
pop esi
pop edi
pop ebx
pop ebp
ret
Function at 0x10200437
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x54
mov eax, dword [ebp + 0xc]
mov ecx, dword [ebp + 8]
lea edx, [0x102032a3]
mov esi, 0xe
lea edi, [ebp - 0x2c]
mov ebx, dword [0x1021e660]
add ebx, 0x1e99
mov dword [0x1021e660], ebx
mov dword [esp], edi
mov dword [esp + 4], edx
mov dword [esp + 8], 0xe
mov dword [ebp - 0x30], eax
mov dword [ebp - 0x34], ecx
mov dword [ebp - 0x38], edi
mov dword [ebp - 0x3c], esi
call fcn.102000ef
mov eax, dword [0x1021e660]
add eax, 0xfffffc44
mov dword [0x1021e664], eax
mov dword [0x1021e660], 0x6c2
call fcn.1020001b
mov dword [esp], eax
mov eax, dword [ebp - 0x38]
mov dword [esp + 4], eax
call fcn.1020027e
xor ecx, ecx
mov dword [0x1021e660], 0x236d
cmp eax, 0
mov dword [ebp - 0x40], eax
mov dword [ebp - 0x44], ecx
je 0x10200599
mov eax, dword [ebp - 0x40]
mov dword [0x1021e660], 0x1258
mov ecx, esp
mov dword [ecx + 0xc], 0x40
mov dword [ecx + 8], 0x1000
mov dword [ecx + 4], 0x6000
mov dword [ecx], 0
call eax
sub esp, 0x10
mov ecx, dword [0x1021e660]
add ecx, 0x194b
mov dword [0x1021e664], ecx
mov dword [esp], eax
mov ecx, dword [ebp - 0x30]
mov dword [esp + 4], ecx
mov dword [ebp - 0x48], eax
call fcn.101ffa0d
mov eax, dword [ebp - 0x48]
mov word [eax], 0x5a4d
add eax, 0x3c
mov dword [ebp - 0x4c], eax
xor eax, eax
mov ecx, dword [ebp - 0x4c]
mov dword [ecx], 0xd0
mov edx, dword [ebp - 0x48]
mov dword [edx + 0xd0], 0x4550
add edx, 0xffc00000
mov esi, dword [ebp - 0x34]
mov dword [esi + 0x4c], edx
mov dword [0x1021e660], 0x341
mov edx, dword [ebp - 0x48]
mov dword [esi + 0x50], edx
cmp edx, 0
mov dword [ebp - 0x44], eax
je 0x10200599
mov eax, dword [ebp - 0x48]
add eax, 0x1e39
mov dword [0x1021e664], 0x1ddf
mov dword [0x1021e660], 0xffffefc9
mov dword [ebp - 0x50], eax
mov eax, dword [ebp - 0x50]
mov dword [ebp - 0x44], eax
jmp 0x10200599
mov eax, dword [ebp - 0x44]
add esp, 0x54
pop esi
pop edi
pop ebx
pop ebp
ret
Function at 0x102005a4
Capabilities:
Get number of processors

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
sub esp, 0x2c
mov dword [ebp - 0xc], 0
mov dword [0x1021e660], 0x1367
mov eax, dword fs:[0x30]
mov dword [ebp - 0xc], eax
xor ecx, ecx
mov edx, dword [ebp - 0xc]
mov edx, dword [edx + 0x10]
mov edx, dword [edx + 0x3c]
mov esi, dword [0x1021e660]
mov edi, esi
add edi, 0xffffec0a
mov dword [0x1021e660], edi
mov dword [ebp - 0x10], eax
mov dword [ebp - 0x14], esi
mov dword [ebp - 0x18], edx
mov dword [ebp - 0x1c], ecx
jmp 0x102005fd
mov eax, dword [ebp - 0x20]
add esp, 0x2c
pop esi
pop edi
pop ebp
ret
mov eax, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0x18]
cmp word [ecx + eax*2], 0
mov edx, eax
mov dword [ebp - 0x24], eax
mov dword [ebp - 0x28], edx
je 0x1020063e
mov eax, dword [ebp - 0x24]
add eax, 1
cmp eax, 0x104
setl cl
mov dword [ebp - 0x2c], eax
mov byte [ebp - 0x2d], cl
mov al, byte [ebp - 0x2d]
test al, 1
mov ecx, dword [ebp - 0x2c]
mov edx, dword [ebp - 0x2c]
mov dword [ebp - 0x1c], ecx
mov dword [ebp - 0x28], edx
jne 0x102005fd
jmp 0x1020063e
mov eax, dword [ebp - 0x28]
xor ecx, ecx
mov edx, dword [ebp - 0x14]
add edx, 0xfffff5a8
mov dword [0x1021e660], edx
mov edx, dword [ebp - 0x18]
cmp word [edx + eax*2 - 0x1a], 0x6c
mov dword [ebp - 0x34], eax
mov dword [ebp - 0x20], ecx
jne 0x102005f3
xor eax, eax
mov dword [0x1021e660], 0x28f
mov ecx, dword [ebp - 0x18]
mov edx, dword [ebp - 0x34]
cmp word [ecx + edx*2 - 0x18], 0x6f
mov dword [ebp - 0x20], eax
jne 0x102005f3
xor eax, eax
mov dword [0x1021e660], 0x2505
mov ecx, dword [ebp - 0x18]
mov edx, dword [ebp - 0x34]
cmp word [ecx + edx*2 - 0x16], 0x61
mov dword [ebp - 0x20], eax
jne 0x102005f3
xor eax, eax
mov dword [0x1021e664], 0x870
mov ecx, dword [ebp - 0x18]
mov edx, dword [ebp - 0x34]
cmp word [ecx + edx*2 - 0x14], 0x64
mov dword [ebp - 0x20], eax
jne 0x102005f3
xor eax, eax
mov dword [0x1021e660], 0x264f
mov ecx, dword [ebp - 0x18]
mov edx, dword [ebp - 0x34]
cmp word [ecx + edx*2 - 0x12], 0x64
mov dword [ebp - 0x20], eax
jne 0x102005f3
xor eax, eax
mov dword [0x1021e660], 0x1f9e
mov ecx, dword [ebp - 0x18]
mov edx, dword [ebp - 0x34]
cmp word [ecx + edx*2 - 0x10], 0x6c
mov dword [ebp - 0x20], eax
jne 0x102005f3
xor eax, eax
mov ecx, dword [ebp - 0x18]
mov edx, dword [ebp - 0x34]
cmp word [ecx + edx*2 - 0xe], 0x6c
mov dword [ebp - 0x20], eax
jne 0x102005f3
mov dword [0x1021e660], 0x536
mov eax, 1
mov dword [ebp - 0x20], eax
jmp 0x102005f3
Function at 0x10200a6c
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x50
mov eax, dword [ebp + 8]
mov ecx, dword [0x1021e660]
add ecx, 0xffffea42
mov dword [0x1021e664], ecx
mov dword [ebp - 0x10], eax
call fcn.10200e17
xor ecx, ecx
mov edx, eax
mov esi, dword [eax + 0x3c]
mov dword [0x1021e660], 0x1516
mov esi, dword [eax + esi + 0x78]
mov dword [0x1021e660], 0x11d0
mov edi, edx
add edi, dword [eax + esi + 0x20]
mov dword [0x1021e664], 0x6c2
mov eax, dword [eax + esi + 0x18]
cmp eax, 0
mov dword [ebp - 0x14], edi
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x1c], edx
mov dword [ebp - 0x20], esi
mov dword [ebp - 0x24], ecx
jne 0x10200ae6
mov eax, dword [ebp - 0x24]
add esp, 0x50
pop esi
pop edi
pop ebx
pop ebp
ret
xor eax, eax
mov ecx, 0xffffefb4
mov edx, dword [ebp - 0x1c]
mov esi, dword [ebp - 0x20]
add edx, dword [edx + esi + 0x24]
mov dword [ebp - 0x28], eax
mov dword [ebp - 0x2c], edx
mov dword [ebp - 0x30], ecx
jmp 0x10200b0f
mov al, byte [ebp - 0x31]
test al, 1
jne 0x10200bd8
jmp 0x10200b82
mov eax, dword [ebp - 0x30]
mov ecx, dword [ebp - 0x2c]
mov edx, dword [ebp - 0x28]
xor esi, esi
mov edi, dword [ebp - 0x14]
mov ebx, dword [edi + edx*4]
mov dword [ebp - 0x38], eax
mov dword [ebp - 0x3c], ecx
mov dword [ebp - 0x40], edx
mov dword [ebp - 0x44], ebx
mov dword [ebp - 0x48], esi
mov eax, dword [ebp - 0x48]
mov ecx, eax
mov edx, dword [ebp - 0x44]
add ecx, edx
mov esi, dword [ebp - 0x1c]
mov bl, byte [esi + ecx]
mov ecx, dword [ebp - 0x10]
mov bh, byte [ecx + eax]
cmp bl, bh
sete cl
cmp bl, 0
mov dword [ebp - 0x4c], eax
mov byte [ebp - 0x4d], bh
mov byte [ebp - 0x31], cl
je 0x10200b02
mov eax, dword [ebp - 0x4c]
add eax, 1
mov cl, byte [ebp - 0x4d]
cmp cl, 0
setne dl
mov ch, byte [ebp - 0x31]
and ch, dl
cmp eax, 0x20
setb dl
and ch, dl
test ch, 1
mov dword [ebp - 0x48], eax
jne 0x10200b2f
jmp 0x10200b02
mov dword [0x1021e660], 0x10da
mov eax, dword [ebp - 0x3c]
add eax, 2
mov ecx, dword [ebp - 0x40]
add ecx, 1
mov edx, dword [ebp - 0x18]
cmp ecx, edx
setb bl
mov dword [ebp - 0x54], eax
mov dword [ebp - 0x58], ecx
mov byte [ebp - 0x59], bl
mov eax, 0xffffeebe
xor ecx, ecx
mov dl, byte [ebp - 0x59]
test dl, 1
mov esi, dword [ebp - 0x58]
mov edi, dword [ebp - 0x54]
mov dword [ebp - 0x2c], edi
mov dword [ebp - 0x24], ecx
mov dword [ebp - 0x28], esi
mov dword [ebp - 0x30], eax
jne 0x10200b0f
jmp 0x10200adb
mov eax, dword [ebp - 0x3c]
movzx ecx, word [eax]
mov edx, dword [ebp - 0x38]
mov dword [0x1021e664], edx
mov esi, dword [ebp - 0x1c]
mov edi, dword [ebp - 0x20]
add esi, dword [esi + edi + 0x1c]
mov ebx, dword [ebp - 0x1c]
add ebx, dword [esi + ecx*4]
mov dword [0x1021e660], 0x1a69
mov dword [ebp - 0x24], ebx
jmp 0x10200adb
Function at 0x10200f84
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x34
mov eax, dword [ebp + 0x14]
mov ecx, dword [ebp + 0x10]
mov edx, dword [ebp + 0xc]
mov esi, dword [ebp + 8]
xor edi, edi
mov ebx, 0x4207
mov dword [0x1021e668], 0
mov dword [0x1021e66c], 0
mov dword [0x1021e678], 0
mov dword [0x1021e664], 0x222c
mov dword [0x1021e660], 0x4207
cmp eax, 0
mov dword [ebp - 0x10], eax
mov eax, edi
mov dword [ebp - 0x14], eax
mov eax, edi
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x1c], ecx
mov dword [ebp - 0x20], edx
mov dword [ebp - 0x24], esi
mov dword [ebp - 0x28], ebx
mov dword [ebp - 0x2c], edi
je 0x10201138
mov eax, dword [ebp - 0x2c]
mov ecx, dword [ebp - 0x18]
mov edx, dword [ebp - 0x28]
mov esi, dword [ebp - 0x14]
mov edi, 0x100
add esi, 1
mov ebx, ecx
add ebx, 1
add edx, 0xfffff351
mov dword [0x1021e660], edx
mov dword [ebp - 0x30], eax
mov eax, esi
cdq
idiv edi
mov dword [0x1021e668], edx
mov esi, dword [ebp - 0x24]
movzx esi, byte [esi + edx]
mov dword [ebp - 0x34], ecx
mov ecx, dword [ebp - 0x30]
add esi, ecx
mov eax, esi
mov dword [ebp - 0x38], edx
cdq
idiv edi
mov dword [0x1021e66c], edx
mov dword [0x1021e660], 0x1bda
mov ecx, dword [ebp - 0x24]
mov esi, dword [ebp - 0x38]
mov cl, byte [ecx + esi]
mov byte [0x1021e670], cl
mov dword [0x1021e660], 0x297
mov edi, dword [ebp - 0x24]
mov cl, byte [edi + edx]
mov byte [edi + esi], cl
mov dword [0x1021e660], 0x2f0
mov cl, byte [0x1021e670]
mov edx, dword [0x1021e66c]
mov byte [edi + edx], cl
mov edx, dword [0x1021e668]
movzx edx, byte [edi + edx]
mov ecx, dword [0x1021e66c]
movzx ecx, byte [edi + ecx]
add ecx, edx
mov dword [0x1021e664], 0xffffe4ab
and ecx, 0xff
mov dword [0x1021e678], ecx
mov dword [0x1021e660], 0x1696
mov cl, byte [edi + ecx]
mov edx, dword [ebp - 0x1c]
mov esi, dword [ebp - 0x34]
mov ch, byte [edx + esi]
mov byte [0x1021e67d], ch
mov byte [0x1021e67e], cl
xor ch, cl
mov byte [0x1021e67c], ch
mov dword [0x1021e664], 0xffffef26
mov dword [0x1021e660], 0x15f1
mov edx, dword [ebp - 0x20]
mov byte [edx + esi], ch
mov edx, dword [ebp - 0x10]
cmp ebx, edx
mov dword [ebp - 0x3c], ebx
je 0x10201138
mov eax, dword [0x1021e660]
mov dword [ebp - 0x40], eax
mov eax, dword [0x1021e668]
mov ecx, dword [0x1021e66c]
mov edx, dword [ebp - 0x40]
mov esi, dword [ebp - 0x3c]
mov dword [ebp - 0x18], esi
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x28], edx
mov dword [ebp - 0x2c], ecx
jmp 0x10200ff9
mov dword [0x1021e664], 0x23ec
add esp, 0x34
pop esi
pop edi
pop ebx
pop ebp
ret
Function at 0x1020114a
Capabilities:
Parse pe header
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x98
call fcn.1000106e
xor ecx, ecx
cmp eax, 0
mov dword [esp + 0x24], ecx
je 0x102011b6
mov eax, dword [esp + 0x24]
mov esp, ebp
pop ebp
ret
mov eax, dword [esp + 0x20]
mov dword [esp + 0x8c], eax
mov dword [0x1021e660], 0x1516
mov ecx, dword [esp + 0x1c]
mov edx, dword [eax + ecx + 0x50]
mov dword [esp + 0x58], edx
mov dword [0x1021e664], 0x3a6
call fcn.102005a4
xor ecx, ecx
cmp eax, 0
mov dword [esp + 0x18], ecx
je 0x1020126c
jmp 0x102012a8
lea eax, [esp + 0x28]
lea ecx, [esp + 0x38]
mov dword [esp], eax
mov dword [esp + 0x14], ecx
call fcn.101ffdf7
lea ecx, [0x10200c09]
mov edx, dword [esp + 0x28]
mov dword [esp + 0x94], edx
mov dword [0x1021e664], 0x1082
mov dword [esp + 0x78], 0x13e400
mov edx, dword [0x1021e64c]
mov dword [esp + 0x5c], edx
mov edx, dword [0x1021e650]
mov dword [esp + 0x6c], edx
mov edx, dword [0x1021e654]
mov dword [esp + 0x64], edx
mov edx, dword [0x1021e658]
mov dword [esp + 0x74], edx
mov edx, dword [0x1021e65c]
mov dword [esp + 0x68], edx
mov dword [0x1021e660], 0xffffe113
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], ecx
mov eax, dword [esp + 0xc]
cmp word [eax], 0x5a4d
mov dword [esp + 0x20], eax
jne 0x10201258
mov eax, dword [esp + 0x20]
mov ecx, dword [eax + 0x3c]
cmp dword [eax + ecx], 0x4550
mov dword [esp + 0x1c], ecx
je 0x10201170
mov eax, dword [esp + 0x20]
add eax, 0xfffff000
and eax, 0xfffff000
mov dword [esp + 0xc], eax
jmp 0x10201231
lea eax, [esp + 0x38]
mov ecx, dword [esp + 0x30]
mov dword [esp], eax
mov dword [esp + 4], ecx
call fcn.10200437
mov dword [esp + 8], eax
mov eax, dword [esp + 8]
mov dword [0x1021e664], 0x2491
mov ecx, esp
lea edx, [esp + 0x38]
mov dword [ecx], edx
call eax
sub esp, 4
mov eax, 1
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0x18]
mov dword [esp + 0x24], eax
jmp 0x10201168
Function at 0x402948
Capabilities:
Get common file path
Set current directory

Disassembly:
push ebx
push esi
add esp, 0xfffffdf0
mov esi, edx
mov ebx, eax
test bl, bl
je 0x402985
xor eax, eax
mov al, bl
add eax, 0x41
dec eax
mov byte [esp], al
mov byte [esp + 1], 0x3a
mov byte [esp + 2], 0
lea eax, [esp + 0x109]
push eax
push 0x105
call sub.KERNEL32.DLL_GetCurrentDirectoryA
push esp
call sub.KERNEL32.DLL_SetCurrentDirectoryA
lea eax, [esp + 4]
push eax
push 0x105
call sub.KERNEL32.DLL_GetCurrentDirectoryA
test bl, bl
je 0x4029a5
lea eax, [esp + 0x109]
push eax
call sub.KERNEL32.DLL_SetCurrentDirectoryA
mov eax, esi
lea edx, [esp + 4]
mov ecx, 0x105
call fcn.0040490c
add esp, 0x210
pop esi
pop ebx
ret

Function at 0x402bdc
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.0040469c
test esi, esi
jne 0x402c12
push 0x105
lea eax, [esp + 4]
push eax
push 0
call sub.KERNEL32.DLL_GetModuleFileNameA_1
mov ecx, eax
mov edx, esp
mov eax, ebx
call fcn.0040478c
jmp 0x402c30
call sub.KERNEL32.DLL_GetCommandLineA
mov edi, eax
mov edx, ebx
mov eax, edi
call fcn.00402a90
mov edi, eax
test esi, esi
je 0x402c30
cmp dword [ebx], 0
je 0x402c30
dec esi
jmp 0x402c19
add esp, 0x108
pop edi
pop esi
pop ebx
ret

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

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

Function at 0x4037bc
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff4
movzx eax, word [0x4b8024]
mov dword [ebp - 8], eax
lea eax, [ebp - 4]
push eax
push 1
push 0
push 0x403854
push 0x80000002
call sub.advapi32.dll_RegOpenKeyExA_1
test eax, eax
jne 0x403834
xor eax, eax
push ebp
push 0x40382d
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 0x403870
mov eax, dword [ebp - 4]
push eax
call sub.advapi32.dll_RegQueryValueExA_1
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x403834
mov eax, dword [ebp - 4]
push eax
call sub.advapi32.dll_RegCloseKey_1
ret
mov ax, word [0x4b8024]
and ax, 0xffc0
mov dx, word [ebp - 8]
and dx, 0x3f
or ax, dx
mov word [0x4b8024], ax
mov esp, ebp
pop ebp
ret

Function at 0x404520
Capabilities:
Write file on windows

Disassembly:
push ecx
cmp byte [0x4bf04c], 0
je 0x404581
cmp word [0x4bf220], 0xd7b2
jne 0x404549
cmp dword [0x4bf228], 0
jbe 0x404549
mov eax, 0x4bf21c
call dword [0x4bf238]
push 0
lea eax, [esp + 4]
push eax
push 0x1e
push 0x4b8094
push 0xfffffffffffffff5
call sub.KERNEL32.DLL_GetStdHandle_1
push eax
call sub.KERNEL32.DLL_WriteFile_1
push 0
lea eax, [esp + 4]
push eax
push 2
push 0x4045a8
push 0xfffffffffffffff5
call sub.KERNEL32.DLL_GetStdHandle_1
push eax
call sub.KERNEL32.DLL_WriteFile_1
pop edx
ret
cmp byte [0x4b8034], 0
jne 0x40459d
push 0
push 0x4b808c
push 0x4b8094
push 0
call sub.user32.dll_MessageBoxA_1
pop edx
ret