joyce8/EMBER2024-capa huggingface dataset:
Function at 0x412680
Capabilities:
Set environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.0041232e

Function at 0x41a3e0
Capabilities:
Query or enumerate registry value

Disassembly:
push 0
mov eax, 0x41db60
call fcn.00408880
mov edi, dword [ebp + 0xc]
lea eax, [ebp + 0xc]
push dword [ebp + 8]
xor ebx, ebx
push eax
mov dword [edi], ebx
mov dword [edi + 4], ebx
call fcn.0041a665
mov dword [ebp - 4], ebx
lea ecx, [ebp + 8]
push ecx
push 0x20219
push ebx
push dword [eax]
push 0x80000000
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
mov esi, eax
or dword [ebp - 4], 0xffffffff
mov ecx, dword [ebp + 0xc]
add ecx, 0xfffffff0
call fcn.00419b52
test esi, esi
jne 0x41a481
mov esi, dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
lea eax, [ebp + 0xc]
push edi
push ebx
push eax
push ebx
push ebx
push dword [ebp + 8]
mov dword [ebp + 0xc], ebx
call esi
test eax, eax
jne 0x41a476
cmp dword [ebp + 0xc], 3
jne 0x41a476
push dword [edi]
call fcn.0041d47b
pop ecx
push edi
push eax
mov dword [edi + 4], eax
lea eax, [ebp + 0xc]
push eax
push ebx
push ebx
push dword [ebp + 8]
call esi
test eax, eax
jne 0x41a473
cmp dword [ebp + 0xc], 3
je 0x41a478
mov dword [edi + 4], ebx
mov dword [edi], ebx
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
cmp dword [edi + 4], ebx
setne al
call fcn.0040885a
ret 8
Function at 0x41a720
Capabilities:
Encrypt data using dpapi

Disassembly:
push 0x14
mov eax, 0x41dc1e
call fcn.00408880
push 8
call fcn.0041d44b
pop ecx
mov dword [ebp - 0x10], eax
xor ebx, ebx
mov dword [ebp - 4], ebx
test eax, eax
je 0x41a74b
mov ecx, eax
call fcn.00419bf8
mov esi, eax
jmp 0x41a74d
mov esi, ebx
or dword [ebp - 4], 0xffffffff
mov eax, dword [esi + 4]
mov edi, dword [ebp + 8]
mov byte [esi], 1
mov dword [eax], edi
lea eax, [ebp - 0x18]
push eax
push edi
mov dword [ebp - 0x18], ebx
mov dword [ebp - 0x14], ebx
call fcn.0041a3e0
test al, al
je 0x41a8b6
lea eax, [ebp - 0x20]
push eax
push 1
push ebx
push ebx
push ebx
push ebx
lea eax, [ebp - 0x18]
push eax
call dword [sym.imp.CRYPT32.dll_CryptUnprotectData]
test eax, eax
je 0x41a7d1
mov eax, 0xe0
cmp dword [ebp - 0x20], eax
jne 0x41a8aa
push eax
push dword [esi + 4]
call fcn.004085ea
mov byte [esi + 1], 1
mov eax, dword [ebp - 0x1c]
mov dword [esi + 4], eax
mov eax, dword [ebp - 0x1c]
pop ecx
pop ecx
cmp dword [eax], edi
jne 0x41a8aa
xor ecx, ecx
mov word [eax + 0x32], cx
mov eax, dword [esi + 4]
mov word [eax + 0xbe], cx
mov byte [esi], bl
jmp 0x41a8aa
call fcn.0041cc3d
test al, al
je 0x41a8aa
mov eax, dword [ebp - 0x18]
and dword [ebp - 0x10], 0
mov ebx, dword [ebp - 0x14]
shr eax, 2
sub eax, 1
je 0x41a80f
mov edi, dword [ebp - 0x10]
push edi
push dword [ebx]
call fcn.0041ceaf
mov dword [ebx], eax
inc edi
mov eax, dword [ebp - 0x18]
lea ebx, [ebx + 4]
shr eax, 2
dec eax
cmp edi, eax
jb 0x41a7f3
mov edi, dword [ebp + 8]
mov ebx, dword [ebp - 0x14]
cmp dword [ebx + 0xc0], edi
jne 0x41a8aa
mov eax, dword [esi + 4]
lea ecx, [ebp + 8]
and dword [ebp - 0x10], 0
mov byte [esi], 0
mov dword [eax], edi
lea eax, [ebx + 2]
push eax
call fcn.00419b9d
mov dword [ebp - 4], 1
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp + 8]
push eax
push dword [ebx + 0xc0]
call fcn.0041a585
mov edi, eax
or dword [ebp - 4], 0xffffffff
mov ecx, dword [ebp + 8]
add ecx, 0xfffffff0
call fcn.00419b52
test edi, edi
je 0x41a8aa
mov ecx, dword [esi + 4]
mov al, byte [ebx]
push 0
mov byte [ecx + 0xdd], al
mov ecx, dword [esi + 4]
mov eax, dword [ebp - 0x10]
mov dword [ecx + 0xc4], eax
lea eax, [ebx + 2]
push dword [edi + 0x14]
mov ecx, esi
push dword [edi]
push eax
lea eax, [ebx + 0x52]
push eax
lea eax, [ebx + 0x82]
push eax
call fcn.00419d31
push 0
mov eax, 0xffff
mov ecx, esi
push eax
push eax
push eax
call fcn.0041ac27
push 1
push dword [ebp - 0x14]
call fcn.004085ea
pop ecx
pop ecx
mov eax, esi
call fcn.0040885a
ret 4
Function at 0x41a9bf
Capabilities:
Set registry value

