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

Disassembly:
push 0x3c
mov eax, 0x426179
call fcn.00418141
mov edi, ecx
cmp dword [edi + 0x2c], 0xffffffff
jne 0x406d98
cmp byte [edi + 0x10], 0
je 0x406d98
lea esi, [edi + 0x14]
xor ebx, ebx
cmp dword [esi + 0x14], 8
mov dword [esi + 0x10], ebx
jb 0x406c96
mov eax, dword [esi]
jmp 0x406c98
mov eax, esi
xor ecx, ecx
mov word [eax], cx
xor eax, eax
mov dword [ebp - 0x14], 7
mov dword [ebp - 0x18], ebx
mov word [ebp - 0x28], ax
lea ecx, [ebp - 0x28]
mov dword [ebp - 4], ebx
call fcn.004084b2
test al, al
jne 0x406cfa
lea ecx, [ebp - 0x40]
call fcn.00407993
push eax
lea ecx, [ebp - 0x28]
call fcn.00402eab
push ebx
push 1
lea ecx, [ebp - 0x40]
call fcn.004065b8
cmp dword [ebp - 0x18], 0
jbe 0x406d8d
mov ebx, 0x42edd0
push ebx
call fcn.0041454e
pop ecx
push eax
push ebx
lea ecx, [ebp - 0x28]
call fcn.0040317e
xor ebx, ebx
cmp dword [ebp - 0x18], 0
jbe 0x406d8d
lea eax, [ebp - 0x28]
cmp esi, eax
je 0x406d16
push 0xffffffffffffffff
push ebx
push eax
mov ecx, esi
call fcn.004063ff
mov ebx, 0x42edd4
push ebx
call fcn.0041454e
pop ecx
push eax
push ebx
mov ecx, esi
call fcn.0040317e
cmp dword [esi + 0x14], 8
jb 0x406d33
mov esi, dword [esi]
xor ebx, ebx
push ebx
push 0x80
push 4
push ebx
push 1
push 4
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [edi + 0x2c], eax
cmp eax, 0xffffffff
je 0x406d8d
push ebx
lea ecx, [ebp - 0x48]
mov dword [ebp - 0x48], ebx
push ecx
push 3
lea ecx, [ebp - 0x44]
mov word [ebp - 0x44], 0xbbef
push ecx
push eax
mov byte [ebp - 0x42], 0xbf
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x406d7a
cmp dword [ebp - 0x48], 3
je 0x406d8d
cmp dword [edi + 0x2c], 0xffffffff
je 0x406d8d
push dword [edi + 0x2c]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
or dword [edi + 0x2c], 0xffffffff
push ebx
push 1
lea ecx, [ebp - 0x28]
call fcn.004065b8
xor eax, eax
cmp dword [edi + 0x2c], 0xffffffff
setne al
call fcn.004180f0
ret

Function at 0x406da7
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
mov esi, ecx
xor ebx, ebx
inc dword [esi + 0xc]
cmp dword [edi + 0x10], ebx
jbe 0x406e4f
cmp byte [esi + 0x10], 1
jne 0x406e2d
call fcn.00406c62
test al, al
je 0x406e2a
cmp dword [edi + 0x14], 0x10
mov ecx, dword [edi + 0x10]
mov dword [ebp - 4], ebx
mov dword [ebp + 8], ecx
jb 0x406de4
mov eax, dword [edi]
jmp 0x406de6
mov eax, edi
push ebx
lea edx, [ebp - 4]
push edx
push ecx
push eax
push dword [esi + 0x2c]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x406e2a
mov eax, dword [ebp + 8]
cmp eax, dword [ebp - 4]
jne 0x406e2a
push ebx
lea eax, [ebp - 4]
mov word [ebp + 8], 0xa0d
push eax
push 2
lea eax, [ebp + 8]
push eax
push dword [esi + 0x2c]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x406e2a
cmp dword [ebp - 4], 2
jne 0x406e2a
mov bl, 1
jmp 0x406e2d
mov byte [esi + 0x10], bl
cmp byte [esi + 0x10], 0
jne 0x406e4f
mov eax, dword [esi + 4]
sub eax, dword [esi]
push 0x18
cdq
pop ecx
idiv ecx
cmp eax, 0x40000
jae 0x406e4f
push edi
mov ecx, esi
call fcn.00406fed
mov bl, 1
pop edi
pop esi
mov al, bl
pop ebx
mov esp, ebp
pop ebp
ret 4
Function at 0x407a78
Capabilities:
Check if file exists
Create directory
Get common file path
Get startup folder

