joyce8/EMBER2024-capa huggingface dataset:
Function at 0x116b250
Capabilities:
Compare security identifiers

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x117f808
push 0x116f288
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x2c
push ebx
push esi
push edi
xor ebx, ebx
mov dword [ebp - 0x1c], ebx
mov dword [ebp - 0x28], ebx
xor esi, esi
mov dword [ebp - 0x20], esi
mov byte [ebp - 0x24], bl
mov dword [ebp - 4], ebx
mov byte [ebp - 0x34], bl
mov byte [ebp - 0x33], bl
mov byte [ebp - 0x32], bl
mov byte [ebp - 0x31], bl
mov byte [ebp - 0x30], bl
mov byte [ebp - 0x2f], 5
lea eax, [ebp - 0x1c]
push eax
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push 0x12
push 1
lea ecx, [ebp - 0x34]
push ecx
call dword [sym.imp.ADVAPI32.dll_AllocateAndInitializeSid]
test eax, eax
je 0x116b329
lea edx, [ebp - 0x28]
push edx
push 8
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x116b329
mov dword [ebp - 0x2c], ebx
lea eax, [ebp - 0x2c]
push eax
push ebx
push ebx
push 1
mov ecx, dword [ebp - 0x28]
push ecx
mov edi, dword [sym.imp.ADVAPI32.dll_GetTokenInformation]
call edi
mov edx, dword [ebp - 0x2c]
push edx
call fcn.0116e1d3
add esp, 4
mov esi, eax
mov dword [ebp - 0x38], esi
mov dword [ebp - 0x20], esi
cmp esi, ebx
je 0x116b329
lea eax, [ebp - 0x2c]
push eax
mov ecx, dword [ebp - 0x2c]
push ecx
push esi
push 1
mov edx, dword [ebp - 0x28]
push edx
call edi
test eax, eax
je 0x116b329
mov eax, dword [ebp - 0x1c]
push eax
mov ecx, dword [esi]
push ecx
call dword [sym.imp.ADVAPI32.dll_EqualSid]
neg eax
sbb eax, eax
neg eax
mov byte [ebp - 0x24], al
jmp 0x116b32c
mov al, byte [ebp - 0x24]
mov dword [ebp - 4], 0xffffffff
call fcn.0116b351
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x116bd20
Capabilities:
Query or enumerate registry value

Disassembly:
push ecx
mov edx, dword [esp + 8]
push esi
mov esi, dword [esp + 0x10]
lea eax, [esp + 4]
push eax
mov eax, dword [ecx + 4]
push esi
push 0
push 0
push edx
push eax
mov dword [esp + 0x1c], 8
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
je 0x116bd58
mov ecx, dword [esp + 0x14]
mov edx, dword [esp + 0x18]
mov dword [esi], ecx
mov dword [esi + 4], edx
pop esi
pop ecx
ret 0x10

Function at 0x116bd60
Capabilities:
Query or enumerate registry value

Disassembly:
mov edx, dword [esp + 4]
push esi
mov esi, dword [esp + 0xc]
lea eax, [esp + 0x10]
push eax
mov eax, dword [ecx + 4]
push esi
push 0
push 0
push edx
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
je 0x116bd94
mov eax, dword [esp + 0x14]
test eax, eax
je 0x116bd94
push eax
push esi
call fcn.0116e20b
add esp, 8
pop esi
ret 0x10

Function at 0x116bda0
Capabilities:
Query or enumerate registry value

Disassembly:
mov edx, dword [esp + 4]
sub esp, 0x24
lea eax, [esp + 0x28]
push eax
mov eax, dword [ecx + 4]
push 0x20019
push 0
push edx
push eax
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x116be22
push ebx
mov ebx, dword [esp + 0x30]
push esi
xor esi, esi
test ebx, ebx
jbe 0x116be15
push ebp
mov ebp, dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
push edi
mov edi, dword [esp + 0x40]
push esi
lea ecx, [esp + 0x18]
push 0x1184320
push ecx
mov dword [esp + 0x1c], 4
call fcn.0116ddff
mov ecx, dword [esp + 0x44]
add esp, 0xc
lea edx, [esp + 0x10]
lea eax, [esp + 0x14]
push edx
push edi
push 0
push 0
push eax
push ecx
call ebp
inc esi
add edi, 4
cmp esi, ebx
jb 0x116bdda
pop edi
pop ebp
mov edx, dword [esp + 0x30]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop esi
pop ebx
add esp, 0x24
ret 0xc

