joyce8/EMBER2024-capa huggingface dataset:
Function at 0x40c880
Capabilities:
Query or enumerate registry value

Disassembly:
sub esp, 0x8c
mov eax, dword [0x576fe4]
xor eax, esp
mov dword [esp + 0x88], eax
mov eax, dword [esp + 0x90]
push esi
push edi
mov edi, dword [esp + 0x9c]
lea ecx, [esp + 0xc]
push ecx
lea edx, [esp + 0x14]
push edx
lea ecx, [esp + 0x10]
push ecx
push 0
push str.CSDVersion
push eax
mov dword [esp + 0x24], 0x80
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov esi, eax
neg esi
sbb esi, esi
add esi, 1
je 0x40c993
mov eax, dword [esp + 8]
cmp eax, 1
jne 0x40c93e
lea edx, [esp + 0x10]
push edx
call fcn.0040b460
cmp dword [esp + 0xa4], 0
lea ecx, [esp + 0x14]
push ecx
push 0x80
je 0x40c91d
mov word [edi + 0x94], ax
xor eax, eax
mov word [edi + 0x96], ax
add edi, 0x14
push edi
call fcn.00506e6b
add esp, 0x10
jmp 0x40c993
mov word [edi + 0x12c], ax
xor eax, eax
mov word [edi + 0x12e], ax
add edi, 0xac
push edi
call fcn.00506e6b
add esp, 0x10
jmp 0x40c993
cmp eax, 4
jne 0x40c993
mov edx, dword [esp + 0x10]
xor ecx, ecx
shr edx, 8
push 0x530041
push 0x80
movzx ax, dl
cmp dword [esp + 0xa8], ecx
je 0x40c976
mov word [edi + 0x94], ax
mov word [edi + 0x96], cx
add edi, 0x14
jmp 0x40c98a
mov word [edi + 0x12c], ax
mov word [edi + 0x12e], cx
add edi, 0xac
push edi
call fcn.00506e6b
add esp, 0xc
mov ecx, dword [esp + 0x90]
pop edi
mov eax, esi
pop esi
xor ecx, esp
call fcn.0050534a
add esp, 0x8c
ret

Function at 0x40d0b0
Capabilities:
Read .ini file

Disassembly:
mov eax, dword [esp + 4]
push ebp
mov ebp, ecx
test eax, eax
jne 0x40d132
push ebx
push esi
push edi
push 0x201
mov esi, 0x200
call fcn.00412be7
add esp, 4
mov edi, eax
mov eax, dword [ebp + 4]
push eax
push esi
push edi
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileSectionNamesA]
mov ebx, eax
lea ecx, [ebx + 2]
cmp ecx, esi
jb 0x40d11f
jmp 0x40d0f0
push edi
add esi, 0x200
call fcn.00412bf2
lea edx, [esi + 1]
push edx
call fcn.00412be7
add esp, 8
mov edi, eax
mov eax, dword [ebp + 4]
push eax
push esi
push edi
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileSectionNamesA]
mov ebx, eax
lea ecx, [ebx + 2]
cmp ecx, esi
jae 0x40d0f0
push edi
call fcn.00412bf2
add esp, 4
pop edi
pop esi
lea eax, [ebx + 2]
pop ebx
pop ebp
ret 8
mov edx, dword [ebp + 4]
mov ecx, dword [esp + 0xc]
push edx
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileSectionNamesA]
pop ebp
ret 8
Function at 0x40d150
Capabilities:
Read .ini file

