joyce8/EMBER2024-capa huggingface dataset:
Function at 0x10a9cd1
Capabilities:
Check os version

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x120
mov eax, dword [0x10b1090]
xor eax, ebp
mov dword [ebp - 4], eax
push edi
xor edi, edi
cmp dword [0x10b3fc4], edi
jne 0x10a9ded
push esi
mov esi, 0x11c
push esi
lea eax, [ebp - 0x120]
push edi
push eax
call sub.msvcrt.dll_memset
add esp, 0xc
lea eax, [ebp - 0x120]
mov dword [ebp - 0x120], esi
mov esi, dword [sym.imp.KERNEL32.dll_GetVersionExW]
push eax
call esi
test eax, eax
jne 0x10a9d38
lea eax, [ebp - 0x120]
push eax
mov dword [ebp - 0x120], 0x114
call esi
mov eax, dword [ebp - 0x110]
dec eax
mov dword [0x10b3fc4], edi
pop esi
je 0x10a9dc0
dec eax
jne 0x10a9ded
cmp dword [ebp - 0x11c], 5
jne 0x10a9dad
mov eax, dword [ebp - 0x118]
sub eax, edi
je 0x10a9da1
dec eax
je 0x10a9d8e
dec eax
je 0x10a9d74
mov dword [0x10b3fc4], 0x14
jmp 0x10a9ded
cmp word [ebp - 0xc], 1
jb 0x10a9d85
mov dword [0x10b3fc4], 0x10
or dword [0x10b3fc4], 4
jmp 0x10a9ded
cmp word [ebp - 0xc], 2
jb 0x10a9d85
mov dword [0x10b3fc4], 8
jmp 0x10a9d85
mov dword [0x10b3fc4], 4
jmp 0x10a9ded
cmp dword [ebp - 0x11c], 4
ja 0x10a9dff
mov dword [0x10b3fc4], 2
cmp dword [ebp - 0x11c], 4
jne 0x10a9ded
cmp dword [ebp - 0x118], edi
je 0x10a9de3
cmp dword [ebp - 0x118], 0xa
je 0x10a9de3
cmp dword [ebp - 0x118], 0x5a
jne 0x10a9ded
mov dword [0x10b3fc4], 1
mov ecx, dword [ebp - 4]
mov eax, dword [0x10b3fc4]
xor ecx, ebp
pop edi
call fcn.01001feb
leave
ret
mov dword [0x10b3fc4], 0x20
jmp 0x10a9ded

Function at 0x10a9e10
Capabilities:
Get geographical location

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x44
mov eax, dword [0x10b1090]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
push 0x20
lea eax, [ebp - 0x44]
push eax
push 8
push 0x404
mov esi, 0xc04
call dword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
test eax, eax
je 0x10a9e64
push 3
lea eax, [ebp - 0x44]
push 0x10a9e74
push eax
call sub.msvcrt.dll_wcsncmp
add esp, 0xc
mov esi, eax
neg esi
sbb esi, esi
and esi, 0xfffff800
add esi, 0xc04
mov ecx, dword [ebp - 4]
mov ax, si
xor ecx, ebp
pop esi
call fcn.01001feb
leave
ret