Function at 0x116be30
Capabilities:
Query or enumerate registry value

Disassembly:
mov edx, dword [esp + 4]
sub esp, 0x28
lea eax, [esp + 0x2c]
push eax
mov eax, dword [ecx + 4]
push 0x20019
push 0
push edx
push eax
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x116bec2
push ebp
mov ebp, dword [esp + 0x34]
push esi
xor esi, esi
test ebp, ebp
jbe 0x116beb5
push ebx
mov ebx, dword [esp + 0x40]
push edi
mov edi, dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
push esi
lea ecx, [esp + 0x1c]
push 0x1184320
push ecx
mov dword [esp + 0x1c], 4
call fcn.0116ddff
add esp, 0xc
lea edx, [esp + 0x10]
lea eax, [esp + 0x14]
lea ecx, [esp + 0x18]
push edx
mov edx, dword [esp + 0x40]
push eax
push 0
push 0
push ecx
push edx
call edi
test eax, eax
jne 0x116beab
mov ax, word [esp + 0x14]
mov word [ebx], ax
inc esi
add ebx, 2
cmp esi, ebp
jb 0x116be6a
pop edi
pop ebx
mov ecx, dword [esp + 0x34]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop esi
pop ebp
add esp, 0x28
ret 0xc
Function at 0x116c000
Capabilities:
Get file version info

Disassembly:
push ecx
push ebx
mov ebx, dword [esp + 0xc]
push ebp
push esi
lea eax, [esp + 0xc]
push edi
push eax
push ebx
call sub.VERSION.dll_GetFileVersionInfoSizeW
mov esi, eax
test esi, esi
je 0x116c131
push esi
call fcn.0116f145
add esp, 4
mov edi, eax
push edi
push esi
push 0
push ebx
call sub.VERSION.dll_GetFileVersionInfoW
push 0
push 0x80
push 3
push 0
push 0
push 0xc0000000
push ebx
call fcn.0115e080
mov ebp, eax
add esp, 0x1c
cmp ebp, 0xffffffff
je 0x116c131
push 0
push ebp
call fcn.0115e3a0
push 0
push 0
push 0
push 4
push 0
push ebp
mov ebx, eax
call fcn.0115e260
add esp, 0x20
mov dword [esp + 0x18], eax
test eax, eax
jne 0x116c08b
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
pop ebx
pop ecx
ret
push 0
push 0
push 0
push 6
push eax
call fcn.0115e2f0
mov esi, eax
add esp, 0x14
test esi, esi
je 0x116c121
push 0x1184918
push edi
call fcn.0116d3f0
push eax
push ebx
push esi
call fcn.0116bf60
push 0x11848f8
push edi
call fcn.0116d3f0
push eax
push ebx
push esi
call fcn.0116bf60
push 0x11848d8
push edi
call fcn.0116d3f0
push eax
push ebx
push esi
call fcn.0116bf60
push 0x11848c0
push edi
call fcn.0116d3f0
add esp, 0x44
push eax
push ebx
push esi
call fcn.0116bf60
push 0x11848a0
push edi
call fcn.0116d3f0
push eax
push ebx
push esi
call fcn.0116bf60
push 0x1184888
push edi
call fcn.0116d3f0
push eax
push ebx
push esi
call fcn.0116bf60
add esp, 0x34
push esi
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov ecx, dword [esp + 0x18]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
push ecx
call esi
push ebp
call esi
pop edi
pop esi
pop ebp
pop ebx
pop ecx
ret
Function at 0x116d1b0
Capabilities:
Acquire debug privileges