Disassembly:
push 4
mov eax, 0x41dc50
call fcn.00408880
push dword [ebp + 8]
lea eax, [ebp - 0x10]
xor ebx, ebx
push eax
call fcn.0041a665
mov dword [ebp - 4], ebx
lea ecx, [ebp + 8]
push ebx
push ecx
push ebx
push 0x20206
push ebx
push ebx
push ebx
push dword [eax]
push 0x80000000
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
mov esi, eax
or dword [ebp - 4], 0xffffffff
mov ecx, dword [ebp - 0x10]
lea ecx, [ecx - 0x10]
call fcn.00419b52
test esi, esi
jne 0x41aa2f
push dword [ebp + 0xc]
push dword [ebp + 0x10]
push 3
push ebx
push ebx
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
push dword [ebp + 8]
neg eax
sbb al, al
lea ebx, [eax + 1]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov al, bl
call fcn.0040885a
ret 0xc

Function at 0x41aa71
Capabilities:
Encrypt data using dpapi

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xd8
mov eax, dword [0x420008]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, ecx
cmp byte [esi], 0
je 0x41aa93
xor al, al
jmp 0x41abab
mov eax, dword [esi + 4]
push ebx
xor ebx, ebx
mov dword [ebp - 0xd0], 0xe0
mov dword [ebp - 0xcc], eax
cmp dword [eax + 0xc0], 0xb
jne 0x41ab66
call fcn.0041cc3d
test al, al
je 0x41ab66
mov ecx, dword [esi + 4]
push edi
push 0x27
mov al, byte [ecx + 0xdd]
mov byte [ebp - 0xc8], al
mov eax, dword [ecx]
mov dword [ebp - 8], eax
lea eax, [ecx + 0x34]
push eax
lea eax, [ebp - 0xc6]
push 0x28
push eax
call fcn.00411569
mov eax, dword [esi + 4]
push 0x17
add eax, 4
push eax
lea eax, [ebp - 0x76]
push 0x18
push eax
call fcn.00411569
mov eax, dword [esi + 4]
push 0x1d
add eax, 0x84
push eax
lea eax, [ebp - 0x46]
push 0x1e
push eax
call fcn.00411569
lea eax, [ebp - 0xc8]
mov dword [ebp - 0xd0], 0xc4
add esp, 0x30
mov dword [ebp - 0xcc], eax
mov edi, eax
push ebx
push dword [edi]
call fcn.0041ce99
mov dword [edi], eax
inc ebx
mov eax, dword [ebp - 0xd0]
lea edi, [edi + 4]
shr eax, 2
dec eax
cmp ebx, eax
jb 0x41ab31
push dword [ebp - 0xcc]
mov eax, dword [esi + 4]
push dword [ebp - 0xd0]
push dword [eax]
call fcn.0041a9bf
pop edi
jmp 0x41abaa
lea eax, [ebp - 0xd8]
push eax
push 5
push ebx
push ebx
push ebx
push ebx
lea eax, [ebp - 0xd0]
push eax
call dword [sym.imp.CRYPT32.dll_CryptProtectData]
test eax, eax
je 0x41aba8
push dword [ebp - 0xd4]
mov eax, dword [esi + 4]
push dword [ebp - 0xd8]
push dword [eax]
call fcn.0041a9bf
push dword [ebp - 0xd4]
mov bl, al
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov al, bl
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.00408849
leave
ret
Function at 0x41bba2
Capabilities:
Query or enumerate registry value