Function at 0x10a9e7f
Capabilities:
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x14
mov eax, dword [0x10b1090]
xor eax, ebp
mov dword [ebp - 4], eax
xor eax, eax
cmp ax, word [0x10b3fc8]
jne 0x10a9f1a
push esi
lea eax, [ebp - 0x10]
push eax
push 1
xor esi, esi
push esi
push 0x10aa010
push 0x80000002
mov dword [ebp - 0x14], 6
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x10a9f19
push edi
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 0xc]
push eax
push esi
push esi
push 0x10aa0c8
push dword [ebp - 0x10]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
push dword [ebp - 0x10]
mov edi, eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
cmp edi, esi
pop edi
jne 0x10a9f19
push 3
push dword [esi*8 + 0x10a9f30]
lea eax, [ebp - 0xc]
push eax
call sub.msvcrt.dll__wcsnicmp
add esp, 0xc
test eax, eax
je 0x10a9f0b
inc esi
cmp esi, 0x1c
jae 0x10a9f19
jmp 0x10a9eea
mov ax, word [esi*8 + 0x10a9f34]
mov word [0x10b3fc8], ax
pop esi
mov ecx, dword [ebp - 4]
mov ax, word [0x10b3fc8]
xor ecx, ebp
call fcn.01001feb
leave
ret
Function at 0x10ab261
Capabilities:
Check for time delay via gettickcount

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x20
push ebx
push esi
push edi
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov edi, dword [sym.imp.USER32.dll_PeekMessageW]
mov dword [ebp - 4], eax
xor esi, esi
push 6
push 0x4ff
push dword [ebp + 0xc]
push esi
push esi
call dword [sym.imp.USER32.dll_MsgWaitForMultipleObjectsEx]
mov ebx, eax
cmp ebx, esi
je 0x10ab2d7
jmp 0x10ab311
cmp dword [ebp - 0x1c], 0x12
je 0x10ab2e8
lea eax, [ebp - 0x20]
push eax
call dword [sym.imp.USER32.dll_TranslateMessage]
cmp dword [ebp - 0x1c], 0x20
jne 0x10ab2cd
mov eax, 0xfffe
cmp word [ebp - 0x14], ax
je 0x10ab2cd
push 0x7f02
push esi
call dword [sym.imp.USER32.dll_LoadCursorW]
push eax
call dword [sym.imp.USER32.dll_SetCursor]
jmp 0x10ab2d7
lea eax, [ebp - 0x20]
push eax
call dword [sym.imp.USER32.dll_DispatchMessageW]
push 1
push esi
push esi
push esi
lea eax, [ebp - 0x20]
push eax
call edi
test eax, eax
je 0x10ab2f6
jmp 0x10ab297
push dword [ebp - 0x18]
call dword [sym.imp.USER32.dll_PostQuitMessage]
mov ebx, 0x102
call dword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, dword [ebp - 4]
cmp eax, dword [ebp + 0x10]
jbe 0x10ab309
mov ebx, 0x102
cmp ebx, esi
je 0x10ab27d
pop edi
pop esi
mov eax, ebx
pop ebx
leave
ret 0xc

