joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4030fa
Capabilities:
Check for time delay via gettickcount

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x90
push ebx
push esi
mov esi, dword [ebp + 0x14]
push edi
mov edi, dword [ebp + 0x10]
mov dword [ebp - 8], esi
test edi, edi
jne 0x40311a
mov dword [ebp - 8], 0x8000
and dword [ebp - 4], 0
mov ebx, edi
test edi, edi
jne 0x403129
mov ebx, 0x410ea0
mov eax, dword [ebp + 8]
test eax, eax
jl 0x40313e
mov ecx, dword [0x42a278]
add ecx, eax
push ecx
call fcn.004032f5
lea eax, [ebp + 0x14]
push 4
push eax
call fcn.004032df
test eax, eax
je 0x403296
test byte [ebp + 0x17], 0x80
je 0x40327f
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ecx, 0x40ce10
mov dword [ebp - 0xc], eax
call fcn.00406787
and dword [ebp + 0x14], 0x7fffffff
mov eax, dword [ebp + 0x14]
mov dword [ebp + 8], eax
jle 0x4032d5
mov esi, 0x4000
cmp dword [ebp + 0x14], esi
jge 0x40318e
mov esi, dword [ebp + 0x14]
mov edi, 0x40cea0
push esi
push edi
call fcn.004032df
test eax, eax
je 0x403296
sub dword [ebp + 0x14], esi
mov dword [0x40ce28], edi
mov dword [0x40ce2c], esi
mov eax, dword [ebp - 8]
mov ecx, 0x40ce10
mov dword [0x40ce30], ebx
mov dword [0x40ce34], eax
call fcn.004067a7
test eax, eax
mov dword [ebp - 0x10], eax
jl 0x403277
mov esi, dword [0x40ce30]
sub esi, ebx
call dword [sym.imp.KERNEL32.dll_GetTickCount]
test byte [0x42a2d4], 1
mov edi, eax
je 0x403236
sub eax, dword [ebp - 0xc]
cmp eax, 0xc8
ja 0x4031fd
cmp dword [ebp + 0x14], 0
jne 0x403236
mov eax, dword [ebp + 8]
push dword [ebp + 8]
sub eax, dword [ebp + 0x14]
push 0x64
push eax
call dword [sym.imp.KERNEL32.dll_MulDiv]
push eax
lea eax, [ebp - 0x90]
push str....__d__
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0xc
lea eax, [ebp - 0x90]
push eax
push 0
call fcn.004052b0
mov dword [ebp - 0xc], edi
test esi, esi
je 0x40326b
cmp dword [ebp + 0x10], 0
jne 0x403253
push esi
push ebx
push dword [ebp + 0xc]
call fcn.00405df0
test eax, eax
je 0x40327b
add dword [ebp - 4], esi
jmp 0x40325f
add dword [ebp - 4], esi
sub dword [ebp - 8], esi
mov ebx, dword [0x40ce30]
cmp dword [ebp - 0x10], 1
jne 0x4031b1
jmp 0x4032d5
cmp dword [ebp + 0x14], 0
jg 0x403181
jmp 0x4032d5
push 0xfffffffffffffffc
jmp 0x403298
push 0xfffffffffffffffe
jmp 0x403298
test edi, edi
je 0x4032ca
cmp dword [ebp + 0x14], esi
jge 0x40328b
mov esi, dword [ebp + 0x14]
push esi
push edi
call fcn.004032df
test eax, eax
jne 0x4032d2
push 0xfffffffffffffffd
pop eax
jmp 0x4032d8
mov esi, dword [ebp - 8]
cmp dword [ebp + 0x14], esi
jge 0x4032a6
mov esi, dword [ebp + 0x14]
mov edi, 0x40cea0
push esi
push edi
call fcn.004032df
test eax, eax
je 0x403296
push esi
push edi
push dword [ebp + 0xc]
call fcn.00405df0
test eax, eax
je 0x40327b
add dword [ebp - 4], esi
sub dword [ebp + 0x14], esi
cmp dword [ebp + 0x14], 0
jg 0x40329b
jmp 0x4032d5
mov dword [ebp - 4], esi
mov eax, dword [ebp - 4]
pop edi
pop esi
pop ebx
leave
ret 0x10
Function at 0x40577f
Capabilities:
Create directory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
mov eax, 0x4083f0
and byte [ebp - 0x1f], 0
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x18], eax
lea eax, [ebp - 0x20]
and dword [ebp - 0x14], 0
and dword [ebp - 4], 0
mov dword [ebp - 8], eax
lea eax, [ebp - 0xc]
push esi
push eax
mov byte [ebp - 0x20], 1
push dword [ebp + 8]
mov word [ebp - 0x1e], 4
mov dword [ebp - 0x10], 0x4083e0
mov dword [ebp - 0xc], 0xc
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
je 0x4057d0
xor eax, eax
jmp 0x4057f7
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
cmp eax, 0xb7
jne 0x4057f7
lea eax, [ebp - 0x20]
push eax
push 0x80000007
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_SetFileSecurityW]
test eax, eax
jne 0x4057cc
call esi
pop esi
leave
ret 4