Disassembly:
push 0x20
mov eax, 0x41e102
call fcn.00408880
xor esi, esi
xor ebx, ebx
mov dword [ebp - 0x20], esi
inc ebx
mov ecx, dword [ebp + 0xc]
mov eax, dword [ecx]
cmp dword [eax - 0xc], ebx
jge 0x41bbd3
mov ecx, dword [ebp + 8]
call fcn.00419939
mov dword [ebp - 4], esi
mov dword [ebp - 0x20], ebx
jmp 0x41bd75
push ecx
push 0x407588
lea eax, [ebp - 0x14]
mov dword [ebp - 0x10], 0x80000002
push eax
call fcn.0041b05d
mov dword [ebp - 4], ebx
lea ecx, [ebp + 0xc]
push dword [ebp - 0x14]
call fcn.00419b9d
mov byte [ebp - 4], 3
lea ecx, [ebp + 0xc]
call fcn.0041b5bd
mov ecx, eax
test ecx, ecx
jns 0x41bc30
mov ecx, dword [ebp + 8]
call fcn.00419939
mov dword [ebp - 0x20], ebx
mov byte [ebp - 4], bl
lea eax, [ebp + 0xc]
mov dword [ebp - 0x2c], eax
mov byte [ebp - 4], bl
mov ecx, dword [ebp + 0xc]
lea ecx, [ecx - 0x10]
call fcn.00419b52
jmp 0x41bd67
mov eax, dword [ebp - 0x14]
mov eax, dword [eax - 0xc]
sub eax, ecx
lea ecx, [ebp - 0x14]
push eax
lea eax, [ebp - 0x28]
push eax
call fcn.0041bfd5
mov byte [ebp - 4], 7
lea ecx, [ebp + 0xc]
call fcn.0041bfb0
lea ecx, [ebp - 0x24]
call fcn.00419939
mov byte [ebp - 4], 8
lea eax, [ebp - 0x10]
push eax
push 0x20219
push esi
push dword [ebp + 0xc]
push dword [ebp - 0x10]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x41bd23
lea eax, [ebp - 0x1c]
mov dword [ebp - 0x18], esi
push eax
push esi
lea eax, [ebp - 0x18]
mov dword [ebp - 0x1c], esi
push eax
push esi
push dword [ebp - 0x28]
push dword [ebp - 0x10]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x41bd1a
cmp dword [ebp - 0x18], ebx
jne 0x41bd1a
mov eax, dword [ebp - 0x1c]
test eax, eax
je 0x41bd1a
xor ecx, ecx
push 2
pop edx
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0041d47b
pop ecx
mov esi, eax
lea eax, [ebp - 0x1c]
push eax
push esi
lea eax, [ebp - 0x18]
push eax
push 0
push dword [ebp - 0x28]
push dword [ebp - 0x10]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x41bd11
cmp dword [ebp - 0x18], ebx
jne 0x41bd11
mov eax, dword [ebp - 0x1c]
test eax, eax
je 0x41bd11
xor ecx, ecx
mov word [esi + eax*2 - 2], cx
lea ecx, [ebp - 0x2c]
push esi
call fcn.00419b9d
mov byte [ebp - 4], 9
lea ecx, [ebp - 0x24]
push eax
call fcn.0041af9b
mov byte [ebp - 4], 8
mov ecx, dword [ebp - 0x2c]
lea ecx, [ecx - 0x10]
call fcn.00419b52
push esi
call fcn.0041d484
pop ecx
xor esi, esi
push dword [ebp - 0x10]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [ebp + 8]
lea eax, [ebp - 0x24]
push eax
call fcn.00419b6a
mov dword [ebp - 0x20], ebx
mov byte [ebp - 4], 7
mov ecx, dword [ebp - 0x24]
lea ecx, [ecx - 0x10]
call fcn.00419b52
mov byte [ebp - 4], 3
mov ecx, dword [ebp - 0x28]
lea ecx, [ecx - 0x10]
call fcn.00419b52
mov byte [ebp - 4], bl
lea eax, [ebp + 0xc]
mov dword [ebp - 0x2c], eax
mov byte [ebp - 4], bl
mov ecx, dword [ebp + 0xc]
lea ecx, [ecx - 0x10]
call fcn.00419b52
mov dword [ebp - 4], esi
mov ecx, dword [ebp - 0x14]
add ecx, 0xfffffff0
call fcn.00419b52
mov eax, dword [ebp + 8]
call fcn.0040885a
ret 8
Function at 0x41be10
Capabilities:
Get token membership

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
mov eax, dword [0x420008]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
xor ebx, ebx
mov word [ebp - 8], 0x500
lea eax, [ebp - 0x14]
mov dword [ebp - 0xc], ebx
push eax
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push 0x220
push 0x20
push 2
lea eax, [ebp - 0xc]
push eax
call dword [sym.imp.ADVAPI32.dll_AllocateAndInitializeSid]
mov dword [ebp - 0x10], eax
test eax, eax
je 0x41be73
lea eax, [ebp - 0x10]
push eax
push dword [ebp - 0x14]
push ebx
call dword [sym.imp.ADVAPI32.dll_CheckTokenMembership]
push dword [ebp - 0x14]
neg eax
sbb eax, eax
and dword [ebp - 0x10], eax
call dword [sym.imp.ADVAPI32.dll_FreeSid]
mov eax, dword [ebp - 0x10]
test eax, eax
mov ecx, dword [ebp - 4]
setne al
xor ecx, ebp
pop ebx
call fcn.00408849
leave
ret