Function at 0x10ab81d
Capabilities:
Create process on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x454
mov eax, dword [0x10b1090]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push edi
mov edi, dword [ebp + 8]
lea eax, [ebp - 0x418]
push eax
lea eax, [ebp - 0x20c]
push eax
push 0x104f8c0
push 0x10ab8f8
push 2
push 0
mov dword [ebp - 0x418], 0x104
call sub.SHLWAPI.dll_AssocQueryStringW
mov ebx, eax
test ebx, ebx
jl 0x10ab8d3
push edi
push 0x10ab8e8
lea eax, [ebp - 0x414]
push 0x104
push eax
call fcn.010343ca
push 0x38
lea eax, [ebp - 0x450]
push 0
push eax
call sub.msvcrt.dll_memset
lea eax, [ebp - 0x20c]
mov dword [ebp - 0x444], eax
lea eax, [ebp - 0x414]
mov dword [ebp - 0x440], eax
add esp, 0x1c
lea eax, [ebp - 0x454]
push eax
mov dword [ebp - 0x454], 0x3c
mov dword [ebp - 0x438], 1
call sub.SHELL32.dll_ShellExecuteExW
test eax, eax
jne 0x10ab8d3
mov ebx, 0x80004005
mov ecx, dword [ebp - 4]
pop edi
mov eax, ebx
xor ecx, ebp
pop ebx
call fcn.01001feb
leave
ret 4
Function at 0x10ab907
Capabilities:
Create process on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x20e0
call fcn.010545e1
mov eax, dword [0x10b1090]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push esi
mov dword [ebp - 0x20a4], eax
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x2098], eax
lea eax, [ebp - 0x209c]
push eax
lea eax, [ebp - 0x104c]
push eax
push 0
push 0xffff
push 0x10abab8
push 0x101c150
mov esi, 0x80004005
mov dword [ebp - 0x209c], 0x1048
call sub.SHLWAPI.dll_SHRegGetValueFromHKCUHKLM
test eax, eax
jne 0x10aba7a
push ebx
push edi
mov edi, dword [sym.imp.KERNEL32.dll_lstrlenW]
mov ebx, 0x10abaa8
push ebx
call edi
push eax
push ebx
lea eax, [ebp - 0x104c]
push eax
call sub.SHLWAPI.dll_StrCmpNICW
test eax, eax
je 0x10ab9ae
mov ebx, 0x10aba94
push ebx
call edi
push eax
push ebx
lea eax, [ebp - 0x104c]
push eax
call sub.SHLWAPI.dll_StrCmpNICW
test eax, eax
jne 0x10aba78
mov ebx, 0x10aba8c
push ebx
lea eax, [ebp - 0x104c]
push eax
call sub.SHLWAPI.dll_StrStrIW
mov dword [ebp - 0x20a0], eax
test eax, eax
je 0x10aba78
lea ecx, [ebp - 0x104c]
sub eax, ecx
sar eax, 1
push eax
mov eax, ecx
push eax
mov esi, 0x824
push esi
lea eax, [ebp - 0x2094]
push eax
call fcn.0101cd02
push dword [ebp - 0x20a4]
lea eax, [ebp - 0x2094]
push esi
push eax
call fcn.01010e3b
push ebx
call edi
mov ecx, dword [ebp - 0x20a0]
lea eax, [ecx + eax*2]
push eax
push esi
lea eax, [ebp - 0x2094]
push eax
call fcn.01010e3b
push 0x38
lea eax, [ebp - 0x20dc]
push 0
push eax
call sub.msvcrt.dll_memset
mov eax, dword [ebp - 0x2098]
mov dword [ebp - 0x20d8], eax
lea eax, [ebp - 0x2094]
mov dword [ebp - 0x20d0], eax
add esp, 0xc
lea eax, [ebp - 0x20e0]
push eax
mov dword [ebp - 0x20e0], 0x3c
mov dword [ebp - 0x20c4], 1
call sub.SHELL32.dll_ShellExecuteExW
mov esi, eax
neg esi
sbb esi, esi
and esi, 0x7fffbffb
add esi, 0x80004005
pop edi
pop ebx
mov ecx, dword [ebp - 4]
mov eax, esi
xor ecx, ebp
pop esi
call fcn.01001feb
leave
ret 8
Function at 0x10abaed
Capabilities:
Create process on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0xd0
mov eax, dword [0x10b1090]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
dec eax
mov ecx, dword [ebp + 8]
push ebx
mov ebx, dword [ebp + 0x10]
push esi
mov dword [ebp - 0x94], ecx
mov esi, 0x80004005
je 0x10abb30
dec eax
je 0x10abbe5
dec eax
je 0x10abbdc
dec eax
jne 0x10abbca
lea ecx, [ebp - 0x90]
call fcn.0107ec95
push 0xffffffffffffffff
push 0x10abbf0
lea ecx, [ebp - 0x90]
call fcn.0107eeb3
mov esi, eax
test esi, esi
jl 0x10abbbf
lea eax, [ebp - 0x90]
push eax
push dword [ebp - 0x94]
call fcn.010ab778
mov esi, eax
test esi, esi
jl 0x10abbbf
push 0x38
lea eax, [ebp - 0xcc]
push 0
push eax
call sub.msvcrt.dll_memset
mov eax, dword [ebp - 0xc]
mov dword [ebp - 0xc0], eax
add esp, 0xc
lea eax, [ebp - 0xd0]
push eax
mov dword [ebp - 0xd0], 0x3c
mov dword [ebp - 0xc8], ebx
mov dword [ebp - 0xb4], 1
call sub.SHELL32.dll_ShellExecuteExW
mov esi, eax
neg esi
sbb esi, esi
and esi, 0x7fffbffb
add esi, 0x80004005
lea ecx, [ebp - 0x90]
call fcn.0107ecb2
mov ecx, dword [ebp - 4]
mov eax, esi
pop esi
xor ecx, ebp
pop ebx
call fcn.01001feb
leave
ret 0xc
push ebx
push ecx
call fcn.010ab907
jmp 0x10abbeb
push ecx
call fcn.010ab81d
mov esi, eax
jmp 0x10abbca
Function at 0x408fea
Capabilities:
Parse pe header

