joyce8/EMBER2024-capa huggingface dataset:
Function at 0x1004b130
Capabilities:
Terminate thread

Disassembly:
sub esp, 8
push esi
mov esi, ecx
mov eax, dword [esi + 8]
test eax, eax
jne 0x1004b144
xor eax, eax
pop esi
add esp, 8
ret
mov eax, dword [esi + 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_SetEvent]
mov ecx, dword [esi + 0x14]
mov eax, dword [esi + 0x18]
mov edx, dword [esi + 8]
mov dword [esp + 4], ecx
push eax
lea ecx, [esp + 8]
push 0
push ecx
push 2
mov dword [esp + 0x18], edx
call dword [sym.imp.KERNEL32.dll_WaitForMultipleObjects]
mov edx, dword [esi + 0x1c]
mov eax, dword [esi + 8]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0x102
jne 0x1004b190
mov ecx, dword [esi + 8]
push 0
push ecx
call dword [sym.imp.KERNEL32.dll_TerminateThread]
mov edx, dword [esi + 0x10]
push edi
mov edi, dword [sym.imp.KERNEL32.dll_ResetEvent]
push edx
call edi
mov eax, dword [esi + 0x14]
push eax
call edi
mov dword [esi + 0xc], 0
pop edi
mov eax, 1
pop esi
add esp, 8
ret

Function at 0x1004b500
Capabilities:
Get user security identifier

Disassembly:
sub esp, 8
push ebx
push ebp
mov ebp, dword [esp + 0x14]
lea eax, [esp + 0x18]
push edi
mov edi, dword [esp + 0x1c]
lea ecx, [esp + 0xc]
xor ebx, ebx
push eax
push ecx
lea edx, [esp + 0x18]
push ebx
push edx
push ebx
push ebp
push ebx
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x28], ebx
mov dword [edi], ebx
call dword [sym.imp.ADVAPI32.dll_LookupAccountNameW]
test eax, eax
jne 0x1004b54b
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
je 0x1004b54b
pop edi
pop ebp
xor eax, eax
pop ebx
add esp, 8
ret
mov eax, dword [esp + 0x10]
push esi
push eax
call fcn.1004e2e8
mov ecx, dword [esp + 0x14]
mov dword [edi], eax
lea edx, [ecx + ecx]
push edx
call fcn.1004e2e8
mov esi, eax
mov eax, dword [edi]
add esp, 8
test eax, eax
je 0x1004b590
test esi, esi
je 0x1004b5a1
lea ecx, [esp + 0x20]
lea edx, [esp + 0x10]
push ecx
push edx
lea ecx, [esp + 0x1c]
push esi
push ecx
push eax
push ebp
push 0
call dword [sym.imp.ADVAPI32.dll_LookupAccountNameW]
mov ebx, eax
test esi, esi
je 0x1004b59d
push esi
call fcn.1004e2f6
add esp, 4
test ebx, ebx
jne 0x1004b5b0
mov edi, dword [edi]
test edi, edi
je 0x1004b5b0
push edi
call fcn.1004e2f6
add esp, 4
pop esi
pop edi
mov eax, ebx
pop ebp
pop ebx
add esp, 8
ret
Function at 0x10066de0
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x100c19b8
push 0x1004f898
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x10
push ebx
push esi
push edi
mov dword [ebp - 0x18], esp
mov ecx, dword [ebp + 8]
xor edx, edx
cmp ecx, edx
je 0x10066e72
mov dword [ebp - 4], edx
mov dword [ebp - 0x1c], edx
mov dword [ebp - 0x20], edx
mov dword [ebp - 0x1c], ecx
cmp word [ecx], 0x5a4d
jne 0x10066e6b
mov eax, dword [ecx + 0x3c]
add eax, ecx
mov dword [ebp - 0x20], eax
cmp dword [eax], 0x4550
jne 0x10066e6b
cmp word [eax + 0x14], dx
je 0x10066e6b
cmp dword [ebp + 0xc], edx
je 0x10066e45
cmp word [eax + 4], 0x14c
jne 0x10066e6b
mov dword [ebp - 4], 0xffffffff
mov eax, 1
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov dword [ebp - 4], 0xffffffff
xor eax, eax
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x10066f60
Capabilities:
Enumerate pe sections

