joyce8/EMBER2024-capa huggingface dataset:
Function at 0x5000472c
Capabilities:
Accept command line arguments

Disassembly:
push ebx
push esi
push edi
add esp, 0xfffffdf4
mov ebx, edx
mov esi, eax
mov eax, ebx
xor edx, edx
call sym.rtl120.bpl__System__UStrAsg_qqrr20System_UnicodeStringx20System_UnicodeString
test esi, esi
jne 0x50004764
push 0x105
lea eax, [esp + 4]
push eax
push 0
call sub.kernel32.dll_GetModuleFileNameW
mov ecx, eax
mov edx, esp
mov eax, ebx
call sym.rtl120.bpl__System__UStrFromPWCharLen_qqrr20System_UnicodeStringpbi
jmp 0x50004782
call sub.kernel32.dll_GetCommandLineW
mov edi, eax
mov edx, ebx
mov eax, edi
call fcn.50004610
mov edi, eax
test esi, esi
je 0x50004782
cmp dword [ebx], 0
je 0x50004782
dec esi
jmp 0x5000476b
add esp, 0x20c
pop edi
pop esi
pop ebx
ret

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

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

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

Disassembly:
push ebx
xor ebx, ebx
imul edx, dword [ebx + sym.rtl120.bpl__System_RandSeed], 0x8088405
inc edx
mov dword [ebx + sym.rtl120.bpl__System_RandSeed], edx
fld qword [ebx + 0x5009c7d8]
push 0
push edx
fild qword [esp]
add esp, 8
fmulp st(1)
pop ebx
ret

Function at 0x50005754
Capabilities:
Get file size
Read file on windows

Disassembly:
push ebx
push esi
push edi
push ebp
push ecx
mov ebp, edx
mov edi, eax
test ebp, ebp
je 0x500057c2
xor ebx, ebx
sar ecx, 1
jns 0x5000576a
adc ecx, 0
mov dword [esp], ecx
cmp ebx, dword [esp]
jge 0x500057bb
mov edx, dword [esi + 0x57]
push ebx
push ebp
sub esp, 0x20
mov edi, 0x5009eaf7
xor edx, edx
mov ecx, dword [edi + 0x10]
call fcn.50005acf
mov dword [esp], eax
xor ecx, ecx
lea edx, [esp + 0x14]
mov dword [edx], 0
call fcn.50005acf
mov eax, dword [edi + 0x38]
push eax
push 0x40
call dword [sym.imp.kernel32.dll_LocalAlloc]
mov ebx, eax
mov ecx, ebx
mov edx, dword [edi + 0x38]
call fcn.50005c4b
mov esi, dword [esp + 0x14]
movzx eax, word [esi]
push es
test eax, eax
je 0x500057d3
xor ebp, ebp

Function at 0x50005773
Capabilities:
Get file size
Read file on windows

Disassembly:
push ebx
push esi
push edi
push ebp
push ecx
mov ebp, edx
mov edi, eax
test ebp, ebp
je 0x500057c2
xor ebx, ebx
sar ecx, 1
jns 0x5000576a
adc ecx, 0
mov dword [esp], ecx
cmp ebx, dword [esp]
jge 0x500057bb
mov edx, dword [esi + 0x57]
push ebx
push ebp
sub esp, 0x20
mov edi, 0x5009eaf7
xor edx, edx
mov ecx, dword [edi + 0x10]
call fcn.50005acf
mov dword [esp], eax
xor ecx, ecx
lea edx, [esp + 0x14]
mov dword [edx], 0
call fcn.50005acf
mov eax, dword [edi + 0x38]
push eax
push 0x40
call dword [sym.imp.kernel32.dll_LocalAlloc]
mov ebx, eax
mov ecx, ebx
mov edx, dword [edi + 0x38]
call fcn.50005c4b
mov esi, dword [esp + 0x14]
movzx eax, word [esi]
push es
test eax, eax
je 0x500057d3
xor ebp, ebp
Function at 0x500057c8
Capabilities:
Get file size
Read file on windows