Disassembly:
push ecx
cmp dword [esp + 8], 0
push ebx
push ebp
push esi
mov ebx, ecx
push edi
mov dword [esp + 0x10], ebx
je 0x40d1fd
mov ebp, dword [esp + 0x1c]
test ebp, ebp
je 0x40d1fd
push 0x201
mov esi, 0x200
call fcn.00412be7
mov edi, eax
mov eax, dword [esp + 0x24]
add esp, 4
test eax, eax
jne 0x40d193
mov eax, 0x530041
mov ecx, dword [ebx + 4]
mov edx, dword [esp + 0x18]
mov ebx, dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
push ecx
push 0x200
push edi
push eax
push ebp
push edx
call ebx
inc eax
cmp eax, 0x200
jb 0x40d1f3
push edi
add esi, 0x200
call fcn.00412bf2
lea eax, [esi + 1]
push eax
call fcn.00412be7
mov edi, eax
mov eax, dword [esp + 0x28]
add esp, 8
test eax, eax
jne 0x40d1db
mov eax, 0x530041
mov ecx, dword [esp + 0x10]
mov edx, dword [ecx + 4]
push edx
push esi
push edi
push eax
mov eax, dword [esp + 0x28]
push ebp
push eax
call ebx
inc eax
cmp eax, esi
jae 0x40d1b4
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
pop ecx
ret 0xc
mov edi, dword [esp + 0x20]
test edi, edi
jne 0x40d21a
push 1
call fcn.00412be7
add esp, 4
pop edi
pop esi
pop ebp
mov byte [eax], 0
pop ebx
pop ecx
ret 0xc
mov eax, edi
lea edx, [eax + 1]
nop
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x40d220
sub eax, edx
inc eax
push eax
call fcn.00412be7
mov esi, eax
add esp, 4
mov ecx, edi
sub esi, edi
lea esp, [esp]
mov dl, byte [ecx]
mov byte [esi + ecx], dl
inc ecx
test dl, dl
jne 0x40d240
pop edi
pop esi
pop ebp
pop ebx
pop ecx
ret 0xc

Function at 0x40d480
Capabilities:
Set registry value

Disassembly:
mov ecx, dword [esp + 8]
mov edx, dword [esp + 4]
lea eax, [esp + 4]
push eax
push 0xf003f
push 0
push ecx
push edx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x40d4c8
mov eax, dword [esp + 0x10]
mov ecx, dword [eax - 0xc]
mov edx, dword [esp + 0xc]
push ecx
push eax
mov eax, dword [esp + 0xc]
push 1
push 0
push edx
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov ecx, dword [esp + 4]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, dword [esp + 8]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40d4e8
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0xc]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40d508
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x10]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40d528
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
ret 0x10
Function at 0x40d530
Capabilities:
Delete registry value

Disassembly:
mov ecx, dword [esp + 8]
mov edx, dword [esp + 4]
lea eax, [esp + 4]
push eax
push 0xf003f
push 0
push ecx
push edx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x40d56b
mov eax, dword [esp + 0xc]
mov ecx, dword [esp + 4]
push eax
push ecx
call dword [sym.imp.ADVAPI32.dll_RegDeleteValueA]
mov edx, dword [esp + 4]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, dword [esp + 8]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40d58b
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0xc]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40d5ab
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
ret 0xc
Function at 0x40d5b0
Capabilities:
Query or enumerate registry key

Disassembly:
push 0xffffffffffffffff
push 0x520ce3
mov eax, dword fs:[0]
push eax
sub esp, 0x110
mov eax, dword [0x576fe4]
xor eax, esp
mov dword [esp + 0x10c], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x576fe4]
xor eax, esp
push eax
lea eax, [esp + 0x124]
mov dword fs:[0], eax
mov ebx, dword [esp + 0x138]
xor edi, edi
push 0xfe
lea eax, [esp + 0x25]
push edi
push eax
mov dword [esp + 0x138], edi
mov byte [esp + 0x2c], 0
call fcn.00505810
add esp, 0xc
push 0x530041
lea ecx, [esp + 0x18]
mov dword [esp + 0x1c], 0xff
call fcn.00403850
mov edx, dword [esp + 0x134]
lea ecx, [esp + 0x1c]
push ecx
push 0xf003f
push edi
push edx
push reloc.OLEAUT32.dll_SysReAllocString
mov byte [esp + 0x140], 1
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
cmp eax, edi
jne 0x40d727
mov ebp, dword [sym.imp.ADVAPI32.dll_RegEnumKeyExA]
mov edx, dword [esp + 0x1c]
push 0
push 0
push 0
push 0
lea eax, [esp + 0x28]
push eax
lea ecx, [esp + 0x34]
push ecx
push edi
push edx
call ebp
mov esi, eax
mov dword [esp + 0x18], 0xff
test esi, esi
jne 0x40d6b6
lea eax, [esp + 0x20]
push eax
lea ecx, [esp + 0x18]
push 0x52fde0
push ecx
call fcn.00402f20
mov edx, dword [esp + 0x20]
add esp, 0xc
cmp dword [edx - 0xc], 0xa
jle 0x40d6b6
mov eax, dword [ebx + 8]
lea ecx, [esp + 0x14]
push ecx
push eax
mov ecx, ebx
call fcn.00413ee6
inc edi
cmp esi, 0x103
jne 0x40d65d
mov edx, dword [esp + 0x1c]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
mov byte [esp + 0x12c], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40d6f2
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x134]
add eax, 0xfffffff0
mov dword [esp + 0x12c], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40d720
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, 1
jmp 0x40d77f
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
mov byte [esp + 0x12c], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40d74f
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x134]
add eax, 0xfffffff0
mov dword [esp + 0x12c], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40d77d
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
xor eax, eax
mov ecx, dword [esp + 0x124]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x10c]
xor ecx, esp
call fcn.0050534a
add esp, 0x11c
ret 8
Function at 0x40d7b0
Capabilities:
Query or enumerate registry value