Function at 0x405831
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
lea eax, [ebp - 0x10]
mov dword [0x4266f0], 0x44
push eax
xor eax, eax
push 0x4266f0
push eax
push eax
push 0x4000000
push eax
push eax
push eax
push dword [ebp + 8]
push eax
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
test eax, eax
je 0x405870
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x10]
leave
ret 4

Function at 0x405874
Capabilities:
Create process on windows

Disassembly:
mov eax, dword [esp + 4]
push eax
and dword [eax + 0x24], 0
mov dword [eax], 0x3c
call dword [sym.imp.SHELL32.dll_ShellExecuteExW]
ret 4

Function at 0x405912
Capabilities:
Delete directory
Delete file
Set file attributes

Disassembly:
push esi
mov esi, dword [esp + 8]
push edi
push esi
call fcn.00405d19
mov edi, eax
cmp edi, 0xffffffff
je 0x405953
test byte [esp + 0x10], 1
push esi
je 0x405935
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
jmp 0x40593b
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
je 0x405944
xor eax, eax
inc eax
jmp 0x405955
test byte [esp + 0x10], 4
jne 0x405953
push edi
push esi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
xor eax, eax
pop edi
pop esi
ret 8
Function at 0x40595a
Capabilities:
Delete file
Enumerate files on windows
Enumerate files recursively

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x258
push ebx
mov ebx, dword [ebp + 0xc]
push esi
push edi
mov edi, dword [ebp + 8]
mov eax, ebx
and eax, 4
push edi
mov dword [ebp - 4], eax
call fcn.00405c25
test bl, 8
mov dword [ebp - 8], eax
je 0x405999
push edi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
neg eax
sbb eax, eax
inc eax
add dword [0x42a2a8], eax
jmp 0x405b16
mov dword [ebp + 8], ebx
and dword [ebp + 8], 1
je 0x4059b3
test eax, eax
je 0x405ac4
test bl, 2
je 0x405ac4
mov esi, 0x4256f0
push edi
push esi
call fcn.0040624c
cmp dword [ebp + 8], 0
je 0x4059d2
push str..
push esi
call sub.KERNEL32.dll_lstrcatW
jmp 0x4059d8
push edi
call fcn.00405b69
cmp word [edi], 0
jne 0x4059e8
cmp word [0x4256f0], 0x5c
jne 0x4059f3
push 0x40a014
push edi
call sub.KERNEL32.dll_lstrcatW
push edi
call sub.KERNEL32.dll_lstrlenW
lea ebx, [edi + eax*2]
lea eax, [ebp - 0x258]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov esi, eax
cmp esi, 0xffffffff
je 0x405ab9
cmp word [ebp - 0x22c], 0x2e
jne 0x405a3d
cmp word [ebp - 0x22a], 0
je 0x405a9c
cmp word [ebp - 0x22a], 0x2e
jne 0x405a3d
cmp word [ebp - 0x228], 0
je 0x405a9c
lea eax, [ebp - 0x22c]
push eax
push ebx
call fcn.0040624c
test byte [ebp - 0x258], 0x10
je 0x405a68
mov eax, dword [ebp + 0xc]
and eax, 3
cmp al, 3
jne 0x405a9c
push dword [ebp + 0xc]
push edi
call fcn.0040595a
jmp 0x405a9c
push dword [ebp - 4]
push edi
call fcn.00405912
test eax, eax
jne 0x405a94
cmp dword [ebp - 4], eax
je 0x405a8c
push edi
push 0xfffffffffffffff1
call fcn.004052b0
push 0
push edi
call fcn.00406012
jmp 0x405a9c
inc dword [0x42a2a8]
jmp 0x405a9c
push edi
push 0xfffffffffffffff2
call fcn.004052b0
lea eax, [ebp - 0x258]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x405a15
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
cmp dword [ebp + 8], 0
je 0x405ac4
and word [ebx - 2], 0
xor esi, esi
cmp dword [ebp + 8], esi
je 0x405b16
cmp dword [ebp - 8], esi
jne 0x405ad8
inc dword [0x42a2a8]
jmp 0x405b16
push edi
call fcn.0040658f
test eax, eax
je 0x405b16
push edi
call fcn.00405b1d
mov eax, dword [ebp - 4]
or al, 1
push eax
push edi
call fcn.00405912
test eax, eax
jne 0x405b0e
cmp dword [ebp - 4], esi
je 0x405ad0
push edi
push 0xfffffffffffffff1
call fcn.004052b0
push esi
push edi
call fcn.00406012
jmp 0x405b16
push edi
push 0xffffffffffffffe5
call fcn.004052b0
pop edi
pop esi
pop ebx
leave
ret 8
Function at 0x405c25
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push esi
push edi
push dword [esp + 0xc]
mov esi, 0x425ef0
push esi
call fcn.0040624c
push esi
call fcn.00405bc8
mov edi, eax
test edi, edi
jne 0x405c46
xor eax, eax
jmp 0x405c9e
push edi
call fcn.004064e0
test byte [0x42a21c], 0x80
je 0x405c63
mov ax, word [edi]
test ax, ax
je 0x405c42
cmp ax, 0x5c
je 0x405c42
sub edi, esi
sar edi, 1
jmp 0x405c7d
call fcn.0040658f
test eax, eax
je 0x405c77
test byte [eax], 0x10
je 0x405c42
push esi
call fcn.00405b69
push esi
call sub.KERNEL32.dll_lstrlenW
cmp eax, edi
push esi
jg 0x405c69
call fcn.00405b1d
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
xor ecx, ecx
cmp eax, 0xffffffff
setne cl
mov eax, ecx
pop edi
pop esi
ret 4

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