Disassembly:
movzx eax, word [esi + ebp*2]
mov word [ebx + ebp*2], ax
add al, 0x6b
add al, 0x6b
inc ebp
movzx edx, word [esi + ebp*2]
test edx, edx
jne 0x500057c2
movzx ebp, word [ebx]
xor eax, eax
mov edx, dword [edi + 8]
test ebp, ebp
je 0x500057ec
inc eax
lea esi, [ebx + eax*2]
movzx ebp, word [esi]
test ebp, ebp
jne 0x500057df
jmp 0x500057ee
mov esi, ebx
movzx ebp, word [esi - 2]
cmp ebp, 0x5c
je 0x50005808
xor ebp, ebp
mov word [ebx + eax*2], bp
dec eax
movzx esi, word [ebx + eax*2 - 2]
cmp esi, 0x5c
jne 0x500057f7
cmp byte [edx], 0
je 0x50005821
xor ebp, ebp
movsx esi, byte [ebp + edx]
inc ebp
mov word [ebx + eax*2], si
inc eax
cmp byte [ebp + edx], 0
jne 0x5000580f
xor eax, eax
xor edx, edx
inc edx
push eax
push 0x80
push 3
push eax
push edx
push edx
push ebx
call dword [sym.imp.kernel32.dll_CreateFileW]
mov esi, eax
cmp esi, 0xffffffff
je 0x50005993
push 0
push esi
call dword [sym.imp.kernel32.dll_GetFileSize]
mov ebp, eax
push 4
push 0x1000
mov eax, dword [edi + 0x20]
push eax
push 0
call dword [sym.imp.kernel32.dll_VirtualAlloc]
mov ebx, eax
xor eax, eax
lea edx, [esp + 0x18]
mov dword [edx], eax
push eax
push edx
push ebp
push ebx
push esi
call dword [sym.imp.kernel32.dll_ReadFile]
test eax, eax

Function at 0x50005d18
Capabilities:
Write file on windows

Disassembly:
push ebx
mov ebx, eax
movzx eax, word [eax + 4]
sub eax, 0xd7b2
cmp eax, 1
ja 0x50005d4b
push 0
mov eax, esp
push 0
push eax
push dword [ebx + 8]
push edx
push dword [ebx]
call sub.kernel32.dll_WriteFile
pop edx
dec eax
jne 0x50005d52
cmp edx, dword [ebx + 8]
je 0x50005d5c
mov eax, 0x65
jmp 0x50005d57
mov eax, 5
jmp 0x50005d57
call sub.kernel32.dll_GetLastError
call sym.rtl120.bpl__System_SetInOutRes_qqri
mov eax, ebx
pop ebx
ret

Function at 0x500069b4
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff4
movzx eax, word [sym.rtl120.bpl__System_Default8087CW]
mov dword [ebp - 8], eax
lea eax, [ebp - 4]
push eax
push 1
push 0
push 0x50006a4c
push 0x80000002
call sub.advapi32.dll_RegOpenKeyExW
test eax, eax
jne 0x50006a2c
xor eax, eax
push ebp
push 0x50006a25
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 0x50006a84
mov eax, dword [ebp - 4]
push eax
call sub.advapi32.dll_RegQueryValueExW
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x50006a2c
mov eax, dword [ebp - 4]
push eax
call sub.advapi32.dll_RegCloseKey
ret
movzx eax, word [sym.rtl120.bpl__System_Default8087CW]
and ax, 0xffc0
movzx edx, word [ebp - 8]
and dx, 0x3f
or ax, dx
mov word [sym.rtl120.bpl__System_Default8087CW], ax
mov esp, ebp
pop ebp
ret
Function at 0x500171c8
Capabilities:
Resolve function by parsing pe exports

