joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4ad07b46
Capabilities:
Write file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
mov ecx, dword [ebp + 0xc]
mov eax, dword [ecx + 0x1c]
test eax, eax
mov dword [ebp - 4], 0x1a
je 0x4ad15e37
push esi
push edi
push eax
call fcn.4ad07bcf
test eax, eax
mov edi, dword [ebp + 0x14]
mov esi, dword [sym.imp.msvcrt.dll__get_osfhandle]
jne 0x4ad15e3e
mov eax, dword [ebp + 8]
test eax, eax
je 0x4ad07bb8
test byte [eax + 0x18], 0x80
jne 0x4ad07bb8
push edi
call fcn.4ad02c7d
test eax, eax
jne 0x4ad07bb8
mov eax, dword [0x4ad33b3c]
cmp eax, 3
je 0x4ad07bb8
cmp dword [ebp + 0x18], 0
je 0x4ad07bb8
cmp eax, 2
je 0x4ad07bb8
push dword [ebp + 0x18]
push 0
push 0
push edi
call esi
pop ecx
push eax
call dword [sym.imp.KERNEL32.dll_SetFileTime]
push edi
call fcn.4ad02e18
inc dword [0x4ad33b60]
pop edi
pop esi
leave
ret 0x14
mov eax, ecx
jmp 0x4ad07b61
push edi
call fcn.4ad02c7d
test eax, eax
jne 0x4ad07b7a
push eax
lea eax, [ebp + 0xc]
push eax
push 1
lea eax, [ebp - 4]
push eax
push edi
call esi
pop ecx
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
jmp 0x4ad07b7a

Function at 0x4ad07cdf
Capabilities:
Delete file
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ebx
push esi
mov esi, dword [ebp + 0x14]
push edi
xor edi, edi
push edi
push esi
push dword [ebp + 0x10]
mov dword [ebp - 4], edi
push dword [ebp + 0xc]
mov dword [0x4ad33b18], edi
push dword [ebp + 8]
call dword [sym.imp.msvcrt.dll__get_osfhandle]
pop ecx
push eax
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
je 0x4ad15f30
mov edx, dword [esi]
cmp edx, edi
je 0x4ad15ee3
mov ecx, dword [ebp + 0x18]
mov eax, dword [ecx + 0x18]
test ah, 0xc0
jne 0x4ad07d4d
cmp edx, 2
jb 0x4ad07d45
mov edx, dword [ebp + 0xc]
cmp word [edx], 0xfeff
je 0x4ad15f03
or eax, 0x8000
mov dword [ecx + 0x18], eax
mov ecx, dword [ecx + 0x18]
mov eax, 0x8002
xor ebx, ebx
and ecx, eax
inc ebx
cmp ecx, eax
je 0x4ad15f0d
mov eax, ebx
pop edi
pop esi
pop ebx
leave
ret 0x1c
call ebx
cmp eax, 0x3e3
je 0x4ad15f30
mov edx, dword [esi]
cmp edx, edi
jne 0x4ad07d27
mov dword [0x4ad2ba04], edi
xor eax, eax
jmp 0x4ad07d64
or eax, 0x4000
jmp 0x4ad07d4a
mov edi, dword [esi]
lea eax, [ebp - 4]
push eax
push esi
push dword [ebp + 0xc]
push ebx
call fcn.4ad0deb1
cmp edi, dword [esi]
je 0x4ad07d62
mov dword [0x4ad33b18], ebx
jmp 0x4ad07d62
call ebx
push dword [ebp + 8]
mov dword [0x4ad2ba04], eax
call fcn.4ad02e18
push dword [ebp + 0x1c]
call fcn.4ad02c7d
test eax, eax
push dword [ebp + 0x1c]
jne 0x4ad15f5e
call fcn.4ad02e18
push dword [ebp + 0x20]
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
jmp 0x4ad15f63
call fcn.4ad02e18
push 1
push dword [0x4ad2ba04]
call fcn.4ad119e4
Function at 0x4ad0856f
Capabilities:
Read file on windows