Disassembly:
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x409029
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x409029
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x409029
mov eax, 0x10b
cmp word [ecx + 0x18], ax
jne 0x409029
cmp dword [ecx + 0x74], 0xe
jbe 0x409029
cmp dword [ecx + 0xe8], 0
setne al
ret
xor al, al
ret

Function at 0x40eee6
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x4c04a8
push 0x4c04a0
push str.FlsAlloc
push 0x1f
call fcn.0040eda5
mov esi, eax
add esp, 0x10
test esi, esi
je 0x40ef1a
push dword [ebp + 8]
mov ecx, esi
call dword [0x427130]
call esi
jmp 0x40ef20
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x40ef64
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x4c04b8
push 0x4c04b0
push str.FlsGetValue
push 0x21
call fcn.0040eda5
mov esi, eax
add esp, 0x10
test esi, esi
je 0x40ef9b
push dword [ebp + 8]
mov ecx, esi
call dword [0x427130]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]

Function at 0x40efa3
Capabilities:
Set thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x4c04c0
push 0x4c04b8
push str.FlsSetValue
push 0x22
call fcn.0040eda5
mov esi, eax
add esp, 0x10
test esi, esi
je 0x40efdd
push dword [ebp + 0xc]
mov ecx, esi
push dword [ebp + 8]
call dword [0x427130]
call esi
pop esi
pop ebp
ret 8
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsSetValue]
Function at 0x401000
Capabilities:
Check if file exists
Create directory
Get file attributes

Disassembly:
push esi
mov esi, dword [esp + 0xc]
test esi, esi
je 0x401090
push ebp
mov ebp, dword [esp + 0x14]
push edi
mov edi, dword [esp + 0x10]
push ebx
cmp byte [esi], 0
je 0x40108d
push 0x5c
push esi
call dword [sym.imp.MSVCR71.dll_strchr]
mov esi, eax
test esi, esi
pop ecx
pop ecx
je 0x40108d
push edi
mov byte [esi], 0
call dword [sym.imp.kernel32.dll_GetFileAttributesA]
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x401066
push 0
push edi
call dword [sym.imp.kernel32.dll_CreateDirectoryA]
test eax, eax
jne 0x40105f
test ebp, ebp
je 0x40105f
push edi
push str.CreateDirectory___s_
push 5
call ebp
add esp, 0xc
jmp 0x401066
push edi
push 1
call ebp
pop ecx
pop ecx
test bl, 0x10
jne 0x401087
push 0xb7
call dword [sym.imp.kernel32.dll_SetLastError]
test ebp, ebp
je 0x401087
push edi
push str.CreateDirectory___s_
push 5
call ebp
add esp, 0xc
mov byte [esi], 0x5c
inc esi
jne 0x401018
pop ebx
pop edi
pop ebp
xor eax, eax
inc eax
pop esi
ret