Disassembly:
push ecx
lea eax, [esp]
mov dword [esp], 0
push eax
push 0x20
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [esp]
push 1
push str.SeBackupPrivilege
push ecx
call fcn.0116d140
mov edx, dword [esp + 0xc]
push 1
push str.SeDebugPrivilege
push edx
call fcn.0116d140
mov eax, dword [esp + 0x18]
push 1
push str.SeRestorePrivilege
push eax
call fcn.0116d140
mov ecx, dword [esp + 0x24]
push 1
push str.SeSecurityPrivilege
push ecx
call fcn.0116d140
mov edx, dword [esp + 0x30]
add esp, 0x30
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov al, 1
pop ecx
ret

Function at 0x116dbfa
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push esi
lea eax, [ebp - 4]
push eax
push 0x20019
xor esi, esi
push esi
push str.CLSIDADB880A6_D8FF_11CF_9377_00AA003B7A11InprocServer32
push SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x116dc50
lea eax, [ebp - 8]
push eax
push dword [ebp + 8]
mov dword [ebp - 8], 0x104
push esi
push esi
push 0x117f87c
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x116dc43
inc esi
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, esi
jmp 0x116dc52
xor eax, eax
pop esi
leave
ret 4
Function at 0x401060
Capabilities:
Print debug messages

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x824
mov eax, dword [0x441064]
xor eax, ebp
mov dword [ebp - 4], eax
push 0x820
lea eax, [ebp - 0x824]
push 0
push eax
call fcn.00412cd0
add esp, 0xc
lea eax, [ebp + 0xc]
push eax
push 0
push dword [ebp + 8]
lea eax, [ebp - 0x824]
push 0x410
push 0x410
push eax
call fcn.00401050
push dword [eax + 4]
push dword [eax]
call fcn.00417c3a
add esp, 0x20
cmp word [ebp - 0x824], 0
je 0x4010cc
lea eax, [ebp - 0x824]
push eax
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00410b68
mov esp, ebp
pop ebp
ret
Function at 0x403240
Capabilities:
Encode data using xor
Hash data using fnv

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 0xc]
mov edx, 0x811c9dc5
push edi
mov edi, dword [ebp + 8]
mov ecx, 0
sub esi, edi
je 0x403271
nop dword [eax]
movzx eax, byte [ecx + edi]
inc ecx
xor eax, edx
imul edx, eax, 0x1000193
cmp ecx, esi
jb 0x403260
pop edi
mov eax, edx
pop esi
pop ebp
ret 8
Function at 0x409150
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
push ecx
cmp dword [ebp + 0xc], 0
mov edx, ecx
push ebx
push esi
push edi
mov ebx, 1
je 0x40916a
cmp dword [edx + 4], 0xffffffff
jne 0x40916c
xor ebx, ebx
mov esi, dword [edx + 0xc]
test ebx, ebx
je 0x4091d9
test esi, esi
je 0x4091d9
mov eax, 0x5a4d
cmp word [esi], ax
jne 0x4091d9
mov eax, dword [esi + 0x3c]
cmp dword [eax + esi], 0x4550
jne 0x4091d9
mov eax, dword [eax + esi + 0x98]
test eax, eax
je 0x4091d9
lea edi, [eax + esi]
test edi, edi
je 0x4091d9
lea eax, [edi + 8]
test eax, eax
je 0x4091d9
cmp byte [eax], 0x30
lea ecx, [eax + 1]
jne 0x4091d9
mov al, byte [ecx]
inc ecx
mov dword [ebp - 4], ecx
cmp al, 0x82
jne 0x4091d9
mov eax, dword [ebp - 4]
movzx ecx, byte [ecx]
shl ecx, 8
movzx eax, byte [eax + 1]
add eax, 0x13
add eax, ecx
and eax, 0xffffff8
je 0x4091d9
mov dword [edx + 0x14], eax
mov dword [edx + 0x18], edi
jmp 0x4091e1
mov edi, dword [edx + 0x18]
xor ebx, ebx
mov eax, dword [edx + 0x14]
add edi, eax
test ebx, ebx
je 0x40925d
mov eax, dword [edx + 0x10]
add eax, esi
cmp edi, eax
jae 0x40925d
xor ebx, ebx
cmp dword [edi], 0x74636159
sete bl
test ebx, ebx
je 0x409252
mov edx, dword [ebp + 8]
movzx ecx, byte [edi + 4]
movzx eax, byte [edi + 5]
shl ecx, 8
inc eax
mov edx, dword [edx]
add eax, ecx
movzx esi, ax
test edx, edx
jne 0x409232
mov eax, dword [ebp + 0xc]
push esi
mov dword [eax], esi
call fcn.00410bdf
mov edx, eax
add esp, 4
mov eax, dword [ebp + 8]
mov dword [eax], edx
test edx, edx
je 0x409252
push esi
push 0
push edx
call fcn.00412cd0
push esi
lea eax, [edi + 6]
push eax
mov eax, dword [ebp + 8]
push dword [eax]
call fcn.004121d0
add esp, 0x18
mov ebx, 1
pop edi
pop esi
mov eax, ebx
pop ebx
mov esp, ebp
pop ebp
ret 8
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret 8
Function at 0x40b590
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2a4
mov eax, dword [0x441064]
xor eax, ebp
mov dword [ebp - 4], eax
cmp dword [ebp + 8], 0
lea eax, [ebp - 0x2a4]
push ebx
push esi
push edi
mov edi, dword [ebp + 0xc]
mov esi, ecx
push eax
push 0
mov ecx, 0x23
mov eax, 0x1c
cmovne eax, ecx
mov ebx, edx
push 0
or eax, 0x8000
push eax
push 0
call dword [sym.imp.SHELL32.dll_SHGetFolderPathW]
test eax, eax
js 0x40b675
push 0x27
lea eax, [ebp - 0x9c]
push eax
lea eax, [esi + 0x8c]
push eax
call dword [sym.imp.ole32.dll_StringFromGUID2]
test eax, eax
js 0x40b675
mov ecx, dword [esi + 0xa0]
mov edx, dword [esi + 0x9c]
movzx eax, cx
push eax
shr ecx, 0x10
push ecx
movzx eax, dx
push eax
shr edx, 0x10
lea eax, [ebp - 0x4c]
push edx
push 0x43dda8
push 0x24
push eax
call fcn.0040b230
add esp, 0x1c
test eax, eax
js 0x40b675
lea eax, [ebp - 0x4c]
push eax
lea eax, [ebp - 0x9c]
push eax
lea eax, [ebp - 0x2a4]
push eax
push str._lsApplicationsCache_lsv_ls.msi
push edi
call fcn.0040df30
add esp, 0x14
test eax, eax
js 0x40b675
push 1
push 1
push dword [edi]
push ebx
call fcn.0040e5a0
test eax, eax
jns 0x40b675
cmp dword [ebp + 8], 1
jne 0x40b675
push edi
push 0
mov edx, ebx
mov ecx, esi
call fcn.0040b590
add esp, 8
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00410b68
mov esp, ebp
pop ebp
ret