Disassembly:
cmp byte [esi + 1], 0xa
jne 0x4ad085d9
mov eax, dword [ebp - 0xc]
mov byte [esi + 2], bl
sub esi, edi
inc esi
inc esi
push ebx
push ebx
mov dword [ebp - 8], esi
add esi, eax
push esi
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
jmp 0x4ad085f1
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push esi
push edi
push 1
xor ebx, ebx
push ebx
push ebx
push dword [ebp + 8]
mov edi, 0x4ad290a0
mov esi, edi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push ebx
push dword [ebp + 0x14]
mov dword [ebp - 0xc], eax
push dword [ebp + 0x10]
push edi
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x4ad08774
mov eax, dword [ebp + 0x14]
mov eax, dword [eax]
cmp eax, ebx
je 0x4ad08774
mov dword [ebp - 8], eax
mov dword [ebp - 4], eax
jle 0x4ad085f1
cmp dword [ebp - 4], 3
jl 0x4ad085d9
mov al, byte [esi]
cmp al, 0xa
je 0x4ad0877b
cmp al, 0xd
je 0x4ad05e66
movzx eax, byte [esi]
cmp byte [eax + 0x4ad34740], bl
jne 0x4ad12008
dec dword [ebp - 4]
inc esi
cmp dword [ebp - 4], ebx
jg 0x4ad085c1
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp - 8]
push edi
push 1
push dword [0x4ad2b9ec]
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
mov ecx, dword [ebp + 0x14]
mov dword [ecx], eax
pop edi
pop esi
pop ebx
leave
ret 0x10
xor eax, eax
jmp 0x4ad0860e
cmp byte [esi + 1], 0xd
je 0x4ad05e70
jmp 0x4ad085d1
cmp dword [ebp - 4], 1
je 0x4ad12019
sub dword [ebp - 4], 2
inc esi
inc esi
jmp 0x4ad085ec
push ebx
lea eax, [ebp - 4]
push eax
push 1
inc esi
push esi
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x4ad1203c
cmp dword [ebp - 4], ebx
je 0x4ad1203c
inc dword [ebp - 8]
jmp 0x4ad085f1
mov eax, dword [ebp + 0x14]
mov dword [eax], ebx
jmp 0x4ad08774