Disassembly:
push esi
push dword [esp + 8]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
mov esi, eax
cmp esi, 0xffffffff
je 0x405d38
and al, 0xfe
push eax
push dword [esp + 0xc]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
mov eax, esi
pop esi
ret 4

Function at 0x405d3e
Capabilities:
Get file attributes

Disassembly:
push dword [esp + 4]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
mov ecx, eax
push 0
inc ecx
neg ecx
sbb ecx, ecx
and ecx, eax
push ecx
push dword [esp + 0x14]
push 0
push 1
push dword [esp + 0x1c]
push dword [esp + 0x1c]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
ret 0xc

Function at 0x405d6d
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push esi
mov esi, dword [ebp + 8]
push edi
push 0x64
pop edi
mov eax, dword [0x40a558]
dec edi
mov dword [ebp - 8], eax
mov eax, dword [0x40a55c]
mov dword [ebp - 4], eax
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push 0x1a
xor edx, edx
pop ecx
div ecx
push esi
lea eax, [ebp - 8]
push 0
push eax
push dword [ebp + 0xc]
add word [ebp - 4], dx
call dword [sym.imp.KERNEL32.dll_GetTempFileNameW]
test eax, eax
jne 0x405dbd
test edi, edi
jne 0x405d7a
and word [esi], di
pop edi
pop esi
leave
ret 8
mov eax, esi
jmp 0x405db7
Function at 0x405e98
Capabilities:
Get file size