Disassembly:
push 0x214
mov eax, 0x4263eb
call fcn.00418141
mov esi, ecx
xor ebx, ebx
mov dword [ebp - 0x220], esi
mov dword [ebp - 0x21c], ebx
xor eax, eax
mov dword [esi + 0x14], 7
mov dword [esi + 0x10], ebx
mov word [esi], ax
lea eax, [ebp - 0x218]
mov dword [ebp - 4], ebx
push eax
push ebx
push ebx
push 0x1c
push ebx
mov dword [ebp - 0x21c], 1
call dword [sym.imp.SHELL32.dll_SHGetFolderPathW]
test eax, eax
jne 0x407ba1
cmp word [ebp - 0x218], ax
jne 0x407ada
mov eax, ebx
jmp 0x407ae7
lea eax, [ebp - 0x218]
push eax
call fcn.0041454e
pop ecx
push eax
lea eax, [ebp - 0x218]
mov ecx, esi
push eax
call fcn.00406681
mov ebx, 0x42edd0
push ebx
call fcn.0041454e
pop ecx
push eax
push ebx
mov ecx, esi
call fcn.0040317e
mov edi, 0x42e2b4
push edi
call fcn.0041454e
pop ecx
push eax
push edi
mov ecx, esi
call fcn.0040317e
cmp dword [esi + 0x14], 8
jb 0x407b2a
mov eax, dword [esi]
jmp 0x407b2c
mov eax, esi
mov ebx, dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
push eax
call ebx
mov edi, dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x407b50
cmp dword [esi + 0x14], 8
jb 0x407b49
mov eax, dword [esi]
jmp 0x407b4b
mov eax, esi
push 0
push eax
call edi
push str.Application
call fcn.0041454e
pop ecx
push eax
push str.Application
mov ecx, esi
call fcn.0040317e
cmp dword [esi + 0x14], 8
jb 0x407b72
mov eax, dword [esi]
jmp 0x407b74
mov eax, esi
push eax
call ebx
test eax, eax
jne 0x407b8c
cmp dword [esi + 0x14], 8
jb 0x407b85
mov eax, dword [esi]
jmp 0x407b87
mov eax, esi
push 0
push eax
call edi
mov edi, 0x42edd0
push edi
call fcn.0041454e
pop ecx
push eax
push edi
mov ecx, esi
call fcn.0040317e
mov eax, esi
call fcn.004180f0
ret

Function at 0x407e1f
Capabilities:
Query or enumerate registry value