Disassembly:
push 0xffffffffffffffff
push 0x520d49
mov eax, dword fs:[0]
push eax
sub esp, 0x18
mov eax, dword [0x576fe4]
xor eax, esp
mov dword [esp + 0x14], eax
push ebp
push esi
push edi
mov eax, dword [0x576fe4]
xor eax, esp
push eax
lea eax, [esp + 0x28]
mov dword fs:[0], eax
mov ebp, dword [esp + 0x38]
mov esi, dword [esp + 0x3c]
mov dword [esp + 0x20], ebp
mov dword [esp + 0x1c], 0
push 0x530041
mov ecx, ebp
mov dword [esp + 0x34], 2
call fcn.00403850
mov ecx, dword [esp + 0x40]
lea eax, [esp + 0x14]
push eax
push 0xf003f
push 0
push ecx
push esi
mov dword [esp + 0x30], 1
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x40d8c5
mov ecx, dword [esp + 0x44]
mov edi, dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
lea edx, [esp + 0x10]
push edx
mov edx, dword [esp + 0x18]
push eax
lea eax, [esp + 0x20]
push eax
push 0
push ecx
push edx
mov dword [esp + 0x30], 1
call edi
test eax, eax
jne 0x40d8ba
mov eax, dword [esp + 0x10]
test eax, eax
je 0x40d8ba
inc eax
push eax
call fcn.00412be7
mov esi, eax
add esp, 4
test esi, esi
je 0x40d8ba
mov eax, dword [esp + 0x10]
inc eax
push eax
push 0
push esi
call fcn.00505810
mov eax, dword [esp + 0x50]
add esp, 0xc
lea ecx, [esp + 0x10]
push ecx
mov ecx, dword [esp + 0x18]
push esi
lea edx, [esp + 0x20]
push edx
push 0
push eax
push ecx
call edi
test eax, eax
jne 0x40d8b1
push esi
push 0x52fde0
push ebp
call fcn.00402f20
add esp, 0xc
push esi
call fcn.00412bf2
add esp, 4
mov edx, dword [esp + 0x14]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, dword [esp + 0x40]
add eax, 0xfffffff0
mov byte [esp + 0x30], 1
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40d8ea
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x44]
add eax, 0xfffffff0
mov byte [esp + 0x30], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40d90f
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, ebp
mov ecx, dword [esp + 0x28]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
mov ecx, dword [esp + 0x14]
xor ecx, esp
call fcn.0050534a
add esp, 0x24
ret 0x10

Function at 0x40d9c0
Capabilities:
Set registry value

Disassembly:
cmp dword [esp + 0xc], 0
push 4
jne 0x40d9ed
mov edx, dword [esp + 8]
lea eax, [esp + 0xc]
push eax
mov eax, dword [ecx + 4]
push 4
push 0
push edx
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
jne 0x40da01
mov eax, 1
ret 0xc
mov eax, dword [esp + 8]
mov ecx, dword [ecx + 4]
lea edx, [esp + 0xc]
push edx
push 3
push 0
push eax
push ecx
jmp 0x40d9db
xor eax, eax
ret 0xc
Function at 0x40da30
Capabilities:
Delete registry key
Query or enumerate registry key