Disassembly:
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_GetShortPathNameW]
push ebp
push esi
mov esi, dword [esp + 0x14]
push edi
test esi, esi
mov dword [0x426d88], 0x55004e
mov dword [0x426d8c], 0x4c
mov edi, 0x400
mov ebp, 0x426d88
je 0x405eee
push 1
push 0
push esi
call fcn.00405d3e
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
push ebp
push esi
call ebx
test eax, eax
je 0x40600d
cmp eax, edi
jg 0x40600d
mov esi, 0x427588
push edi
push esi
push dword [esp + 0x1c]
call ebx
test eax, eax
je 0x40600d
cmp eax, edi
jg 0x40600d
push esi
push ebp
push str._ls_ls_r_n
push 0x426988
call dword [sym.imp.USER32.dll_wsprintfA]
mov ebx, eax
mov eax, dword [0x42a214]
add esp, 0x10
push dword [eax + 0x128]
push esi
call fcn.0040626e
push 4
push 0xc0000000
push esi
call fcn.00405d3e
mov ebp, eax
cmp ebp, 0xffffffff
mov dword [esp + 0x18], ebp
je 0x40600d
push 0
push ebp
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
lea eax, [edi + ebx + 0xa]
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov esi, eax
test esi, esi
je 0x406006
push edi
push esi
push ebp
call fcn.00405dc1
test eax, eax
je 0x406006
push str._Rename__r_n
push esi
call fcn.00405ca3
test eax, eax
jne 0x405fa4
lea eax, [esi + edi]
push str._Rename__r_n
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
add edi, 0xa
jmp 0x405fd9
add eax, 0xa
push 0x40a560
push eax
call fcn.00405ca3
mov ebp, eax
test ebp, ebp
je 0x405fd5
lea ecx, [esi + edi]
lea eax, [ecx + ebx]
jmp 0x405fc6
mov dl, byte [ecx]
mov byte [eax], dl
dec eax
dec ecx
cmp ecx, ebp
ja 0x405fc0
sub ebp, esi
inc ebp
mov eax, ebp
mov ebp, dword [esp + 0x18]
jmp 0x405fdb
mov ebp, dword [esp + 0x18]
mov eax, edi
push ebx
add eax, esi
push 0x426988
push eax
call fcn.00405cf9
xor eax, eax
push eax
push eax
push eax
push ebp
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
add edi, ebx
push edi
push esi
push ebp
call fcn.00405df0
push esi
call dword [sym.imp.KERNEL32.dll_GlobalFree]
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
pop ebx
ret

Function at 0x406012
Capabilities:
Move file

Disassembly:
push 5
push dword [esp + 0xc]
push dword [esp + 0xc]
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
test eax, eax
jne 0x406035
push dword [esp + 8]
push dword [esp + 8]
call fcn.00405e98
pop ecx
pop ecx
inc dword [0x42a2b0]
ret 8
Function at 0x40611a
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push ecx
lea eax, [ebp + 0x18]
push esi
push eax
mov eax, dword [ebp + 0x18]
neg eax
sbb eax, eax
mov dword [ebp - 4], 0x800
and eax, 0x100
or eax, 0x20019
push eax
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.004060b9
mov esi, dword [ebp + 0x14]
test eax, eax
jne 0x40618a
lea eax, [ebp - 4]
push edi
push eax
lea eax, [ebp + 0xc]
push esi
push eax
push 0
push dword [ebp + 0x10]
push dword [ebp + 0x18]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
push dword [ebp + 0x18]
mov edi, eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
and word [esi + 0x7fe], 0
test edi, edi
pop edi
jne 0x40618a
cmp dword [ebp + 0xc], 1
je 0x40618e
cmp dword [ebp + 0xc], 2
je 0x40618e
and word [esi], 0
pop esi
leave
ret 0x14
Function at 0x4065b6
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x23c
push esi
mov esi, 0x104
lea eax, [ebp - 0x23c]
push esi
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
cmp eax, esi
pop esi
jbe 0x4065da
xor eax, eax
test eax, eax
je 0x4065ed
cmp word [ebp + eax*2 - 0x23e], 0x5c
je 0x4065ed
xor ecx, ecx
jmp 0x4065f0
xor ecx, ecx
inc ecx
push dword [ebp + 8]
lea ecx, [ecx*2 + 0x40a014]
lea eax, [ebp + eax*2 - 0x23c]
push ecx
push str._s_S.dll
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x10
lea eax, [ebp - 0x23c]
push 8
push 0
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
leave
ret 4