Disassembly:
push 0x38
mov eax, 0x426506
call fcn.00418141
mov dword [ebp - 0x38], edx
mov eax, ecx
mov dword [ebp - 0x30], eax
mov esi, dword [ebp + 8]
xor edx, edx
mov dword [ebp - 0x3c], edx
xor ecx, ecx
mov dword [eax + 0x14], 7
mov dword [eax + 0x10], edx
mov dword [ebp - 0x44], eax
mov word [eax], cx
mov dword [ebp - 4], edx
mov edi, 0x100
push 0x101
mov dword [ebp - 0x3c], 1
mov dword [ebp - 0x34], edi
call fcn.00417aa6
pop ecx
mov edx, esi
lea ecx, [ebp - 0x2c]
mov ebx, eax
call fcn.00407540
mov esi, dword [ebp - 0x38]
mov dword [ebp - 4], 1
cmp dword [ebp - 0x18], 8
lea ecx, [ebp - 0x34]
push ecx
push ebx
lea ecx, [ebp - 0x40]
push ecx
lea eax, [ebp - 0x2c]
cmovae eax, dword [ebp - 0x2c]
push 0
push eax
push esi
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
cmp eax, 0xea
jne 0x407ec3
add edi, edi
cmp edi, 0x100000
ja 0x407edf
push edi
push ebx
call fcn.00417b70
pop ecx
pop ecx
test eax, eax
je 0x407edf
mov ebx, eax
mov dword [ebp - 0x34], edi
jmp 0x407e80
test eax, eax
jne 0x407edf
cmp dword [ebp - 0x40], 1
jne 0x407edf
mov esi, dword [ebp - 0x30]
cmp dword [ebp - 0x34], eax
jbe 0x407ee2
push ebx
mov ecx, esi
call fcn.004066f8
jmp 0x407ee2
mov esi, dword [ebp - 0x30]
push ebx
call fcn.00417b38
pop ecx
push 0
push 1
lea ecx, [ebp - 0x2c]
call fcn.004065b8
mov eax, esi
call fcn.004180f0
ret
Function at 0x4080d7
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x20
mov eax, dword [0x4351f0]
xor eax, esp
mov dword [esp + 0x1c], eax
push ebx
push esi
mov esi, ecx
lea ecx, [esp + 0xc]
call fcn.00407540
cmp dword [esp + 0x20], 8
lea ecx, [ebp + 8]
push 4
push ecx
push 4
lea eax, [esp + 0x18]
cmovae eax, dword [esp + 0x18]
push 0
push eax
push esi
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
mov ebx, eax
lea ecx, [esp + 0xc]
neg ebx
push 0
sbb bl, bl
push 1
inc bl
call fcn.004065b8
mov ecx, dword [esp + 0x24]
mov al, bl
pop esi
pop ebx
xor ecx, esp
call fcn.0041453f
mov esp, ebp
pop ebp
ret

Function at 0x408140
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30
mov eax, dword [0x4351f0]
xor eax, ebp
mov dword [ebp - 8], eax
push ebx
push esi
push edi
push 4
mov esi, ecx
mov edx, str.InstallerResult
pop ebx
lea ecx, [ebp - 0x20]
mov dword [ebp - 0x24], ebx
or edi, 0xffffffff
call fcn.00407540
cmp dword [ebp - 0xc], 8
lea ecx, [ebp - 0x24]
push ecx
lea ecx, [ebp - 0x2c]
push ecx
lea ecx, [ebp - 0x28]
push ecx
lea eax, [ebp - 0x20]
cmovae eax, dword [ebp - 0x20]
push 0
push eax
push esi
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x40819c
cmp dword [ebp - 0x24], ebx
jne 0x40819c
cmp dword [ebp - 0x28], ebx
cmove edi, dword [ebp - 0x2c]
push 0
push 1
lea ecx, [ebp - 0x20]
call fcn.004065b8
mov ecx, dword [ebp - 8]
mov eax, edi
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0041453f
mov esp, ebp
pop ebp
ret

Function at 0x4081bb
Capabilities:
Enumerate processes

Disassembly:
push 0x254
mov eax, 0x4265bd
call fcn.00418141
mov edi, ecx
push 0
push 2
call dword [sym.imp.KERNEL32.dll_CreateToolhelp32Snapshot]
mov esi, eax
cmp esi, 0xffffffff
je 0x40825c
mov ecx, edi
call fcn.00403af9
lea eax, [ebp - 0x258]
mov dword [ebp - 0x258], 0x22c
push eax
push esi
call dword [sym.imp.KERNEL32.dll_Process32FirstW]
lea eax, [ebp - 0x234]
push eax
call dword [sym.imp.USER32.dll_CharLowerW]
lea edx, [ebp - 0x234]
lea ecx, [ebp - 0x28]
call fcn.00407358
and dword [ebp - 4], 0
movzx ecx, byte [0x43746a]
push ecx
push eax
push ecx
lea eax, [ebp - 0x260]
mov ecx, edi
push eax
call fcn.004090a3
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x28]
push 0
push 1
call fcn.004062d8
lea eax, [ebp - 0x258]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_Process32NextW]
test eax, eax
jne 0x4081fc
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
call fcn.004180f0
ret
Function at 0x4082b2
Capabilities:
Get installed programs
Query or enumerate registry key

