joyce8/EMBER2024-capa huggingface dataset:
Function at 0x40cdb0
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x56c641
mov eax, dword fs:[0]
push eax
sub esp, 0x2d4
mov eax, dword [0x5cc6c0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, ecx
cmp dword [ebx + 0x1c], 0
je 0x40cdf0
mov eax, 1
jmp 0x40cfdc
push 0x208
lea eax, [ebp - 0x218]
push 0
push eax
call fcn.0053efc0
add esp, 0xc
lea eax, [ebp - 0x218]
push 0x104
push eax
push 0x400000
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
mov edi, dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
lea eax, [ebp - 0x218]
push eax
call edi
mov esi, dword [ebp + 8]
test esi, esi
je 0x40ce41
lea eax, [ebp - 0x218]
push eax
call edi
sub esi, 1
jne 0x40ce33
push str.netul.dll
lea eax, [ebp - 0x218]
push eax
call dword [sym.imp.SHLWAPI.dll_PathAppendW]
lea eax, [ebp - 0x218]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x40cfc7
call fcn.00467400
push 1
mov ecx, dword [eax]
mov edx, dword [ecx + 8]
mov ecx, eax
call edx
movzx eax, al
sub eax, 1
jne 0x40cfc3
push 0x4c
push str.d:jenkins.jenkinsworkspacepcstorepcstoremaincommonhttptaskfactory.cpp
lea ecx, [ebp - 0x248]
mov dword [ebp - 0x238], eax
mov dword [ebp - 0x234], 0xf
mov byte [ebp - 0x248], al
call fcn.00406f00
push 3
push 0x57fd94
lea ecx, [ebp - 0x230]
mov dword [ebp - 4], 0
mov dword [ebp - 0x220], 0
mov dword [ebp - 0x21c], 0xf
mov byte [ebp - 0x230], 0
call fcn.00406f00
push 0x2f
lea eax, [ebp - 0x248]
mov byte [ebp - 4], 1
push eax
lea eax, [ebp - 0x230]
push eax
lea ecx, [ebp - 0x2e0]
call fcn.0040a870
mov esi, eax
push str.netul_not_find._search_path:
push esi
mov byte [ebp - 4], 2
call fcn.00409440
lea eax, [ebp - 0x218]
push eax
push esi
call fcn.00409440
add esp, 0x10
call fcn.00467400
push esi
mov ecx, eax
mov edx, dword [eax]
call dword [edx + 0x1c]
lea ecx, [ebp - 0x2e0]
call fcn.0040b790
mov edx, dword [ebp - 0x21c]
cmp edx, 0x10
jb 0x40cf72
mov ecx, dword [ebp - 0x230]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x40cf68
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40cffa
push edx
push ecx
call fcn.004f9d5c
add esp, 8
mov edx, dword [ebp - 0x234]
mov dword [ebp - 0x220], 0
mov dword [ebp - 0x21c], 0xf
mov byte [ebp - 0x230], 0
cmp edx, 0x10
jb 0x40cfc3
mov ecx, dword [ebp - 0x248]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x40cfb9
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40cfff
push edx
push ecx
call fcn.004f9d5c
add esp, 8
xor eax, eax
jmp 0x40cfdc
lea eax, [ebp - 0x218]
mov dword [ebx + 0x1c], 1
push eax
mov ecx, ebx
call fcn.0040ccc0
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004fa004
mov esp, ebp
pop ebp
ret 4
call fcn.00542850
call fcn.00542850
int3
Function at 0x413270
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
mov eax, dword [0x5cc6c0]
xor eax, ebp
mov dword [ebp - 4], eax
mov edx, dword [ebp + 8]
push esi
mov esi, dword [ebp + 0xc]
push edi
mov edi, dword [ebp + 0x10]
mov eax, dword [edi]
add eax, eax
mov dword [edi], 0
mov dword [ebp - 0xc], eax
lea eax, [ebp - 0xc]
push eax
push esi
lea eax, [ebp - 8]
push eax
push 0
push edx
push dword [ecx]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x4132fb
mov eax, dword [ebp - 8]
cmp eax, 1
je 0x4132bd
cmp eax, 2
jne 0x4132d9
mov ecx, dword [ebp - 0xc]
test esi, esi
je 0x4132f5
test ecx, ecx
je 0x4132f0
test cl, 1
jne 0x4132d9
mov eax, ecx
shr eax, 1
cmp word [esi + eax*2 - 2], 0
je 0x4132f5
pop edi
mov eax, 0xd
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004fa004
mov esp, ebp
pop ebp
ret 0xc
xor eax, eax
mov word [esi], ax
shr ecx, 1
xor eax, eax
mov dword [edi], ecx
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.004fa004
mov esp, ebp
pop ebp
ret 0xc
Function at 0x417790
Capabilities:
Print debug messages

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x218
mov eax, dword [0x5cc6c0]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [ebp + 8]
lea eax, [ebp - 0x214]
push 0x210
push 0
push eax
call fcn.0053efc0
add esp, 0xc
lea eax, [ebp - 0x214]
push 0x108
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
push 0
push 1
push 1
push fcn.0045d530
lea eax, [ebp - 0x218]
mov dword [ebp - 0x218], 0
push eax
push esi
lea eax, [ebp - 0x214]
push eax
call fcn.00413b60
pop esi
test eax, eax
jne 0x41781a
push str._n_Adjustprivilege:_CreateProcess_fail.__n
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
xor al, al
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004fa004
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 4]
mov al, 1
xor ecx, ebp
call fcn.004fa004
mov esp, ebp
pop ebp
ret
Function at 0x417830
Capabilities:
Compare security identifiers