Disassembly:
insb byte es:[edi], dx
pop es
or dl, byte [esp + ecx*2 + 0x61]
outsb dx, byte [esi]
jne 0x50017232
jae 0x50017179
jno 0x500171d8
push eax
inc eax
adc eax, dword [eax]
push eax
add byte [eax], al
or byte [ebx + 0x79], dl
jae 0x50017238
je 0x5001724e
insb byte es:[edi], dx
jae 0x500171e8
add byte [ebp + 0x72440040], cl
add dword [eax], edx
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [edx + esi*2 + 1], cl
push eax
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
pop esi
jb 0x50017210
push eax
sbb al, 0
add byte [eax], al
loopne 0x50017228
add byte [eax - 0x58], dl
insb byte es:[edi], dx
add byte [eax - 0x50], dl
insb byte es:[edi], dx
add byte [eax + 0x64], dl
popal
cmp byte [edi], ch
push eax
cmp al, 0x6f
test byte [ebx], ch
push eax
add byte [eax], al
add byte [eax], al
add dword [eax], eax
add byte [eax], al
inc eax
adc al, byte [eax]
push eax
add al, 0
add byte [eax], al
or dword [ebp + 0x78], eax
arpl word [ebp + 0x70], sp
je 0x500172cf
outsd dx, dword [esi]
outsb dx, byte [esi]
insb byte es:[edi], dx
jb sym.rtl120.bpl___xp_18Sysutils_Exception
push eax
push eax
inc eax

Function at 0x5001726c
Capabilities:
Resolve function by parsing pe exports

Disassembly:
pop es
or dword [ebp + 0x78], eax
arpl word [ebp + 0x70], sp
je 0x500172de
outsd dx, dword [esi]
outsb dx, byte [esi]
inc esp
jb 0x5001727b
push eax
inc eax
adc eax, dword [eax]
push eax
add byte [eax], al
or byte [ebx + 0x79], dl
jae 0x500172db
je 0x500172f1
insb byte es:[edi], dx
jae 0x5001728b
add ah, ah
jb 0x50017290
push eax
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
in al, dx
jb 0x500172b0
push eax
sbb al, 0
add byte [eax], al
in al, dx
jno 0x500172b8
push eax
test al, 0x6c
add byte [eax - 0x50], dl
insb byte es:[edi], dx
add byte [eax + 0x64], dl
popal
add dl, byte [eax + 0x18]
push eax
add byte [eax + 0x68], dl

Function at 0x50017304
Capabilities:
Resolve function by parsing pe exports

Disassembly:
pop es
adc al, byte [ebp + 0x41]
jb 0x50017371
jne 0x50017379
outsb dx, byte gs:[esi]
je 0x50017355
js 0x50017375
jo 0x50017389
imul ebp, dword [edi + 0x6e], sym.rtl120.bpl__Sysutils_EArgumentException_
push 0x500172
add byte [eax], cl
push ebx
jns 0x50017399
push ebp
je 0x50017392
insb byte es:[edi], dx
jae 0x5001732c
add byte [ebp + 0x73880040], cl
add dword [eax], edx
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax + 0x1c500173], dl
add byte [eax], al
add byte [edx + esi*2 + 0x6ca85001], cl
Function at 0x500173b4
Capabilities:
Resolve function by parsing pe exports

Disassembly:
pop es
sbb al, 0x45
inc ecx
jb 0x50017421
jne 0x50017429
outsb dx, byte gs:[esi]
je 0x5001740f
jne 0x50017436
dec edi
push dx
popal
outsb dx, byte [esi]
inc ebp
js 0x5001742f
jo 0x50017443
imul ebp, dword [edi + 0x6e], sym.rtl120.bpl__Sysutils_EArgumentOutOfRangeException_
add byte [ebx + 1], dh
push eax
add byte [eax], al
or byte [ebx + 0x79], dl
jae 0x50017436
je 0x5001744c
insb byte es:[edi], dx
jae 0x500173e6
add byte [eax + sym.rtl120.bpl__Sysutils_ENoConstructException_], dl
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
push eax
xor al, 0x6f
add byte [eax - 0x60], dl
imul eax, dword [eax], 0x50
push 0xc500260
invalid
push eax
lodsb al, byte [esi]

Function at 0x50017464
Capabilities:
Resolve function by parsing pe exports