Disassembly:
push 0x858
mov eax, 0x4265fb
call fcn.00418141
mov eax, dword [ebp + 8]
xor ebx, ebx
mov dword [ebp - 0x85c], eax
mov edi, ebx
lea eax, [ebp - 0x850]
mov dword [ebp - 0x850], ebx
push eax
push edx
push ebx
push str.SOFTWAREMicrosoftWindowsCurrentVersionUninstall
push ecx
mov dword [ebp - 0x858], ebx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x4083fd
push ebx
push ebx
push ebx
push ebx
lea eax, [ebp - 0x854]
push eax
lea eax, [ebp - 0x81c]
push eax
push ebx
mov ebx, dword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
jmp 0x4083d7
lea eax, [ebp - 0x858]
inc edi
push eax
push 0x20119
push 0
lea eax, [ebp - 0x81c]
push eax
push dword [ebp - 0x850]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x4083c2
mov edx, dword [ebp - 0x858]
lea ecx, [ebp - 0x834]
push str.DisplayName
call fcn.00407e1f
pop ecx
and dword [ebp - 4], 0
cmp dword [ebp - 0x824], 0
jbe 0x4083a3
lea edx, [ebp - 0x834]
lea ecx, [ebp - 0x84c]
call fcn.00407289
mov byte [ebp - 4], 1
movzx ecx, byte [0x43746a]
push ecx
push eax
push ecx
mov ecx, dword [ebp - 0x85c]
lea eax, [ebp - 0x864]
push eax
call fcn.004090a3
push 0
push 1
lea ecx, [ebp - 0x84c]
call fcn.004062d8
push dword [ebp - 0x858]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x834]
push 0
push 1
call fcn.004065b8
xor eax, eax
push eax
push eax
push eax
push eax
lea eax, [ebp - 0x854]
push eax
lea eax, [ebp - 0x81c]
push eax
push edi
push dword [ebp - 0x850]
mov dword [ebp - 0x854], 0x400
call ebx
test eax, eax
je 0x408315
push dword [ebp - 0x850]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
call fcn.004180f0
ret

Function at 0x4084b2
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20c
mov eax, dword [0x4351f0]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
lea eax, [ebp - 0x20c]
mov esi, ecx
push eax
push 0x104
xor bl, bl
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
cmp eax, 0x105
ja 0x4084f9
test eax, eax
je 0x4084f9
push eax
lea eax, [ebp - 0x20c]
mov ecx, esi
push eax
call fcn.00406681
inc bl
mov ecx, dword [ebp - 4]
mov al, bl
pop esi
xor ecx, ebp
pop ebx
call fcn.0041453f
mov esp, ebp
pop ebp
ret

Function at 0x40850b
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push ebx
push esi
push edi
xor ebx, ebx
mov dword [ebp - 8], ecx
push ebx
push 0x80
push 2
push ebx
push ebx
push 0x40000000
push dword [ebp + 8]
mov edi, edx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
cmp esi, 0xffffffff
je 0x40855e
push ebx
lea eax, [ebp - 4]
mov dword [ebp - 4], ebx
push eax
push edi
push dword [ebp - 8]
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x408557
cmp dword [ebp - 4], edi
jne 0x408557
mov bl, 1
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
mov al, bl
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x408567
Capabilities:
Hash data using sha1
Hash data using sha1 via wincrypt
Hash data via wincrypt
Initialize hashing via wincrypt
Read file on windows