Function at 0x4031f4
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x5c
pushal
call 0x403203
pop dword [ebp - 0x4c]
mov eax, 0x403203
sub dword [ebp - 0x4c], eax
mov dword [ebp - 0x5c], 0x6cd07913
sub dword [ebp - 0x5c], 0x1e7e33c8
mov dword [ebp - 0x58], 0x9b6cb35f
add dword [ebp - 0x58], 0x96c698e6
mov dword [ebp - 0x54], 0xac3cce5
add dword [ebp - 0x54], 0x41887749
mov dword [ebp - 0x50], 0xeab7f43e
add dword [ebp - 0x50], 0x15480bc2
lea eax, [ebp - 0x5c]
push eax
mov eax, 0x3c2ae9ac
sub eax, 0x3bea6920
add eax, dword [ebp - 0x4c]
call dword [eax]
mov dword [ebp - 0x5c], 0x15eeddda
add dword [ebp - 0x5c], 0x5e838b7c
mov dword [ebp - 0x58], 0x9d9a1736
add dword [ebp - 0x58], 0xa3d24a3f
mov dword [ebp - 0x54], 0x634449df
sub dword [ebp - 0x54], 0xffd4dd73
mov dword [ebp - 0x50], 0x4b4e43d3
add dword [ebp - 0x50], 0xb4b1bc2d
lea ebx, [ebp - 0x5c]
push ebx
push eax
mov eax, sym.imp.kernel32.dll_GetProcAddress
add eax, dword [ebp - 0x4c]
call dword [eax]
push 0x40
push 0x1000
push 0x39a01
push 0
call eax
mov ecx, 0x16b8ceb
add ecx, 0xfe94c735
xor ebx, ebx
add ebx, eax
mov edi, 0xec0a1b52
add edi, 0x1436f4ae
add edi, dword [ebp - 0x4c]
mov edx, 0x176de5c0
sub edx, 0xd5fc6453
xor dword [ebp - 0x10], 0x59d7cb5b
mov esi, dword [edi]
xor dword [ebp - 0x3c], 0x1f53f1c9
sub esi, edx
mov dword [ebp - 0x44], 0x2659c7a4
mov dword [ebx], esi
sub dword [ebp - 0x20], edx
add ebx, 0x9bdd96b5
sub ebx, 0x9bdd96b1
add edi, 0x8e3858a0
add edi, 0x71c7a764
loop 0x40331d
add eax, 0xc738011c
sub eax, 0xc736bdc9
mov ebx, eax
add eax, 0xb3c3ccca
sub eax, 0xb3c3ccc5
mov ecx, 0xaa19d96
sub ecx, 0xa619d96
add ecx, dword [ebp - 0x4c]
call ebx
leave
ret
Function at 0x4037e0
Capabilities:
Set registry value

Disassembly:
sub esp, 0xc
mov eax, dword [esp + 0x10]
push ebx
push esi
push 0
push 0
or eax, 4
mov dword [esp + 0x10], 0
push eax
push 0
push 0
push str.SoftwareClassesCLSID
mov esi, ecx
mov dword [esp + 0x24], 0
push 0x80000001
lea ecx, [esp + 0x24]
mov dword [esp + 0x2c], 0
xor bl, bl
call fcn.0040fb0d
test eax, eax
jne 0x40389d
mov eax, dword [esi]
cmp dword [eax + 0x14], 8
jb 0x403832
mov eax, dword [eax]
push 0
push 0
push 2
push 1
push 0
push eax
push dword [esp + 0x20]
lea ecx, [esp + 0x24]
call fcn.0040fb0d
test eax, eax
jne 0x40389d
call fcn.00405d60
mov esi, dword [esp + 8]
mov edx, eax
test edx, edx
jne 0x403869
mov eax, 0xd
test eax, eax
sete bl
jmp 0x4038a1
mov ecx, edx
push edi
lea edi, [ecx + 2]
nop
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x403870
sub ecx, edi
sar ecx, 1
lea eax, [ecx*2 + 2]
push eax
push edx
push 1
push 0
push 0
push esi
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
test eax, eax
pop edi
sete bl
jmp 0x4038a1
mov esi, dword [esp + 8]
test esi, esi
je 0x4038ac
push esi
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop esi
mov al, bl
pop ebx
add esp, 0xc
ret 4

Function at 0x404a80
Capabilities:
Query or enumerate registry key