Disassembly:
pop es
adc eax, 0x436f4e45
outsd dx, dword [esi]
outsb dx, byte [esi]
jae 0x500174e2
jb 0x500174e5
arpl word [ebp + eax*2 + 0x78], si
arpl word [ebp + 0x70], sp
je 0x500174e2
outsd dx, dword [esi]
outsb dx, byte [esi]
inc eax
je 0x5001747f
push eax
push 0x500172
add byte [eax], cl
push ebx
jns sym.rtl120.bpl___xp_15Sysutils_EAbort
push ebp
add byte [eax + 0x68], dl

Function at 0x500174fc
Capabilities:
Resolve function by parsing pe exports

Disassembly:
pop es
push es
inc ebp
inc ecx
bound ebp, qword [edi + 0x72]
je 0x500174ed
je 0x50017508
push eax
push 0x500172
add byte [eax], cl
push ebx
jns 0x50017585
push ebp
je 0x5001757e
insb byte es:[edi], dx
jae 0x50017518
add byte [ebp + 0x75740040], cl
add dword [eax], edx
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [ebp + esi*2 + 1], bh
push eax
and byte [eax], al
add byte [eax], al
in al, dx
jno 0x50017548
push eax
test al, 0x6c
add byte [eax - 0x50], dl
insb byte es:[edi], dx
add byte [eax + 0x64], dl
popal
add dl, byte [eax + 0x18]
outsd dx, dword [esi]
add byte [eax + 0x38], dl
outsd dx, dword [esi]
add byte [eax + 0x3c], dl
outsd dx, dword [esi]
add byte [eax + 0x40], dl
outsd dx, dword [esi]
add byte [eax + 0x34], dl
outsd dx, dword [esi]
add byte [eax - 0x7c], dl
imul eax, dword [eax], 0x50

Function at 0x50017590
Capabilities:
Resolve function by parsing pe exports

Disassembly:
pop es
push cs
inc ebp
dec eax
popal
jo 0x500175dd
js 0x500175fd
jo 0x50017611
imul ebp, dword [edi + 0x6e], sym.rtl120.bpl__Sysutils_EHeapException_
push 0x500172
add byte [eax], cl
push ebx
jns 0x50017621
push ebp
je 0x5001761a
insb byte es:[edi], dx
jae 0x500175b4
add byte [ebp + 0x76100040], cl
add dword [eax], edx
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], bl
jbe 0x500175dc
add byte [eax], al
add byte [esi*2 + 0x6ca85001], bl
insd dword es:[edi], dx
Function at 0x500176c0
Capabilities:
Resolve function by parsing pe exports

Disassembly:
add byte [eax], al
in al, dx
jno 0x5001767c
push eax
test al, 0x6c
pop es
or eax, dword [ebp + 0x49]
outsb dx, byte [esi]
dec edi
jne sym.rtl120.bpl__Sysutils_EExternal_
inc ebp
jb 0x5001773d
outsd dx, dword [esi]
jb 0x50017676
jbe 0x500176d1
push eax
push 0x500172
add byte [eax], cl
push ebx
jns 0x5001774e
push ebp
je 0x50017747
insb byte es:[edi], dx
jae 0x500176e1
add byte [ebx + 0x1773cc0], cl
push eax
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
inc esp
ja 0x50017708
push eax
and byte [eax], al
add byte [eax], al
in al, dx
jno 0x50017710
push eax
test al, 0x6c
add byte [eax - 0x50], dl
insb byte es:[edi], dx
add byte [eax + 0x64], dl
popal
add dl, byte [eax + 0x18]
outsd dx, dword [esi]
add byte [eax + 0x38], dl
outsd dx, dword [esi]
add byte [eax + 0x3c], dl
outsd dx, dword [esi]
add byte [eax + 0x40], dl
outsd dx, dword [esi]
add byte [eax + 0x34], dl
outsd dx, dword [esi]

Function at 0x50017754
Capabilities:
Resolve function by parsing pe exports