Disassembly:
push ebx
mov ebx, dword [esp + 8]
push ebp
push esi
test ebx, ebx
push edi
je 0x10066fad
mov edi, dword [esp + 0x18]
test edi, edi
je 0x10066fad
mov eax, dword [ebx + 0x3c]
xor ecx, ecx
add eax, ebx
xor edx, edx
mov cx, word [eax + 0x14]
mov dx, word [eax + 6]
lea esi, [ecx + eax + 0x18]
xor ecx, ecx
test edx, edx
mov dword [esp + 0x14], esi
jbe 0x10066fad
lea eax, [esi + 0x10]
mov esi, dword [eax - 4]
cmp edi, esi
jb 0x10066fa5
mov ebp, dword [eax]
add ebp, esi
cmp edi, ebp
jb 0x10066fb4
inc ecx
add eax, 0x28
cmp ecx, edx
jb 0x10066f96
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
ret
mov eax, dword [esp + 0x14]
lea edx, [ecx + ecx*4]
mov esi, dword [eax + edx*8 + 0xc]
lea ecx, [eax + edx*8]
mov eax, dword [eax + edx*8 + 0x14]
sub eax, esi
add eax, ebx
add eax, edi
pop edi
pop esi
pop ebp
pop ebx
ret
Function at 0x10067880
Capabilities:
Allocate or change rwx memory
Execute shellcode via indirect call

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x100c19c8
push 0x1004f898
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x20
push ebx
push esi
push edi
mov dword [ebp - 0x18], esp
xor ebx, ebx
mov dword [ebp - 0x20], ebx
lea eax, [ebp - 0x20]
push eax
mov edi, dword [ebp + 0x14]
push edi
mov ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp + 8]
push edx
call fcn.10067000
add esp, 0x10
mov esi, eax
cmp esi, ebx
je 0x10067933
mov eax, dword [esi]
push eax
mov eax, dword [ebp - 0x20]
push eax
call edi
add esp, 8
mov dword [ebp - 0x24], eax
mov edi, dword [ebp + 0x10]
sub edi, dword [ebp - 0x20]
mov dword [ebp - 4], ebx
mov dword [ebp - 0x30], ebx
lea ecx, [ebp - 0x30]
push ecx
push 0x40
push 4
push esi
mov ebx, dword [sym.imp.KERNEL32.dll_VirtualProtect]
call ebx
test eax, eax
je 0x1006792c
mov dword [esi], edi
lea edx, [ebp - 0x30]
push edx
mov eax, dword [ebp - 0x30]
push eax
push 4
push esi
call ebx
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x24]
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov dword [ebp - 4], 0xffffffff
xor eax, eax
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x100680c0
Capabilities:
Access peb ldr_data
Get kernel32 base address

Disassembly:
push 0xffffffffffffffff
push 0x100bdd2c
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
push ecx
mov eax, dword [0x100c08b8]
push ebx
push ebp
push esi
mov esi, ecx
push edi
mov dword [esp + 0x10], esi
lea edi, [esi + 8]
mov dword [edi], eax
mov ecx, dword [0x100c08b8]
lea ebp, [esi + 0x18]
xor ebx, ebx
mov dword [esp + 0x1c], ebx
mov dword [ebp], ecx
mov edx, dword [0x100c08b8]
mov dword [esi + 0x20], edx
lea ecx, [esi + 0x28]
mov byte [esp + 0x1c], 2
call fcn.10088b30
mov eax, dword [esp + 0x24]
mov ecx, edi
push eax
mov byte [esp + 0x20], 3
mov dword [esi], 0x100c19e4
mov dword [esi + 4], ebx
mov dword [esi + 0xc], ebx
mov dword [esi + 0x10], ebx
mov dword [esi + 0x14], ebx
mov dword [esi + 0x1c], ebx
mov word [esi + 0x24], 0xffff
call fcn.1003dc20
mov eax, dword [esp + 0x28]
mov cx, word [esp + 0x30]
test eax, 0xffff0000
mov word [esi + 0x24], cx
mov dword [esi + 0x14], eax
je 0x10068163
push eax
mov ecx, ebp
call fcn.1003dc20
mov edx, dword [ebp]
mov dword [esi + 0x14], edx
mov eax, dword [esp + 0x2c]
test eax, 0xffff0000
mov dword [esi + 0x1c], eax
je 0x10068181
lea edi, [esi + 0x20]
push eax
mov ecx, edi
call fcn.1003dc20
mov eax, dword [edi]
mov dword [esi + 0x1c], eax
mov ecx, dword [esp + 0x14]
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x10
ret 0x10
Function at 0x1006be60
Capabilities:
Check os version
Get system information on windows