Disassembly:
sub esp, 0x21c
mov eax, dword [0x431134]
xor eax, esp
mov dword [esp + 0x218], eax
push ebx
mov ebx, ecx
mov dword [esp + 4], 0
push ebp
mov ebp, dword [esp + 0x228]
lea ecx, [esp + 8]
push esi
mov eax, dword [ebx + 4]
or eax, 0x2001f
mov dword [esp + 0x10], 0
push eax
push ebp
push dword [ebx]
mov dword [esp + 0x20], 0
call fcn.0040fb0d
mov esi, eax
test esi, esi
je 0x404ae9
mov ecx, dword [esp + 0xc]
test ecx, ecx
je 0x404ae2
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, esi
jmp 0x404b92
push edi
mov edi, dword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
lea eax, [esp + 0x20]
push eax
push 0
push 0
push 0
lea eax, [esp + 0x2c]
mov dword [esp + 0x2c], 0x100
push eax
lea eax, [esp + 0x3c]
push eax
push 0
push dword [esp + 0x2c]
call edi
test eax, eax
jne 0x404b59
lea esp, [esp]
lea eax, [esp + 0x28]
push eax
lea ecx, [esp + 0x14]
call fcn.00404a80
mov esi, eax
test esi, esi
jne 0x404bac
lea eax, [esp + 0x20]
mov dword [esp + 0x1c], 0x100
push eax
push esi
push esi
push esi
lea eax, [esp + 0x2c]
push eax
lea eax, [esp + 0x3c]
push eax
push esi
push dword [esp + 0x2c]
call edi
test eax, eax
je 0x404b20
mov eax, dword [esp + 0x10]
mov esi, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test eax, eax
je 0x404b72
push eax
call esi
mov dword [esp + 0x10], 0
push ebp
mov ecx, ebx
mov dword [esp + 0x18], 0
call fcn.0040fb0d
mov ecx, dword [esp + 0x10]
mov edi, eax
test ecx, ecx
je 0x404b8f
push ecx
call esi
mov eax, edi
pop edi
mov ecx, dword [esp + 0x224]
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.0040a8aa
add esp, 0x21c
ret 4
mov eax, dword [esp + 0x10]
test eax, eax
je 0x404bbb
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, esi
jmp 0x404b91
Function at 0x405610
Capabilities:
Accept command line arguments
Create thread

Disassembly:
sub esp, 0xc
mov eax, dword [0x431134]
xor eax, esp
mov dword [esp + 8], eax
cmp byte [0x431c9c], 0
push edi
mov edi, ecx
je 0x40563f
or eax, 0xffffffff
pop edi
mov ecx, dword [esp + 8]
xor ecx, esp
call fcn.0040a8aa
add esp, 0xc
ret 4
push esi
push 0
call dword [sym.imp.ole32.dll_CoInitialize]
mov esi, eax
mov dword [esp + 8], esi
test esi, esi
jns 0x405672
cmp esi, 0x80010106
jne 0x40578b
push str.Mscoree.dll
call dword [sym.imp.kernel32.dll_GetModuleHandleW]
test eax, eax
jne 0x405676
jmp 0x405787
mov byte [edi + 0x3e], 1
call dword [sym.imp.kernel32.dll_GetCommandLineW]
lea ecx, [esp + 8]
push ecx
push eax
mov ecx, edi
call fcn.0040fb0d
cmp al, 1
jne 0x405777
push 5
push 4
mov ecx, edi
call fcn.0040fb0d
mov esi, eax
test esi, esi
js 0x405771
push ebx
jne 0x405743
cmp byte [edi + 0x3c], 0
je 0x40572e
push 0
push 0
push 0
push 0
call dword [sym.imp.kernel32.dll_CreateEventW]
mov dword [edi + 0x30], eax
test eax, eax
je 0x405720
lea eax, [esp + 0x10]
push eax
push 0
push edi
push 0x405510
push 0
push 0
call dword [sym.imp.kernel32.dll_CreateThread]
mov ebx, eax
test ebx, ebx
jne 0x4056f5
push dword [edi + 0x30]
call dword [sym.imp.kernel32.dll_CloseHandle]
mov dword [edi + 0x30], ebx
test ebx, ebx
je 0x405720
call dword [sym.imp.ole32.dll_CoResumeClassObjects]
mov esi, eax
test esi, esi
jns 0x405717
push dword [edi + 0x30]
call dword [sym.imp.kernel32.dll_SetEvent]
mov eax, dword [edi + 0x34]
add eax, eax
push eax
push ebx
call dword [sym.imp.kernel32.dll_WaitForSingleObject]
push ebx
call dword [sym.imp.kernel32.dll_CloseHandle]
jmp 0x405736
mov ecx, edi
mov esi, 0x80004005
call fcn.004059c0
jmp 0x405747
call dword [sym.imp.ole32.dll_CoResumeClassObjects]
mov esi, eax
test esi, esi
jns 0x405747
mov ecx, edi
call fcn.004059c0
jmp 0x405747
mov byte [edi + 0x3c], 0
mov eax, esi
pop ebx
test eax, eax
jne 0x405757
mov ecx, edi
call fcn.0040fb0d
jmp 0x405759
js 0x405771
mov ecx, edi
call fcn.004059c0
cmp byte [edi + 0x3c], 0
mov esi, eax
je 0x405771
push dword [edi + 0x38]
call dword [sym.imp.kernel32.dll_Sleep]
mov dword [esp + 8], esi
jmp 0x40577b
mov esi, dword [esp + 8]
cmp byte [edi + 0x3e], 0
je 0x40578b
call dword [sym.imp.ole32.dll_CoUninitialize]
mov esi, dword [esp + 8]
mov ecx, dword [esp + 0x10]
mov eax, esi
pop esi
pop edi
xor ecx, esp
call fcn.0040a8aa
add esp, 0xc
ret 4
Function at 0x407ca0
Capabilities:
Query environment variable
Query or enumerate registry value