Disassembly:
sub esp, 0x114
mov eax, dword [0x576fe4]
xor eax, esp
mov dword [esp + 0x110], eax
push ebp
push esi
mov esi, dword [esp + 0x120]
push edi
mov edi, dword [esp + 0x128]
mov ebp, ecx
mov dword [esp + 0x14], esi
test edi, edi
je 0x40db0b
push edi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
test eax, eax
je 0x40db0b
lea eax, [esp + 0xc]
push eax
push 0x10008
push 0
push edi
push esi
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x40db10
push ebx
mov ebx, dword [sym.imp.ADVAPI32.dll_RegEnumKeyExA]
mov eax, dword [esp + 0x10]
push 0
push 0
push 0
push 0
lea ecx, [esp + 0x24]
push ecx
lea edx, [esp + 0x30]
push edx
push 0
push eax
mov dword [esp + 0x34], 0x104
call ebx
mov esi, eax
cmp esi, 0x103
je 0x40daed
test esi, esi
jne 0x40dafb
mov edx, dword [esp + 0x10]
lea ecx, [esp + 0x1c]
push ecx
push edx
mov ecx, ebp
call fcn.0040da30
mov esi, eax
test esi, esi
je 0x40da95
mov ecx, dword [esp + 0x10]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, esi
pop ebx
jmp 0x40db10
mov eax, dword [esp + 0x18]
push edi
push eax
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
mov esi, eax
mov ecx, dword [esp + 0x10]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, esi
pop ebx
jmp 0x40db10
mov eax, 0x3f2
mov ecx, dword [esp + 0x11c]
pop edi
pop esi
pop ebp
xor ecx, esp
call fcn.0050534a
add esp, 0x114
ret 8

Function at 0x40db30
Capabilities:
Set registry value

Disassembly:
push esi
push edi
mov edi, dword [esp + 0x10]
push edi
mov esi, ecx
call fcn.00507b06
mov ecx, dword [esi + 4]
add esp, 4
push eax
mov eax, dword [esp + 0x10]
push edi
push 1
push 0
push eax
push ecx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
neg eax
sbb eax, eax
pop edi
inc eax
pop esi
ret 8
Function at 0x40e920
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
mov ecx, dword [esp + 8]
test ecx, ecx
jne 0x40e92b
xor eax, eax
ret
mov edx, dword [esp + 0xc]
mov eax, dword [esp + 4]
push esi
not eax
cmp edx, 8
jb 0x40ea09
mov esi, edx
shr esi, 3
push edi
movzx edi, byte [ecx]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x532ce0]
movzx edi, byte [ecx + 1]
xor edi, eax
and edi, 0xff
inc ecx
shr eax, 8
xor eax, dword [edi*4 + 0x532ce0]
movzx edi, byte [ecx + 1]
xor edi, eax
and edi, 0xff
inc ecx
shr eax, 8
xor eax, dword [edi*4 + 0x532ce0]
movzx edi, byte [ecx + 1]
xor edi, eax
inc ecx
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x532ce0]
movzx edi, byte [ecx + 1]
xor edi, eax
inc ecx
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x532ce0]
movzx edi, byte [ecx + 1]
xor edi, eax
inc ecx
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x532ce0]
movzx edi, byte [ecx + 1]
inc ecx
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x532ce0]
movzx edi, byte [ecx + 1]
inc ecx
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x532ce0]
inc ecx
sub edx, 8
sub esi, 1
jne 0x40e945
pop edi
test edx, edx
je 0x40ea2b
lea ecx, [ecx]
movzx esi, byte [ecx]
xor esi, eax
and esi, 0xff
shr eax, 8
xor eax, dword [esi*4 + 0x532ce0]
inc ecx
sub edx, 1
jne 0x40ea10
not eax
pop esi
ret

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