Disassembly:
push ebp
mov ebp, esp
push 0xfffffffffffffffe
push 0x5b8710
push 0x53f780
mov eax, dword fs:[0]
push eax
sub esp, 0x34
mov eax, dword [0x5cc6c0]
xor dword [ebp - 8], eax
xor eax, ebp
mov dword [ebp - 0x1c], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0x10]
mov dword fs:[0], eax
mov eax, dword [ebp + 8]
mov dword [ebp - 0x40], eax
mov ecx, dword [ebp + 0xc]
mov dword [ebp - 0x44], ecx
mov dword [ebp - 0x2c], 0
xor edi, edi
mov dword [ebp - 0x38], edi
mov dword [ebp - 0x34], edi
mov dword [ebp - 4], edi
mov dword [eax], edi
mov dword [ecx], edi
lea eax, [ebp - 0x2c]
push eax
push edi
push 8
call dword [sym.imp.KERNEL32.dll_GetCurrentThread]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenThreadToken]
test eax, eax
je 0x4178aa
cmp dword [ebp - 0x2c], edi
je 0x4178aa
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x4178e2
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
cmp eax, 0x3f0
jne 0x4179c4
lea eax, [ebp - 0x2c]
push eax
push 8
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x4179c4
cmp dword [ebp - 0x2c], 0
je 0x4179c4
mov dword [ebp - 0x30], 0
lea eax, [ebp - 0x30]
push eax
push 0
push 0
push 2
push dword [ebp - 0x2c]
mov ebx, dword [sym.imp.ADVAPI32.dll_GetTokenInformation]
call ebx
test eax, eax
jne 0x4179c4
cmp dword [ebp - 0x30], eax
jbe 0x4179c4
call esi
cmp eax, 0x7a
jne 0x4179c4
push dword [ebp - 0x30]
call fcn.00547551
add esp, 4
mov edi, eax
mov dword [ebp - 0x38], edi
test edi, edi
je 0x4179c4
mov dword [ebp - 0x28], 0
lea eax, [ebp - 0x28]
push eax
push dword [ebp - 0x30]
push edi
push 2
push dword [ebp - 0x2c]
call ebx
test eax, eax
je 0x4179c4
mov eax, dword [ebp - 0x28]
cmp eax, dword [ebp - 0x30]
jne 0x4179c4
mov dword [ebp - 0x24], 0
mov word [ebp - 0x20], 0x500
lea eax, [ebp - 0x34]
push eax
push 0
push 0
push 0
push 0
push 0
push 0
push 0x220
push 0x20
push 2
lea eax, [ebp - 0x24]
push eax
call dword [sym.imp.ADVAPI32.dll_AllocateAndInitializeSid]
test eax, eax
je 0x4179c4
cmp dword [ebp - 0x34], 0
je 0x4179c4
xor esi, esi
mov dword [ebp - 0x3c], esi
cmp esi, dword [edi]
jae 0x4179c4
lea ebx, [edi + esi*8]
push dword [ebp - 0x34]
push dword [ebx + 4]
call dword [sym.imp.ADVAPI32.dll_EqualSid]
test eax, eax
jne 0x4179ad
inc esi
jmp 0x417990
mov eax, dword [ebp - 0x40]
mov dword [eax], 1
mov eax, dword [ebx + 8]
shr eax, 2
and eax, 1
mov ecx, dword [ebp - 0x44]
mov dword [ecx], eax
mov dword [ebp - 4], 0xfffffffe
call fcn.004179f1
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x1c]
xor ecx, ebp
call fcn.004fa004
mov esp, ebp
pop ebp
ret 8
Function at 0x4183d0
Capabilities:
Check if file exists
Create process on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x56d180
mov eax, dword fs:[0]
push eax
sub esp, 0x48
mov eax, dword [0x5cc6c0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, dword [ebp + 8]
mov bl, byte [ebp + 0x14]
push edi
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x418413
xor al, al
jmp 0x4185a0
push edi
lea ecx, [ebp - 0x54]
mov dword [ebp - 0x54], 0
call fcn.0040a2d0
mov eax, dword [ebp - 0x54]
mov esi, 1
mov edx, esi
mov dword [ebp - 4], 0
mov ecx, dword [eax - 8]
sub edx, dword [eax - 4]
sub ecx, 0x104
or ecx, edx
jge 0x418454
push 0x104
lea ecx, [ebp - 0x54]
call fcn.004066c0
mov eax, dword [ebp - 0x54]
push eax
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
mov eax, dword [ebp - 0x54]
test eax, eax
jne 0x418466
xor ecx, ecx
jmp 0x41847f
push dword [eax - 8]
push eax
call fcn.00547144
mov ecx, eax
add esp, 8
test ecx, ecx
js 0x4185bc
mov eax, dword [ebp - 0x54]
cmp ecx, dword [eax - 8]
jg 0x4185bc
mov dword [eax - 0xc], ecx
xor edx, edx
mov eax, dword [ebp - 0x54]
push edi
mov word [eax + ecx*2], dx
lea ecx, [ebp - 0x50]
mov dword [ebp - 0x50], edx
call fcn.0040a2d0
push dword [ebp - 0x50]
xorps xmm0, xmm0
mov byte [ebp - 4], 1
movlpd qword [ebp - 0x48], xmm0
movlpd qword [ebp - 0x40], xmm0
movlpd qword [ebp - 0x38], xmm0
movlpd qword [ebp - 0x30], xmm0
movlpd qword [ebp - 0x28], xmm0
movlpd qword [ebp - 0x20], xmm0
movlpd qword [ebp - 0x18], xmm0
mov dword [ebp - 0x4c], 0x3c
call dword [sym.imp.SHLWAPI.dll_PathIsDirectoryW]
test eax, eax
je 0x41852b
mov eax, dword [ebp - 0x50]
mov ecx, dword [eax - 8]
sub esi, dword [eax - 4]
sub ecx, 0x104
or esi, ecx
jge 0x418501
push 0x104
lea ecx, [ebp - 0x50]
call fcn.004066c0
mov eax, dword [ebp - 0x50]
push eax
call dword [sym.imp.SHLWAPI.dll_PathAddBackslashW]
mov eax, dword [ebp - 0x50]
cmp dword [eax - 8], 0x104
jl 0x4185bc
mov dword [eax - 0xc], 0x104
xor ecx, ecx
mov eax, dword [ebp - 0x50]
mov word [eax + 0x208], cx
mov eax, dword [ebp + 0xc]
xor ecx, ecx
mov dword [ebp - 0x38], eax
test bl, bl
mov eax, dword [ebp - 0x50]
mov dword [ebp - 0x3c], eax
mov eax, dword [ebp - 0x54]
mov dword [ebp - 0x34], eax
mov eax, str.runas
cmove eax, ecx
mov dword [ebp - 0x30], 1
mov dword [ebp - 0x40], eax
lea eax, [ebp - 0x4c]
push eax
mov dword [ebp - 0x48], 0x440
call dword [sym.imp.SHELL32.dll_ShellExecuteExW]
mov edx, dword [ebp - 0x50]
test eax, eax
setne bl
or esi, 0xffffffff
add edx, 0xfffffff0
mov eax, esi
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x418586
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov eax, dword [ebp - 0x54]
add eax, 0xfffffff0
lock xadd dword [eax + 0xc], esi
dec esi
test esi, esi
jg 0x41859e
mov ecx, dword [eax]
push eax
mov edx, dword [ecx]
call dword [edx + 4]
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004fa004
mov esp, ebp
pop ebp
ret
push 0x80070057
call fcn.004061e0
int3
Function at 0x4185d0
Capabilities:
Enumerate processes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x230
mov eax, dword [0x5cc6c0]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
xor bl, bl
push 0
push 2
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov esi, eax
cmp esi, 0xffffffff
je 0x418646
lea eax, [ebp - 0x230]
mov dword [ebp - 0x230], 0x22c
push eax
push esi
call sub.KERNEL32.dll_Process32FirstW
test eax, eax
je 0x41863f
lea eax, [ebp - 0x20c]
push edi
push eax
call fcn.005473f2
add esp, 8
test eax, eax
je 0x41863d
lea eax, [ebp - 0x230]
push eax
push esi
call sub.KERNEL32.dll_Process32NextW
test eax, eax
jne 0x418616
jmp 0x41863f
mov bl, 1
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 4]
mov al, bl
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004fa004
mov esp, ebp
pop ebp
ret