Disassembly:
sub esp, 0x10
push ebx
push ebp
push esi
mov esi, dword [esp + 0x28]
mov eax, dword [esi]
mov dword [esi + 4], 0
test eax, eax
je 0x407cbc
xor ecx, ecx
mov word [eax], cx
mov ebx, dword [esp + 0x24]
lea eax, [esp + 0xc]
mov ebp, dword [esp + 0x20]
push eax
push 0
lea eax, [esp + 0x30]
mov dword [esp + 0x30], 0
push eax
push 0
push ebx
push ebp
mov dword [esp + 0x24], 0
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x407e24
mov eax, dword [esp + 0x28]
cmp eax, 1
je 0x407d0c
cmp eax, 2
je 0x407d0c
pop esi
pop ebp
mov eax, 0xd
pop ebx
add esp, 0x10
ret
mov eax, dword [esp + 0xc]
shr eax, 1
cmp eax, 1
ja 0x407d20
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x10
ret
push eax
mov ecx, esi
call fcn.004073d0
test al, al
jne 0x407d38
pop esi
pop ebp
mov eax, 0xe
pop ebx
add esp, 0x10
ret
mov eax, dword [esi]
test eax, eax
push edi
mov edi, 0x4263a8
mov ecx, edi
cmovne ecx, eax
lea eax, [esp + 0x10]
push eax
push ecx
lea eax, [esp + 0x34]
push eax
push 0
push ebx
push ebp
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
cmp dword [esp + 0x2c], 2
mov dword [esp + 0x1c], eax
jne 0x407e1f
cmp dword [esi + 4], 0
jbe 0x407e1f
push 0x25
push dword [esi]
call fcn.0040d836
add esp, 8
test eax, eax
je 0x407e1f
mov ecx, dword [esi]
sub eax, ecx
sar eax, 1
js 0x407e1f
test ecx, ecx
mov eax, edi
push 0
cmovne eax, ecx
push 0
push eax
call dword [sym.imp.kernel32.dll_ExpandEnvironmentStringsW]
mov dword [esp + 0x18], eax
test eax, eax
jle 0x407e1f
xor ebx, ebx
lea ebp, [eax + 1]
mov dword [esp + 0x14], ebx
test ebp, ebp
je 0x407dec
lea ebx, [ebp + 0x20]
and ebx, 0xffffffe0
lea eax, [ebx + ebx]
push eax
push 0
call fcn.0041fb70
mov ecx, eax
add esp, 8
test ecx, ecx
je 0x407e1f
xor eax, eax
mov word [ecx], ax
lea eax, [ebx - 1]
mov dword [esp + 0x14], eax
mov ebx, ecx
xor eax, eax
mov word [ecx + ebp*2], ax
jmp 0x407df1
mov ecx, 0x4263a8
mov eax, dword [esi]
test eax, eax
push dword [esp + 0x18]
cmovne edi, eax
push ecx
push edi
call dword [sym.imp.kernel32.dll_ExpandEnvironmentStringsW]
mov eax, dword [esi]
mov ecx, dword [esp + 0x14]
mov dword [esi], ebx
mov dword [esi + 8], ecx
mov dword [esi + 4], ebp
test eax, eax
je 0x407e1f
push eax
call fcn.0041fa50
add esp, 4
mov eax, dword [esp + 0x1c]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x10
ret
Function at 0x409ad0
Capabilities:
Get common file path