Disassembly:
pop es
or dword [ebp + 0x45], eax
js 0x500177ce
jb 0x500177cb
popal
insb byte es:[edi], dx
cmp al, 0x77
add dword [eax + 0x68], edx
jb 0x50017767
push eax
add byte [eax], al
or byte [ebx + 0x79], dl
jae 0x500177c3
je 0x500177d9
insb byte es:[edi], dx
jae 0x50017773
add ah, cl
ja 0x50017778
push eax
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
aam 0x77
add dword [eax + 0x20], edx
add byte [eax], al
add ah, ah
jbe 0x500177a0
push eax
test al, 0x6c
add byte [eax - 0x50], dl
insb byte es:[edi], dx
add byte [eax + 0x64], dl
popal
add dl, byte [eax + 0x18]
outsd dx, dword [esi]
add byte [eax + 0x38], dl
outsd dx, dword [esi]
add byte [eax + 0x3c], dl
outsd dx, dword [esi]
add byte [eax + 0x40], dl
outsd dx, dword [esi]
push eax
push eax

Function at 0x500177ec
Capabilities:
Resolve function by parsing pe exports

Disassembly:
pop es
adc al, byte [ebp + 0x45]
js 0x50017866
jb 0x50017863
popal
insb byte es:[edi], dx
inc ebp
js 0x5001785d
jo 0x50017871
imul ebp, dword [edi + 0x6e], sym.rtl120.bpl__Sysutils_EExternalException_
push eax
ja 0x50017808
push eax
add byte [eax], al
or byte [ebx + 0x79], dl
jae 0x50017864
push eax
test byte [ebx], ch
push eax
add byte [eax - 0x60], dl
imul eax, dword [eax], 0x50
push 0xc500260
invalid
Function at 0x50019bd4
Capabilities:
Encrypt data using rc4 prga

Disassembly:
cmp eax, edx
je 0x50019c7d
test eax, edx
je 0x50019c80
push 0
push 0
cmp word [eax - 0xa], 2
je 0x50019bfd
push edx
mov edx, eax
mov eax, esp
call sym.rtl120.bpl__System__UStrFromLStr_qqrr20System_UnicodeStringx27System__AnsiStringT_us_i0__
pop edx
mov eax, dword [esp]
cmp word [edx - 0xa], 2
je 0x50019c13
push eax
lea eax, [esp + 8]
call sym.rtl120.bpl__System__UStrFromLStr_qqrr20System_UnicodeStringx27System__AnsiStringT_us_i0__
pop eax
mov edx, dword [esp + 4]
movzx ecx, word [edx]
cmp cx, word [eax]
je 0x50019c22
movzx eax, word [eax]
sub eax, ecx
jmp 0x50019c49
push ebx
mov ebx, dword [eax - 4]
xor ecx, ecx
sub ebx, dword [edx - 4]
push ebx
adc ecx, 0xffffffff
and ecx, ebx
sub ecx, dword [eax - 4]
shl ecx, 1
sub eax, ecx
sub edx, ecx
mov ebx, dword [ecx + eax]
xor ebx, dword [ecx + edx]
jne 0x50019c63
add ecx, 4
js 0x50019c3a
pop eax
pop ebx
mov ecx, esp
mov edx, dword [ecx]
or edx, dword [ecx + 4]
je 0x50019c60
push eax
mov eax, ecx
mov edx, 2
call sym.rtl120.bpl__System__LStrArrayClr_qqrpvi
pop eax
pop edx
pop edx
ret
bsf ebx, ebx
shr ebx, 4
add ebx, ebx
add ecx, ebx
jns 0x50019c47
movzx eax, word [ecx + eax]
movzx edx, word [ecx + edx]
sub eax, edx
pop ebx
pop ebx
jmp 0x50019c49
xor eax, eax
ret
test eax, eax
je 0x50019c90
test edx, edx
jne 0x50019be4
mov eax, dword [eax - 4]
ret
sub eax, dword [edx - 4]
ret

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