Function at 0x4ad08b31
Capabilities:
Manipulate console buffer
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetFileType]
and eax, 0xffff7fff
cmp eax, 2
je 0x4ad0c8a9
pop ebp
jmp fcn.4ad0856f
pop ebp
jmp fcn.4ad0b9c4
Function at 0x4ad08b58
Capabilities:
Set current directory

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x218
mov eax, dword [0x4ad33b78]
and word [ebp - 6], 0
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
add eax, 0x40
push esi
mov word [ebp - 0xa], ax
push edi
lea eax, [ebp - 0xc]
push eax
mov word [ebp - 0xc], 0x3d
mov word [ebp - 8], 0x3a
call fcn.4ad01b84
mov esi, dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
mov ebx, dword [sym.imp.KERNEL32.dll_SetErrorMode]
mov edi, eax
test edi, edi
je 0x4ad172df
push edi
call esi
test al, al
je 0x4ad172d5
push 0
push 0x4ad34400
call fcn.4ad01555
mov ecx, dword [ebp - 4]
pop edi
pop esi
pop ebx
call fcn.4ad01305
leave
ret 4
push 1
call ebx
mov dword [ebp - 0x218], eax
mov ax, word [ebp - 0xa]
and word [ebp - 0x20e], 0
mov word [ebp - 0x214], ax
mov ax, word [ebp - 8]
mov word [ebp - 0x212], ax
mov ax, word [0x4ad33b8c]
mov word [ebp - 0x210], ax
push 0x4ad2b0d0
lea eax, [ebp - 0x214]
push eax
lea eax, [ebp - 0xc]
push eax
call fcn.4ad01594
lea eax, [ebp - 0x214]
push eax
call esi
test eax, eax
jne 0x4ad1733b
push eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.4ad0606f
pop ecx
pop ecx
test edi, edi
je 0x4ad08bb3
push dword [ebp - 0x218]
call ebx
jmp 0x4ad08bb3
Function at 0x4ad0f712
Capabilities:
Check if file exists
Get disk information
Get file attributes

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x66c
mov eax, dword [0x4ad33b78]
push esi
push edi
mov edi, dword [ebp + 8]
push edi
mov dword [ebp - 4], eax
call fcn.4ad01349
lea ecx, [ebp - 0x668]
push ecx
lea ecx, [ebp - 0x414]
push ecx
push 0x208
push eax
call dword [sym.imp.KERNEL32.dll_GetFullPathNameW]
mov esi, eax
test esi, esi
je 0x4ad0f7b9
push 4
lea eax, [ebp - 0x414]
push 0x4ad0f7cc
push eax
call dword [sym.imp.msvcrt.dll_wcsncmp]
add esp, 0xc
test eax, eax
je 0x4ad175b2
mov eax, dword [ebp - 0x668]
test eax, eax
je 0x4ad17610
cmp word [eax], 0
je 0x4ad17610
lea eax, [ebp - 0x66c]
push eax
lea eax, [ebp - 0x664]
push eax
push 0x37
lea eax, [ebp - 0x414]
push eax
call fcn.4ad02a4c
push dword [ebp - 0x66c]
movzx esi, al
call fcn.4ad01c38
test esi, esi
je 0x4ad0f8f3
mov eax, esi
mov ecx, dword [ebp - 4]
pop edi
pop esi
call fcn.4ad01305
leave
ret 4
cmp word [ebp - 0x412], 0x5c
je 0x4ad0f926
cmp word [ebp - 0x412], 0x3a
jne 0x4ad0f7b9
cmp word [ebp - 0x410], 0x5c
jne 0x4ad0f7b9
cmp word [ebp - 0x40e], si
jne 0x4ad0f7b9
lea eax, [ebp - 0x414]
push eax
call dword [sym.imp.KERNEL32.dll_GetDriveTypeW]
cmp eax, 1
ja 0x4ad17608
jmp 0x4ad0f7b9
lea eax, [ebp - 0x40c]
push eax
push edi
mov dword [ebp - 0x668], eax
call dword [sym.imp.msvcrt.dll_wcsstr]
test eax, eax
pop ecx
pop ecx
mov dword [ebp - 0x668], eax
je 0x4ad175f1
cmp eax, edi
jbe 0x4ad175f1
mov si, word [eax]
and word [eax], 0
push edi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
mov ecx, eax
mov eax, dword [ebp - 0x668]
mov word [eax], si
jmp 0x4ad175fa
push edi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
mov ecx, eax
mov eax, ecx
inc eax
neg eax
sbb eax, eax
and eax, ecx
jmp 0x4ad0f7bb
xor esi, esi
inc esi
jmp 0x4ad0f7b9
lea eax, [ebp - 0x414]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
xor ecx, ecx
cmp eax, 0xffffffff
setne cl
mov esi, ecx
jmp 0x4ad0f7b9
Function at 0x4ad0fac4
Capabilities:
Delete directory

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x288
mov eax, dword [0x4ad33b78]
push ebx
xor ebx, ebx
push edi
mov dword [ebp - 0x288], ebx
mov dword [ebp - 0x27c], ebx
mov word [ebp - 0x278], bx
mov word [ebp - 0x276], bx
mov dword [ebp - 4], eax
xor eax, eax
lea edi, [ebp - 0x274]
stosd dword es:[edi], eax
mov word [ebp - 0x270], bx
mov word [ebp - 0x26e], bx
mov ecx, dword [ebp + 8]
lea edi, [ebp - 0x26c]
stosd dword es:[edi], eax
mov word [ebp - 0x268], bx
mov word [ebp - 0x266], bx
lea edi, [ebp - 0x264]
stosd dword es:[edi], eax
mov word [ebp - 0x260], bx
mov word [ebp - 0x25e], bx
lea edi, [ebp - 0x25c]
stosd dword es:[edi], eax
mov word [ebp - 0x258], bx
mov word [ebp - 0x256], bx
lea edi, [ebp - 0x254]
stosd dword es:[edi], eax
mov word [ebp - 0x250], bx
mov word [ebp - 0x24e], bx
lea edi, [ebp - 0x24c]
stosd dword es:[edi], eax
mov dword [ebp - 0x244], ebx
mov dword [ebp - 0x240], ebx
mov byte [ebp - 0x23c], bl
mov dword [ebp - 0x238], ebx
mov dword [ebp - 0x230], ebx
lea edi, [ebp - 0x22c]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
mov eax, dword [0x4ad2b9f0]
mov dword [ebp - 0x220], eax
lea eax, [ebp - 0x288]
push eax
push ecx
mov dword [ebp - 0x214], ebx
mov dword [ebp - 0x284], 6
mov dword [ebp - 0x280], ebx
mov dword [ebp - 0x248], ebx
mov dword [ebp - 0x234], ebx
call fcn.4ad0fd7f
cmp eax, 1
je 0x4ad0ff91
push ebx
lea eax, [ebp - 0x210]
push eax
call fcn.4ad01555
mov edi, dword [ebp - 0x248]
cmp edi, ebx
je 0x4ad17b8e
push esi
lea esi, [ebp - 0x244]
mov eax, dword [esi]
cmp eax, ebx
je 0x4ad0ff99
push eax
call dword [sym.imp.msvcrt.dll_wcslen]
pop ecx
cmp eax, ebx
je 0x4ad17bc7
dec edi
mov esi, dword [esi + 0xc]
jne 0x4ad0fbf6
mov edi, dword [ebp - 0x288]
mov eax, dword [ebp - 0x248]
lea esi, [ebp - 0x244]
and edi, 0x10
mov dword [ebp - 0x218], eax
cmp edi, ebx
je 0x4ad17bdc
test byte [ebp - 0x287], 0x20
je 0x4ad17ba0
lea eax, [ebp - 0x21c]
push eax
push dword [esi]
call fcn.4ad0f946
cmp eax, ebx
jne 0x4ad0ff76
dec dword [ebp - 0x218]
mov esi, dword [esi + 0xc]
jne 0x4ad0fc31
lea eax, [ebp - 0x210]
push eax
push 0x4ad34400
call dword [sym.imp.msvcrt.dll_wcscpy]
pop ecx
pop ecx
push dword [ebp - 0x220]
call fcn.4ad014fd
mov eax, dword [ebp - 0x214]
pop esi
mov ecx, dword [ebp - 4]
pop edi
pop ebx
call fcn.4ad01305
leave
ret 4
cmp eax, 0x91
je 0x4ad0ffa0
push ebx
push eax
mov dword [ebp - 0x214], eax
call fcn.4ad0606f
pop ecx
pop ecx
jmp 0x4ad0fc5c
xor eax, eax
inc eax
jmp 0x4ad0fc8d
xor eax, eax
jmp 0x4ad0fc08
cmp dword [ebp - 0x21c], ebx
je 0x4ad0fc5c
jmp 0x4ad0ff7d
push ebx
push 0x232a
call fcn.4ad0606f
pop ecx
pop ecx
jmp 0x4ad0ff91
push 0x2328
push 0x234e
push dword [esi]
call fcn.4ad0c64d
xor ecx, ecx
inc ecx
cmp eax, ecx
je 0x4ad0fc46
mov dword [ebp - 0x214], ecx
jmp 0x4ad0fc5c
push ebx
push 0x232a
call fcn.4ad0606f
pop ecx
xor eax, eax
pop ecx
inc eax
jmp 0x4ad0fc8c
push dword [esi]
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
test eax, eax
jne 0x4ad0fc5c
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x4ad0ff7d
Function at 0x4ad0fcd3
Capabilities:
Check if file exists
Delete directory
Get file attributes
Set file attributes

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x14
mov eax, dword [0x4ad33b78]
and dword [ebp - 0x10], 0
push esi
mov esi, dword [ebp + 8]
mov dword [ebp - 4], eax
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 0xc]
push eax
push 4
push esi
call dword [sym.imp.KERNEL32.dll_GetFullPathNameW]
cmp eax, 3
je 0x4ad1798c
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
push esi
call ebx
test eax, eax
je 0x4ad0ff48
mov eax, dword [ebp - 0x10]
pop ebx
mov ecx, dword [ebp - 4]
pop esi
call fcn.4ad01305
leave
ret 4
push edi
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
call edi
cmp eax, 5
mov dword [ebp - 0x10], eax
je 0x4ad179a9
pop edi
jmp 0x4ad0fd17
cmp word [ebp - 0xa], 0x3a
jne 0x4ad0fd05
cmp word [ebp - 8], 0x5c
jne 0x4ad0fd05
xor eax, eax
jmp 0x4ad0fd1b
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x4ad0ff5d
test al, 1
je 0x4ad0ff5d
and eax, 0xfffffffe
push eax
push esi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
test eax, eax
je 0x4ad0ff5d
push esi
call ebx
test eax, eax
je 0x4ad179e4
and dword [ebp - 0x10], 0
jmp 0x4ad0ff5d
call edi
mov dword [ebp - 0x10], eax
jmp 0x4ad0ff5d

