joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4037a9
Capabilities:
Set registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x448
mov eax, dword [0x40f014]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
xor eax, eax
mov dword [ebp - 0x220], 0x40
push 0x218
push eax
lea eax, [ebp - 0x21c]
mov ebx, edx
push eax
mov edi, ecx
call sub.msvcrt.dll_memset
add esp, 0xc
lea ecx, [ebp - 0x220]
mov edx, 0x10e
push ebx
call fcn.00403510
mov esi, eax
test esi, esi
jne 0x40395f
push 0x4023cc
mov edx, 0x10e
lea ecx, [ebp - 0x220]
call fcn.00403510
mov esi, eax
test esi, esi
jne 0x40395f
lea ecx, [ebp - 0x220]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, si
jne 0x403829
sub ecx, edx
sar ecx, 1
lea eax, [ecx*2 + 2]
push eax
lea eax, [ebp - 0x220]
push eax
push 2
push esi
push 0x4023dc
push edi
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
mov esi, eax
test esi, esi
jne 0x40395f
lea eax, [ebp - 0x448]
push eax
lea eax, [ebp - 0x440]
push eax
xor eax, eax
push eax
push 0xf003f
push eax
push 0x4023fc
push eax
push 0x40240c
push edi
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
mov esi, eax
test esi, esi
jne 0x40395f
push 4
lea eax, [ebp - 0x444]
mov dword [ebp - 0x444], 1
push eax
push 4
xor edi, edi
push edi
push 0x402420
push dword [ebp - 0x440]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
mov esi, eax
test esi, esi
jne 0x403953
push 0x218
lea eax, [ebp - 0x438]
mov dword [ebp - 0x43c], 0x40
push edi
push eax
call sub.msvcrt.dll_memset
add esp, 0xc
lea ecx, [ebp - 0x43c]
push ebx
mov ebx, 0x10e
mov edx, ebx
call fcn.00403510
mov esi, eax
test esi, esi
jne 0x403953
push 0x402430
mov edx, ebx
lea ecx, [ebp - 0x43c]
call fcn.00403510
mov esi, eax
test esi, esi
jne 0x403953
lea ecx, [ebp - 0x43c]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, di
jne 0x40391f
sub ecx, edx
sar ecx, 1
lea eax, [ecx*2 + 2]
push eax
lea eax, [ebp - 0x43c]
push eax
push 2
push edi
push 0x402440
push dword [ebp - 0x440]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
mov esi, eax
push dword [ebp - 0x440]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [ebp - 4]
mov eax, esi
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0040de60
leave
ret