Disassembly:
push ebx
push esi
mov esi, eax
mov eax, esi
call sym.rtl120.bpl__System__UStrToPWChar_qqrx20System_UnicodeString
push eax
call sub.kernel32.dll_GetFileAttributesW
cmp eax, 0xffffffff
je 0x5001bd6e
test al, 0x10
sete al
pop esi
pop ebx
ret
call sub.kernel32.dll_GetLastError_1
mov ebx, eax
cmp ebx, 2
je 0x5001bd8f
cmp ebx, 3
je 0x5001bd8f
cmp ebx, 0x7b
je 0x5001bd8f
mov eax, esi
call fcn.5001bd10
test al, al
jne 0x5001bd93
xor eax, eax
jmp 0x5001bd95
mov al, 1
pop esi
pop ebx
ret

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

Disassembly:
push ebx
mov ebx, eax
mov eax, ebx
call sym.rtl120.bpl__System__UStrToPWChar_qqrx20System_UnicodeString
push eax
call sub.kernel32.dll_GetFileAttributesW
cmp eax, 0xffffffff
je 0x5001bdb1
test al, 0x10
jne 0x5001bdb5
xor eax, eax
pop ebx
ret
mov al, 1
pop ebx
ret

Function at 0x5001bfac
Capabilities:
Get file attributes

Disassembly:
push ebx
mov ebx, eax
mov eax, ebx
call sym.rtl120.bpl__System__UStrToPWChar_qqrx20System_UnicodeString
push eax
call sub.kernel32.dll_GetFileAttributesW
pop ebx
ret

Function at 0x5001bfc0
Capabilities:
Set file attributes

Disassembly:
push ebx
push esi
push edi
mov edi, edx
mov esi, eax
xor ebx, ebx
push edi
mov eax, esi
call sym.rtl120.bpl__System__UStrToPWChar_qqrx20System_UnicodeString
push eax
call sub.kernel32.dll_SetFileAttributesW
test eax, eax
jne 0x5001bfe2
call sub.kernel32.dll_GetLastError_1
mov ebx, eax
mov eax, ebx
pop edi
pop esi
pop ebx
ret
Function at 0x5001bfe8
Capabilities:
Get file attributes

Disassembly:
push ebx
mov ebx, eax
mov eax, ebx
call sym.rtl120.bpl__System__UStrToPWChar_qqrx20System_UnicodeString
push eax
call sub.kernel32.dll_GetFileAttributesW
test al, 1
setne al
pop ebx
ret

Function at 0x5001c000
Capabilities:
Check if file exists
Get file attributes
Set file attributes

Disassembly:
push ebx
push esi
push edi
push ebp
push ecx
mov byte [esp], dl
mov esi, eax
xor ebx, ebx
mov eax, esi
call sym.rtl120.bpl__System__UStrToPWChar_qqrx20System_UnicodeString
mov ebp, eax
push ebp
call sub.kernel32.dll_GetFileAttributesW
mov edi, eax
cmp edi, 0xffffffff
je 0x5001c03d
cmp byte [esp], 0
je 0x5001c02d
or edi, 1
jmp 0x5001c030
and edi, 0xfffffffe
push edi
push ebp
call sub.kernel32.dll_SetFileAttributesW
cmp eax, 1
sbb ebx, ebx
inc ebx
mov eax, ebx
pop edx
pop ebp
pop edi
pop esi
pop ebx
ret