Function at 0x4ad10e9e
Capabilities:
Get disk information

Disassembly:
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x90
mov dword [0x4ad2ba04], eax
je 0x4ad182c2
jmp 0x4ad10f3f
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x62c
mov eax, dword [0x4ad33b78]
push esi
lea ecx, [ebp - 0x41c]
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ecx
xor esi, esi
push eax
mov dword [0x4ad2ba04], esi
call fcn.4ad10f5d
test al, al
je 0x4ad10f3f
lea eax, [ebp - 0x41c]
push eax
lea eax, [ebp - 0x210]
push eax
call dword [sym.imp.msvcrt.dll_wcscpy]
lea eax, [ebp - 0x210]
push 0x4ad0136c
push eax
call dword [sym.imp.msvcrt.dll_wcscat]
add esp, 0x10
push 0x106
lea eax, [ebp - 0x628]
push eax
push esi
lea eax, [ebp - 0x62c]
push eax
push esi
push esi
push esi
lea eax, [ebp - 0x210]
push eax
call dword [sym.imp.KERNEL32.dll_GetVolumeInformationW]
test eax, eax
je 0x4ad1001b
lea eax, [ebp - 0x628]
push 0x4ad10f50
push eax
call dword [sym.imp.msvcrt.dll__wcsicmp]
test eax, eax
pop ecx
pop ecx
je 0x4ad182ae
xor al, al
mov ecx, dword [ebp - 4]
pop esi
call fcn.4ad01305
leave
ret 4
cmp dword [ebp - 0x62c], 0xc
jne 0x4ad10f3f
mov al, 1
jmp 0x4ad10f41
mov dword [0x4ad2ba04], esi
jmp 0x4ad10f3f