Disassembly:
mov edx, dword [esp + 4]
mov eax, dword [edx]
movsx ecx, byte [esp + 8]
xor ecx, eax
shr eax, 8
and ecx, 0xff
mov ecx, dword [ecx*4 + 0x532ce0]
xor ecx, eax
movzx eax, cl
add eax, dword [edx + 4]
mov dword [edx], ecx
mov ecx, dword [edx + 8]
imul eax, eax, 0x8088405
inc eax
mov dword [edx + 4], eax
shr eax, 0x18
xor eax, ecx
and eax, 0xff
shr ecx, 8
xor ecx, dword [eax*4 + 0x532ce0]
mov dword [edx + 8], ecx
ret

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

Disassembly:
push ebx
push esi
mov esi, dword [esp + 0xc]
mov ecx, dword [esi + 8]
mov eax, ecx
and eax, 0xfffd
or eax, 2
mov edx, eax
xor edx, 1
imul edx, eax
mov al, byte [esp + 0x10]
shr edx, 8
xor al, dl
mov edx, dword [esi]
push edi
movsx edi, al
xor edi, edx
shr edx, 8
and edi, 0xff
mov ebx, dword [edi*4 + 0x532ce0]
xor ebx, edx
movzx edx, bl
add edx, dword [esi + 4]
mov dword [esi], ebx
imul edx, edx, 0x8088405
inc edx
mov dword [esi + 4], edx
shr edx, 0x18
xor edx, ecx
and edx, 0xff
shr ecx, 8
xor ecx, dword [edx*4 + 0x532ce0]
pop edi
mov dword [esi + 8], ecx
pop esi
pop ebx
ret
Function at 0x40ef00
Capabilities:
Read file on windows

Disassembly:
push ebx
mov ebx, dword [esp + 0xc]
push esi
push edi
mov edi, dword [esp + 0x1c]
mov esi, ebx
imul esi, dword [esp + 0x18]
cmp byte [edi], 0
je 0x40ef42
mov ecx, dword [esp + 0x10]
mov edx, dword [edi + 4]
push 0
lea eax, [esp + 0x18]
push eax
push esi
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x40ef36
mov byte [edi + 8], 1
mov eax, dword [esp + 0x14]
pop edi
xor edx, edx
pop esi
div ebx
pop ebx
ret
mov ecx, dword [edi + 0x1c]
mov eax, dword [edi + 0x18]
lea edx, [ecx + esi]
cmp edx, eax
jbe 0x40ef53
sub eax, ecx
mov esi, eax
mov eax, dword [edi + 0x14]
add eax, ecx
mov ecx, dword [esp + 0x10]
push esi
push eax
push ecx
call fcn.00505890
add dword [edi + 0x1c], esi
add esp, 0xc
pop edi
mov eax, esi
xor edx, edx
pop esi
div ebx
pop ebx
ret

Function at 0x40ffd0
Capabilities:
Check if file exists
Create directory
Get file attributes