Function at 0x418660
Capabilities:
Hide graphical window
Log keystrokes

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
push 0
call dword [sym.imp.USER32.dll_GetForegroundWindow]
push eax
call dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
mov esi, eax
mov dword [ebp - 4], esi
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push 1
mov ebx, eax
push ebx
push esi
call dword [sym.imp.USER32.dll_AttachThreadInput]
mov esi, dword [ebp + 8]
push esi
call dword [sym.imp.USER32.dll_BringWindowToTop]
push 5
push esi
call dword [sym.imp.USER32.dll_ShowWindow]
push 0
push ebx
push dword [ebp - 4]
call dword [sym.imp.USER32.dll_AttachThreadInput]
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x4187c0
Capabilities:
Get file size

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x56d1c3
mov eax, dword fs:[0]
push eax
sub esp, 0xb8
mov eax, dword [0x5cc6c0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 8]
cmp dword [eax + 0x14], 8
jb 0x4187f8
mov eax, dword [eax]
lea ecx, [ebp - 0xc0]
push 3
mov dword [ebp - 0xc4], ecx
lea ecx, [ebp - 0xc4]
push eax
call fcn.0041a320
mov edx, dword [ebp - 0xc4]
mov ecx, edx
mov dword [ebp - 4], 0
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x14], 0xf
mov byte [ebp - 0x28], 0
lea esi, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x418836
sub ecx, esi
push ecx
push edx
lea ecx, [ebp - 0x28]
call fcn.00406f00
mov eax, dword [ebp - 0xc4]
lea ecx, [ebp - 0xc0]
mov byte [ebp - 4], 2
cmp eax, ecx
je 0x418866
push eax
call fcn.00542951
add esp, 4
cmp dword [ebp - 0x14], 0x10
lea edx, [ebp - 0x28]
mov dword [ebp - 0x30], 0
cmovae edx, dword [ebp - 0x28]
mov ecx, edx
mov dword [ebp - 0x2c], 0xf
mov byte [ebp - 0x40], 0
lea esi, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x418888
sub ecx, esi
push ecx
push edx
lea ecx, [ebp - 0x40]
call fcn.00406f00
cmp dword [ebp - 0x2c], 0x10
lea eax, [ebp - 0x40]
push 0
cmovae eax, dword [ebp - 0x40]
push 0x80
push 3
push 0
push 1
push SysReAllocString
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, 0xffffffff
jne 0x4188ca
or esi, eax
jmp 0x4188dc
push 0
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
push edi
mov esi, eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edx, dword [ebp - 0x2c]
cmp edx, 0x10
jb 0x41890c
mov ecx, dword [ebp - 0x40]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x418902
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x41896b
push edx
push ecx
call fcn.004f9d5c
add esp, 8
mov edx, dword [ebp - 0x14]
mov dword [ebp - 0x30], 0
mov dword [ebp - 0x2c], 0xf
mov byte [ebp - 0x40], 0
cmp edx, 0x10
jb 0x41894e
mov ecx, dword [ebp - 0x28]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x418944
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x418970
push edx
push ecx
call fcn.004f9d5c
add esp, 8
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004fa004
mov esp, ebp
pop ebp
ret
call fcn.00542850
call fcn.00542850
int3
Function at 0x418980
Capabilities:
Get file size
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x56d1f0
mov eax, dword fs:[0]
push eax
sub esp, 0x24
mov eax, dword [0x5cc6c0]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov eax, dword [ebp + 8]
xor bl, bl
mov ecx, dword [ebp + 0xc]
mov dword [ebp - 0x28], ecx
mov dword [ebp - 0x24], ecx
cmp dword [eax + 0x14], 0x10
mov byte [ebp - 0x19], bl
jb 0x4189c7
mov eax, dword [eax]
push 0
push 0
push 3
push 0
push 3
push SysReAllocString
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
mov dword [ebp - 0x2c], esi
cmp esi, 0xffffffff
jne 0x4189ee
xor al, al
jmp 0x418a82
push 0
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
cmp edi, 0xffffffff
je 0x418a79
test edi, edi
jne 0x418a06
mov bl, 1
jmp 0x418a79
push 0x5d78a8
push edi
call fcn.004fa1d7
add esp, 8
mov dword [ebp - 0x20], eax
test eax, eax
je 0x418a79
push 0
lea ecx, [ebp - 0x18]
push ecx
push edi
push eax
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x418a6d
cmp dword [ebp - 0x18], edi
jne 0x418a6d
mov ecx, dword [ebp - 0x28]
push edi
mov edi, dword [ebp - 0x20]
push edi
mov dword [ebp - 4], 0
call fcn.00406f00
mov bl, 1
jmp 0x418a70
mov edi, dword [ebp - 0x20]
push edi
call fcn.004fa1d2
add esp, 4
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.004fa004
mov esp, ebp
pop ebp
ret
Function at 0x418aa0
Capabilities:
Check if file exists
Clear file content
Get file attributes
Set file attributes
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
mov eax, dword [0x5cc6c0]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov esi, dword [ebp + 8]
mov eax, esi
mov byte [ebp - 0x10], 0
mov byte [ebp - 9], 0
cmp dword [esi + 0x14], 0x10
jb 0x418ac7
mov eax, dword [esi]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x418af5
test bl, 1
je 0x418af5
cmp dword [esi + 0x14], 0x10
mov ecx, esi
mov byte [ebp - 9], 1
jb 0x418ae8
mov ecx, dword [esi]
mov eax, ebx
and eax, 0xfffffffe
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
cmp dword [esi + 0x14], 0x10
mov eax, esi
jb 0x418aff
mov eax, dword [esi]
push edi
push 0
push 0x80
push 4
push 0
push 1
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, 0xffffffff
je 0x418b65
push edi
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
cmp dword [ebp + 0x20], 0x10
lea eax, [ebp - 8]
push 0
push eax
push dword [ebp + 0x1c]
lea ecx, [ebp + 0xc]
cmovae ecx, dword [ebp + 0xc]
push ecx
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x418b5e
mov ecx, dword [ebp - 0x10]
mov edx, 1
mov eax, dword [ebp + 0x1c]
cmp eax, dword [ebp - 8]
movzx ecx, cl
cmove ecx, edx
mov dword [ebp - 0x10], ecx
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp byte [ebp - 9], 0
pop edi
je 0x418b7c
cmp dword [esi + 0x14], 0x10
jb 0x418b74
mov esi, dword [esi]
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
mov edx, dword [ebp + 0x20]
pop esi
pop ebx
cmp edx, 0x10
jb 0x418bae
mov ecx, dword [ebp + 0xc]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x418ba4
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x418bbf
push edx
push ecx
call fcn.004f9d5c
add esp, 8
mov ecx, dword [ebp - 4]
mov al, byte [ebp - 0x10]
xor ecx, ebp
call fcn.004fa004
mov esp, ebp
pop ebp
ret
call fcn.00542850
int3