Function at 0x404038
Capabilities:
Set registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ebx
push esi
xor esi, esi
xor ebx, ebx
inc ebx
mov dword [ebp - 4], esi
push edi
mov edi, esi
cmp dword [ebp + 0xc], esi
jbe 0x4040b8
test ebx, ebx
je 0x40406c
lea eax, [ebp - 4]
push eax
push 0x402864
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyW]
test eax, eax
jne 0x40409a
mov ebx, esi
mov eax, dword [ebp + 0x10]
test eax, eax
je 0x404092
cmp dword [eax + edi*4], esi
je 0x404092
push 1
push 0x4023a0
push 1
push esi
push dword [eax + edi*4]
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
test eax, eax
jne 0x40409a
inc edi
cmp edi, dword [ebp + 0xc]
jb 0x404050
jmp 0x4040a9
jg 0x4040a0
mov esi, eax
jmp 0x4040a9
movzx esi, ax
or esi, 0x80070000
cmp dword [ebp - 4], 0
je 0x4040b8
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret 0xc
Function at 0x404339
Capabilities:
Query or enumerate registry value
Set registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
push esi
push edi
xor edi, edi
lea ecx, [ebp - 0xc]
push 4
pop ebx
mov dword [ebp - 0xc], edi
mov dword [ebp - 4], edi
mov dword [ebp - 0x14], edi
mov dword [ebp - 8], edi
mov dword [ebp - 0x10], ebx
call fcn.0040a924
mov esi, eax
test esi, esi
jne 0x4043eb
lea eax, [ebp - 4]
push eax
push 0x2001f
push edi
push 0x4024b8
push dword [ebp - 0xc]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
je 0x40439c
lea eax, [ebp - 4]
push eax
push 0x4024b8
push dword [ebp - 0xc]
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyW]
test eax, eax
jne 0x4043dc
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0x14]
push eax
push edi
push dword [ebp + 8]
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x4043bf
mov eax, dword [ebp - 8]
inc eax
jmp 0x4043c2
xor eax, eax
inc eax
push ebx
mov dword [ebp - 8], eax
lea eax, [ebp - 8]
push eax
push ebx
push edi
push dword [ebp + 8]
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
je 0x4043eb
jg 0x4043e2
mov esi, eax
jmp 0x4043eb
movzx esi, ax
or esi, 0x80070000
cmp dword [ebp - 4], edi
je 0x4043f9
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret 4
Function at 0x4050ab
Capabilities:
Create process on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x47c
mov eax, dword [0x40f014]
xor eax, esp
mov dword [esp + 0x478], eax
mov eax, dword [ebp + 0x10]
push ebx
push esi
push edi
push 0x210
mov dword [esp + 0x10], eax
mov esi, edx
lea eax, [esp + 0x274]
mov ebx, ecx
push 0
push eax
call sub.msvcrt.dll_memset
push 0x44
lea eax, [esp + 0x30]
push 0
push eax
call sub.msvcrt.dll_memset
xor eax, eax
lea edi, [esp + 0x28]
stosd dword es:[edi], eax
add esp, 0x18
mov ecx, ebx
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
call fcn.00403d45
test eax, eax
jne 0x405119
mov esi, 0x8007000e
jmp 0x40529b
cmp dword [ebx + 0x1c], 6
jge 0x405129
mov esi, 0x8007139f
jmp 0x40529b
test esi, esi
je 0x405296
cmp dword [ebp + 8], 0
je 0x405296
mov edi, dword [esp + 0xc]
test edi, edi
je 0x405296
mov eax, dword [ebx + 0x24]
mov cx, word [esi]
cmp cx, word [eax]
jne 0x405170
test cx, cx
je 0x40516c
mov cx, word [esi + 2]
cmp cx, word [eax + 2]
jne 0x405170
add esi, 4
add eax, 4
test cx, cx
jne 0x40514a
xor eax, eax
jmp 0x405175
sbb eax, eax
or eax, 1
test eax, eax
je 0x405183
mov esi, 0x80070005
jmp 0x40529b
push dword [ebp + 8]
mov edx, 0x104
lea ecx, [esp + 0x6c]
call fcn.00403c5c
test eax, eax
js 0x405296
lea ecx, [esp + 0x68]
call fcn.00408ecf
lea ecx, [esp + 0x68]
call fcn.00408e67
test eax, eax
js 0x405296
lea ecx, [esp + 0x68]
call fcn.00408f9a
test eax, eax
js 0x405296
push ecx
lea eax, [esp + 0x6c]
mov ecx, ebx
push eax
call fcn.00403ede
mov esi, eax
test esi, esi
js 0x40529b
cmp dword [ebx + 0x54], 0
jne 0x4051f1
lea ecx, [esp + 0x68]
call fcn.0040950a
test eax, eax
je 0x405179
mov ecx, 0x108
lea eax, [esp + 0x270]
push ecx
mov edx, ecx
lea ecx, [esp + 0x6c]
push eax
call fcn.0040a7fb
mov esi, eax
test esi, esi
js 0x40529b
cmp dword [ebp + 0xc], 0
je 0x405236
push 0x402570
mov edx, 0x108
lea ecx, [esp + 0x274]
call fcn.00403510
mov esi, eax
test esi, esi
js 0x40529b
xor ecx, ecx
mov dword [esp + 0x20], 0x44
lea eax, [esp + 0x10]
push eax
lea eax, [esp + 0x24]
push eax
push ecx
push ecx
push ecx
push ecx
push ecx
push ecx
lea eax, [esp + 0x290]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
test eax, eax
jne 0x40527a
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x40529b
movzx esi, si
or esi, 0x80070000
jmp 0x40529b
push edi
lea eax, [esp + 0x14]
mov ecx, ebx
push eax
call fcn.00403f37
mov esi, eax
test esi, esi
js 0x40529b
mov dword [ebx + 0x1c], 8
jmp 0x40529b
mov esi, 0x80070057
cmp dword [esp + 0x14], 0
je 0x4052ac
push dword [esp + 0x14]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [esp + 0x10], 0
je 0x4052bd
push dword [esp + 0x10]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, ebx
call fcn.00403d59
mov ecx, dword [esp + 0x484]
mov eax, esi
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.0040de60
mov esp, ebp
pop ebp
ret 0xc
Function at 0x4056f0
Capabilities:
Create thread

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push esi
push edi
push 0x14
push 8
mov edi, ecx
mov dword [ebp - 4], 0x8007000e
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov esi, eax
test esi, esi
je 0x4057d5
push dword [ebp + 8]
call dword [sym.imp.OLEAUT32.dll_SysReAllocString]
mov dword [esi + 4], eax
test eax, eax
je 0x4057c5
push dword [ebp + 0xc]
call dword [sym.imp.OLEAUT32.dll_SysReAllocString]
mov dword [esi + 8], eax
test eax, eax
je 0x4057bc
mov eax, dword [ebp + 0x10]
mov dword [esi + 0xc], eax
mov eax, dword [ebp + 0x14]
mov dword [esi + 0x10], eax
xor eax, eax
push eax
push eax
push esi
push 0x4052e0
push eax
push eax
mov dword [esi], edi
call dword [sym.imp.KERNEL32.dll_CreateThread]
mov edi, eax
test edi, edi
je 0x40579e
push 0xffffffffffffffff
push edi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
test eax, eax
je 0x40578a
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jle 0x405785
movzx eax, ax
or eax, 0x80070000
mov dword [ebp - 4], eax
jmp 0x405795
lea eax, [ebp - 4]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_GetExitCodeThread]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x4057b3
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jle 0x4057b0
movzx eax, ax
or eax, 0x80070000
mov dword [ebp - 4], eax
push dword [esi + 8]
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
push dword [esi + 4]
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
push esi
call fcn.004035ce
mov eax, dword [ebp - 4]
pop ecx
pop edi
pop esi
leave
ret 0x10
call fcn.0040a5a6
int3
Function at 0x405922
Capabilities:
Set registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push esi
xor esi, esi
mov ebx, ecx
push edi
mov edi, edx
mov dword [ebp - 0xc], esi
mov dword [ebp - 8], esi
mov dword [ebp - 4], esi
call fcn.00403d45
test eax, eax
jne 0x40594f
mov esi, 0x8007000e
jmp 0x405a41
cmp dword [ebx + 0x1c], 7
jge 0x40595f
mov esi, 0x8007139f
jmp 0x405a41
test edi, edi
je 0x405a3c
cmp dword [ebp + 8], esi
je 0x405a3c
mov eax, dword [ebx + 0x24]
mov cx, word [edi]
cmp cx, word [eax]
jne 0x405999
test cx, cx
je 0x405995
mov cx, word [edi + 2]
cmp cx, word [eax + 2]
jne 0x405999
add edi, 4
add eax, 4
test cx, cx
jne 0x405973
mov eax, esi
jmp 0x40599e
sbb eax, eax
or eax, 1
test eax, eax
je 0x4059ac
mov esi, 0x80070005
jmp 0x405a41
lea eax, [ebp - 0xc]
push eax
push 0x20019
push esi
push 0x402670
push SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x405a2b
lea eax, [ebp - 8]
mov edi, 0x2001f
push eax
push edi
push esi
push dword [ebp + 8]
push dword [ebp - 0xc]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x405a2b
lea eax, [ebp - 4]
push eax
push edi
push esi
mov edi, 0x40267c
push edi
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
je 0x405a10
lea eax, [ebp - 4]
push eax
push edi
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyW]
test eax, eax
jne 0x405a2b
push 4
lea eax, [ebp + 0x10]
push eax
push 4
push esi
push 0x4026a4
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
test eax, eax
je 0x405a41
jg 0x405a31
mov esi, eax
jmp 0x405a41
movzx esi, ax
or esi, 0x80070000
jmp 0x405a41
mov esi, 0x80070057
cmp dword [ebp - 4], 0
je 0x405a50
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
cmp dword [ebp - 8], 0
je 0x405a5f
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
cmp dword [ebp - 0xc], 0
je 0x405a6e
push dword [ebp - 0xc]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, ebx
call fcn.00403d59
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret 0xc
Function at 0x406758
Capabilities:
Delete file
Set file attributes