Function at 0x4ad195ed
Capabilities:
Enumerate files on windows

Disassembly:
mov edi, edi
push esi
mov esi, dword [0x4ad2fac4]
jmp 0x4ad19604
push esi
call fcn.4ad0873a
mov esi, dword [esi + 0xf4]
test esi, esi
jne 0x4ad195f8
call fcn.4ad0c96f
and dword [0x4ad2fac0], esi
push 1
push 0x4ad34700
call dword [sym.imp.msvcrt.dll_longjmp]
nop
nop
nop
nop
nop
Function at 0x4ad19f13
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov ebx, eax
xor edi, edi
cmp ebx, edi
jne 0x4ad19f4f
mov eax, dword [sym.imp.msvcrt.dll__iob]
push 0x4ad19254
add eax, 0x40
push str._nCMD_Internal_Error__s_n
push eax
call dword [sym.imp.msvcrt.dll_fprintf]
xor eax, eax
add esp, 0xc
inc eax
jmp 0x4ad1a008
push esi
push edi
push dword [ebp + 8]
call fcn.4ad02b83
mov esi, eax
push 0x20
push esi
mov dword [ebp + 8], esi
call fcn.4ad01a67
cmp eax, edi
je 0x4ad19f6d
mov word [eax], di
cmp esi, edi
je 0x4ad19f7e
push esi
call dword [sym.imp.msvcrt.dll_wcslen]
pop ecx
mov dword [ebp - 0xc], eax
jmp 0x4ad19f81
mov dword [ebp - 0xc], edi
mov dword [ebp - 8], 1
cmp ebx, edi
je 0x4ad19f99
push ebx
call dword [sym.imp.msvcrt.dll_wcslen]
pop ecx
mov dword [ebp - 4], eax
jmp 0x4ad19f9c
mov dword [ebp - 4], edi
cmp dword [ebp - 4], edi
jbe 0x4ad19fed
cmp dword [0x4ad2b9e8], edi
jne 0x4ad19fe8
mov eax, dword [ebp - 0xc]
cmp dword [ebp - 4], eax
jb 0x4ad19fdf
push dword [ebp + 8]
lea esi, [ebx + eax*2]
mov di, word [esi]
and word [esi], 0
push ebx
call dword [sym.imp.KERNEL32.dll_lstrcmpiW]
test eax, eax
mov word [esi], di
jne 0x4ad19fdd
push ebx
push str._s_r_n
call fcn.4ad05e0c
and dword [ebp - 8], 0
pop ecx
pop ecx
xor edi, edi
mov eax, dword [ebp - 4]
lea ebx, [ebx + eax*2 + 2]
jmp 0x4ad19f88
xor eax, eax
inc eax
jmp 0x4ad1a007
cmp dword [ebp - 8], edi
je 0x4ad1a004
push dword [ebp + 8]
push 1
push 0x23a9
call fcn.4ad0606f
add esp, 0xc
mov eax, dword [ebp - 8]
pop esi
pop edi
pop ebx
leave
ret 4