Disassembly:
mov eax, dword [0x100fad68]
sub esp, 0x114
test eax, eax
jne 0x1006bfad
push esi
mov esi, dword [sym.imp.KERNEL32.dll_GetVersionExW]
push edi
push 0x100fab00
mov dword [0x100fad68], 1
mov dword [0x100fab00], 0x114
call esi
mov edx, dword [0x100fab10]
xor eax, eax
cmp edx, 2
sete al
test eax, eax
mov dword [0x100e63a0], eax
je 0x1006bf88
push ebx
push 0x100fac18
mov dword [0x100fac18], 0x11c
call esi
mov ebx, dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push 0x100e728c
call ebx
mov edi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov esi, eax
push str.GetNativeSystemInfo
push esi
call edi
push str.GetProductInfo
push esi
mov dword [0x100fad5c], eax
call edi
mov dword [0x100fad60], eax
mov eax, dword [0x100fad5c]
test eax, eax
push 0x100fad38
je 0x1006bf04
call eax
jmp 0x1006bf0a
call dword [sym.imp.KERNEL32.dll_GetSystemInfo]
mov eax, dword [0x100fac1c]
cmp eax, 6
jae 0x1006bf22
cmp eax, 5
jne 0x1006bf36
cmp dword [0x100fac20], 2
jb 0x1006bf36
cmp word [0x100fad38], 9
jne 0x1006bf36
mov dword [0x100faaf4], 1
push str.Ntdll.dll
call ebx
test eax, eax
pop ebx
je 0x1006bf54
push str.RtlGetVersion
push eax
call edi
mov edx, eax
mov dword [0x100fad64], edx
jmp 0x1006bf5a
mov edx, dword [0x100fad64]
test edx, edx
je 0x1006bf88
mov ecx, 0x44
xor eax, eax
lea edi, [esp + 0xc]
rep stosd dword es:[edi], eax
lea eax, [esp + 8]
mov dword [esp + 8], 0x114
push eax
call edx
test eax, eax
jne 0x1006bf88
mov ecx, dword [esp + 0x14]
mov dword [0x100fab0c], ecx
push 0x100fab08
push 0x100fab04
call fcn.1006c350
add esp, 8
call fcn.1006bfc0
pop edi
mov eax, 1
pop esi
add esp, 0x114
ret
mov eax, 1
add esp, 0x114
ret
Function at 0x1006d1e0
Capabilities:
Get common file path
Get file version info

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x100c1a50
push 0x1004f898
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x434
push ebx
push esi
push edi
mov dword [ebp - 0x18], esp
mov eax, dword [0x100fad6c]
xor ebx, ebx
cmp eax, ebx
jne 0x1006d340
mov word [ebp - 0x220], bx
mov ecx, 0x81
xor eax, eax
lea edi, [ebp - 0x21e]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
push 0x104
lea eax, [ebp - 0x220]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
test eax, eax
je 0x1006d33b
mov word [ebp - 0x42c], bx
mov ecx, 0x81
xor eax, eax
lea edi, [ebp - 0x42a]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
push str.user32.dll
lea ecx, [ebp - 0x220]
push ecx
push 0x100e22d0
lea edx, [ebp - 0x42c]
push edx
call fcn.1004f648
add esp, 0x10
mov dword [ebp - 0x434], ebx
lea eax, [ebp - 0x434]
push eax
lea ecx, [ebp - 0x42c]
push ecx
call sub.VERSION.dll_GetFileVersionInfoSizeW
mov dword [ebp - 0x224], eax
push eax
call fcn.1004e2e8
add esp, 4
mov esi, eax
mov dword [ebp - 0x440], esi
cmp esi, ebx
je 0x1006d33b
push esi
mov edx, dword [ebp - 0x224]
push edx
mov eax, dword [ebp - 0x434]
push eax
lea ecx, [ebp - 0x42c]
push ecx
call sub.VERSION.dll_GetFileVersionInfoW
test eax, eax
je 0x1006d332
mov dword [ebp - 0x438], ebx
lea edx, [ebp - 0x224]
push edx
lea eax, [ebp - 0x438]
push eax
push 0x100e7468
push esi
call sub.VERSION.dll_VerQueryValueW
test eax, eax
je 0x1006d332
mov dword [ebp - 4], ebx
mov eax, dword [ebp - 0x438]
mov dword [ebp - 0x43c], eax
mov ecx, dword [eax]
mov dword [0x100fad6c], ecx
mov dword [ebp - 4], 0xffffffff
jmp 0x1006d332
push esi
call fcn.1004e2f6
add esp, 4
mov eax, dword [0x100fad6c]
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x1006f9e0
Capabilities:
Get common file path