Function at 0x40b690
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2a4
mov eax, dword [0x441064]
xor eax, ebp
mov dword [ebp - 4], eax
cmp dword [ebp + 8], 0
lea eax, [ebp - 0x2a4]
push ebx
push esi
push edi
mov edi, dword [ebp + 0xc]
mov esi, ecx
push eax
push 0
mov ecx, 0x23
mov eax, 0x1c
cmovne eax, ecx
mov ebx, edx
push 0
or eax, 0x8000
push eax
push 0
call dword [sym.imp.SHELL32.dll_SHGetFolderPathW]
test eax, eax
js 0x40b775
push 0x27
lea eax, [ebp - 0x9c]
push eax
lea eax, [esi + 0x8c]
push eax
call dword [sym.imp.ole32.dll_StringFromGUID2]
test eax, eax
js 0x40b775
mov ecx, dword [esi + 0xa0]
mov edx, dword [esi + 0x9c]
movzx eax, cx
push eax
shr ecx, 0x10
push ecx
movzx eax, dx
push eax
shr edx, 0x10
lea eax, [ebp - 0x4c]
push edx
push 0x43dda8
push 0x24
push eax
call fcn.0040b230
add esp, 0x1c
test eax, eax
js 0x40b775
lea eax, [ebp - 0x4c]
push eax
lea eax, [ebp - 0x9c]
push eax
lea eax, [ebp - 0x2a4]
push eax
push str._lsApplicationsCache_lsv_ls.mst
push edi
call fcn.0040df30
add esp, 0x14
test eax, eax
js 0x40b775
push 1
push 1
push dword [edi]
push ebx
call fcn.0040e5a0
test eax, eax
jns 0x40b775
cmp dword [ebp + 8], 1
jne 0x40b775
push edi
push 0
mov edx, ebx
mov ecx, esi
call fcn.0040b690
add esp, 8
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00410b68
mov esp, ebp
pop ebp
ret
Function at 0x40e130
Capabilities:
Delete file
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push esi
lea eax, [ebp - 4]
mov dword [ebp - 8], 0
push eax
lea eax, [ebp - 8]
mov dword [ebp - 4], 0
push eax
push dword [ebp + 8]
mov dword [ebp - 0x10], 0
push 0
mov dword [ebp - 0xc], 0
call fcn.0040e240
mov esi, eax
test esi, esi
js 0x40e22e
push edi
push 0
push 0x80
push dword [ebp + 0x10]
push 0
push 0
push 0x40000000
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
cmp edi, 0xffffffff
jne 0x40e1c4
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x40e1a8
movzx esi, si
or esi, 0x80070000
test esi, esi
mov eax, 0x80004005
cmovns esi, eax
push esi
push 0xe7
push str.c:_buildagentwork_f0a36ae8bd009770_third_partydutil_resrutil.cpp
call fcn.0040ebe0
jmp 0x40e218
push 0
lea eax, [ebp - 0x10]
mov dword [ebp - 0xc], 1
push eax
push dword [ebp - 4]
push dword [ebp - 8]
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x40e211
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x40e1f7
movzx esi, si
or esi, 0x80070000
test esi, esi
mov eax, 0x80004005
cmovns esi, eax
push esi
push 0xed
push str.c:_buildagentwork_f0a36ae8bd009770_third_partydutil_resrutil.cpp
call fcn.0040ebe0
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
test esi, esi
jns 0x40e22c
cmp dword [ebp - 0xc], 0
je 0x40e22c
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov eax, esi
pop esi
mov esp, ebp
pop ebp
ret 0xc
Function at 0x40e420
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x220
mov eax, dword [0x441064]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
mov dword [ebp - 0x218], eax
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x214], eax
mov eax, dword [ebp + 0x10]
push esi
mov dword [ebp - 0x220], eax
mov esi, 0x80004005
mov eax, dword [ebp + 0x14]
push edi
mov dword [ebp - 0x21c], eax
or edi, 0xffffffff
lea eax, [ebp - 0x20c]
mov dword [ebp - 0x210], 0
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
test eax, eax
jne 0x40e4af
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x40e498
movzx esi, si
or esi, 0x80070000
test esi, esi
jns 0x40e4af
push esi
push 0x4be
push 0x42f538
call fcn.0040ebe0
jmp 0x40e57c
push ebx
xor ebx, ebx
cmp edi, 0xffffffff
jne 0x40e544
push dword [ebp - 0x214]
lea eax, [ebp - 0x20c]
push ebx
push dword [ebp - 0x218]
push eax
lea eax, [ebp - 0x210]
push str._s_s_05d._s
push eax
call fcn.0040df30
mov esi, eax
add esp, 0x18
test esi, esi
js 0x40e57b
push 0
push 0x80
push 1
push 0
push 1
push 0x40000000
push dword [ebp - 0x210]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
cmp edi, 0xffffffff
jne 0x40e537
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x40e527
movzx esi, si
or esi, 0x80070000
cmp esi, 0x80070050
jne 0x40e533
xor esi, esi
jmp 0x40e537
test esi, esi
js 0x40e57b
inc ebx
cmp ebx, 0x3e8
jl 0x40e4b2
mov eax, dword [ebp - 0x21c]
test eax, eax
je 0x40e553
mov dword [eax], edi
or edi, 0xffffffff
mov ecx, dword [ebp - 0x220]
test ecx, ecx
je 0x40e56f
mov eax, dword [ebp - 0x210]
mov dword [ecx], eax
mov dword [ebp - 0x210], 0
cmp edi, 0xffffffff
je 0x40e57b
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop ebx
mov eax, dword [ebp - 0x210]
test eax, eax
je 0x40e58c
push eax
call fcn.0040e120
mov ecx, dword [ebp - 4]
mov eax, esi
pop edi
xor ecx, ebp
pop esi
call fcn.00410b68
mov esp, ebp
pop ebp
ret 0x10
Function at 0x40e5a0
Capabilities:
Move file

