joyce8/EMBER2024-capa huggingface dataset:
Function at 0x57c3f0
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 8]
push edi
mov edi, ecx
lea ecx, [edi + 0x5c]
mov eax, dword [esi]
push 0xffffffffffffffff
mov dword [edi], eax
mov eax, dword [esi + 4]
mov dword [edi + 4], eax
movzx eax, word [esi + 8]
mov word [edi + 8], ax
movzx eax, byte [esi + 0xa]
mov byte [edi + 0xa], al
movzx eax, byte [esi + 0xb]
mov byte [edi + 0xb], al
movzx eax, byte [esi + 0xc]
mov byte [edi + 0xc], al
mov eax, dword [esi + 0x14]
mov dword [edi + 0x14], eax
mov eax, dword [esi + 0x18]
mov dword [edi + 0x18], eax
xor eax, eax
mov dword [edi + 0x1c], 0
mov dword [edi + 0x20], 0
mov dword [edi + 0x24], 0
mov dword [edi + 0x28], 0
mov dword [edi + 0x2c], 0
mov dword [edi + 0x30], 0
mov dword [edi + 0x34], 0
mov dword [edi + 0x38], 0
mov dword [edi + 0x3c], 0
mov dword [edi + 0x40], 0
mov dword [edi + 0x44], 0
mov dword [edi + 0x48], 0
mov dword [edi + 0x4c], 0
mov dword [edi + 0x50], 0
mov dword [edi + 0x54], 0
mov dword [edi + 0x58], 0
mov dword [ecx + 0x14], 7
mov dword [ecx + 0x10], 0
push eax
mov word [ecx], ax
lea eax, [esi + 0x5c]
push eax
call fcn.00403530
mov eax, dword [esi + 0x74]
mov dword [edi + 0x74], eax
mov eax, dword [esi + 0x78]
mov dword [edi + 0x78], eax
mov eax, dword [esi + 0x7c]
mov dword [edi + 0x7c], eax
mov eax, dword [esi + 0x80]
mov dword [edi + 0x80], eax
movzx eax, word [esi + 0xe]
mov word [edi + 0xe], ax
movzx eax, word [esi + 0x10]
mov word [edi + 0x10], ax
mov eax, dword [esi + 0x1c]
mov dword [edi + 0x1c], eax
mov eax, dword [esi + 0x20]
mov dword [edi + 0x20], eax
mov eax, dword [esi + 0x24]
mov dword [edi + 0x24], eax
mov eax, dword [esi + 0x28]
mov dword [edi + 0x28], eax
mov eax, dword [esi + 0x2c]
mov dword [edi + 0x2c], eax
mov eax, dword [esi + 0x30]
mov dword [edi + 0x30], eax
mov eax, dword [esi + 0x34]
mov dword [edi + 0x34], eax
mov eax, dword [esi + 0x38]
mov dword [edi + 0x38], eax
mov eax, dword [esi + 0x3c]
mov dword [edi + 0x3c], eax
mov eax, dword [esi + 0x40]
mov dword [edi + 0x40], eax
mov eax, dword [esi + 0x44]
mov dword [edi + 0x44], eax
mov eax, dword [esi + 0x48]
mov dword [edi + 0x48], eax
mov eax, dword [esi + 0x4c]
mov dword [edi + 0x4c], eax
mov eax, dword [esi + 0x50]
mov dword [edi + 0x50], eax
mov eax, dword [esi + 0x54]
mov dword [edi + 0x54], eax
mov eax, dword [esi + 0x58]
mov dword [edi + 0x58], eax
mov eax, edi
pop edi
pop esi
pop ebp
ret 4
Function at 0x57e8f0
Capabilities:
Access peb ldr_data
Get number of processors

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x5a2554
mov eax, dword fs:[0]
push eax
sub esp, 0x50
mov eax, dword [0x606040]
xor eax, esp
mov dword [esp + 0x48], eax
push ebx
push esi
push edi
mov eax, dword [0x606040]
xor eax, esp
push eax
lea eax, [esp + 0x60]
mov dword fs:[0], eax
mov edi, ecx
mov dword [esp + 0x14], edi
mov eax, dword [ebp + 0x14]
mov esi, dword [ebp + 8]
mov ebx, dword [ebp + 0xc]
push 0x2c
mov dword [esp + 0x1c], eax
lea eax, [esp + 0x30]
push 0
push eax
mov dword [edi + 0xc], esi
mov dword [edi + 0x10], ebx
call fcn.00539180
neg ebx
mov dword [esp + 0x38], 0x28
mov dword [esp + 0x40], ebx
add esp, 0xc
cmp dword [edi + 0x14], 0
lea ebx, [edi + 0x14]
mov dword [esp + 0x30], esi
mov dword [esp + 0x38], 0x180001
mov dword [esp + 0x3c], 0
jle 0x57e98b
mov esi, dword [sym.imp.KERNEL32.dll_Sleep]
push 0x64
call esi
cmp dword [ebx], 0
jg 0x57e982
push ebx
call dword [sym.imp.KERNEL32.dll_InterlockedIncrement]
mov eax, dword [edi + 8]
mov esi, dword [edi]
cmp eax, 0xffffffff
jle 0x57e99f
mov dword [edi + 4], eax
test esi, esi
je 0x57ea0e
lea ecx, [esp + 0x1c]
call fcn.0040ad09
push 0
lea eax, [esp + 0x30]
mov dword [esp + 0x6c], 0
push eax
push dword [esp + 0x20]
push dword [ebp + 0xc]
push 0
push esi
push dword [esp + 0x38]
call dword [sym.imp.GDI32.dll_SetDIBits]
push dword [esp + 0x20]
call dword [sym.imp.GDI32.dll_CreateCompatibleDC]
push esi
mov esi, dword [sym.imp.GDI32.dll_SelectObject]
mov edi, eax
push edi
call esi
push eax
push edi
call esi
push edi
call dword [sym.imp.GDI32.dll_DeleteDC]
lea ecx, [esp + 0x1c]
call fcn.0040b608
lea ecx, [esp + 0x1c]
mov dword [esp + 0x68], 0xffffffff
call fcn.0040ae49
mov edi, dword [esp + 0x14]
push ebx
mov dword [edi + 8], 0xffffffff
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
mov al, 1
mov ecx, dword [esp + 0x60]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x48]
xor ecx, esp
call fcn.00535334
mov esp, ebp
pop ebp
ret 0x10
Function at 0x57ead0
Capabilities:
Delete file

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20c
mov eax, dword [0x606040]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
push esi
mov ebx, ecx
mov esi, dword [eax]
cmp esi, dword [eax + 4]
jae 0x57eb8f
push edi
mov ecx, dword [ebx]
cmp ecx, dword [ebx + 4]
jae 0x57eb25
lea ecx, [ecx]
mov eax, dword [ecx]
cmp eax, dword [ecx + 4]
jae 0x57eb1d
mov edx, dword [eax + 4]
cmp edx, dword [esi]
jne 0x57eb15
mov dword [eax + 4], 0xffffffff
add eax, 0x1c
cmp eax, dword [ecx + 4]
jb 0x57eb07
add ecx, 0xc
cmp ecx, dword [ebx + 4]
jb 0x57eb00
mov edi, dword [ebx + 0xc]
cmp edi, dword [ebx + 0x10]
je 0x57eb7f
lea ecx, [ecx]
push 0x208
lea eax, [ebp - 0x20c]
push 0
push eax
call fcn.00539180
push dword [esi]
mov eax, edi
sub eax, dword [ebx + 0xc]
sar eax, 3
push eax
push dword [ebx + 0x24]
lea eax, [ebp - 0x20c]
push str._sTemp__d__d.bmp
push 0x104
push eax
call fcn.00536b33
add esp, 0x24
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
add edi, 8
cmp edi, dword [ebx + 0x10]
jne 0x57eb30
mov eax, dword [ebp + 8]
add esi, 4
cmp esi, dword [eax + 4]
jb 0x57eaf6
pop edi
mov ecx, dword [ebp - 4]
pop esi
xor ecx, ebp
pop ebx
call fcn.00535334
mov esp, ebp
pop ebp
ret 4
Function at 0x57fd80
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5a269d
mov eax, dword fs:[0]
push eax
push ecx
push esi
push edi
mov eax, dword [0x606040]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov dword [ebp - 0x10], edi
push 0x5dbfa4
lea ecx, [edi + 4]
mov dword [edi], 0x7d1a
call fcn.00402cd0
mov dword [ebp - 4], 0
lea ecx, [edi + 0x10]
mov dword [edi + 8], 5
mov dword [edi + 0xc], 0
call fcn.00580220
mov byte [ebp - 4], 1
mov ecx, 1
mov eax, dword [edi + 4]
sub ecx, dword [eax - 4]
mov eax, dword [eax - 8]
sub eax, 0x104
or ecx, eax
jge 0x57fe02
push 0x104
lea ecx, [edi + 4]
call fcn.00402400
push 0
push 5
push dword [edi + 4]
push 0
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
mov eax, dword [edi + 4]
test eax, eax
jne 0x57fe1c
xor ecx, ecx
jmp 0x57fe2e
push dword [eax - 8]
push eax
call fcn.005360d5
mov ecx, eax
add esp, 8
test ecx, ecx
js 0x57fe60
mov eax, dword [edi + 4]
cmp ecx, dword [eax - 8]
jg 0x57fe60
mov dword [eax - 0xc], ecx
xor edx, edx
mov eax, dword [edi + 4]
push edx
mov word [eax + ecx*2], dx
mov ecx, edi
mov dword [edi + 0x28], edx
call fcn.0057f330
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret
push 0x80070057
call fcn.00401e70
int3