Disassembly:
mov edi, edi
push ebx
push esi
push edi
mov edi, edx
mov ebx, ecx
xor esi, esi
call fcn.00403d45
test eax, eax
jne 0x406773
mov esi, 0x8007000e
jmp 0x4067b3
cmp dword [ebx + 0x1c], 4
jge 0x406780
mov esi, 0x8007139f
jmp 0x4067b3
test edi, edi
jne 0x40678b
mov esi, 0x80070057
jmp 0x4067b3
mov edx, dword [ebx + 0x4c]
mov ecx, edi
call fcn.00407ad1
test eax, eax
jne 0x4067a0
mov esi, 0x80070005
jmp 0x4067b3
push 0x80
push edi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
push edi
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov ecx, ebx
call fcn.00403d59
pop edi
mov eax, esi
pop esi
pop ebx
ret

Function at 0x407dbf
Capabilities:
Delete file
Set file attributes

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x108
mov eax, dword [0x40f014]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
mov esi, edx
mov ebx, ecx
xor edi, edi
jmp 0x407e48
cmp dword [esi + 8], 0
jne 0x407e45
cmp dword [esi], 0
je 0x407e45
push 0x104
lea eax, [ebp - 0x108]
push 0
push eax
call sub.msvcrt.dll_memset
mov edx, dword [esi]
lea eax, [ebp - 0x108]
add esp, 0xc
mov ecx, 0x104
push ecx
push eax
push ecx
mov ecx, ebx
call fcn.00407c0d
test eax, eax
je 0x407e42
push 0x80
lea eax, [ebp - 0x108]
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
test eax, eax
je 0x407e42
lea eax, [ebp - 0x108]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
test eax, eax
jne 0x407e45
xor edi, edi
inc edi
mov esi, dword [esi + 4]
test esi, esi
jne 0x407ddf
mov ecx, dword [ebp - 4]
mov eax, edi
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0040de60
leave
ret
Function at 0x407e5f
Capabilities:
Delete directory
Delete file
Enumerate files on windows
Enumerate files recursively
Set file attributes

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x254
mov eax, dword [0x40f014]
xor eax, esp
mov dword [esp + 0x250], eax
push ebx
push esi
push edi
mov edi, 0x104
lea eax, [esp + 0x150]
push edi
xor esi, esi
mov ebx, ecx
push esi
push eax
call sub.msvcrt.dll_memset
add esp, 0xc
test ebx, ebx
je 0x408033
cmp byte [ebx], 0
je 0x408033
push ebx
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
test eax, eax
jne 0x408033
push ebx
mov edx, edi
lea ecx, [esp + 0x154]
call fcn.00406ff8
mov esi, eax
test esi, esi
js 0x408033
lea ecx, [esp + 0x150]
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x407edc
sub ecx, edx
sub edi, ecx
lea ecx, [esp + 0x150]
push 0x4029b0
mov edx, edi
call fcn.00407227
mov esi, eax
test esi, esi
js 0x408033
lea eax, [esp + 0x10]
push eax
lea eax, [esp + 0x154]
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov edi, eax
cmp edi, 0xffffffff
jne 0x407f3c
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x408033
movzx esi, si
or esi, 0x80070000
jmp 0x408033
push 0x4029b4
lea eax, [esp + 0x40]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpA]
test eax, eax
je 0x407fde
push 0x4029b8
lea eax, [esp + 0x40]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpA]
test eax, eax
je 0x407fde
lea eax, [esp + 0x3c]
push eax
push ebx
push 0x4029bc
lea eax, [esp + 0x15c]
push 0x103
push eax
call fcn.00407275
mov esi, eax
add esp, 0x14
test esi, esi
js 0x408027
test byte [esp + 0x10], 0x10
lea eax, [esp + 0x150]
je 0x407fc0
push 0x90
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
lea ecx, [esp + 0x150]
call fcn.00407e5f
mov esi, eax
test esi, esi
js 0x408027
jmp 0x407fde
push 0x80
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
lea eax, [esp + 0x150]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
test eax, eax
je 0x40804a
lea eax, [esp + 0x10]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x407f3c
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x12
jne 0x40804a
push edi
call dword [sym.imp.KERNEL32.dll_FindClose]
push ebx
or edi, 0xffffffff
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
test eax, eax
jne 0x408033
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x408033
movzx esi, si
or esi, 0x80070000
cmp edi, 0xffffffff
je 0x408033
push edi
call dword [sym.imp.KERNEL32.dll_FindClose]
mov ecx, dword [esp + 0x25c]
mov eax, esi
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.0040de60
mov esp, ebp
pop ebp
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x408027
jmp 0x40801e
Function at 0x40815b
Capabilities:
Compare security identifiers

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ecx
push esi
push edi
xor esi, esi
push esi
push esi
push 3
push esi
push esi
push 0x20000
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
cmp edi, 0xffffffff
je 0x4081eb
lea eax, [ebp - 8]
mov dword [ebp - 8], esi
push eax
push 0x4029c4
call dword [sym.imp.ADVAPI32.dll_ConvertStringSidToSidW]
test eax, eax
je 0x4081cd
lea edx, [ebp - 4]
mov dword [ebp - 4], esi
mov ecx, edi
call fcn.00408fbf
mov esi, eax
test esi, esi
js 0x4081c2
push dword [ebp - 4]
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_EqualSid]
push dword [ebp - 4]
neg eax
sbb esi, esi
inc esi
call dword [sym.imp.KERNEL32.dll_LocalFree]
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_LocalFree]
jmp 0x4081e2
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x4081e2
movzx esi, si
or esi, 0x80070000
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x408200
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x408200
movzx esi, si
or esi, 0x80070000
pop edi
mov eax, esi
pop esi
leave
ret

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

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x148
mov eax, dword [0x40f014]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
xor edi, edi
mov eax, ecx
inc edi
mov dword [ebp - 0x134], eax
cmp dword [0x40f468], 0
mov ebx, edx
mov esi, 0x80004005
je 0x408608
push 0x40f46c
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov eax, dword [ebp - 0x134]
cmp edi, 0x1f4
jg 0x408647
push edi
push 0x4029d8
push eax
push 0x4029dc
push 0x104
push ebx
call fcn.00407275
add esp, 0x18
mov esi, eax
inc edi
test esi, esi
js 0x4086f8
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
mov eax, dword [ebp - 0x134]
jne 0x408608
test esi, esi
js 0x4086f8
and dword [ebp - 0x138], 0
lea eax, [ebp - 0x13c]
and dword [ebp - 0x13c], 0
lea edx, [ebp - 0x130]
push eax
lea eax, [ebp - 0x138]
push eax
lea eax, [ebp - 0x48]
push eax
lea eax, [ebp - 0x8c]
push eax
lea eax, [ebp - 0xd0]
push eax
lea ecx, [ebp - 0x148]
call fcn.004083d9
mov esi, eax
test esi, esi
js 0x4086f8
lea eax, [ebp - 0x148]
push eax
push ebx
push dword [ebp - 0x134]
call dword [sym.imp.KERNEL32.dll_CreateDirectoryExA]
test eax, eax
jne 0x4086c1
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x4086c3
movzx esi, si
or esi, 0x80070000
test esi, esi
js 0x4086ce
mov ecx, ebx
call fcn.00408206
mov esi, eax
cmp dword [ebp - 0x138], 0
je 0x4086e3
push dword [ebp - 0x138]
call dword [sym.imp.KERNEL32.dll_LocalFree]
cmp dword [ebp - 0x13c], 0
je 0x4086f8
push dword [ebp - 0x13c]
call dword [sym.imp.KERNEL32.dll_LocalFree]
cmp dword [0x40f468], 0
je 0x40870c
push 0x40f46c
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov ecx, dword [ebp - 4]
mov eax, esi
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0040de60
leave
ret 4
Function at 0x40871f
Capabilities:
Create directory

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [0x40f014]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
lea eax, [ebp - 0x14]
mov dword [ebp - 0x20], edx
push eax
mov dword [ebp - 0x24], ecx
mov esi, 0x80004005
xor ebx, ebx
xor edi, edi
call dword [sym.imp.RPCRT4.dll_UuidCreate]
test eax, eax
jne 0x408788
and dword [ebp - 0x18], ebx
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x14]
push eax
call dword [sym.imp.RPCRT4.dll_UuidToStringW]
test eax, eax
jne 0x408788
push dword [ebp - 0x18]
call dword [sym.imp.OLEAUT32.dll_SysReAllocString]
test eax, eax
je 0x408777
mov ebx, eax
jmp 0x40877c
mov edi, 0x8007000e
lea eax, [ebp - 0x18]
push eax
call dword [sym.imp.RPCRT4.dll_RpcStringFreeW]
jmp 0x408797
jg 0x40878e
mov edi, eax
jmp 0x408797
movzx edi, ax
or edi, 0x80070000
test edi, edi
js 0x408805
and dword [ebp - 0x1c], 0
lea eax, [ebp - 0x1c]
push eax
mov edx, ebx
call fcn.004076d1
test eax, eax
js 0x4087fe
push dword [ebp - 0x1c]
mov edi, dword [ebp - 0x24]
push edi
push 0x4029e8
push 0x104
push dword [ebp - 0x20]
call fcn.00407275
add esp, 0x14
mov esi, eax
push dword [ebp - 0x1c]
call dword [sym.imp.ole32.dll_CoTaskMemFree]
test esi, esi
js 0x4087fe
push 0
push dword [ebp - 0x20]
push edi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryExA]
test eax, eax
jne 0x4087fe
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x4087fe
movzx esi, si
or esi, 0x80070000
push ebx
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
mov ecx, dword [ebp - 4]
mov eax, esi
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0040de60
leave
ret 4
Function at 0x408878
Capabilities:
Copy file

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x634
mov eax, dword [0x40f014]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
mov edi, edx
mov dword [ebp - 0x630], ecx
or esi, 0xffffffff
call dword [sym.imp.ole32.dll_CoImpersonateClient]
test eax, eax
js 0x4089d6
push 0
push 0x80
push 3
push 0
push 1
push SysReAllocString
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
call dword [sym.imp.ole32.dll_CoRevertToSelf]
cmp esi, 0xffffffff
je 0x4089d6
test esi, esi
je 0x4089d6
mov ecx, edi
call fcn.004078de
mov dword [ebp - 0x634], eax
cmp eax, edi
je 0x4089d6
mov edi, 0x104
lea eax, [ebp - 0x414]
push edi
push eax
push 0xffffffffffffffff
push dword [ebp - 0x630]
push 8
push 0
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
test eax, eax
jne 0x408922
call fcn.00407457
mov edi, eax
jmp 0x4089db
push dword [ebp - 0x634]
lea eax, [ebp - 0x414]
push eax
push 0x4029f0
lea eax, [ebp - 0x20c]
push edi
push eax
call fcn.00403c91
mov edi, eax
add esp, 0x14
test edi, edi
js 0x4089db
lea ecx, [ebp - 0x20c]
call fcn.00408e67
mov edi, eax
test edi, edi
js 0x4089db
lea ecx, [ebp - 0x20c]
call fcn.00408ecf
push 0
push 0x10c
lea eax, [ebp - 0x62c]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetFinalPathNameByHandleW]
cmp eax, 3
je 0x4089d6
cmp eax, 8
je 0x4089d6
cmp eax, 0x57
je 0x4089d6
push 1
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x62c]
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileW]
test eax, eax
je 0x408916
lea ecx, [ebp - 0x20c]
call fcn.004080a9
mov edi, eax
test edi, edi
js 0x4089db
push dword [ebx]
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.OLEAUT32.dll_SysReAllocString]
mov dword [ebx], eax
jmp 0x4089db
mov edi, 0x80004005
cmp esi, 0xffffffff
je 0x4089eb
test esi, esi
je 0x4089eb
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 4]
mov eax, edi
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0040de60
leave
ret 4
Function at 0x4089fe
Capabilities:
Check if file exists
Copy file
Get file attributes

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x418
mov eax, dword [0x40f014]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
mov edi, edx
mov ebx, ecx
xor esi, esi
inc esi
mov ecx, dword [edi]
call fcn.004078de
mov dword [ebp - 0x418], eax
cmp eax, dword [edi]
je 0x408b0b
push 0x104
lea eax, [ebp - 0x414]
push eax
push 0xffffffffffffffff
push ebx
push 8
push 0
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
test eax, eax
jne 0x408a59
call fcn.00407457
jmp 0x408b10
mov ebx, dword [ebp - 0x418]
cmp esi, 0x1f4
jg 0x408b0b
push ebx
push esi
lea eax, [ebp - 0x414]
push eax
push 0x402a04
lea eax, [ebp - 0x20c]
push 0x104
push eax
call fcn.00403c91
add esp, 0x18
inc esi
test eax, eax
js 0x408aa4
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x408a5f
lea ecx, [ebp - 0x20c]
call fcn.0040d4dd
mov esi, eax
test esi, esi
js 0x408b07
lea ecx, [ebp - 0x20c]
call fcn.00408e67
mov esi, eax
test esi, esi
js 0x408b07
push 1
lea eax, [ebp - 0x20c]
push eax
push dword [edi]
call dword [sym.imp.KERNEL32.dll_CopyFileW]
test eax, eax
je 0x408a4f
lea ecx, [ebp - 0x20c]
call fcn.004080a9
mov esi, eax
test esi, esi
js 0x408b07
push dword [edi]
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.OLEAUT32.dll_SysReAllocString]
mov dword [edi], eax
mov eax, esi
jmp 0x408b10
mov eax, 0x80004005
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0040de60
leave
ret