joyce8/EMBER2024-capa huggingface dataset:
Function at 0x41cde0
Capabilities:
Extract resource via kernel32 functions
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
push ebx
push esi
push edi
mov edi, ecx
test edi, edi
je 0x41cf1c
push str.Module
push 0x76
push 0
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov esi, eax
test esi, esi
jne 0x41ce17
call dword [sym.imp.KERNEL32.dll_GetLastError]
pop edi
mov esi, eax
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push esi
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
je 0x41ce08
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov dword [ebp - 0x10], eax
test eax, eax
jne 0x41ce40
mov esi, 0xd
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push esi
push 0
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov dword [ebp - 0xc], eax
test eax, eax
je 0x41ce08
push 0
push 0x80
push 1
push 0
push 0
push 0x10000000
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebx, eax
test ebx, ebx
je 0x41ce78
cmp ebx, 0xffffffff
je 0x41ce78
xor esi, esi
jmp 0x41ce88
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jne 0x41cf03
mov edx, dword [ebp - 0xc]
xor edi, edi
lea eax, [edx - 1]
mov dword [ebp - 0x18], eax
test eax, eax
je 0x41cf03
mov ecx, ebx
call fcn.00405f00
mov byte [ebp - 1], al
mov ecx, edx
mov edx, dword [ebp - 0x10]
sub ecx, edi
add edx, edi
cmp byte [ebp - 1], 0
je 0x41cefe
test edx, edx
je 0x41cef7
test ecx, ecx
je 0x41cef7
push 0
lea eax, [ebp - 8]
mov dword [ebp - 8], 0
push eax
push ecx
push edx
push ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov ecx, dword [ebp - 8]
mov dword [ebp - 0x14], ecx
test eax, eax
jne 0x41cee9
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [ebp - 0x14]
mov esi, eax
test esi, esi
jne 0x41cf03
jmp 0x41ceeb
xor esi, esi
add edi, ecx
cmp edi, dword [ebp - 0x18]
jae 0x41cf03
mov edx, dword [ebp - 0xc]
jmp 0x41cea1
mov esi, 0x57
jmp 0x41cf03
mov esi, 6
test ebx, ebx
je 0x41cf21
cmp ebx, 0xffffffff
je 0x41cf21
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov esi, 0x57
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x41d000
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2c
mov eax, dword [0x48f008]
xor eax, ebp
mov dword [ebp - 8], eax
mov eax, dword [ebp + 8]
push ebx
xor bl, bl
mov dword [ebp - 0x2c], edx
mov dword [ebp - 0x28], ecx
push esi
test eax, eax
je 0x41d0df
push 0
push 0x80
push 3
push 0
push 1
push 0x80000000
xorps xmm0, xmm0
push eax
movups xmmword [ebp - 0x1c], xmm0
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
test esi, esi
je 0x41d050
cmp esi, 0xffffffff
jne 0x41d05a
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x41d0cf
mov ecx, esi
call fcn.00405f00
test al, al
je 0x41d0cf
push 0
lea eax, [ebp - 0x20]
mov dword [ebp - 0x20], 0
push eax
push 0x10
lea eax, [ebp - 0x1c]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov ecx, dword [ebp - 0x20]
mov dword [ebp - 0x24], ecx
test eax, eax
jne 0x41d096
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x41d0cf
mov ecx, dword [ebp - 0x24]
cmp ecx, 0x10
jne 0x41d0cf
test esi, esi
je 0x41d0ab
cmp esi, 0xffffffff
je 0x41d0ab
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 0x28]
mov bl, 1
mov eax, dword [ebp - 0x1c]
mov dword [ecx], eax
mov ecx, dword [ebp - 0x2c]
mov eax, dword [ebp - 0x18]
mov dword [ecx], eax
mov al, bl
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0043fc58
mov esp, ebp
pop ebp
ret
test esi, esi
je 0x41d0df
cmp esi, 0xffffffff
je 0x41d0df
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 8]
mov al, bl
pop esi
xor ecx, ebp
pop ebx
call fcn.0043fc58
mov esp, ebp
pop ebp
ret
Function at 0x41d920
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x28
mov eax, dword [0x48f008]
xor eax, ebp
mov dword [ebp - 8], eax
push ebx
mov ebx, ecx
mov eax, edx
mov dword [ebp - 0x20], eax
push esi
push edi
test ebx, ebx
je 0x41db07
test eax, eax
je 0x41db07
push 0
push 0x80
push 3
push 0
push 1
push 0x80000000
xorps xmm0, xmm0
push ebx
movups xmmword [ebp - 0x1c], xmm0
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
je 0x41d97b
cmp esi, 0xffffffff
jne 0x41d9b4
call edi
mov edi, eax
test edi, edi
je 0x41d9ae
test esi, esi
je 0x41db0c
cmp esi, 0xffffffff
je 0x41db0c
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, edi
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0043fc58
mov esp, ebp
pop ebp
ret
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, esi
call fcn.00405f00
test al, al
jne 0x41d9c6
mov edi, 6
jmp 0x41d9f2
push 0
lea eax, [ebp - 0x24]
mov dword [ebp - 0x24], 0
push eax
push 0x10
lea eax, [ebp - 0x1c]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov ecx, dword [ebp - 0x24]
mov dword [ebp - 0x28], ecx
test eax, eax
jne 0x41da0f
call edi
mov edi, eax
test edi, edi
je 0x41da0c
test esi, esi
je 0x41da02
cmp esi, 0xffffffff
je 0x41da02
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test edi, edi
jne 0x41db0c
jmp 0x41da4c
mov ecx, dword [ebp - 0x28]
cmp ecx, 0x10
je 0x41da3c
test esi, esi
je 0x41da24
cmp esi, 0xffffffff
je 0x41da24
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edi, 0xd
mov eax, edi
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0043fc58
mov esp, ebp
pop ebp
ret
test esi, esi
je 0x41da4c
cmp esi, 0xffffffff
je 0x41da4c
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x18]
cmp eax, 0x66316561
jne 0x41da7c
mov edx, dword [ebp - 0x20]
push ecx
push 0x80
mov ecx, ebx
call fcn.0041d2a0
add esp, 8
mov edi, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0043fc58
mov esp, ebp
pop ebp
ret
cmp eax, 0x66326561
jne 0x41daa9
mov edx, dword [ebp - 0x20]
push ecx
push 0x100
mov ecx, ebx
call fcn.0041d2a0
add esp, 8
mov edi, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0043fc58
mov esp, ebp
pop ebp
ret
cmp eax, 0x64316561
jne 0x41dad6
mov edx, dword [ebp - 0x20]
push ecx
push 0x80
mov ecx, ebx
call fcn.0041d5e0
add esp, 8
mov edi, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0043fc58
mov esp, ebp
pop ebp
ret
cmp eax, 0x64326561
jne 0x41da24
mov edx, dword [ebp - 0x20]
push ecx
push 0x100
mov ecx, ebx
call fcn.0041d5e0
add esp, 8
mov edi, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0043fc58
mov esp, ebp
pop ebp
ret
mov edi, 0x57
mov ecx, dword [ebp - 8]
mov eax, edi
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0043fc58
mov esp, ebp
pop ebp
ret
Function at 0x41f740
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
push ebx
mov ebx, dword [ecx + 0xc]
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x10], 0
mov dword [ebp - 0x1c], 0x479ee0
mov dword [ebp - 0xc], 0
test ebx, ebx
jne 0x41f774
lea eax, [ebx + 0x57]
pop ebx
mov esp, ebp
pop ebp
ret 0xc
push esi
push edi
lea eax, [ebp - 8]
mov dword [ebp - 8], 0
push eax
push 0
lea eax, [ebp - 0xc]
push eax
push 0
push dword [ebp + 0xc]
push ebx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
mov edi, eax
test edi, edi
jne 0x41f88c
mov esi, dword [ebp - 0x18]
mov eax, esi
test eax, eax
je 0x41f7b9
push esi
call fcn.0043ff40
xor esi, esi
add esp, 4
mov dword [ebp - 0x18], esi
xor eax, eax
mov dword [ebp - 0x10], esi
mov ecx, dword [ebp - 8]
mov dword [ebp - 4], ecx
test ecx, ecx
je 0x41f850
test eax, eax
je 0x41f7e1
push eax
call fcn.0043ff40
mov ecx, dword [ebp - 4]
xor esi, esi
add esp, 4
mov dword [ebp - 0x18], esi
mov dword [ebp - 0x10], esi
xor eax, eax
test ecx, ecx
je 0x41f832
test eax, eax
je 0x41f803
push eax
call fcn.0043ff40
mov ecx, dword [ebp - 4]
add esp, 4
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x10], 0
push 0x4582b0
push ecx
call fcn.0043fc9a
mov ecx, dword [ebp - 0x10]
mov esi, eax
add esp, 8
mov dword [ebp - 0x18], esi
test esi, esi
setne dl
test esi, esi
cmovne ecx, dword [ebp - 4]
mov dword [ebp - 0x10], ecx
test dl, dl
jne 0x41f832
mov edi, 0x7a
jmp 0x41f88f
lea eax, [ebp - 8]
push eax
push esi
lea eax, [ebp - 0xc]
push eax
push 0
push dword [ebp + 0xc]
push ebx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
mov edi, eax
test edi, edi
jne 0x41f88c
mov esi, dword [ebp - 0x18]
mov ebx, dword [ebp + 8]
lea eax, [ebp - 0x1c]
cmp ebx, eax
je 0x41f87e
mov eax, dword [ebx + 4]
test eax, eax
je 0x41f86d
push eax
call fcn.0043ff40
mov esi, dword [ebp - 0x18]
add esp, 4
mov eax, dword [ebp - 0x10]
mov dword [ebx + 4], esi
xor esi, esi
mov dword [ebp - 0x18], esi
mov dword [ebx + 0xc], eax
mov dword [ebp - 0x10], esi
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x41f88f
mov eax, dword [ebp - 0xc]
mov dword [ecx], eax
jmp 0x41f88f
mov esi, dword [ebp - 0x18]
mov dword [ebp - 0x1c], vtable.kn::basic_buffer_base_void__class_kn::void_allocator_.0
test esi, esi
je 0x41f8a3
push esi
call fcn.0043ff40
add esp, 4
mov eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
Function at 0x42d2f0
Capabilities:
Access peb ldr_data
Get ntdll base address

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4564e8
mov eax, dword fs:[0]
push eax
sub esp, 0xd8
push esi
push edi
mov eax, dword [0x48f008]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, edx
mov esi, ecx
mov dword [ebp - 0x10], esi
push ecx
lea ecx, [ebp - 0xe4]
call fcn.004300e0
mov dword [ebp - 4], 0
xor ecx, ecx
mov eax, dword [eax + 0xc]
mov dword [ebp - 0x10], ecx
test eax, eax
je 0x42d358
lea ecx, [ebp - 0x10]
push ecx
push edi
push 0
push str.SystemCurrentControlSetServicesjsdlp_plcmgr_service
push eax
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
mov ecx, dword [ebp - 0x10]
jmp 0x42d35d
mov eax, 0x57
push eax
push ecx
lea ecx, [ebp - 0x7c]
call fcn.00430670
push eax
lea ecx, [ebp - 0x48]
mov dword [ebp - 0x44], 0xd
mov dword [ebp - 0x3c], 0
mov dword [ebp - 0x40], vtable.kn::auto_handle_struct_HKEY_____struct_kn::system::registry_key_delete_.0
mov byte [ebp - 0x34], 0
mov dword [ebp - 0x48], vtable.js::basic_crypto_registry_object_808481642_.0
mov dword [ebp - 0x2c], 0
mov dword [ebp - 0x30], vtable.kn::auto_ptr_class_kn::crypto_aes_base_unsigned_char__class_std::allocator_unsigned_char____struct_std::default_delete_class_kn::crypto_aes_base_unsigned_char__class_std::allocator_unsigned_char____.0
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x24], vtable.kn::basic_buffer_unsigned_char__class_std::allocator_unsigned_char__.0
call fcn.00430010
lea ecx, [ebp - 0x7c]
call fcn.0042d250
mov byte [ebp - 4], 1
xor ecx, ecx
mov eax, dword [ebp - 0x3c]
mov dword [ebp - 0x14], ecx
test eax, eax
je 0x42d3e3
lea ecx, [ebp - 0x14]
push ecx
push edi
push 0
push str.details
push eax
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
mov ecx, dword [ebp - 0x14]
jmp 0x42d3e8
mov eax, 0x57
push eax
push ecx
lea ecx, [ebp - 0xb0]
call fcn.00430670
mov dword [esi + 4], 0xd
mov ecx, esi
mov dword [esi + 0xc], 0
mov dword [esi + 8], vtable.kn::auto_handle_struct_HKEY_____struct_kn::system::registry_key_delete_.0
mov byte [esi + 0x14], 0
mov dword [esi], vtable.js::basic_crypto_registry_object_808481642_.0
mov dword [esi + 0x1c], 0
mov dword [esi + 0x18], vtable.kn::auto_ptr_class_kn::crypto_aes_base_unsigned_char__class_std::allocator_unsigned_char____struct_std::default_delete_class_kn::crypto_aes_base_unsigned_char__class_std::allocator_unsigned_char____.0
push eax
mov dword [esi + 0x28], 0
mov dword [esi + 0x30], 0
mov dword [esi + 0x24], vtable.kn::basic_buffer_unsigned_char__class_std::allocator_unsigned_char__.0
call fcn.00430010
lea ecx, [ebp - 0xb0]
call fcn.0042d250
lea ecx, [ebp - 0x48]
call fcn.0042d250
lea ecx, [ebp - 0xe4]
call fcn.0042d250
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x42dc60
Capabilities:
Delete registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x456658
mov eax, dword fs:[0]
push eax
sub esp, 0x84
mov eax, dword [0x48f008]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
cmp ecx, 2
jbe 0x42dc98
mov esi, 0x57
jmp 0x42dd04
xor eax, eax
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x14], 7
mov word [ebp - 0x28], ax
push ecx
mov dword [ebp - 4], eax
lea eax, [ebp - 0x28]
push 0x4854d0
push eax
call fcn.00416a80
add esp, 0xc
test al, al
jne 0x42dd20
mov esi, 0x7a
mov edx, dword [ebp - 0x14]
cmp edx, 8
jb 0x42dd04
mov ecx, dword [ebp - 0x28]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x42dcfa
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x42dde5
push edx
push ecx
call fcn.0043fc69
add esp, 8
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0043fc58
mov esp, ebp
pop ebp
ret
mov edx, 0xf003f
lea ecx, [ebp - 0x90]
call fcn.0042d2f0
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x28]
cmp dword [ebp - 0x14], 8
push 0xf003f
cmovae ecx, dword [ebp - 0x28]
push ecx
lea ecx, [ebp - 0x5c]
push ecx
mov ecx, eax
call fcn.0042ff70
lea ecx, [ebp - 0x90]
call fcn.0042d250
mov esi, dword [ebp - 0x58]
test esi, esi
je 0x42dd6f
lea ecx, [ebp - 0x5c]
call fcn.0042d250
jmp 0x42dcca
mov eax, dword [ebp - 0x50]
test eax, eax
jne 0x42dd86
lea ecx, [ebp - 0x5c]
lea esi, [eax + 0x57]
call fcn.0042d250
jmp 0x42dcca
push str.desc
push eax
call dword [sym.imp.ADVAPI32.dll_RegDeleteValueW]
mov esi, eax
test esi, esi
je 0x42dda5
lea ecx, [ebp - 0x5c]
call fcn.0042d250
jmp 0x42dcca
lea ecx, [ebp - 0x5c]
call fcn.0042d250
mov edx, dword [ebp - 0x14]
cmp edx, 8
jb 0x42dd04
mov ecx, dword [ebp - 0x28]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x42dcfa
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x42dcfa
call fcn.0044316c
int3
Function at 0x42e210
Capabilities:
Delete registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x456658
mov eax, dword fs:[0]
push eax
sub esp, 0x84
mov eax, dword [0x48f008]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
cmp ecx, 2
jbe 0x42e248
mov esi, 0x57
jmp 0x42e2b4
xor eax, eax
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x14], 7
mov word [ebp - 0x28], ax
push ecx
mov dword [ebp - 4], eax
lea eax, [ebp - 0x28]
push 0x4854d0
push eax
call fcn.00416a80
add esp, 0xc
test al, al
jne 0x42e2d0
mov esi, 0x7a
mov edx, dword [ebp - 0x14]
cmp edx, 8
jb 0x42e2b4
mov ecx, dword [ebp - 0x28]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x42e2aa
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x42e395
push edx
push ecx
call fcn.0043fc69
add esp, 8
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0043fc58
mov esp, ebp
pop ebp
ret
mov edx, 0xf003f
lea ecx, [ebp - 0x90]
call fcn.0042d2f0
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x28]
cmp dword [ebp - 0x14], 8
push 0xf003f
cmovae ecx, dword [ebp - 0x28]
push ecx
lea ecx, [ebp - 0x5c]
push ecx
mov ecx, eax
call fcn.0042ff70
lea ecx, [ebp - 0x90]
call fcn.0042d250
mov esi, dword [ebp - 0x58]
test esi, esi
je 0x42e31f
lea ecx, [ebp - 0x5c]
call fcn.0042d250
jmp 0x42e27a
mov eax, dword [ebp - 0x50]
test eax, eax
jne 0x42e336
lea ecx, [ebp - 0x5c]
lea esi, [eax + 0x57]
call fcn.0042d250
jmp 0x42e27a
push str.module_info_flags
push eax
call dword [sym.imp.ADVAPI32.dll_RegDeleteValueW]
mov esi, eax
test esi, esi
je 0x42e355
lea ecx, [ebp - 0x5c]
call fcn.0042d250
jmp 0x42e27a
lea ecx, [ebp - 0x5c]
call fcn.0042d250
mov edx, dword [ebp - 0x14]
cmp edx, 8
jb 0x42e2b4
mov ecx, dword [ebp - 0x28]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x42e2aa
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x42e2aa
call fcn.0044316c
int3
Function at 0x42f880
Capabilities:
Delete registry key

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4568d5
mov eax, dword fs:[0]
push eax
sub esp, 0x5c
mov eax, dword [0x48f008]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
cmp edi, 2
jbe 0x42f8bc
mov esi, 0x57
jmp 0x42f958
mov edx, 0xf003f
lea ecx, [ebp - 0x68]
call fcn.0042d2f0
mov dword [ebp - 4], 0
mov esi, dword [ebp - 0x64]
test esi, esi
jne 0x42f950
xor eax, eax
mov dword [ebp - 0x18], esi
mov dword [ebp - 0x14], 7
mov word [ebp - 0x28], ax
push edi
lea eax, [ebp - 0x28]
mov byte [ebp - 4], 1
push 0x4854d0
push eax
call fcn.00416a80
add esp, 0xc
test al, al
jne 0x42f976
mov esi, 0x7a
mov edx, dword [ebp - 0x14]
cmp edx, 8
jb 0x42f940
mov ecx, dword [ebp - 0x28]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x42f936
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x42fa2e
push edx
push ecx
call fcn.0043fc69
add esp, 8
xor eax, eax
mov dword [ebp - 0x14], 7
mov dword [ebp - 0x18], eax
mov word [ebp - 0x28], ax
lea ecx, [ebp - 0x68]
call fcn.0042d250
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0043fc58
mov esp, ebp
pop ebp
ret
cmp dword [ebp - 0x14], 8
lea edi, [ebp - 0x28]
mov ebx, dword [ebp - 0x5c]
cmovae edi, dword [ebp - 0x28]
test ebx, ebx
jne 0x42f990
lea esi, [ebx + 0x57]
jmp 0x42f906
mov dword [ebp - 0x30], 0
mov eax, ebx
mov dword [ebp - 0x34], vtable.kn::auto_handle_struct_HKEY_____struct_kn::system::registry_key_delete_.0
test edi, edi
je 0x42f9c0
lea eax, [ebp - 0x30]
push eax
push 0xf003f
push 0
push edi
push ebx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
mov esi, eax
test esi, esi
jne 0x42f9e1
mov eax, dword [ebp - 0x30]
push 0
push eax
call dword [sym.imp.ADVAPI32.dll_RegDeleteTreeW]
mov esi, eax
test esi, esi
jne 0x42f9e1
test edi, edi
je 0x42f9ee
push edi
push ebx
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyW]
mov esi, eax
test esi, esi
je 0x42f9ee
lea ecx, [ebp - 0x34]
call fcn.0041f580
jmp 0x42f906
lea ecx, [ebp - 0x34]
call fcn.0041f580
mov edx, dword [ebp - 0x14]
cmp edx, 8
jb 0x42f940
mov ecx, dword [ebp - 0x28]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x42f936
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x42f936
call fcn.0044316c
int3
Function at 0x430670
Capabilities:
Access peb ldr_data
Get ntdll base address

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4569e3
mov eax, dword fs:[0]
push eax
push ecx
push ebx
push esi
push edi
mov eax, dword [0x48f008]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
mov dword [ebp - 0x10], esi
mov eax, dword [ebp + 0xc]
mov dword [esi + 4], eax
mov eax, dword [ebp + 8]
mov dword [esi + 0xc], eax
mov dword [esi + 8], vtable.kn::auto_handle_struct_HKEY_____struct_kn::system::registry_key_delete_.0
mov byte [esi + 0x14], 1
mov dword [ebp - 4], 0
mov dword [esi], vtable.js::basic_crypto_registry_object_808481642_.0
mov dword [esi + 0x1c], 0
mov dword [esi + 0x18], vtable.kn::auto_ptr_class_kn::crypto_aes_base_unsigned_char__class_std::allocator_unsigned_char____struct_std::default_delete_class_kn::crypto_aes_base_unsigned_char__class_std::allocator_unsigned_char____.0
mov dword [esi + 0x28], 0
mov dword [esi + 0x30], 0
mov dword [esi + 0x24], vtable.kn::basic_buffer_unsigned_char__class_std::allocator_unsigned_char__.0
mov byte [ebp - 4], 2
cmp dword [esi + 4], 0
jne 0x430717
mov edx, 0x100
lea ecx, [esi + 0x24]
call fcn.00420580
mov edi, eax
test edi, edi
jne 0x430714
lea edx, [esi + 0x24]
lea ecx, [esi + 0x18]
call fcn.0041de90
test al, al
mov ecx, 0x7a
cmove edi, ecx
mov dword [esi + 4], edi
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
Function at 0x434280
Capabilities:
Encode data using xor
Manually build aes constants

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x80c
mov eax, dword [0x48f008]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
xor esi, esi
mov edx, 1
nop dword [eax]
mov eax, edx
mov dword [ebp + esi*4 - 0x804], edx
and al, 0x80
mov dword [ebp + edx*4 - 0x404], esi
movzx ecx, al
lea eax, [edx + edx]
neg ecx
sbb ecx, ecx
inc esi
and ecx, 0x1b
xor ecx, eax
xor ecx, edx
movzx edx, cl
cmp esi, 0x100
jl 0x4342a0
mov esi, 1
mov edx, 0x492c80
nop dword [eax]
mov eax, esi
mov dword [edx], esi
and al, 0x80
movzx ecx, al
lea eax, [esi + esi]
neg ecx
sbb ecx, ecx
add edx, 4
and ecx, 0x1b
xor ecx, eax
movzx esi, cl
cmp edx, 0x492ca8
jl 0x4342e0
mov eax, 1
mov byte [0x492680], 0x63
mov byte [0x492be3], 0
mov dword [ebp - 0x808], eax
nop dword [eax]
mov ecx, dword [ebp + eax*4 - 0x404]
lea eax, [ebp - 0x408]
shl ecx, 2
sub eax, ecx
mov ebx, dword [eax]
mov ecx, ebx
sar ecx, 7
lea eax, [ebx + ebx]
or ecx, eax
movzx eax, cl
xor ebx, eax
mov ecx, eax
shr ecx, 7
add eax, eax
or ecx, eax
movzx eax, cl
xor ebx, eax
mov ecx, eax
add eax, eax
shr ecx, 7
or ecx, eax
movzx edx, cl
mov ecx, edx
shr ecx, 7
lea eax, [edx + edx]
or ecx, eax
xor ecx, 0x63
movzx eax, cl
xor eax, edx
xor ebx, eax
mov eax, dword [ebp - 0x808]
mov byte [eax + 0x492680], bl
mov byte [ebx + 0x492b80], al
inc eax
mov dword [ebp - 0x808], eax
cmp eax, 0x100
jl 0x434320
mov ebx, 0xff
xor esi, esi
mov dword [ebp - 0x80c], ebx
nop
movzx edx, byte [esi + 0x492680]
mov eax, edx
and al, 0x80
movzx ecx, al
neg ecx
lea eax, [edx + edx]
sbb ecx, ecx
and ecx, 0x1b
xor ecx, eax
movzx eax, cl
mov ecx, eax
xor ecx, edx
shl ecx, 8
xor ecx, edx
shl ecx, 8
xor ecx, edx
shl ecx, 8
xor ecx, eax
mov dword [esi*4 + 0x4940a8], ecx
rol ecx, 8
mov dword [esi*4 + 0x493ca8], ecx
rol ecx, 8
mov dword [esi*4 + 0x4930a8], ecx
rol ecx, 8
mov dword [esi*4 + 0x492ca8], ecx
movzx ecx, byte [esi + 0x492b80]
test ecx, ecx
je 0x434460
mov ecx, dword [ebp + ecx*4 - 0x404]
mov eax, dword [ebp - 0x3cc]
add eax, ecx
cdq
idiv ebx
mov eax, dword [ebp - 0x3e0]
add eax, ecx
mov edi, dword [ebp + edx*4 - 0x804]
cdq
idiv ebx
mov eax, dword [ebp - 0x3d0]
add eax, ecx
mov ebx, dword [ebp + edx*4 - 0x804]
cdq
idiv dword [ebp - 0x80c]
mov eax, dword [ebp + edx*4 - 0x804]
mov dword [ebp - 0x808], eax
mov eax, dword [ebp - 0x3d8]
add eax, ecx
mov ecx, 0xff
cdq
idiv ecx
mov eax, dword [ebp + edx*4 - 0x804]
jmp 0x43446c
xor ebx, ebx
xor edi, edi
mov dword [ebp - 0x808], ebx
xor eax, eax
shl eax, 8
xor eax, dword [ebp - 0x808]
shl eax, 8
xor eax, ebx
mov ebx, 0xff
shl eax, 8
xor eax, edi
mov dword [esi*4 + 0x4938a8], eax
rol eax, 8
mov dword [esi*4 + 0x4934a8], eax
rol eax, 8
mov dword [esi*4 + 0x4944a8], eax
rol eax, 8
mov dword [esi*4 + 0x492780], eax
inc esi
cmp esi, 0x100
jl 0x4343a0
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0043fc58
mov esp, ebp
pop ebp
ret