Disassembly:
sub esp, 0x20c
mov eax, dword [0x576fe4]
xor eax, esp
mov dword [esp + 0x208], eax
push ebp
mov ebp, dword [esp + 0x218]
push edi
mov edi, dword [esp + 0x218]
test edi, edi
je 0x41000d
push edi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x41000d
push 0
push edi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
mov al, byte [ebp]
test al, al
je 0x4100c6
push esi
mov esi, ebp
mov ecx, ebp
lea ecx, [ecx]
cmp al, 0x2f
je 0x410028
cmp al, 0x5c
jne 0x41002a
mov esi, ecx
mov al, byte [ecx + 1]
inc ecx
test al, al
jne 0x410020
cmp esi, ebp
je 0x410060
sub esi, ebp
push esi
lea eax, [esp + 0x114]
push ebp
push eax
call fcn.00505890
lea ecx, [esp + 0x11c]
push ecx
push edi
mov byte [esp + esi + 0x124], 0
call fcn.0040ffd0
add esp, 0x14
mov byte [esp + 0xc], 0
test edi, edi
je 0x41007b
lea edx, [esp + 0xc]
mov eax, edi
sub edx, edi
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x410071
mov eax, ebp
mov edx, ebp
nop
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x410080
lea edi, [esp + 0xc]
sub eax, edx
dec edi
mov edi, edi
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x410090
mov ecx, eax
shr ecx, 2
mov esi, edx
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
lea edx, [esp + 0xc]
and ecx, 3
push edx
rep movsb byte es:[edi], byte [esi]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
pop esi
cmp eax, 0xffffffff
jne 0x4100c6
push 0
lea eax, [esp + 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
mov ecx, dword [esp + 0x210]
pop edi
pop ebp
xor ecx, esp
call fcn.0050534a
add esp, 0x20c
ret
Function at 0x411810
Capabilities:
Resolve function by parsing pe exports

Disassembly:
sub esp, 8
push ebx
push edi
mov edi, dword [esp + 0x14]
xor ebx, ebx
cmp edi, ebx
jne 0x41182a
pop edi
mov eax, 0xffffff9a
pop ebx
add esp, 8
ret
cmp dword [edi + 0x18], ebx
je 0x41181f
cmp dword [edi + 0x7c], ebx
je 0x41183d
push edi
call fcn.0040f920
add esp, 4
lea eax, [esp + 8]
push eax
lea ecx, [esp + 0x18]
push ecx
lea edx, [esp + 0x14]
push edx
push edi
call fcn.0040f730
add esp, 0x10
test eax, eax
je 0x411864
pop edi
mov eax, 0xffffff99
pop ebx
add esp, 8
ret
push esi
push 0x84
call fcn.0050703b
mov esi, eax
add esp, 4
cmp esi, ebx
je 0x4118a5
push 0x4000
call fcn.0050703b
mov ecx, dword [esp + 0x1c]
mov edx, dword [esp + 0x10]
add esp, 4
mov dword [esi], eax
mov dword [esi + 0x44], ecx
mov dword [esi + 0x48], edx
mov dword [esi + 0x4c], ebx
cmp eax, ebx
jne 0x4118b1
push esi
call fcn.00506ed3
add esp, 4
pop esi
pop edi
mov eax, 0xffffff98
pop ebx
add esp, 8
ret
mov dword [esi + 0x40], ebx
mov ecx, dword [edi + 0x3c]
xor eax, eax
cmp dword [edi + 0x34], ebx
mov dword [esi + 0x54], ecx
mov dword [esi + 0x50], ebx
mov edx, dword [edi + 0x34]
sete al
mov dword [esi + 0x64], edx
mov ecx, dword [edi]
mov dword [esi + 0x60], ecx
mov edx, dword [edi + 0xc]
mov dword [esi + 0x68], edx
mov dword [esi + 0x18], ebx
cmp eax, ebx
jne 0x4118fd
lea eax, [esi + 4]
push eax
mov dword [esi + 0x24], ebx
mov dword [esi + 0x28], ebx
mov dword [esi + 0x2c], ebx
call fcn.0040ed00
add esp, 4
test eax, eax
jne 0x4118fd
mov dword [esi + 0x40], 1
mov ecx, dword [edi + 0x40]
mov dword [esi + 0x58], ecx
mov edx, dword [edi + 0x44]
mov dword [esi + 0x5c], edx
mov al, byte [edi + 0x30]
and al, 1
mov byte [esi + 0x6c], al
mov ecx, dword [edi + 0x30]
shr ecx, 3
test cl, 1
je 0x411927
mov dl, byte [edi + 0x39]
mov byte [esi + 0x80], dl
jmp 0x411930
mov al, byte [edi + 0x3f]
mov byte [esi + 0x80], al
movzx ecx, byte [esi + 0x6c]
neg ecx
sbb ecx, ecx
push ebp
mov ebp, dword [esp + 0x20]
and ecx, 0xc
lea ebx, [esi + 0x70]
mov dword [esi + 0x7c], ecx
mov dword [ebx], 0x12345678
mov dword [esi + 0x74], 0x23456789
mov dword [esi + 0x78], 0x34567890
test ebp, ebp
je 0x411977
mov edi, edi
movzx eax, byte [ebp]
test al, al
je 0x411977
push eax
push ebx
call fcn.0040ea30
add esp, 8
add ebp, 1
jne 0x411960
mov edx, dword [edi + 0x78]
mov eax, dword [esp + 0x14]
lea ecx, [edx + eax + 0x1e]
pop ebp
mov dword [esi + 0x3c], ecx
mov dword [esi + 8], 0
mov dword [edi + 0x7c], esi
pop esi
pop edi
xor eax, eax
pop ebx
add esp, 8
ret
Function at 0x411c20
Capabilities:
Get common file path

Disassembly:
push ebx
mov ebx, ecx
cmp dword [ebx], 0
jne 0x411ced
cmp dword [ebx + 4], 0xffffffff
jne 0x411ced
push edi
lea edi, [ebx + 0x140]
push edi
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
mov eax, edi
lea edx, [eax + 1]
mov edi, edi
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x411c50
sub eax, edx
mov al, byte [eax + ebx + 0x13f]
cmp al, 0x5c
je 0x411c81
cmp al, 0x2f
je 0x411c81
dec edi
lea esp, [esp]
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x411c70
mov ax, word [0x52ff5c]
mov word [edi], ax
mov edi, dword [esp + 0x14]
push esi
mov esi, dword [esp + 0x10]
cmp edi, 1
jne 0x411cac
push 1
push 0
push 0
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp eax, 0xffffffff
jne 0x411cac
pop esi
pop edi
mov eax, 0x2000000
pop ebx
ret 0xc
mov edx, dword [esp + 0x14]
lea ecx, [esp + 0x18]
push ecx
push edi
push edx
push esi
call fcn.0040edb0
add esp, 0x10
test eax, eax
jne 0x411cce
mov eax, dword [esp + 0x18]
pop esi
pop edi
pop ebx
ret 0xc
push eax
call fcn.00411620
add esp, 4
mov dword [ebx], eax
neg eax
sbb eax, eax
pop esi
and eax, 0xfffffe00
pop edi
add eax, 0x200
pop ebx
ret 0xc
mov eax, 0x1000000
pop ebx
ret 0xc
Function at 0x412650
Capabilities:
Check os version

Disassembly:
push esi
push 0x9c
push 0
push 0x5795f0
mov dword [0x57968c], 0
call fcn.00505810
mov esi, dword [sym.imp.KERNEL32.dll_GetVersionExA]
add esp, 0xc
push 0x5795f0
mov dword [0x5795f0], 0x94
call esi
test eax, eax
je 0x4126cb
cmp dword [0x579600], 2
mov dword [0x5795ec], 1
jne 0x4126cb
cmp dword [0x5795f4], 5
jb 0x4126cb
push 0x9c
push 0
push 0x5795f0
call fcn.00505810
add esp, 0xc
push 0x5795f0
mov dword [0x5795f0], 0x9c
call esi
pop esi
ret

Function at 0x42107b
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ebx
push esi
push edi
xor ebx, ebx
xor edi, edi
mov dword [ebp - 4], ecx
cmp dword [ebp + 8], ebx
je 0x4210c2
call fcn.0041825b
mov esi, dword [eax + 0xc]
push pe_nt_image_headers32
push dword [ebp + 8]
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
test eax, eax
je 0x4210c2
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov ebx, eax
test ebx, ebx
je 0x4210de
push ebx
call dword [sym.imp.KERNEL32.dll_LockResource]
mov edi, eax
mov ecx, dword [ebp - 4]
push edi
call fcn.00420bf5
mov esi, eax
test edi, edi
je 0x4210dc
test ebx, ebx
je 0x4210dc
push ebx
call dword [sym.imp.KERNEL32.dll_FreeResource]
mov eax, esi
pop edi
pop esi
pop ebx
leave
ret 4

Function at 0x4214ad
Capabilities:
Get graphical window text

Disassembly:
push 4
mov eax, 0x52b914
call fcn.00507d45
mov esi, ecx
cmp dword [esi + 0x50], 0
jne 0x4214d2
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [esi + 0x20]
call dword [sym.imp.USER32.dll_GetWindowTextA]
jmp 0x421518
lea ecx, [ebp - 0x10]
call fcn.00402040
mov ecx, dword [esi + 0x50]
mov eax, dword [ecx]
and dword [ebp - 4], 0
lea edx, [ebp - 0x10]
push edx
call dword [eax + 0x8c]
push 0xffffffffffffffff
push dword [ebp - 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.00416a39
add esp, 0x10
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov ecx, dword [ebp - 0x10]
add ecx, 0xfffffff0
mov esi, eax
call fcn.00401710
mov eax, esi
call fcn.00507e1d
ret 8