Disassembly:
sub esp, 0x208
push ebx
push esi
push edi
mov ecx, 0x81
xor eax, eax
lea edi, [esp + 0xe]
mov word [esp + 0xc], 0
push 0x104
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [esp + 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
test eax, eax
jbe 0x1006faa0
lea ecx, [esp + 0xc]
push 0x5c
push ecx
call fcn.1004e33e
add esp, 8
test eax, eax
je 0x1006fa2f
mov word [eax], 0
mov edi, dword [esp + 0x218]
test edi, edi
je 0x1006fa99
mov ebx, dword [esp + 0x21c]
test ebx, ebx
je 0x1006fa99
lea edx, [esp + 0xc]
test edx, edx
je 0x1006fa99
mov eax, dword [esp + 0x220]
mov esi, 0x7a
test eax, eax
je 0x1006fa76
push eax
lea eax, [esp + 0x10]
push eax
push 0x100e22d0
push ebx
push edi
call fcn.1004f495
add esp, 0x14
xor esi, esi
jmp 0x1006faa8
lea ecx, [esp + 0xc]
push ecx
call fcn.1004e37e
add esp, 4
cmp ebx, eax
jbe 0x1006faa8
lea edx, [esp + 0xc]
push edx
push edi
call fcn.1004e9d9
add esp, 8
xor esi, esi
jmp 0x1006faa8
mov esi, 0x57
jmp 0x1006faa8
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
mov dword [0x100fade0], esi
je 0x1006fab9
push esi
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
pop edi
test esi, esi
pop esi
pop ebx
sete al
add esp, 0x208
ret

Function at 0x1006fad0
Capabilities:
Get common file path

Disassembly:
sub esp, 0x104
push ebx
push esi
push edi
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0xd]
mov byte [esp + 0xc], 0
push 0x104
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea eax, [esp + 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
test eax, eax
jbe 0x1006fba3
lea ecx, [esp + 0xc]
push 0x5c
push ecx
call fcn.1004f1f0
add esp, 8
test eax, eax
je 0x1006fb1c
mov byte [eax], 0
mov ebx, dword [esp + 0x114]
test ebx, ebx
je 0x1006fb9c
mov esi, dword [esp + 0x118]
test esi, esi
je 0x1006fb9c
lea edx, [esp + 0xc]
test edx, edx
je 0x1006fb9c
mov eax, dword [esp + 0x11c]
mov edx, 0x7a
test eax, eax
je 0x1006fb65
push eax
lea eax, [esp + 0x10]
push eax
push 0x100e74c4
push esi
push ebx
call fcn.1008aeac
add esp, 0x14
xor edx, edx
mov esi, edx
jmp 0x1006fbab
lea edi, [esp + 0xc]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp esi, ecx
jbe 0x1006fb98
lea edi, [esp + 0xc]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov edx, ecx
mov esi, edi
mov edi, ebx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
xor edx, edx
rep movsb byte es:[edi], byte [esi]
mov esi, edx
jmp 0x1006fbab
mov esi, 0x57
jmp 0x1006fbab
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
mov dword [0x100fade0], esi
je 0x1006fbbc
push esi
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
pop edi
test esi, esi
pop esi
pop ebx
sete al
add esp, 0x104
ret
Function at 0x1006fbd0
Capabilities:
Get common file path

Disassembly:
sub esp, 0x208
push ebx
push esi
push edi
mov ecx, 0x81
xor eax, eax
lea edi, [esp + 0xe]
mov word [esp + 0xc], 0
push 0x104
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [esp + 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
test eax, eax
jbe 0x1006fc90
lea ecx, [esp + 0xc]
push 0x5c
push ecx
call fcn.1004e33e
add esp, 8
test eax, eax
je 0x1006fc1f
mov word [eax], 0
mov edi, dword [esp + 0x218]
test edi, edi
je 0x1006fc89
mov ebx, dword [esp + 0x21c]
test ebx, ebx
je 0x1006fc89
lea edx, [esp + 0xc]
test edx, edx
je 0x1006fc89
mov eax, dword [esp + 0x220]
mov esi, 0x7a
test eax, eax
je 0x1006fc66
push eax
lea eax, [esp + 0x10]
push eax
push 0x100e22d0
push ebx
push edi
call fcn.1004f495
add esp, 0x14
xor esi, esi
jmp 0x1006fc98
lea ecx, [esp + 0xc]
push ecx
call fcn.1004e37e
add esp, 4
cmp ebx, eax
jbe 0x1006fc98
lea edx, [esp + 0xc]
push edx
push edi
call fcn.1004e9d9
add esp, 8
xor esi, esi
jmp 0x1006fc98
mov esi, 0x57
jmp 0x1006fc98
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
mov dword [0x100fade0], esi
je 0x1006fca9
push esi
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
pop edi
test esi, esi
pop esi
pop ebx
sete al
add esp, 0x208
ret

Function at 0x10074ac0
Capabilities:
Query environment variable

Disassembly:
sub esp, 0x410
push edi
mov ecx, 0x81
xor eax, eax
lea edi, [esp + 6]
mov word [esp + 4], 0
push 0x104
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [esp + 8]
push eax
push str.USERPROFILE
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
test eax, eax
jbe 0x10074bfa
cmp eax, 0x104
jae 0x10074bfa
lea ecx, [esp + 4]
push esi
push ecx
call fcn.1006ed90
add esp, 4
test eax, eax
je 0x10074b81
mov ecx, 0x81
xor eax, eax
lea edi, [esp + 0x212]
mov word [esp + 0x210], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea edx, [esp + 0x210]
push 0x104
lea eax, [esp + 0xc]
push edx
push eax
call fcn.1006ea50
lea ecx, [esp + 0x21c]
push ecx
call fcn.1004e37e
mov esi, eax
add esp, 0x10
cmp esi, 0x104
jge 0x10074b81
lea edx, [esp + 0x210]
push esi
lea eax, [esp + 0xc]
push edx
push eax
call fcn.1004e301
add esp, 0xc
mov word [esp + esi*2 + 8], 0
mov edi, dword [esp + 0x41c]
test edi, edi
je 0x10074bec
mov esi, dword [esp + 0x420]
test esi, esi
je 0x10074bec
lea ecx, [esp + 8]
test ecx, ecx
je 0x10074bec
mov eax, dword [esp + 0x424]
test eax, eax
je 0x10074bcd
lea edx, [esp + 8]
push eax
push edx
push 0x100e22d0
push esi
push edi
call fcn.1004f495
add esp, 0x14
mov eax, 1
pop esi
pop edi
add esp, 0x410
ret
lea eax, [esp + 8]
push eax
call fcn.1004e37e
add esp, 4
cmp esi, eax
jbe 0x10074bec
lea ecx, [esp + 8]
push ecx
push edi
call fcn.1004e9d9
add esp, 8
pop esi
mov eax, 1
pop edi
add esp, 0x410
ret
xor eax, eax
pop edi
add esp, 0x410
ret
Function at 0x10077dd0
Capabilities:
Check if file exists
Create directory
Delete file
Get file attributes
Set file attributes

Disassembly:
sub esp, 0x104
push ebx
mov ebx, dword [esp + 0x10c]
test ebx, ebx
jne 0x10077dec
xor eax, eax
pop ebx
add esp, 0x104
ret
push ebp
push esi
push edi
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0x11]
mov byte [esp + 0x10], 0
push 0x103
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea eax, [esp + 0x14]
push ebx
push eax
mov ebp, 1
call fcn.1004fda0
lea ecx, [esp + 0x1c]
push 0x5c
push ecx
call fcn.1004fce0
mov esi, eax
lea edi, [esp + 0x24]
or ecx, 0xffffffff
xor eax, eax
add esp, 0x14
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp ecx, 2
jbe 0x10077e70
cmp byte [esp + 0x10], 0x5c
jne 0x10077e70
cmp byte [esp + 0x11], 0x5c
jne 0x10077e70
lea edx, [esp + 0x12]
push 0x5c
push edx
call fcn.1004fce0
add esp, 8
test eax, eax
je 0x10077eee
inc eax
push 0x5c
push eax
call fcn.1004fce0
add esp, 8
mov esi, eax
test esi, esi
je 0x10077eee
lea eax, [esp + 0x10]
mov byte [esi], 0
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
mov ebx, eax
mov edi, ebx
and edi, 0x10
jne 0x10077eb2
test bl, 1
je 0x10077ea1
mov ecx, ebx
lea edx, [esp + 0x10]
and ecx, 0xfffffffe
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
lea eax, [esp + 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov ebp, eax
test ebp, ebp
je 0x10077f24
cmp ebx, 0xffffffff
je 0x10077ebb
test edi, edi
jne 0x10077eca
lea ecx, [esp + 0x10]
push 0
push ecx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
mov ebp, eax
test ebp, ebp
je 0x10077f24
mov byte [esi], 0x5c
inc esi
push 0x5c
push esi
call fcn.1004fce0
mov esi, eax
add esp, 8
test esi, esi
jne 0x10077e74
test ebp, ebp
je 0x10077f24
mov ebx, dword [esp + 0x118]
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x10077f19
test al, 0x10
jne 0x10077f24
test al, 1
je 0x10077f0c
and al, 0xfe
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
push ebx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov ebp, eax
test ebp, ebp
je 0x10077f24
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
mov ebp, eax
pop edi
mov eax, ebp
pop esi
pop ebp
pop ebx
add esp, 0x104
ret
Function at 0x10077f40
Capabilities:
Check if file exists
Create directory
Delete file
Get file attributes
Set file attributes

Disassembly:
sub esp, 0x208
push ebx
mov ebx, dword [esp + 0x210]
test ebx, ebx
jne 0x10077f5c
xor eax, eax
pop ebx
add esp, 0x208
ret
push ebp
push esi
push edi
mov ecx, 0x81
xor eax, eax
lea edi, [esp + 0x12]
mov word [esp + 0x10], 0
push 0x103
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [esp + 0x14]
push ebx
push eax
mov ebp, 1
call fcn.1004e301
mov edi, 0x5c
lea ecx, [esp + 0x1c]
push edi
push ecx
call fcn.1004e39b
lea edx, [esp + 0x24]
mov esi, eax
push edx
call fcn.1004e37e
add esp, 0x18
cmp eax, 2
jbe 0x10077fe1
cmp word [esp + 0x10], di
jne 0x10077fe1
cmp word [esp + 0x12], di
jne 0x10077fe1
lea eax, [esp + 0x14]
push edi
push eax
call fcn.1004e39b
add esp, 8
test eax, eax
je 0x10078069
add eax, 2
push edi
push eax
call fcn.1004e39b
add esp, 8
mov esi, eax
test esi, esi
je 0x10078069
lea ecx, [esp + 0x10]
mov word [esi], 0
push ecx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
mov ebx, eax
mov edi, ebx
and edi, 0x10
jne 0x10078029
test bl, 1
je 0x10078018
mov edx, ebx
lea eax, [esp + 0x10]
and edx, 0xfffffffe
push edx
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
lea ecx, [esp + 0x10]
push ecx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov ebp, eax
test ebp, ebp
je 0x1007809f
cmp ebx, 0xffffffff
je 0x10078032
test edi, edi
jne 0x10078041
lea edx, [esp + 0x10]
push 0
push edx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
mov ebp, eax
test ebp, ebp
je 0x1007809f
mov word [esi], 0x5c
add esi, 2
push 0x5c
push esi
call fcn.1004e39b
mov esi, eax
add esp, 8
test esi, esi
jne 0x10077fe9
test ebp, ebp
je 0x1007809f
mov ebx, dword [esp + 0x21c]
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x10078094
test al, 0x10
jne 0x1007809f
test al, 1
je 0x10078087
and al, 0xfe
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
push ebx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov ebp, eax
test ebp, ebp
je 0x1007809f
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
mov ebp, eax
pop edi
mov eax, ebp
pop esi
pop ebp
pop ebx
add esp, 0x208
ret
Function at 0x10078490
Capabilities:
Check if file exists
Create directory
Delete file
Get file attributes
Set file attributes

Disassembly:
sub esp, 0x208
push ebx
mov ebx, dword [esp + 0x210]
push ebp
push esi
test ebx, ebx
push edi
jne 0x100784c4
push 0x57
mov dword [0x100fade0], 0x57
call dword [sym.imp.KERNEL32.dll_SetLastError]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x208
ret
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x100784eb
test al, 0x10
jne 0x1007865d
push 0x80
push ebx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
push ebx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x1007865d
mov ecx, 0x81
lea edi, [esp + 0x12]
mov word [esp + 0x10], ax
push 0x103
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [esp + 0x14]
push ebx
push eax
mov ebp, 1
call fcn.1004e301
mov edi, 0x5c
lea ecx, [esp + 0x1c]
push edi
push ecx
call fcn.1004e39b
lea edx, [esp + 0x24]
mov esi, eax
push edx
call fcn.1004e37e
add esp, 0x18
cmp eax, 2
jbe 0x1007857a
cmp word [esp + 0x10], di
jne 0x1007857a
cmp word [esp + 0x12], di
jne 0x1007857a
lea eax, [esp + 0x14]
push edi
push eax
call fcn.1004e39b
add esp, 8
test eax, eax
je 0x10078602
add eax, 2
push edi
push eax
call fcn.1004e39b
add esp, 8
mov esi, eax
test esi, esi
je 0x10078602
lea ecx, [esp + 0x10]
mov word [esi], 0
push ecx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
mov ebx, eax
mov edi, ebx
and edi, 0x10
jne 0x100785c2
test bl, 1
je 0x100785b1
mov edx, ebx
lea eax, [esp + 0x10]
and edx, 0xfffffffe
push edx
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
lea ecx, [esp + 0x10]
push ecx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov ebp, eax
test ebp, ebp
je 0x1007863a
cmp ebx, 0xffffffff
je 0x100785cb
test edi, edi
jne 0x100785da
lea edx, [esp + 0x10]
push 0
push edx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
mov ebp, eax
test ebp, ebp
je 0x1007863a
mov word [esi], 0x5c
add esi, 2
push 0x5c
push esi
call fcn.1004e39b
mov esi, eax
add esp, 8
test esi, esi
jne 0x10078582
test ebp, ebp
je 0x1007863a
mov ebx, dword [esp + 0x21c]
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x1007862b
test al, 0x10
jne 0x10078636
test al, 1
je 0x10078620
and al, 0xfe
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
push ebx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
je 0x1007863a
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
mov ebp, eax
test ebp, ebp
jne 0x1007865d
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
mov dword [0x100fade0], eax
je 0x10078650
push eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x208
ret
mov eax, dword [esp + 0x220]
test eax, eax
je 0x10078670
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x208
ret