Function at 0x41bed7
Capabilities:
Set registry value

Disassembly:
push 8
mov eax, 0x41e1a9
call fcn.00408880
lea ecx, [ebp - 0x14]
call fcn.00419939
xor edi, edi
mov dword [ebp - 4], edi
lea eax, [ebp - 0x14]
push dword [ebp + 8]
push 0x4074a8
push 0x40745c
push eax
call fcn.0041a211
add esp, 0x10
lea eax, [ebp - 0x10]
push edi
push eax
push edi
push 0x20206
push edi
push edi
push edi
push dword [ebp - 0x14]
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
test eax, eax
jne 0x41bf6b
push 4
lea eax, [ebp + 0xc]
push eax
push 4
push edi
push 0x40750c
push dword [ebp - 0x10]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
mov eax, dword [ebp + 0x10]
mov ecx, dword [eax]
mov eax, dword [ecx - 0xc]
lea eax, [eax*2 + 2]
push eax
push ecx
push 1
push edi
push 0x407520
push dword [ebp - 0x10]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
push dword [ebp - 0x10]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
or dword [ebp - 4], 0xffffffff
mov ecx, dword [ebp - 0x14]
lea ecx, [ecx - 0x10]
call fcn.00419b52
xor eax, eax
call fcn.0040885a
ret 0xc

Function at 0x41c705
Capabilities:
Query or enumerate registry value