Function at 0x418db0
Capabilities:
Check if file exists
Get common file path

Disassembly:
push ebp
mov ebp, esp
push ecx
cmp word [0x5d6460], 0
push esi
mov esi, dword [ebp + 8]
mov dword [ebp - 4], esi
je 0x418ded
mov ecx, 0x5d6460
mov dword [esi + 0x10], 0
xor eax, eax
mov dword [esi + 0x14], 7
mov word [esi], ax
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x418de0
jmp 0x418e4d
push 0
push 0x1a
push 0x5d6460
push 0
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
push dword [ebp + 0xc]
push 0x5d6460
call dword [sym.imp.SHLWAPI.dll_PathAppendW]
push 0x5d6460
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x418e27
push 0x5d6460
push eax
call dword [sym.imp.SHELL32.dll_SHCreateDirectory]
mov ecx, 0x5d6460
mov dword [esi + 0x10], 0
xor eax, eax
mov dword [esi + 0x14], 7
mov word [esi], ax
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x418e42
sub ecx, edx
sar ecx, 1
push ecx
push 0x5d6460
mov ecx, esi
call fcn.00406a80
mov eax, esi
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x418fd0
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x56d27b
mov eax, dword fs:[0]
push eax
sub esp, 0xa4
mov eax, dword [0x5cc6c0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, dword [ebp + 8]
mov dword [ebp - 0x2c], edi
call fcn.0040ca80
lea ecx, [ebp - 0x2c]
push ecx
mov ecx, eax
call fcn.004217a0
mov edx, dword [eax]
xor eax, eax
mov ecx, edx
mov dword [ebp - 4], 0
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x14], 7
mov word [ebp - 0x28], ax
lea esi, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x419035
sub ecx, esi
sar ecx, 1
push ecx
push edx
lea ecx, [ebp - 0x28]
call fcn.00406a80
mov edx, dword [ebp - 0x2c]
or eax, 0xffffffff
mov byte [ebp - 4], 2
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x41906d
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
cmp dword [ebp - 0x14], 8
lea eax, [ebp - 0x28]
mov esi, dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
cmovae eax, dword [ebp - 0x28]
push eax
call esi
test eax, eax
jne 0x4190ab
cmp dword [ebp - 0x14], 8
lea eax, [ebp - 0x28]
cmovae eax, dword [ebp - 0x28]
push eax
call esi
test eax, eax
jne 0x4190ab
cmp dword [ebp - 0x14], 8
lea eax, [ebp - 0x28]
cmovae eax, dword [ebp - 0x28]
push eax
push 0
call dword [sym.imp.SHELL32.dll_SHCreateDirectory]
cmp dword [ebp - 0x14], 8
lea eax, [ebp - 0x28]
lea ecx, [ebp - 0xac]
cmovae eax, dword [ebp - 0x28]
push 0xfde9
mov dword [ebp - 0xb0], ecx
lea ecx, [ebp - 0xb0]
push eax
call fcn.0041a320
mov edx, dword [ebp - 0xb0]
mov ecx, edx
mov dword [edi + 0x10], 0
mov dword [edi + 0x14], 0xf
mov byte [ebp - 4], 3
mov byte [edi], 0
lea esi, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x4190f3
sub ecx, esi
push ecx
push edx
mov ecx, edi
call fcn.00406f00
mov eax, dword [ebp - 0xb0]
lea ecx, [ebp - 0xac]
cmp eax, ecx
je 0x41911e
push eax
call fcn.00542951
add esp, 4
mov edx, dword [ebp - 0x14]
cmp edx, 8
jb 0x419154
mov ecx, dword [ebp - 0x28]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x41914a
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x419171
push edx
push ecx
call fcn.004f9d5c
add esp, 8
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004fa004
mov esp, ebp
pop ebp
ret
call fcn.00542850
int3
Function at 0x41a1f0
Capabilities:
Read .ini file

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20c
mov eax, dword [0x5cc6c0]
xor eax, ebp
mov dword [ebp - 4], eax
push 0x208
lea eax, [ebp - 0x20c]
push 0
push eax
call fcn.0053efc0
add esp, 0xc
cmp word [0x5d6250], 0
jne 0x41a25f
cmp word [0x5d6048], 0
jne 0x41a24a
push 0x104
push 0x5d6048
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
push 0x5d6048
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
push 0x5805d8
push 0x5d6048
push 0x5d6250
call dword [sym.imp.SHLWAPI.dll_PathCombineW]
push 0x5d6250
push 0x104
lea eax, [ebp - 0x20c]
push eax
push 0x5805f0
push str.state
push 0x58099c
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringW]
mov ecx, str.PCStoreUpdate
lea eax, [ebp - 0x20c]
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x41a2b6
test dx, dx
je 0x41a2b2
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x41a2b6
add eax, 4
add ecx, 4
test dx, dx
jne 0x41a290
xor eax, eax
jmp 0x41a2bb
sbb eax, eax
or eax, 1
test eax, eax
je 0x41a30f
mov eax, str.bigupdate
lea ecx, [ebp - 0x20c]
nop word [eax + eax]
mov dx, word [ecx]
cmp dx, word [eax]
jne 0x41a2f6
test dx, dx
je 0x41a2f2
mov dx, word [ecx + 2]
cmp dx, word [eax + 2]
jne 0x41a2f6
add ecx, 4
add eax, 4
test dx, dx
jne 0x41a2d0
xor eax, eax
jmp 0x41a2fb
sbb eax, eax
or eax, 1
test eax, eax
je 0x41a30f
xor al, al
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004fa004
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 4]
mov al, 1
xor ecx, ebp
call fcn.004fa004
mov esp, ebp
pop ebp
ret