Function at 0x580220
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5a26e8
mov eax, dword fs:[0]
push eax
push ecx
push esi
mov eax, dword [0x606040]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
mov dword [ebp - 0x10], esi
push 0x5dbfa4
call fcn.00402cd0
mov dword [ebp - 4], 0
mov ecx, 1
mov dword [esi + 4], 0xff1
mov dword [esi + 8], 0x1180
mov dword [esi + 0xc], 0xff0
mov dword [esi + 0x10], 0xff1
mov dword [esi + 0x14], 0xff1
mov eax, dword [esi]
sub ecx, dword [eax - 4]
mov eax, dword [eax - 8]
sub eax, 0x104
or ecx, eax
jge 0x58029f
push 0x104
mov ecx, esi
call fcn.00402400
push 0
push 5
push dword [esi]
push 0
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
mov eax, dword [esi]
test eax, eax
jne 0x5802b7
xor ecx, ecx
jmp 0x5802c9
push dword [eax - 8]
push eax
call fcn.005360d5
mov ecx, eax
add esp, 8
test ecx, ecx
js 0x5802ed
mov eax, dword [esi]
cmp ecx, dword [eax - 8]
jg 0x5802ed
mov dword [eax - 0xc], ecx
xor edx, edx
mov eax, dword [esi]
mov word [eax + ecx*2], dx
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
mov esp, ebp
pop ebp
ret
push 0x80070057
call fcn.00401e70
int3
Function at 0x587b80
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5a3160
mov eax, dword fs:[0]
push eax
sub esp, 0x14
push esi
mov eax, dword [0x606040]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
push 0
lea ecx, [ebp - 0x20]
mov dword [esi + 0x78], 0
call fcn.0043d420
push 0x64
lea ecx, [ebp - 0x20]
mov dword [ebp - 4], 0
call fcn.0043d636
call fcn.0041a0c0
mov eax, dword [eax + 4]
cmp word [eax + 0x120], 0
jbe 0x587c63
call fcn.0040a74d
xor ecx, ecx
mov edx, eax
test edx, edx
setne cl
test ecx, ecx
jne 0x587bfc
push 0x80004005
call fcn.00401e70
mov eax, dword [edx]
mov ecx, edx
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x10], eax
lea eax, [ebp - 0x14]
mov byte [ebp - 4], 1
push eax
lea eax, [ebp - 0x10]
mov dword [ebp - 0x14], 0
push eax
lea ecx, [ebp - 0x20]
call fcn.0043d46f
call fcn.0041a0c0
lea ecx, [ebp - 0x20]
mov eax, dword [eax + 4]
movzx eax, word [eax + 0x120]
push eax
push dword [ebp - 0x10]
mov dword [ebp - 0x14], eax
call fcn.0043d69e
mov byte [ebp - 4], 0
or ecx, 0xffffffff
mov edx, dword [ebp - 0x10]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x587c63
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
push dword [ebp - 0x20]
call dword [sym.imp.KERNEL32.dll_LockResource]
cmp word [eax], 1
jne 0x587c8d
mov ecx, 0xffff
cmp word [eax + 2], cx
jne 0x587c8d
cmp dword [0x6157f4], 0
je 0x587c8d
or dword [eax + 8], 0x400000
push 0
push dword [esi + 0x88]
mov ecx, esi
push eax
call fcn.0043e3cb
mov ecx, esi
call fcn.0043e137
lea ecx, [ebp - 0x20]
mov dword [ebp - 4], 0xffffffff
mov esi, eax
call fcn.0043d45b
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x58db80
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push esi
lea eax, [ebp - 4]
mov dword [ebp - 4], 0
push eax
push 0x20019
push 0
push str.SOFTWARECanonIJ_Scan_Utility
push SysReAllocString
mov esi, ecx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
mov eax, dword [ebp - 4]
test eax, eax
je 0x58dc59
lea ecx, [ebp - 8]
mov dword [ebp - 8], 0
push ecx
push 0
lea ecx, [ebp - 0xc]
mov dword [ebp - 0xc], 0
push ecx
push 0
push 0x5df25c
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x58dc50
mov edx, dword [ebp - 8]
test edx, edx
js 0x58dc99
mov eax, dword [esi]
mov ecx, 1
sub ecx, dword [eax - 4]
mov eax, dword [eax - 8]
sub eax, edx
or ecx, eax
jge 0x58dc06
push edx
mov ecx, esi
call fcn.00402400
lea eax, [ebp - 8]
push eax
push dword [esi]
push 0
push 0
push 0x5df25c
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
mov eax, dword [esi]
je 0x58dc60
test eax, eax
jne 0x58dc2c
xor ecx, ecx
jmp 0x58dc3e
push dword [eax - 8]
push eax
call fcn.005360d5
mov ecx, eax
add esp, 8
test ecx, ecx
js 0x58dc99
mov eax, dword [esi]
cmp ecx, dword [eax - 8]
jg 0x58dc99
mov dword [eax - 0xc], ecx
xor edx, edx
mov eax, dword [esi]
mov word [eax + ecx*2], dx
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
pop esi
mov esp, ebp
pop ebp
ret
test eax, eax
je 0x58dc74
push dword [eax - 8]
push eax
call fcn.005360d5
add esp, 8
test eax, eax
js 0x58dc99
mov ecx, dword [esi]
cmp eax, dword [ecx - 8]
jg 0x58dc99
mov dword [ecx - 0xc], eax
xor edx, edx
mov ecx, dword [esi]
mov word [ecx + eax*2], dx
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, 1
pop esi
mov esp, ebp
pop ebp
ret
push 0x80070057
call fcn.00401e70
int3
Function at 0x58dcb0
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push esi
lea eax, [ebp - 4]
mov dword [ebp - 4], 0
push eax
push 0x20019
push 0
push str.SOFTWARECanonIJ_Scan_Utility
push SysReAllocString
mov esi, ecx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
mov eax, dword [ebp - 4]
test eax, eax
je 0x58dd89
lea ecx, [ebp - 8]
mov dword [ebp - 8], 0
push ecx
push 0
lea ecx, [ebp - 0xc]
mov dword [ebp - 0xc], 0
push ecx
push 0
push str.PEManualDEV
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x58dd80
mov edx, dword [ebp - 8]
test edx, edx
js 0x58ddc9
mov eax, dword [esi]
mov ecx, 1
sub ecx, dword [eax - 4]
mov eax, dword [eax - 8]
sub eax, edx
or ecx, eax
jge 0x58dd36
push edx
mov ecx, esi
call fcn.00402400
lea eax, [ebp - 8]
push eax
push dword [esi]
push 0
push 0
push str.PEManualDEV
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
mov eax, dword [esi]
je 0x58dd90
test eax, eax
jne 0x58dd5c
xor ecx, ecx
jmp 0x58dd6e
push dword [eax - 8]
push eax
call fcn.005360d5
mov ecx, eax
add esp, 8
test ecx, ecx
js 0x58ddc9
mov eax, dword [esi]
cmp ecx, dword [eax - 8]
jg 0x58ddc9
mov dword [eax - 0xc], ecx
xor edx, edx
mov eax, dword [esi]
mov word [eax + ecx*2], dx
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
pop esi
mov esp, ebp
pop ebp
ret
test eax, eax
je 0x58dda4
push dword [eax - 8]
push eax
call fcn.005360d5
add esp, 8
test eax, eax
js 0x58ddc9
mov ecx, dword [esi]
cmp eax, dword [ecx - 8]
jg 0x58ddc9
mov dword [ecx - 0xc], eax
xor edx, edx
mov ecx, dword [esi]
mov word [ecx + eax*2], dx
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, 1
pop esi
mov esp, ebp
pop ebp
ret
push 0x80070057
call fcn.00401e70
int3
Function at 0x58de10
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5a3560
mov eax, dword fs:[0]
push eax
sub esp, 0xc
push ebx
push esi
push edi
mov eax, dword [0x606040]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, ecx
mov dword [ebp - 0x18], eax
push 0
push 0x5dbfa4
call fcn.00403930
call fcn.0040a74d
xor edx, edx
mov ecx, eax
test ecx, ecx
setne dl
test edx, edx
jne 0x58de65
push 0x80004005
call fcn.00401e70
mov eax, dword [ecx]
call dword [eax + 0xc]
lea edi, [eax + 0x10]
mov dword [ebp - 0x14], edi
mov dword [ebp - 4], 0
mov ebx, 1
mov eax, dword [edi - 8]
mov ecx, ebx
sub ecx, dword [edi - 4]
sub eax, 0x104
or eax, ecx
jge 0x58de9d
push 0x104
lea ecx, [ebp - 0x14]
call fcn.00402400
mov edi, dword [ebp - 0x14]
push edi
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
push dword [edi - 8]
push edi
call fcn.005360d5
add esp, 8
test eax, eax
js 0x58dff0
cmp eax, dword [edi - 8]
jg 0x58dff0
xor ecx, ecx
mov dword [edi - 0xc], eax
mov word [edi + eax*2], cx
call fcn.0040a74d
xor ecx, ecx
mov edx, eax
test edx, edx
setne cl
test ecx, ecx
jne 0x58deeb
push 0x80004005
call fcn.00401e70
mov eax, dword [edx]
mov ecx, edx
call dword [eax + 0xc]
lea esi, [eax + 0x10]
mov dword [ebp - 0x10], esi
mov byte [ebp - 4], 1
mov ecx, ebx
mov eax, dword [esi - 8]
sub ecx, dword [esi - 4]
sub eax, 0x104
or eax, ecx
jge 0x58df1d
push 0x104
lea ecx, [ebp - 0x10]
call fcn.00402400
mov esi, dword [ebp - 0x10]
push 0x104
push esi
push edi
call dword [sym.imp.KERNEL32.dll_GetLongPathNameW]
push dword [esi - 8]
push esi
call fcn.005360d5
add esp, 8
test eax, eax
js 0x58dff0
cmp eax, dword [esi - 8]
jg 0x58dff0
mov dword [esi - 0xc], eax
xor ecx, ecx
mov word [esi + eax*2], cx
mov eax, dword [esi - 8]
sub ebx, dword [esi - 4]
sub eax, 0x104
or eax, ebx
jge 0x58df6f
push 0x104
lea ecx, [ebp - 0x10]
call fcn.00402400
mov esi, dword [ebp - 0x10]
push esi
call dword [sym.imp.SHLWAPI.dll_PathRemoveBackslashW]
push dword [esi - 8]
push esi
call fcn.005360d5
add esp, 8
test eax, eax
js 0x58dff0
cmp eax, dword [esi - 8]
jg 0x58dff0
xor ecx, ecx
mov dword [esi - 0xc], eax
mov word [esi + eax*2], cx
lea eax, [ebp - 0x10]
mov ecx, dword [ebp - 0x18]
push eax
call fcn.00403360
lea edx, [esi - 0x10]
mov byte [ebp - 4], 0
or esi, 0xffffffff
lea ecx, [edx + 0xc]
mov eax, esi
lock xadd dword [ecx], eax
dec eax
test eax, eax
jg 0x58dfc0
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
add edi, 0xfffffff0
mov dword [ebp - 4], 0xffffffff
lea eax, [edi + 0xc]
lock xadd dword [eax], esi
dec esi
test esi, esi
jg 0x58dfde
mov ecx, dword [edi]
push edi
mov eax, dword [ecx]
call dword [eax + 4]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push 0x80070057
call fcn.00401e70
int3
Function at 0x58e000
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push esi
lea eax, [ebp - 4]
mov dword [ebp - 4], 0
push eax
push 0x20019
push 0
push str.SOFTWARECanonIJ_Scan_Utility
push SysReAllocString
mov esi, ecx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
mov eax, dword [ebp - 4]
test eax, eax
je 0x58e0d9
lea ecx, [ebp - 8]
mov dword [ebp - 8], 0
push ecx
push 0
lea ecx, [ebp - 0xc]
mov dword [ebp - 0xc], 0
push ecx
push 0
push str.TempDir
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x58e0d0
mov edx, dword [ebp - 8]
test edx, edx
js 0x58e119
mov eax, dword [esi]
mov ecx, 1
sub ecx, dword [eax - 4]
mov eax, dword [eax - 8]
sub eax, edx
or ecx, eax
jge 0x58e086
push edx
mov ecx, esi
call fcn.00402400
lea eax, [ebp - 8]
push eax
push dword [esi]
push 0
push 0
push str.TempDir
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
mov eax, dword [esi]
je 0x58e0e0
test eax, eax
jne 0x58e0ac
xor ecx, ecx
jmp 0x58e0be
push dword [eax - 8]
push eax
call fcn.005360d5
mov ecx, eax
add esp, 8
test ecx, ecx
js 0x58e119
mov eax, dword [esi]
cmp ecx, dword [eax - 8]
jg 0x58e119
mov dword [eax - 0xc], ecx
xor edx, edx
mov eax, dword [esi]
mov word [eax + ecx*2], dx
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
pop esi
mov esp, ebp
pop ebp
ret
test eax, eax
je 0x58e0f4
push dword [eax - 8]
push eax
call fcn.005360d5
add esp, 8
test eax, eax
js 0x58e119
mov ecx, dword [esi]
cmp eax, dword [ecx - 8]
jg 0x58e119
mov dword [ecx - 0xc], eax
xor edx, edx
mov ecx, dword [esi]
mov word [ecx + eax*2], dx
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, 1
pop esi
mov esp, ebp
pop ebp
ret
push 0x80070057
call fcn.00401e70
int3
Function at 0x58e130
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push esi
lea eax, [ebp - 4]
mov dword [ebp - 4], 0
push eax
push 0x20019
push 0
push str.SOFTWARECanonIJ_Scan_Utility
push SysReAllocString
mov esi, ecx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
mov eax, dword [ebp - 4]
test eax, eax
je 0x58e209
lea ecx, [ebp - 8]
mov dword [ebp - 8], 0
push ecx
push 0
lea ecx, [ebp - 0xc]
mov dword [ebp - 0xc], 0
push ecx
push 0
push str.PEDev
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x58e200
mov edx, dword [ebp - 8]
test edx, edx
js 0x58e249
mov eax, dword [esi]
mov ecx, 1
sub ecx, dword [eax - 4]
mov eax, dword [eax - 8]
sub eax, edx
or ecx, eax
jge 0x58e1b6
push edx
mov ecx, esi
call fcn.00402400
lea eax, [ebp - 8]
push eax
push dword [esi]
push 0
push 0
push str.PEDev
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
mov eax, dword [esi]
je 0x58e210
test eax, eax
jne 0x58e1dc
xor ecx, ecx
jmp 0x58e1ee
push dword [eax - 8]
push eax
call fcn.005360d5
mov ecx, eax
add esp, 8
test ecx, ecx
js 0x58e249
mov eax, dword [esi]
cmp ecx, dword [eax - 8]
jg 0x58e249
mov dword [eax - 0xc], ecx
xor edx, edx
mov eax, dword [esi]
mov word [eax + ecx*2], dx
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
pop esi
mov esp, ebp
pop ebp
ret
test eax, eax
je 0x58e224
push dword [eax - 8]
push eax
call fcn.005360d5
add esp, 8
test eax, eax
js 0x58e249
mov ecx, dword [esi]
cmp eax, dword [ecx - 8]
jg 0x58e249
mov dword [ecx - 0xc], eax
xor edx, edx
mov ecx, dword [esi]
mov word [ecx + eax*2], dx
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, 1
pop esi
mov esp, ebp
pop ebp
ret
push 0x80070057
call fcn.00401e70
int3
Function at 0x58e9e0
Capabilities:
Create directory

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5a3676
mov eax, dword fs:[0]
push eax
sub esp, 8
push ebx
push esi
push edi
mov eax, dword [0x606040]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 4], 0
or ebx, 0xffffffff
mov eax, dword [ebp + 8]
cmp dword [eax - 0xc], 0
je 0x58ead8
push eax
call dword [sym.imp.SHLWAPI.dll_PathIsDirectoryW]
test eax, eax
jne 0x58ead5
mov eax, dword [ebp + 8]
add eax, 0xfffffff0
push eax
call fcn.004039f0
add esp, 4
lea esi, [eax + 0x10]
mov dword [ebp - 0x10], esi
mov byte [ebp - 4], 1
mov ecx, 1
mov eax, dword [esi - 8]
sub ecx, dword [esi - 4]
sub eax, 0x104
or eax, ecx
jge 0x58ea6b
push 0x104
lea ecx, [ebp - 0x10]
call fcn.00402400
mov esi, dword [ebp - 0x10]
push esi
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
push dword [esi - 8]
push esi
call fcn.005360d5
add esp, 8
test eax, eax
js 0x58eb08
cmp eax, dword [esi - 8]
jg 0x58eb08
xor ecx, ecx
mov dword [esi - 0xc], eax
push ecx
mov word [esi + eax*2], cx
mov edi, esp
add esi, 0xfffffff0
push esi
call fcn.004039f0
add esp, 4
add eax, 0x10
mov dword [edi], eax
call fcn.0058e9e0
add esp, 4
push 0
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
mov byte [ebp - 4], 0
lea eax, [esi + 0xc]
mov ecx, ebx
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x58ead5
mov ecx, dword [esi]
push esi
mov eax, dword [ecx]
call dword [eax + 4]
mov eax, dword [ebp + 8]
lea edx, [eax - 0x10]
mov dword [ebp - 4], 0xffffffff
lea eax, [edx + 0xc]
lock xadd dword [eax], ebx
dec ebx
test ebx, ebx
jg 0x58eaf6
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push 0x80070057
call fcn.00401e70
int3
Function at 0x58eec0
Capabilities:
Check if file exists
Create directory

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5a3718
mov eax, dword fs:[0]
push eax
sub esp, 0x14
push esi
push edi
mov eax, dword [0x606040]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
mov dword [ebp - 0x18], esi
mov dword [ebp - 4], 0
mov dword [ebp - 0x14], 0
mov eax, dword [edx]
sub eax, 0x10
push eax
call fcn.004039f0
add eax, 0x10
add esp, 4
mov dword [esi], eax
mov dword [ebp - 4], 0
mov eax, 0xff0
mov dword [ebp - 0x14], 1
cmp word [ebp + 8], ax
jne 0x58efe3
push 0
call fcn.005389d1
add esp, 4
mov dword [ebp - 0x20], eax
lea eax, [ebp + 8]
mov dword [ebp - 0x1c], edx
lea ecx, [ebp - 0x20]
push str._Y__m__d
push eax
call fcn.004095f0
mov dword [ebp - 4], 1
mov ecx, 1
mov edi, dword [eax]
mov eax, dword [esi]
sub ecx, dword [eax - 4]
mov eax, dword [eax - 8]
sub eax, 0x104
or eax, ecx
jge 0x58ef76
push 0x104
mov ecx, esi
call fcn.00402400
push edi
push dword [esi]
call dword [sym.imp.SHLWAPI.dll_PathAppendW]
mov byte [ebp - 4], 0
or ecx, 0xffffffff
mov edx, dword [ebp + 8]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x58efa0
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov eax, dword [esi]
test eax, eax
jne 0x58efaa
xor ecx, ecx
jmp 0x58efbc
push dword [eax - 8]
push eax
call fcn.005360d5
mov ecx, eax
add esp, 8
test ecx, ecx
js 0x58eff6
mov eax, dword [esi]
cmp ecx, dword [eax - 8]
jg 0x58eff6
mov dword [eax - 0xc], ecx
xor edx, edx
mov eax, dword [esi]
mov word [eax + ecx*2], dx
push dword [esi]
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x58efe3
push eax
push dword [esi]
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
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
push 0x80070057
call fcn.00401e70
int3