Disassembly:
push 4
mov eax, 0x41e301
call fcn.00408880
mov edi, dword [ebp + 8]
lea eax, [ebp + 8]
xor ebx, ebx
push eax
mov dword [edi], ebx
mov dword [edi + 4], ebx
call fcn.0041c91e
mov dword [ebp - 4], ebx
lea ecx, [ebp - 0x10]
push ecx
push 0x20219
push ebx
push dword [eax]
push 0x80000000
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
mov esi, eax
or dword [ebp - 4], 0xffffffff
mov ecx, dword [ebp + 8]
add ecx, 0xfffffff0
call fcn.00419b52
test esi, esi
jne 0x41c7a3
mov esi, dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
lea eax, [ebp + 8]
push edi
push ebx
push eax
push ebx
push ebx
push dword [ebp - 0x10]
mov dword [ebp + 8], ebx
call esi
test eax, eax
jne 0x41c798
cmp dword [ebp + 8], 3
jne 0x41c798
push dword [edi]
call fcn.0041d47b
pop ecx
push edi
push eax
mov dword [edi + 4], eax
lea eax, [ebp + 8]
push eax
push ebx
push ebx
push dword [ebp - 0x10]
call esi
test eax, eax
jne 0x41c795
cmp dword [ebp + 8], 3
je 0x41c79a
mov dword [edi + 4], ebx
mov dword [edi], ebx
push dword [ebp - 0x10]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
cmp dword [edi + 4], ebx
setne al
call fcn.0040885a
ret 4
Function at 0x41c8a7
Capabilities:
Set registry value

Disassembly:
push 8
mov eax, 0x41e1a9
call fcn.00408880
lea eax, [ebp - 0x14]
xor ebx, ebx
push eax
call fcn.0041c91e
mov dword [ebp - 4], ebx
lea ecx, [ebp - 0x10]
push ebx
push ecx
push ebx
push 0x20206
push ebx
push ebx
push ebx
push dword [eax]
push 0x80000000
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
mov esi, eax
or dword [ebp - 4], 0xffffffff
mov ecx, dword [ebp - 0x14]
lea ecx, [ecx - 0x10]
call fcn.00419b52
test esi, esi
jne 0x41c914
push dword [ebp + 8]
push dword [ebp + 0xc]
push 3
push ebx
push ebx
push dword [ebp - 0x10]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
push dword [ebp - 0x10]
neg eax
sbb al, al
lea ebx, [eax + 1]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov al, bl
call fcn.0040885a
ret 8

Function at 0x41ca6d
Capabilities:
Query or enumerate registry value

Disassembly:
push 8
mov eax, 0x41e38e
call fcn.00408880
xor ebx, ebx
mov dword [ebp - 4], ebx
lea eax, [ebp - 0x14]
push 0xfffffffffffffffe
pop edi
push dword [ebp + 8]
mov dword [ebp - 0x10], edi
push eax
call fcn.0041ca23
mov byte [ebp - 4], 1
lea ecx, [ebp + 8]
push ecx
push 0x20019
push ebx
push dword [eax]
push dword [ebp + 0xc]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
mov esi, eax
mov byte [ebp - 4], bl
mov ecx, dword [ebp - 0x14]
add ecx, 0xfffffff0
call fcn.00419b52
test esi, esi
jne 0x41caf4
lea eax, [ebp + 0xc]
mov dword [ebp - 0x14], ebx
push eax
lea eax, [ebp - 0x10]
mov dword [ebp + 0xc], 4
push eax
lea eax, [ebp - 0x14]
push eax
push ebx
push dword [ebp + 0x10]
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
push dword [ebp + 8]
mov esi, eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test esi, esi
je 0x41caf4
mov dword [ebp - 0x10], edi
jmp 0x41caf7
mov edi, dword [ebp - 0x10]
or dword [ebp - 4], 0xffffffff
mov ecx, dword [ebp + 0x10]
add ecx, 0xfffffff0
call fcn.00419b52
mov eax, edi
call fcn.0040885a
ret 0xc

Function at 0x41cb10
Capabilities:
Set registry value