Disassembly:
push 0x4c
mov eax, 0x42665e
call fcn.00418141
mov edi, edx
mov esi, ecx
xor eax, eax
mov dword [ebp - 0x2c], 0xf
mov dword [ebp - 0x58], eax
mov dword [ebp - 0x30], eax
mov byte [ebp - 0x40], al
mov dword [ebp - 4], eax
push 0x10000
mov dword [ebp - 0x48], eax
mov dword [ebp - 0x44], eax
mov dword [ebp - 0x50], eax
mov dword [ebp - 0x4c], eax
call fcn.00417aa6
mov ebx, eax
mov dword [ebp - 0x54], ebx
pop ecx
test ebx, ebx
je 0x40870a
cmp dword [edi + 0x14], 8
jb 0x4085b8
mov edi, dword [edi]
push 0
push 0x8000000
push 3
push 0
push 1
push 0x80000000
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
cmp edi, 0xffffffff
je 0x408703
push 0xf0000000
push 1
push 0
push 0
lea eax, [ebp - 0x48]
push eax
call dword [sym.imp.ADVAPI32.dll_CryptAcquireContextW]
test eax, eax
jne 0x408601
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x40870a
lea eax, [ebp - 0x44]
push eax
push 0
push 0
push 0x8004
push dword [ebp - 0x48]
call dword [sym.imp.ADVAPI32.dll_CryptCreateHash]
test eax, eax
jne 0x40864c
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor ebx, ebx
push ebx
push dword [ebp - 0x48]
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
jmp 0x40870c
cmp dword [ebp - 0x50], 0
je 0x408684
push 0
push dword [ebp - 0x50]
push ebx
push dword [ebp - 0x44]
call dword [sym.imp.ADVAPI32.dll_CryptHashData]
test eax, eax
je 0x408663
push 0
lea eax, [ebp - 0x50]
push eax
push 0x10000
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x408633
xor ebx, ebx
push ebx
push dword [ebp - 0x48]
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
push dword [ebp - 0x44]
call dword [sym.imp.ADVAPI32.dll_CryptDestroyHash]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x40870c
test eax, eax
je 0x408663
push 0
lea eax, [ebp - 0x4c]
mov dword [ebp - 0x4c], 0x14
push eax
lea eax, [ebp - 0x28]
push eax
push 2
push dword [ebp - 0x44]
call dword [sym.imp.ADVAPI32.dll_CryptGetHashParam]
test eax, eax
je 0x4086e8
xor ebx, ebx
cmp dword [ebp - 0x4c], ebx
jbe 0x4086e5
movzx eax, byte [ebp + ebx - 0x28]
lea ecx, [ebp - 0x40]
shr eax, 4
movzx eax, byte [eax + 0x42e190]
push eax
call fcn.00405adb
movzx eax, byte [ebp + ebx - 0x28]
lea ecx, [ebp - 0x40]
and eax, 0xf
movzx eax, byte [eax + 0x42e190]
push eax
call fcn.00405adb
inc ebx
cmp ebx, dword [ebp - 0x4c]
jb 0x4086af
mov ebx, dword [ebp - 0x54]
push dword [ebp - 0x44]
call dword [sym.imp.ADVAPI32.dll_CryptDestroyHash]
push 0
push dword [ebp - 0x48]
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push ebx
call fcn.00417b38
pop ecx
xor ebx, ebx
lea eax, [ebp - 0x40]
mov dword [esi + 0x14], 0xf
mov dword [esi + 0x10], ebx
mov ecx, esi
push eax
mov byte [esi], bl
call fcn.00405f3c
push ebx
push 1
lea ecx, [ebp - 0x40]
call fcn.004062d8
mov eax, esi
call fcn.004180f0
ret
Function at 0x408736
Capabilities:
Create new key via cryptacquirecontext
Hash data via wincrypt
Hash data with md5
Initialize hashing via wincrypt