Function at 0x5001c198
Capabilities:
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffec
push ebx
mov ebx, eax
mov byte [ebp - 1], 0
push 0
push 0x80
push 3
push 0
push 1
push 0x80000000
mov eax, ebx
call sym.rtl120.bpl__System__UStrToPWChar_qqrx20System_UnicodeString
push eax
call sub.kernel32.dll_CreateFileW_1
mov dword [ebp - 0xc], eax
push 0
push 0
push 0
push 2
push 0
mov eax, dword [ebp - 0xc]
push eax
call sub.kernel32.dll_CreateFileMappingW
mov dword [ebp - 0x10], eax
push 0
push 0
push 0
push 4
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_MapViewOfFile_1
mov dword [ebp - 8], eax
mov ebx, dword [ebp - 8]
xor eax, eax
push ebp
push 0x5001c255
push dword fs:[eax]
mov dword fs:[eax], esp
test ebx, ebx
je 0x5001c21b
lea eax, [ebp - 0x14]
push eax
push 0xe
push 0
mov eax, dword [ebp - 8]
push eax
call sub.IMAGEHLP.DLL_ImageDirectoryEntryToData
test eax, eax
jne 0x5001c222
call sym.rtl120.bpl__System__TryFinallyExit_qqrv
jmp 0x5001c25c
mov byte [ebp - 1], 1
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x5001c25c
cmp dword [ebp - 0xc], 0
je 0x5001c254
mov eax, dword [ebp - 8]
push eax
call sub.kernel32.dll_UnmapViewOfFile_1
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_CloseHandle_1
mov eax, dword [ebp - 0xc]
push eax
call sub.kernel32.dll_CloseHandle_1
ret
movzx eax, byte [ebp - 1]
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x500250cc
Capabilities:
Get geographical location

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffe00
push ebx
push esi
mov esi, ecx
mov ebx, dword [ebp + 8]
push pe_nt_image_headers32
lea ecx, [ebp - 0x200]
push ecx
push edx
push eax
call sub.kernel32.dll_GetLocaleInfoW_1
test eax, eax
jle 0x50025105
mov ecx, eax
dec ecx
lea edx, [ebp - 0x200]
mov eax, ebx
call sym.rtl120.bpl__System__UStrFromPWCharLen_qqrr20System_UnicodeStringpbi
jmp 0x5002510e
mov eax, ebx
mov edx, esi
call sym.rtl120.bpl__System__UStrAsg_qqrr20System_UnicodeStringx20System_UnicodeString
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4

Function at 0x50025118
Capabilities:
Get geographical location

Disassembly:
push ebx
push esi
push edi
push ecx
mov edi, ecx
mov esi, edx
mov ebx, eax
push 2
lea eax, [esp + 4]
push eax
push esi
push ebx
call sub.kernel32.dll_GetLocaleInfoW_1
test eax, eax
jle 0x5002513a
movzx eax, word [esp]
jmp 0x5002513c
mov eax, edi
pop edx
pop edi
pop esi
pop ebx
ret

Function at 0x500259ec
Capabilities:
Write file on windows

Disassembly:
add esp, 0xfffff004
push eax
add esp, 0xffffff7c
push 0x800
lea ecx, [esp + 0x88]
call sym.rtl120.bpl__Sysutils_ExceptionErrorMessage_qqrp14System_TObjectpvpbi
mov eax, dword [sym.rtl120.bpl__System_IsConsole]
cmp byte [eax], 0
je 0x50025a7e
mov eax, dword [sym.rtl120.bpl__System_Output]
call sym.rtl120.bpl__System_Flush_qqrr15System_Textfile
call sym.rtl120.bpl__System___IOTest_qqrv
lea eax, [esp + 0x884]
push eax
lea eax, [esp + 0x88]
push eax
call sub.user32.dll_CharToOemW
push 0
lea eax, [esp + 4]
push eax
lea eax, [esp + 0x88c]
call sym.rtl120.bpl__Sysutils_StrLen_qqrpxc
push eax
lea eax, [esp + 0x890]
push eax
push 0xfffffffffffffff4
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 0x50025acc
push 0xfffffffffffffff4
call sub.kernel32.dll_GetStdHandle_1
push eax
call sub.kernel32.dll_WriteFile_1
jmp 0x50025ab7
push 0x40
lea eax, [esp + 8]
push eax
mov eax, dword [sym.rtl120.bpl__Sysconst__SExceptTitle]
mov eax, dword [eax + 4]
push eax
mov eax, dword [0x500a6b30]
call sym.rtl120.bpl__System_FindResourceHInstance_qqrui
push eax
call sub.user32.dll_LoadStringW_1
push 0x2010
lea eax, [esp + 8]
push eax
lea eax, [esp + 0x8c]
push eax
push 0
call sub.user32.dll_MessageBoxW
add esp, 0x1084
ret