Disassembly:
push 0
mov eax, 0x41e3d0
call fcn.00408880
xor ebx, ebx
mov dword [ebp - 4], ebx
mov edi, dword [ebp + 0xc]
cmp edi, 0xffffffff
jge 0x41cb2c
or edi, 0xffffffff
push dword [ebp + 8]
lea eax, [ebp + 8]
push eax
call fcn.0041ca23
mov byte [ebp - 4], 1
lea ecx, [ebp + 0xc]
push ebx
push ecx
push ebx
push 0x20006
push ebx
push ebx
push ebx
push dword [eax]
movzx eax, byte [ebp + 0x10]
sub eax, 0x7fffffff
push eax
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
mov esi, eax
mov byte [ebp - 4], bl
mov ecx, dword [ebp + 8]
add ecx, 0xfffffff0
call fcn.00419b52
test esi, esi
jne 0x41cb91
push 4
lea eax, [ebp + 0x10]
mov dword [ebp + 0x10], edi
push eax
push 4
push ebx
push dword [ebp + 0x14]
push dword [ebp + 0xc]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
push dword [ebp + 0xc]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
or dword [ebp - 4], 0xffffffff
mov ecx, dword [ebp + 0x14]
lea ecx, [ecx - 0x10]
call fcn.00419b52
call fcn.0040885a
ret 0x10
Function at 0x41ccf7
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xac
mov eax, dword [0x420008]
xor eax, ebp
mov dword [ebp - 4], eax
push edi
mov edi, dword [ebp + 8]
cmp edi, 0x26
ja 0x41cdd9
push ebx
push esi
lea eax, [ebp - 0xac]
xor ebx, ebx
push eax
push 0x20219
push ebx
push 0x407400
push 0x80000000
or esi, 0xffffffff
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x41cdd3
lea eax, [ebp - 0xa8]
mov dword [ebp - 0xa4], ebx
push eax
push ebx
lea eax, [ebp - 0xa4]
mov dword [ebp - 0xa8], ebx
push eax
push ebx
push ebx
push dword [ebp - 0xac]
mov ebx, dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
call ebx
test eax, eax
jne 0x41cdc7
cmp dword [ebp - 0xa4], 3
jne 0x41cdc7
cmp dword [ebp - 0xa8], 0x9c
jne 0x41cdc7
lea eax, [ebp - 0xa8]
push eax
lea eax, [ebp - 0xa0]
push eax
lea eax, [ebp - 0xa4]
push eax
push 0
push 0
push dword [ebp - 0xac]
call ebx
test eax, eax
jne 0x41cdc7
cmp dword [ebp - 0xa4], 3
jne 0x41cdc7
mov esi, dword [ebp + edi*4 - 0xa0]
lea ecx, [edi*4 + 0xf5b7]
add esi, edi
xor esi, ecx
push dword [ebp - 0xac]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, esi
pop esi
pop ebx
jmp 0x41cddc
or eax, 0xffffffff
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop edi
call fcn.00408849
leave
ret 4

Function at 0x41cdeb
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
xor ebx, ebx
lea eax, [ebp - 4]
push ebx
push eax
push ebx
push 0x20206
push ebx
push ebx
push ebx
push 0x407400
push 0x80000000
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
test eax, eax
jne 0x41ce37
push dword [ebp + 8]
push dword [ebp + 0xc]
push 3
push ebx
push ebx
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
push dword [ebp - 4]
neg eax
sbb al, al
lea ebx, [eax + 1]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov al, bl
pop ebx
leave
ret 8

Function at 0x41ce3e
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xa0
mov eax, dword [0x420008]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
push edi
mov edi, dword [ebp + 8]
xor esi, esi
push esi
mov ecx, edi
call fcn.0041c6ce
lea ecx, [esi*4 + 0xf5b7]
xor eax, ecx
sub eax, esi
mov dword [ebp + esi*4 - 0xa0], eax
inc esi
cmp esi, 0x27
jl 0x41ce58
lea eax, [ebp - 0xa0]
push eax
push 0x9c
call fcn.0041cdeb
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.00408849
leave
ret 4
Function at 0x4030a8
Capabilities:
Generate random numbers using the delphi lcg

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

Function at 0x403620
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff4
movzx eax, word [0x417024]
mov dword [ebp - 8], eax
lea eax, [ebp - 4]
push eax
push 1
push 0
push 0x4036b8
push 0x80000002
call sub.advapi32.dll_RegOpenKeyExA
test eax, eax
jne 0x403698
xor eax, eax
push ebp
push 0x403691
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 0x4036d4
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 0x403698
mov eax, dword [ebp - 4]
push eax
call sub.advapi32.dll_RegCloseKey
ret
movzx eax, word [0x417024]
and ax, 0xffc0
movzx edx, word [ebp - 8]
and dx, 0x3f
or ax, dx
mov word [0x417024], ax
mov esp, ebp
pop ebp
ret