Disassembly:
push 0x28
mov eax, 0x42669c
call fcn.00418141
mov esi, edx
mov edi, ecx
xor ebx, ebx
mov dword [ebp - 0x34], edi
mov dword [ebp - 0x30], ebx
mov dword [edi + 0x14], 0xf
mov dword [edi + 0x10], ebx
mov byte [edi], bl
xor eax, eax
mov dword [ebp - 4], ebx
push 0xf0000000
inc eax
mov dword [ebp - 0x28], ebx
push eax
push ebx
mov dword [ebp - 0x30], eax
lea eax, [ebp - 0x28]
push ebx
push eax
mov dword [ebp - 0x24], ebx
call dword [sym.imp.ADVAPI32.dll_CryptAcquireContextW]
test eax, eax
je 0x408823
lea eax, [ebp - 0x24]
push eax
push ebx
push ebx
push 0x8003
push dword [ebp - 0x28]
call dword [sym.imp.ADVAPI32.dll_CryptCreateHash]
test eax, eax
je 0x408819
cmp dword [esi + 0x14], 0x10
mov eax, dword [esi + 0x10]
jb 0x4087a6
mov esi, dword [esi]
push ebx
push eax
push esi
push dword [ebp - 0x24]
call dword [sym.imp.ADVAPI32.dll_CryptHashData]
test eax, eax
je 0x408810
push ebx
lea eax, [ebp - 0x2c]
mov dword [ebp - 0x2c], 0x10
push eax
lea eax, [ebp - 0x20]
push eax
push 2
push dword [ebp - 0x24]
call dword [sym.imp.ADVAPI32.dll_CryptGetHashParam]
test eax, eax
je 0x408810
mov esi, ebx
cmp dword [ebp - 0x2c], esi
jbe 0x408810
movzx eax, byte [ebp + esi - 0x20]
mov ecx, edi
shr eax, 4
movzx eax, byte [eax + 0x42e190]
push eax
call fcn.00405adb
movzx eax, byte [ebp + esi - 0x20]
mov ecx, edi
and eax, 0xf
movzx eax, byte [eax + 0x42e190]
push eax
call fcn.00405adb
inc esi
cmp esi, dword [ebp - 0x2c]
jb 0x4087dc
push dword [ebp - 0x24]
call dword [sym.imp.ADVAPI32.dll_CryptDestroyHash]
push ebx
push dword [ebp - 0x28]
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
mov eax, edi
call fcn.004180f0
ret
Function at 0x408973
Capabilities:
Get common file path
Get file version info

Disassembly:
push 0x25c
mov eax, 0x42674d
call fcn.00418141
mov esi, ecx
xor ebx, ebx
mov dword [ebp - 0x268], esi
mov dword [ebp - 0x258], ebx
mov dword [esi + 0x14], 0xf
mov dword [esi + 0x10], ebx
mov byte [esi], bl
push 0x104
lea eax, [ebp - 0x224]
mov dword [ebp - 4], ebx
push eax
mov dword [ebp - 0x258], 1
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
test eax, eax
je 0x408bbf
xor ecx, ecx
mov dword [ebp - 0x228], 7
push eax
lea eax, [ebp - 0x224]
mov word [ebp - 0x23c], cx
push eax
lea ecx, [ebp - 0x23c]
mov dword [ebp - 0x22c], ebx
call fcn.00406681
mov edi, str._ntoskrnl.exe
mov dword [ebp - 4], 1
push edi
call fcn.0041454e
pop ecx
push eax
push edi
lea ecx, [ebp - 0x23c]
call fcn.0040317e
cmp dword [ebp - 0x228], 8
lea ecx, [ebp - 0x260]
lea eax, [ebp - 0x23c]
cmovae eax, dword [ebp - 0x23c]
push ecx
push eax
call dword [sym.imp.VERSION.dll_GetFileVersionInfoSizeW]
mov ebx, eax
test ebx, ebx
je 0x408bb0
push ebx
call fcn.00417aa6
mov edi, eax
pop ecx
test edi, edi
je 0x408bb0
cmp dword [ebp - 0x228], 8
lea eax, [ebp - 0x23c]
push edi
cmovae eax, dword [ebp - 0x23c]
push ebx
push 0
push eax
call dword [sym.imp.VERSION.dll_GetFileVersionInfoW]
test eax, eax
je 0x408ba9
lea eax, [ebp - 0x264]
push eax
lea eax, [ebp - 0x25c]
push eax
push 0x42edd0
push edi
call dword [sym.imp.VERSION.dll_VerQueryValueW]
test eax, eax
je 0x408ba9
mov ebx, dword [ebp - 0x25c]
cmp dword [ebx], 0xfeef04bd
jne 0x408ba9
movzx edx, word [ebx + 0xa]
lea ecx, [ebp - 0x254]
call fcn.00405baf
push eax
mov ecx, esi
call fcn.00402e5e
push 0
push 1
lea ecx, [ebp - 0x254]
call fcn.004062d8
push 0x42ed94
call fcn.00415410
pop ecx
push eax
push 0x42ed94
mov ecx, esi
call fcn.00405bf6
movzx edx, word [ebx + 8]
lea ecx, [ebp - 0x254]
call fcn.00405baf
push 0xffffffffffffffff
push 0
push eax
mov ecx, esi
mov byte [ebp - 4], 2
call fcn.00405c98
push 0
push 1
lea ecx, [ebp - 0x254]
mov byte [ebp - 4], 1
call fcn.004062d8
push 0x42ed94
call fcn.00415410
pop ecx
push eax
push 0x42ed94
mov ecx, esi
call fcn.00405bf6
movzx edx, word [ebx + 0xe]
lea ecx, [ebp - 0x254]
call fcn.00405baf
push 0xffffffffffffffff
push 0
push eax
mov ecx, esi
mov byte [ebp - 4], 3
call fcn.00405c98
push 0
push 1
lea ecx, [ebp - 0x254]
mov byte [ebp - 4], 1
call fcn.004062d8
push 0x42ed94
call fcn.00415410
pop ecx
push eax
push 0x42ed94
mov ecx, esi
call fcn.00405bf6
movzx edx, word [ebx + 0xc]
lea ecx, [ebp - 0x254]
call fcn.00405baf
push 0xffffffffffffffff
push 0
push eax
mov ecx, esi
mov byte [ebp - 4], 4
call fcn.00405c98
push 0
push 1
lea ecx, [ebp - 0x254]
call fcn.004062d8
push edi
call fcn.00417b38
pop ecx
push 0
push 1
lea ecx, [ebp - 0x23c]
call fcn.004065b8
mov eax, esi
call fcn.004180f0
ret
Function at 0x40a496
Capabilities:
Check if file exists
Delete file