Disassembly:
sub esp, 0x144
mov eax, dword [esp + 0x14c]
push ebx
push ebp
push esi
push edi
mov edi, dword [esp + 0x158]
mov dword [esp + 0x10], eax
cmp edi, eax
je 0x409b87
mov ebp, dword [sym.imp.kernel32.dll_LoadLibraryW]
mov ebx, dword [sym.imp.kernel32.dll_lstrcatW]
mov esi, dword [edi]
push esi
call ebp
test eax, eax
jne 0x409b89
test esi, esi
jne 0x409b16
or eax, 0xffffffff
jmp 0x409b24
push str.TWAIN_32.DLL
push esi
call fcn.0040fb0d
add esp, 8
test eax, eax
jne 0x409b7a
push 0xa0
lea eax, [esp + 0x18]
push eax
call dword [sym.imp.kernel32.dll_GetWindowsDirectoryW]
lea eax, [esp + 0x14]
lea edx, [eax + 2]
nop
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x409b40
sub eax, edx
sar eax, 1
cmp word [esp + eax*2 + 0x12], 0x5c
je 0x409b63
push 0x427758
lea eax, [esp + 0x18]
push eax
call ebx
push str.TWAIN_32.DLL
lea eax, [esp + 0x18]
push eax
call ebx
lea eax, [esp + 0x14]
push eax
call ebp
test eax, eax
jne 0x409b89
add edi, 4
cmp edi, dword [esp + 0x10]
jne 0x409b00
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x144
ret 8

Function at 0x40acc4
Capabilities:
Parse pe header

Disassembly:
push 0
call dword [sym.imp.kernel32.dll_GetModuleHandleW]
test eax, eax
je 0x40ad03
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x40ad03
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x40ad03
mov eax, 0x10b
cmp word [ecx + 0x18], ax
jne 0x40ad03
cmp dword [ecx + 0x74], 0xe
jbe 0x40ad03
cmp dword [ecx + 0xe8], 0
setne al
ret
xor al, al
ret

Function at 0x40fb0d
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
pushal
call 0x40fb1c
pop dword [ebp - 0x14]
mov eax, 0xc973a7a5
sub eax, 0xc932ac89
sub dword [ebp - 0x14], eax
push 0x40
push 0x1000
push 0x3d4b2
push 0
mov eax, 0x96f9d6dc
sub eax, 0x96b78560
add eax, dword [ebp - 0x14]
call dword [eax]
mov ecx, 0xe155e903
add ecx, 0x1eaa64f1
xor esi, esi
add esi, eax
mov edi, 0x9452fa0
sub edi, 0x901cda0
add edi, dword [ebp - 0x14]
mov edx, 0x69860eae
add edx, 0xd5333537
sub dword [ebp - 4], 0xda66fdde
mov ebx, dword [edi]
xor dword [ebp - 0xc], esi
xor ebx, edx
mov dword [esi], ebx
add esi, 0xc35e2361
add esi, 0x3ca1dca3
add edi, 0xfe53c0d4
sub edi, 0xfe53c0d0
loop 0x40fb7d
add eax, 0xb45501c0
add eax, 0x4bac28e3
xor ebx, ebx
add ebx, eax
add eax, 5
mov ecx, 0x1f44f2e6
sub ecx, 0x1f04f2e6
add ecx, dword [ebp - 0x14]
call ebx
leave
ret