Function at 0x4041bc
Capabilities:
Write file on windows

Disassembly:
push ecx
cmp byte [0x418044], 0
je 0x40421d
cmp word [0x418218], 0xd7b2
jne 0x4041e5
cmp dword [0x418220], 0
jbe 0x4041e5
mov eax, 0x418214
call dword [0x418230]
push 0
lea eax, [esp + 4]
push eax
push 0x1e
push str.Runtime_error_____at_00000000
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 0x404244
push 0xfffffffffffffff5
call sub.kernel32.dll_GetStdHandle
push eax
call sub.kernel32.dll_WriteFile
pop edx
ret
cmp byte [0x417030], 0
jne 0x404239
push 0
push str.Error
push str.Runtime_error_____at_00000000
push 0
call sub.user32.dll_MessageBoxA
pop edx
ret
Function at 0x4061bc
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebx
mov ebx, eax
mov eax, ebx
call fcn.004047a8
push eax
call sub.kernel32.dll_GetFileAttributesA
cmp eax, 0xffffffff
je 0x4061d5
test al, 0x10
je 0x4061d9
xor eax, eax
pop ebx
ret
mov al, 1
pop ebx
ret

Function at 0x406368
Capabilities:
Get common file path

Disassembly:
push ebx
add esp, 0xfffffefc
mov ebx, eax
push 0x104
lea eax, [esp + 4]
push eax
call sub.kernel32.dll_GetWindowsDirectoryA
mov eax, ebx
mov edx, esp
mov ecx, 0x104
call fcn.004045ac
add esp, 0x104
pop ebx
ret

Function at 0x406398
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
call fcn.00404798
xor eax, eax
push ebp
push 0x4063e0
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, dword [ebp - 4]
call fcn.004047a8
push eax
call sub.kernel32.dll_GetFileAttributesA
cmp eax, 0xffffffff
setne bl
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4063e7
lea eax, [ebp - 4]
call fcn.0040433c
ret

Function at 0x406664
Capabilities:
Encrypt data using rc6

Disassembly:
push ebx
push esi
push edi
push ebp
add esp, 0xffffffb4
lea edx, [esp + 0xc]
mov eax, dword [0x41a8b4]
mov ecx, 0x40
call fcn.00402f80
mov dword [0x41a800], 0xb7e15163
mov ebx, 0x2b
mov eax, 0x41a800
mov edx, dword [eax]
add edx, 0x9e3779b9
mov dword [eax + 4], edx
add eax, 4
dec ebx
jne 0x406692
xor ebx, ebx
xor ebp, ebp
xor esi, esi
xor edi, edi
mov dword [esp], 0x84
mov eax, dword [ebx*4 + 0x41a800]
add eax, esi
add eax, edi
mov dword [esp + 4], 3
mov ecx, dword [esp + 4]
mov edx, eax
shl edx, cl
mov ecx, dword [esp + 4]
neg ecx
shr eax, cl
or edx, eax
mov eax, edx
mov esi, eax
mov dword [ebx*4 + 0x41a800], esi
lea eax, [edi + esi]
mov dword [esp + 8], eax
mov ecx, dword [esp + 8]
mov eax, dword [esp + ebp*4 + 0xc]
add eax, esi
add eax, edi
shl eax, cl
mov ecx, dword [esp + 8]
neg ecx
mov edx, dword [esp + ebp*4 + 0xc]
add edx, esi
add edi, edx
shr edi, cl
or eax, edi
mov edi, eax
mov dword [esp + ebp*4 + 0xc], edi
lea eax, [ebx + 1]
mov ecx, 0x2c
cdq
idiv ecx
mov ebx, edx
inc ebp
and ebp, 0x8000000f
jns 0x40672a
dec ebp
or ebp, 0xfffffff0
inc ebp
dec dword [esp]
jne 0x4066b2
add esp, 0x4c
pop ebp
pop edi
pop esi
pop ebx
ret