Disassembly:
push ecx
push esi
push edi
mov edi, ecx
cmp dword [edi + 0x10], 0xffffffff
jne 0x40a4ff
cmp byte [edi + 0xc], 2
jne 0x40a4ff
lea esi, [edi + 0x20]
mov ecx, esi
call fcn.00408403
cmp dword [esi + 0x14], 8
jb 0x40a4bb
mov eax, dword [esi]
jmp 0x40a4bd
mov eax, esi
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x40a4db
cmp dword [esi + 0x14], 8
jb 0x40a4d2
mov eax, dword [esi]
jmp 0x40a4d4
mov eax, esi
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
cmp dword [esi + 0x14], 8
jb 0x40a4e3
mov esi, dword [esi]
push 0
push 0x80
push 2
push 0
push 1
push 0xc0000000
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [edi + 0x10], eax
xor eax, eax
cmp dword [edi + 0x10], 0xffffffff
pop edi
setne al
pop esi
pop ecx
ret

Function at 0x40a50c
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
push edi
mov edi, ecx
xor ebx, ebx
mov al, byte [edi + 0xc]
inc dword [edi + 0x1c]
cmp al, 2
jne 0x40a553
call fcn.0040a496
test al, al
je 0x40a54d
push ebx
lea eax, [ebp - 4]
mov dword [ebp - 4], ebx
push eax
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [edi + 0x10]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x40a54d
mov eax, dword [ebp - 4]
add dword [edi + 0x14], eax
jmp 0x40a572
mov byte [edi + 0x18], 1
jmp 0x40a574
cmp al, 1
jne 0x40a574
mov ecx, dword [ebp + 8]
mov esi, dword [ebp + 0xc]
push dword [ebp + 8]
lea eax, [ecx + esi]
push eax
push ecx
push dword [edi + 4]
mov ecx, edi
call fcn.0040a57f
add dword [edi + 0x14], esi
mov bl, 1
pop edi
pop esi
mov al, bl
pop ebx
mov esp, ebp
pop ebp
ret 8
Function at 0x40bdbd
Capabilities:
Check if file exists
Get file size
Read file on windows