Function at 0x406719
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
cmp dword [0x427d8c], 0
push esi
jne 0x406750
xor ecx, ecx
push 8
mov eax, ecx
pop esi
mov edx, eax
and dl, 1
neg dl
sbb edx, edx
and edx, 0xedb88320
shr eax, 1
xor eax, edx
dec esi
jne 0x40672a
mov dword [ecx*4 + 0x427d88], eax
inc ecx
cmp ecx, 0x100
jl 0x406725
mov edx, dword [esp + 0x10]
mov eax, dword [esp + 8]
test edx, edx
not eax
jbe 0x406781
mov ecx, dword [esp + 0xc]
push edi
movzx edi, byte [ecx]
mov esi, eax
and esi, 0xff
xor esi, edi
shr eax, 8
mov esi, dword [esi*4 + 0x427d88]
xor eax, esi
inc ecx
dec edx
jne 0x406763
pop edi
not eax
pop esi
ret 0xc
Function at 0x404f4a
Capabilities:
Accept command line arguments

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push esi
push edi
call dword [sym.imp.KERNEL32.dll_GetCommandLineW]
and dword [ebp - 4], 0
lea ecx, [ebp - 8]
and dword [ebp - 0xc], 0
lea edx, [ebp - 4]
push ecx
lea ecx, [ebp - 0xc]
mov dword [ebp - 8], eax
push ecx
mov ecx, eax
call fcn.00410398
mov esi, eax
test esi, esi
js 0x404ffa
mov ecx, dword [ebp - 8]
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0xc]
push eax
lea edx, [ebp - 4]
call fcn.00410398
mov esi, eax
test esi, esi
jne 0x404ff3
mov ebx, dword [sym.imp.KERNEL32.dll_lstrcmpW]
mov edi, dword [ebp - 4]
push 0x2f
pop ecx
movzx eax, word [edi]
cmp cx, ax
je 0x404fb1
push 0x2d
pop ecx
cmp cx, ax
jne 0x405024
lea esi, [edi + 2]
push esi
push str.standalone
call ebx
test eax, eax
jne 0x404fc5
mov eax, dword [ebp + 8]
jmp 0x404fd4
push esi
push str.standalone:temp
call ebx
test eax, eax
jne 0x40501c
mov eax, dword [ebp + 0xc]
mov ecx, dword [ebp - 8]
lea edx, [ebp - 4]
mov dword [eax], 1
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0xc]
push eax
call fcn.00410398
mov esi, eax
test esi, esi
je 0x404f9b
xor eax, eax
test esi, esi
cmovns esi, eax
mov edi, dword [ebp - 4]
test edi, edi
je 0x405011
push edi
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
push esi
push str.standalone:delete
call ebx
mov esi, 0x80070057
jmp 0x404ffd
Function at 0x40a083
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
mov eax, dword [ebp + 0xc]
push ebx
push esi
xor bl, bl
push edi
mov edi, dword [ebp + 8]
test eax, eax
jne 0x40a0f5
mov eax, dword [edi + 0xc]
lea edx, [ebp - 8]
push edx
push eax
mov ecx, dword [eax]
call dword [ecx + 0x40]
mov esi, eax
test esi, esi
js 0x40a1df
lea eax, [ebp + 0xc]
xor ebx, ebx
push eax
inc ebx
push ebx
push 0
push dword [edi + 0x14]
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
cmp esi, 0x80070002
je 0x40a1ea
cmp esi, 0x80070003
je 0x40a1ea
test esi, esi
js 0x40a1df
mov eax, dword [ebp + 0xc]
lea ecx, [ebp + 8]
mov dword [ebp + 8], 4
push ecx
lea ecx, [ebp - 4]
push ecx
push 0
push 0
push str.Size
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
test esi, esi
js 0x40a1d2
mov eax, dword [ebp - 4]
and dword [edi + 0x4c], 0
mov dword [edi + 0x48], eax
lea eax, [ebp + 8]
push eax
lea eax, [ebp - 4]
mov dword [ebp + 8], 4
push eax
push 0
push 0
push str.Progress
push dword [ebp + 0xc]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
test esi, esi
js 0x40a1d2
mov eax, dword [ebp - 4]
xor ecx, ecx
mov dword [edi + 0x50], eax
lea eax, [ebp + 8]
push eax
lea eax, [edi + 0x74]
mov dword [edi + 0x54], ecx
push eax
push ecx
push ecx
push str.LastAttemptHigh
push dword [ebp + 0xc]
mov dword [ebp + 8], 4
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
test esi, esi
js 0x40a1d2
lea eax, [ebp + 8]
mov dword [ebp + 8], 4
push eax
lea eax, [edi + 0x70]
push eax
push 0
push 0
push str.LastAttemptLow
push dword [ebp + 0xc]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
test bl, bl
je 0x40a1df
push dword [ebp + 0xc]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
xor eax, eax
mov esi, ebx
mov dword [edi + 0x48], eax
mov dword [edi + 0x4c], eax
mov dword [edi + 0x50], eax
mov dword [edi + 0x54], eax
mov dword [edi + 0x70], eax
mov dword [edi + 0x74], eax
jmp 0x40a1df
Function at 0x40a202
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push esi
push edi
mov edi, ecx
xor ebx, ebx
mov byte [ebp - 1], bl
cmp dword [edi + 0x44], ebx
je 0x40a21f
xor esi, esi
inc esi
jmp 0x40a3f1
mov ecx, dword [ebp + 8]
test ecx, ecx
jne 0x40a26d
mov eax, dword [edi + 0xc]
lea edx, [ebp - 0xc]
push edx
push eax
mov ecx, dword [eax]
call dword [ecx + 0x40]
mov esi, eax
test esi, esi
js 0x40a3f1
lea eax, [ebp + 8]
push eax
push 2
push ebx
push dword [edi + 0x14]
push dword [ebp - 0xc]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
test esi, esi
js 0x40a3f1
mov ecx, dword [ebp + 8]
mov byte [ebp - 1], 1
mov eax, dword [edi + 0x48]
push 4
mov dword [ebp - 8], eax
lea eax, [ebp - 8]
push eax
push 4
push ebx
mov ebx, dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
push str.Size
push ecx
call ebx
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
test esi, esi
js 0x40a3e2
mov eax, dword [edi + 0x50]
push 4
mov dword [ebp - 8], eax
lea eax, [ebp - 8]
push eax
push 4
push 0
push str.Progress
push dword [ebp + 8]
call ebx
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
test esi, esi
js 0x40a3e2
push 4
lea eax, [edi + 0x74]
push eax
push 4
push 0
push str.LastAttemptHigh
push dword [ebp + 8]
call ebx
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
test esi, esi
js 0x40a3e2
push 4
lea eax, [edi + 0x70]
push eax
push 4
push 0
push str.LastAttemptLow
push dword [ebp + 8]
call ebx
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
test esi, esi
js 0x40a3e2
push 4
lea eax, [edi + 0x6c]
push eax
push 4
push 0
push str.LastError
push dword [ebp + 8]
call ebx
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
test esi, esi
js 0x40a3e2
push 4
lea eax, [edi + 0x5c]
push eax
push 4
push 0
push str.StateCache
push dword [ebp + 8]
call ebx
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
test esi, esi
js 0x40a3e2
push 4
lea eax, [edi + 0x60]
push eax
push 4
push 0
push str.StateExtract
push dword [ebp + 8]
call ebx
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
test esi, esi
js 0x40a3e2
push 4
lea eax, [edi + 0x64]
push eax
push 4
push 0
push str.StateVerify
push dword [ebp + 8]
call ebx
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
test esi, esi
js 0x40a3e2
push 4
lea eax, [edi + 0x68]
push eax
push 4
push 0
push str.StateAvailable
push dword [ebp + 8]
call ebx
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
cmp byte [ebp - 1], 0
je 0x40a3f1
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
Function at 0x40c21b
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push ebx
push esi
mov esi, dword [ebp + 8]
xor ebx, ebx
cmp dword [esi + 0xc], ebx
jne 0x40c234
mov eax, 0x80004001
jmp 0x40c3a1
mov eax, dword [ebp + 0xc]
push edi
test byte [eax + 4], 2
je 0x40c383
push 0xffffffffffffffff
add eax, 0x108
lea ecx, [esi + 0x115c]
push eax
push 0x824
push ecx
call fcn.00414a70
add esp, 0x10
cmp eax, 0x50
jne 0x40c26d
mov edi, 0x8007007a
jmp 0x40c39e
push 0x824
mov edi, ebx
lea eax, [esi + 0x115c]
lea ebx, [esi + 0x114]
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
test eax, eax
jne 0x40c2a8
call dword [sym.imp.KERNEL32.dll_GetLastError]
movzx edi, ax
or edi, 0x80070000
test eax, eax
cmovle edi, eax
test edi, edi
js 0x40c39e
movzx ecx, word [ebx]
push 0x68
pop eax
push 0x74
pop edx
cmp ax, cx
jne 0x40c31b
movzx eax, word [esi + 0x116]
cmp dx, ax
jne 0x40c31b
cmp dx, word [esi + 0x118]
jne 0x40c2e9
push 0x70
pop edx
cmp dx, word [esi + 0x11a]
push 0x74
pop edx
jne 0x40c2e9
push 0x3a
pop edx
cmp dx, word [esi + 0x11c]
push 0x74
pop edx
je 0x40c344
cmp dx, ax
jne 0x40c31b
cmp dx, word [esi + 0x118]
jne 0x40c31b
push 0x70
pop eax
cmp ax, word [esi + 0x11a]
jne 0x40c31b
push 0x73
pop eax
cmp ax, word [esi + 0x11c]
jne 0x40c31b
push 0x3a
pop eax
cmp ax, word [esi + 0x11e]
je 0x40c344
push 0x66
pop eax
cmp ax, cx
jne 0x40c367
cmp dx, word [esi + 0x116]
jne 0x40c367
push 0x70
pop eax
cmp ax, word [esi + 0x118]
jne 0x40c367
push 0x3a
pop eax
cmp ax, word [esi + 0x11a]
jne 0x40c367
test cx, cx
je 0x40c353
xor eax, eax
add ebx, 2
cmp word [ebx], ax
jne 0x40c34b
push 0x2f
pop eax
cmp ax, word [ebx - 2]
je 0x40c374
mov word [ebx], ax
xor eax, eax
mov word [ebx + 2], ax
jmp 0x40c374
mov ecx, ebx
call fcn.0040e8b3
mov edi, eax
test edi, edi
js 0x40c39e
xor ebx, ebx
mov dword [esi + 0x21a4], ebx
test edi, edi
js 0x40c395
mov eax, dword [ebp + 0xc]
test byte [eax + 4], 4
je 0x40c395
mov eax, dword [eax + 0x1150]
mov dword [esi + 0x21a8], eax
push ebx
push esi
call fcn.0040c3a7
mov edi, eax
mov eax, edi
pop edi
pop esi
pop ebx
pop ebp
ret 0xc
Function at 0x40c3a7
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
mov ebx, dword [ebp + 8]
lea edx, [ebp - 8]
push esi
push edi
xor edi, edi
mov eax, dword [ebx + 0xc]
mov dword [ebp - 8], edi
mov dword [ebp - 4], edi
push edx
mov ecx, dword [eax]
push eax
call dword [ecx + 0x60]
mov esi, eax
test esi, esi
js 0x40c499
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 4]
push eax
push edi
push 0x2001f
push edi
push edi
push edi
lea eax, [ebx + 0x14]
push eax
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
test esi, esi
js 0x40c499
mov edi, dword [sym.imp.KERNEL32.dll_lstrlenW]
lea eax, [ebx + 0x115c]
push eax
call edi
push eax
lea esi, [ebx + 0x114]
lea ecx, [eax*2 + 2]
lea eax, [ebx + 0x115c]
mov dword [ebp + 8], ecx
push eax
push esi
call edi
push eax
push esi
push 1
push 0x7f
call dword [sym.imp.KERNEL32.dll_CompareStringW]
push dword [ebp + 8]
mov edi, dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
test eax, eax
lea eax, [ebx + 0x115c]
push eax
je 0x40c454
push 2
jmp 0x40c456
push 1
push 0
push str.Path
push dword [ebp - 4]
call edi
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
test esi, esi
js 0x40c499
push 4
lea eax, [ebx + 0x21a8]
push eax
push 4
push 0
push str.Priority
push dword [ebp - 4]
call edi
movzx esi, ax
or esi, 0x80070000
test eax, eax
cmovle esi, eax
cmp dword [ebp - 4], 0
je 0x40c4a8
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8