Disassembly:
push ebp
mov ebp, esp
push ebx
mov ebx, dword [ebp + 0xc]
xor eax, eax
push esi
push edi
mov edi, dword [ebp + 0x10]
xor esi, esi
test edi, edi
setne al
mov ecx, eax
or ecx, 2
cmp dword [ebp + 0x14], esi
cmove ecx, eax
push ecx
push ebx
push dword [ebp + 8]
mov dword [ebp + 0x10], ecx
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
test eax, eax
jne 0x40e6a8
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test edi, edi
jne 0x40e5fd
cmp esi, 0x50
je 0x40e5ef
cmp esi, 0xb7
jne 0x40e5fd
mov esi, 1
pop edi
mov eax, esi
pop esi
pop ebx
pop ebp
ret 0x10
cmp esi, 3
jne 0x40e69b
movzx eax, word [ebx]
xor edi, edi
mov ecx, ebx
test ax, ax
je 0x40e68d
mov edx, eax
cmp dx, 0x5c
mov eax, ecx
cmovne eax, edi
add ecx, 2
mov edi, eax
movzx eax, word [ecx]
mov edx, eax
test ax, ax
jne 0x40e614
test edi, edi
je 0x40e68d
xor eax, eax
push eax
push ebx
mov word [edi], ax
call fcn.0040ead0
mov esi, eax
mov eax, 0x5c
mov word [edi], ax
test esi, esi
js 0x40e6a8
push dword [ebp + 0x10]
push ebx
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
test eax, eax
jne 0x40e6a8
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x40e672
movzx esi, si
or esi, 0x80070000
test esi, esi
jns 0x40e6a8
push esi
push 0x42e
push 0x42f538
call fcn.0040ebe0
pop edi
mov eax, esi
pop esi
pop ebx
pop ebp
ret 0x10
mov esi, 0x80070003
pop edi
mov eax, esi
pop esi
pop ebx
pop ebp
ret 0x10
test esi, esi
jle 0x40e6a8
movzx esi, si
or esi, 0x80070000
pop edi
mov eax, esi
pop esi
pop ebx
pop ebp
ret 0x10
Function at 0x40e990
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x414
mov eax, dword [0x441064]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [ebp + 0xc]
lea eax, [ebp - 0x20c]
push edi
mov edi, dword [ebp + 8]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
test eax, eax
je 0x40ea87
cmp eax, 0x104
jae 0x40ea87
lea eax, [ebp - 0x414]
push eax
push 0
push edi
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_GetTempFileNameW]
test eax, eax
jne 0x40ea12
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x40ea00
movzx esi, si
or esi, 0x80070000
test esi, esi
mov eax, 0x80004005
cmovns esi, eax
push esi
push 0x53
jmp 0x40eaa9
mov ecx, dword [ebp + 0x10]
xor eax, eax
test ecx, ecx
je 0x40ea23
cmp ecx, 0x7fffffff
jbe 0x40ea28
mov eax, 0x80070057
test eax, eax
js 0x40eab5
test ecx, ecx
je 0x40ea5e
mov edx, 0x7ffffffe
lea edi, [ebp - 0x414]
sub edx, ecx
sub edi, esi
lea eax, [edx + ecx]
test eax, eax
je 0x40ea5e
movzx eax, word [edi + esi]
test ax, ax
je 0x40ea5e
mov word [esi], ax
add esi, 2
sub ecx, 1
jne 0x40ea43
test ecx, ecx
lea eax, [esi - 2]
pop edi
cmovne eax, esi
xor edx, edx
test ecx, ecx
pop esi
mov word [eax], dx
mov eax, 0x8007007a
cmovne eax, edx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00410b68
mov esp, ebp
pop ebp
ret 0xc
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x40ea9c
movzx esi, si
or esi, 0x80070000
test esi, esi
mov eax, 0x80004005
cmovns esi, eax
push esi
push 0x4e
push 0x42f598
call fcn.0040ebe0
mov eax, esi
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.00410b68
mov esp, ebp
pop ebp
ret 0xc
Function at 0x40ead0
Capabilities:
Check if file exists
Create directory
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push esi
push edi
push dword [ebp + 0xc]
mov edi, dword [ebp + 8]
xor esi, esi
push edi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x40ebcb
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
jne 0x40eb03
xor esi, esi
pop edi
mov eax, esi
pop esi
pop ebp
ret 8
cmp eax, 3
je 0x40eb18
push edi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x40eb18
test al, 0x10
jne 0x40eaf9
movzx eax, word [edi]
mov ecx, edi
push ebx
xor ebx, ebx
test ax, ax
je 0x40ebb5
mov edx, eax
nop dword [eax + eax]
cmp dx, 0x5c
mov eax, ecx
cmovne eax, ebx
add ecx, 2
mov ebx, eax
movzx eax, word [ecx]
mov edx, eax
test ax, ax
jne 0x40eb30
test ebx, ebx
je 0x40ebb5
push dword [ebp + 0xc]
xor eax, eax
push edi
mov word [ebx], ax
call fcn.0040ead0
mov esi, eax
mov eax, 0x5c
mov word [ebx], ax
test esi, esi
js 0x40ebca
push dword [ebp + 0xc]
push edi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x40ebaa
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
cmp esi, 0xb7
jne 0x40eb94
pop ebx
mov esi, 1
pop edi
mov eax, esi
pop esi
pop ebp
ret 8
test esi, esi
jle 0x40ebca
movzx esi, si
pop ebx
or esi, 0x80070000
pop edi
mov eax, esi
pop esi
pop ebp
ret 8
pop ebx
xor esi, esi
pop edi
mov eax, esi
pop esi
pop ebp
ret 8
mov esi, 0x80070003
push esi
push 0x82
push 0x42f598
call fcn.0040ebe0
pop ebx
pop edi
mov eax, esi
pop esi
pop ebp
ret 8
Function at 0x40f330
Capabilities:
Get session information
Print debug messages

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x828
mov eax, dword [0x441064]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [ebp + 0x10]
lea eax, [ebp - 0x828]
push eax
push esi
push dword [ebp + 0xc]
mov dword [ebp - 0x828], 0
push dword [ebp + 8]
push 0
call sub.WTSAPI32.dll_WTSQuerySessionInformationW
test eax, eax
jne 0x40f3a8
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x42f808
lea ecx, [ebp - 0x824]
push 0x410
push ecx
call fcn.00409270
add esp, 0x10
lea ecx, [ebp - 0x824]
push ecx
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
xor eax, eax
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00410b68
mov esp, ebp
pop ebp
ret
push dword [esi]
lea ecx, [ebp - 0x824]
push dword [ebp + 0xc]
push 0x42f8a8
push 0x410
push ecx
call fcn.00409270
add esp, 0x14
lea ecx, [ebp - 0x824]
push ecx
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
mov ecx, dword [ebp - 4]
mov eax, 1
xor ecx, ebp
pop esi
call fcn.00410b68
mov esp, ebp
pop ebp
ret