Disassembly:
push 0x6c
mov eax, 0x426e5c
call fcn.00418141
mov eax, ecx
mov dword [ebp - 0x64], eax
xor bl, bl
lea esi, [eax + 0x80]
cmp dword [esi + 0x14], 8
mov byte [ebp - 0x59], bl
jb 0x40bde3
mov eax, dword [esi]
jmp 0x40bde5
mov eax, esi
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x40bf6f
xor ebx, ebx
mov dword [ebp - 0x14], 0xf
mov dword [ebp - 0x18], ebx
mov byte [ebp - 0x28], bl
mov dword [ebp - 4], ebx
cmp dword [esi + 0x14], 8
jb 0x40be0e
mov esi, dword [esi]
push ebx
push 0x80
push 3
push ebx
push 1
push 0xc0000000
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
cmp esi, 0xffffffff
je 0x40be92
lea eax, [ebp - 0x60]
mov dword [ebp - 0x60], ebx
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
lea eax, [edi - 1]
cmp eax, 0xffffe
ja 0x40be8b
cmp dword [ebp - 0x60], 0
jne 0x40be8b
push ecx
lea eax, [edi + 1]
push eax
lea ecx, [ebp - 0x28]
call fcn.004074f3
cmp dword [ebp - 0x14], 0x10
lea ecx, [ebp - 0x60]
push ebx
push ecx
lea eax, [ebp - 0x28]
cmovae eax, dword [ebp - 0x28]
push edi
push eax
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x40be7b
cmp dword [ebp - 0x60], edi
je 0x40be8b
cmp dword [ebp - 0x14], 0x10
lea eax, [ebp - 0x28]
mov dword [ebp - 0x18], ebx
cmovae eax, dword [ebp - 0x28]
mov byte [eax], bl
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ebx, dword [ebp - 0x64]
add ebx, 0x44
mov ecx, ebx
call fcn.00407076
xor eax, eax
mov dword [ebp - 0x78], eax
mov dword [ebp - 0x70], eax
mov dword [ebp - 0x6c], eax
lea eax, [ebp - 0x28]
mov byte [ebp - 4], 1
push eax
lea edx, [ebp - 0x78]
lea ecx, [ebp - 0x40]
call fcn.00401834
pop ecx
mov byte [ebp - 4], 2
cmp dword [ebp - 0x30], 0
jne 0x40bf4c
cmp dword [ebp - 0x78], 5
jne 0x40bf4c
lea ecx, [ebp - 0x78]
call fcn.00401454
push str.allowed_origins
lea ecx, [ebp - 0x58]
mov esi, eax
call fcn.00405f0d
lea eax, [ebp - 0x58]
mov ecx, esi
push eax
lea eax, [ebp - 0x64]
push eax
call fcn.00403037
push 0
push 1
lea ecx, [ebp - 0x58]
call fcn.004062d8
mov eax, dword [ebp - 0x64]
cmp eax, dword [esi]
je 0x40bf3a
lea ecx, [eax + 0x28]
cmp dword [ecx], 4
jne 0x40bf3a
call fcn.00401419
mov edi, eax
mov esi, dword [edi]
jmp 0x40bf35
cmp dword [esi], 3
jne 0x40bf32
mov ecx, esi
call fcn.004013de
push eax
mov ecx, ebx
call fcn.00406fed
add esi, 0x10
cmp esi, dword [edi + 4]
jne 0x40bf1e
mov eax, dword [ebx + 4]
sub eax, dword [ebx]
push 0x18
cdq
pop ecx
idiv ecx
test eax, eax
setne bl
jmp 0x40bf4f
mov bl, byte [ebp - 0x59]
push 0
push 1
lea ecx, [ebp - 0x40]
call fcn.004062d8
lea ecx, [ebp - 0x78]
call fcn.00401269
push 0
push 1
lea ecx, [ebp - 0x28]
call fcn.004062d8
mov al, bl
call fcn.004180f0
ret