Function at 0x4ad1a013
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push esi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov esi, eax
test esi, esi
jne 0x4ad1a043
mov eax, dword [sym.imp.msvcrt.dll__iob]
push 0x4ad19254
add eax, 0x40
push str._nCMD_Internal_Error__s_n
push eax
call dword [sym.imp.msvcrt.dll_fprintf]
add esp, 0xc
xor eax, eax
inc eax
pop esi
ret
push edi
test esi, esi
je 0x4ad1a054
push esi
call dword [sym.imp.msvcrt.dll_wcslen]
pop ecx
mov edi, eax
jmp 0x4ad1a056
xor edi, edi
test edi, edi
jbe 0x4ad1a081
cmp dword [0x4ad2b9e8], 0
jne 0x4ad1a07c
cmp word [esi], 0x3d
je 0x4ad1a076
push esi
push str._s_r_n
call fcn.4ad05e0c
pop ecx
pop ecx
lea esi, [esi + edi*2 + 2]
jmp 0x4ad1a044
xor eax, eax
inc eax
jmp 0x4ad1a083
xor eax, eax
pop edi
pop esi
ret
Function at 0x4ad1b11f
Capabilities:
Query or enumerate registry key
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x418
mov eax, dword [0x4ad33b78]
push ebx
mov ebx, dword [ebp + 8]
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
test eax, eax
push esi
push edi
jne 0x4ad1b1d7
xor edi, edi
push 0x104
lea eax, [ebp - 0x20c]
push eax
push edi
push ebx
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyW]
mov esi, eax
test esi, esi
jne 0x4ad1b1c6
cmp word [ebp - 0x20c], 0x2e
jne 0x4ad1b1b6
lea eax, [ebp - 0x418]
push eax
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x20c]
push eax
push ebx
mov dword [ebp - 0x418], 0x208
call dword [sym.imp.ADVAPI32.dll_RegQueryValueW]
mov esi, eax
test esi, esi
jne 0x4ad1b23d
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x20c]
push eax
push str._s_s_r_n
call fcn.4ad05e0c
add esp, 0xc
mov esi, eax
cmp dword [0x4ad2b9e8], 0
jne 0x4ad1b1d2
inc edi
test esi, esi
je 0x4ad1b145
jmp 0x4ad1b23d
cmp esi, 0x103
jne 0x4ad1b23d
xor esi, esi
jmp 0x4ad1b23d
xor eax, eax
inc eax
jmp 0x4ad1b23f
push 0
push eax
call fcn.4ad02b83
mov edi, eax
push 0x20
push edi
call fcn.4ad01a67
test eax, eax
je 0x4ad1b1f1
and word [eax], 0
lea eax, [ebp - 0x418]
push eax
lea eax, [ebp - 0x414]
push eax
push edi
push ebx
mov dword [ebp - 0x418], 0x208
call dword [sym.imp.ADVAPI32.dll_RegQueryValueW]
mov esi, eax
test esi, esi
jne 0x4ad1b22d
lea eax, [ebp - 0x414]
push eax
push edi
push str._s_s_r_n
call fcn.4ad05e0c
mov esi, eax
jmp 0x4ad1b23a
push edi
push 1
push 0x23a3
call fcn.4ad0606f
add esp, 0xc
mov eax, esi
mov ecx, dword [ebp - 4]
pop edi
pop esi
pop ebx
call fcn.4ad01305
leave
ret 8

Function at 0x4ad1b253
Capabilities:
Delete registry key
Set registry value

Disassembly:
push 0xc
push 0x4ad1b310
call fcn.4ad0162f
mov esi, dword [ebp + 0x10]
xor edi, edi
cmp esi, edi
je 0x4ad1b2df
cmp word [esi], di
je 0x4ad1b2df
push esi
call dword [sym.imp.msvcrt.dll_wcslen]
pop ecx
push eax
push esi
push 1
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegSetValueW]
mov dword [ebp - 0x1c], eax
cmp eax, edi
jne 0x4ad1b2d3
mov dword [ebp - 4], edi
push edi
push edi
push edi
push 0x8000000
call dword [sym.imp.SHELL32.dll_SHChangeNotify]
push esi
push dword [ebp + 0xc]
push str._s_s_r_n
call fcn.4ad05e0c
add esp, 0xc
or dword [ebp - 4], 0xffffffff
jmp 0x4ad1b304
push dword [ebp + 0xc]
push 1
push 0x235d
jmp 0x4ad1b2fc
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyW]
mov dword [ebp - 0x1c], eax
cmp eax, edi
je 0x4ad1b304
push dword [ebp + 0xc]
push 1
push 0x23a3
call fcn.4ad0606f
add esp, 0xc
mov eax, dword [ebp - 0x1c]
call fcn.4ad01447
ret 0xc
Function at 0x4ad1b321
Capabilities:
Query or enumerate registry key
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x428
mov eax, dword [0x4ad33b78]
push ebx
push esi
push edi
mov edi, dword [ebp + 0xc]
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
xor esi, esi
cmp edi, esi
mov dword [ebp - 0x420], eax
jne 0x4ad1b478
mov edi, dword [sym.imp.ADVAPI32.dll_RegEnumKeyW]
mov ebx, 0x104
push ebx
lea ecx, [ebp - 0x20c]
push ecx
push esi
mov dword [ebp - 0x424], esi
push eax
jmp 0x4ad1b45b
cmp word [ebp - 0x20c], 0x2e
je 0x4ad1b438
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.msvcrt.dll_wcslen]
mov esi, eax
lea eax, [ebp - 0x20c]
mov dword [esp], 0x4ad1b590
push eax
call dword [sym.imp.msvcrt.dll_wcscat]
lea eax, [ebp - 0x414]
push 0x4ad1b550
push eax
call dword [sym.imp.msvcrt.dll_wcscpy]
add esp, 0x10
lea eax, [ebp - 0x418]
push eax
lea eax, [ebp - 0x20c]
push eax
push dword [ebp - 0x420]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyW]
test eax, eax
jne 0x4ad1b438
and word [ebp + esi*2 - 0x20c], ax
lea eax, [ebp - 0x41c]
push eax
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x428]
push eax
push 0
push 0x4ad02a6c
push dword [ebp - 0x418]
mov dword [ebp - 0x41c], 0x208
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
push dword [ebp - 0x418]
mov esi, eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test esi, esi
jne 0x4ad1b438
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x20c]
push eax
push str._s_s_r_n
call fcn.4ad05e0c
add esp, 0xc
cmp dword [0x4ad2b9e8], 0
jne 0x4ad1b473
inc dword [ebp - 0x424]
push ebx
lea eax, [ebp - 0x20c]
push eax
push dword [ebp - 0x424]
push dword [ebp - 0x420]
call edi
mov esi, eax
test esi, esi
je 0x4ad1b36d
cmp esi, 0x103
jne 0x4ad1b491
xor esi, esi
jmp 0x4ad1b491
xor eax, eax
inc eax
jmp 0x4ad1b493
cmp word [edi], 0x2e
jne 0x4ad1b4a2
push 0x7b
pop esi
push edi
push 1
push 0x23a5
call fcn.4ad0606f
add esp, 0xc
mov eax, esi
mov ecx, dword [ebp - 4]
pop edi
pop esi
pop ebx
call fcn.4ad01305
leave
ret 8
push esi
push edi
call fcn.4ad02b83
mov edi, eax
push 0x20
push edi
call fcn.4ad01a67
cmp eax, esi
je 0x4ad1b4ba
mov word [eax], si
push edi
push 0x4ad1926c
lea eax, [ebp - 0x20c]
push 0x104
push eax
call dword [sym.imp.msvcrt.dll__snwprintf]
add esp, 0x10
lea eax, [ebp - 0x418]
push eax
lea eax, [ebp - 0x20c]
push eax
push dword [ebp - 0x420]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyW]
cmp eax, esi
je 0x4ad1b4f7
mov esi, eax
jmp 0x4ad1b481
lea eax, [ebp - 0x41c]
push eax
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x428]
push eax
push esi
push 0x4ad02a6c
push dword [ebp - 0x418]
mov dword [ebp - 0x41c], 0x208
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
mov esi, eax
test esi, esi
jne 0x4ad1b481
lea eax, [ebp - 0x414]
push eax
push edi
push str._s_s_r_n
call fcn.4ad05e0c
jmp 0x4ad1b48e