joyce8/EMBER2024-capa huggingface dataset:
Function at 0x40f5db
Capabilities:
Delete file
Get common file path

Disassembly:
mov eax, 0x4e345f
call fcn.004bb144
sub esp, 0x1a0
cmp byte [0x531fd5], 0
push ebx
je 0x40f5ff
mov al, byte [0x531fd4]
jmp 0x40f6fd
mov eax, dword [0x52d2c4]
mov dword [ebp - 0x10], eax
and dword [ebp - 4], 0
lea eax, [ebp - 0x1ac]
push eax
push 0xff
call dword [sym.imp.KERNEL32.DLL_GetTempPathA]
test eax, eax
je 0x40f630
lea eax, [ebp - 0x1ac]
lea ecx, [ebp - 0x10]
push eax
call fcn.004d8551
push str.swflash.cab
lea ecx, [ebp - 0x10]
call fcn.004d87a4
call fcn.0040a359
push 0
push dword [ebp - 0x10]
push str.http:__download.macromedia.com_pub_shockwave_cabs_flash_swflash.cab
call fcn.0040f731
add esp, 0xc
call fcn.0040f70a
test eax, eax
je 0x40f688
push 0
lea ecx, [ebp - 0xac]
call fcn.0040a0c2
lea ecx, [ebp - 0xac]
mov byte [ebp - 4], 1
call fcn.004d8f04
and byte [ebp - 4], 0
lea ecx, [ebp - 0xac]
call fcn.0040a124
call fcn.0040f77e
call fcn.0040a4dc
lea ecx, [ebp - 0x14]
call fcn.0040581f
push ecx
lea eax, [ebp - 0x10]
mov ecx, esp
mov dword [ebp - 0x18], esp
push eax
mov byte [ebp - 4], 2
call fcn.004d813d
lea ecx, [ebp - 0x14]
call fcn.0040584b
test eax, eax
je 0x40f6cd
call fcn.0040fa10
test eax, eax
mov dword [0x511fd8], eax
setg al
mov byte [0x531fd4], al
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.DLL_DeleteFileA]
mov bl, byte [0x531fd4]
and byte [ebp - 4], 0
lea ecx, [ebp - 0x14]
mov byte [0x531fd5], 1
call fcn.00405844
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x10]
call fcn.004d83c8
mov al, bl
mov ecx, dword [ebp - 0xc]
pop ebx
mov dword fs:[0], ecx
leave
ret
Function at 0x40f7b0
Capabilities:
Create process on windows

Disassembly:
mov eax, 0x4e347c
call fcn.004bb144
sub esp, 0x5c
push ebx
xor ebx, ebx
cmp byte [0x531fd6], bl
push edi
mov edi, ecx
je 0x40f7d5
mov al, byte [0x531fd4]
jmp 0x40f922
call fcn.0040fa10
push dword [ebp + 8]
mov ecx, edi
mov dword [0x511fd8], eax
call fcn.0040fe87
mov ecx, dword [0x511fd8]
mov edx, eax
cmp ecx, ebx
setg al
cmp edx, ebx
mov byte [0x531fd4], al
jle 0x40f807
cmp ecx, edx
jge 0x40f922
cmp al, bl
jne 0x40f922
mov eax, dword [0x52d2c4]
mov dword [ebp - 0x10], eax
lea eax, [ebp - 0x10]
mov ecx, edi
push eax
mov dword [ebp - 4], ebx
push dword [ebp + 8]
call fcn.0040fcb7
test eax, eax
je 0x40f907
cmp byte [edi + 0x49], bl
je 0x40f842
push str.__Q:A__R:N
lea ecx, [ebp - 0x10]
call fcn.004d87a4
push esi
push 0x44
pop esi
lea eax, [ebp - 0x68]
push esi
push ebx
push eax
call fcn.004bb170
push 0x10
lea eax, [ebp - 0x24]
push ebx
push eax
mov dword [ebp - 0x68], esi
call fcn.004bb170
add esp, 0x18
lea eax, [ebp - 0x24]
lea ecx, [ebp - 0x10]
push eax
lea eax, [ebp - 0x68]
push eax
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
call fcn.004d87f8
push eax
push ebx
call dword [sym.imp.KERNEL32.DLL_CreateProcessA]
push 0xffffffffffffffff
push dword [ebp - 0x24]
call dword [sym.imp.KERNEL32.DLL_WaitForSingleObject]
push dword [ebp - 0x24]
mov esi, dword [sym.imp.KERNEL32.DLL_CloseHandle]
call esi
push dword [ebp - 0x20]
call esi
call fcn.0040fa10
cmp eax, ebx
mov dword [0x511fd8], eax
setg byte [0x531fd4]
cmp eax, ebx
pop esi
jge 0x40f907
mov eax, dword [0x52d2c4]
mov dword [ebp + 8], eax
push 0x65be
lea ecx, [ebp + 8]
mov byte [ebp - 4], 1
call fcn.004d9496
push str.Flash_Player_installation
lea ecx, [ebp - 0x14]
call fcn.004d8436
push 0x2030
mov ecx, edi
push dword [ebp - 0x14]
push dword [ebp + 8]
call fcn.0040e94e
lea ecx, [ebp - 0x14]
mov byte [0x531fd5], 1
call fcn.004d83c8
lea ecx, [ebp + 8]
mov byte [ebp - 4], bl
call fcn.004d83c8
mov bl, byte [0x531fd4]
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x10]
mov byte [0x531fd6], 1
call fcn.004d83c8
mov al, bl
mov ecx, dword [ebp - 0xc]
pop edi
pop ebx
mov dword fs:[0], ecx
leave
ret 4
Function at 0x40fa10
Capabilities:
Get file version info
Query or enumerate registry value

Disassembly:
mov eax, 0x4e34c0
call fcn.004bb144
sub esp, 0x128
or dword [ebp - 0x28], 0xffffffff
lea eax, [ebp - 0x18]
push ebx
push eax
xor ebx, ebx
push 1
push ebx
push str.SOFTWAREClassesCLSIDD27CDB6E_AE6D_11CF_96B8_444553540000InprocServer32
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
je 0x40fa4a
or eax, 0xffffffff
jmp 0x40fbbd
mov eax, dword [0x52d2c4]
push esi
push edi
mov dword [ebp - 0x10], eax
lea eax, [ebp - 0x20]
mov esi, dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
push eax
push ebx
push ebx
mov edi, 0x531e00
push ebx
push edi
push dword [ebp - 0x18]
mov dword [ebp - 4], ebx
call esi
cmp eax, ebx
je 0x40fa7b
or esi, 0xffffffff
jmp 0x40fbad
lea eax, [ebp - 0x20]
lea ecx, [ebp - 0x10]
push eax
push dword [ebp - 0x20]
call fcn.004d886f
push eax
push ebx
push ebx
push edi
push dword [ebp - 0x18]
call esi
cmp eax, ebx
jne 0x40fa73
push dword [ebp - 0x18]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push ebx
push ebx
lea ecx, [ebp - 0x10]
call fcn.004d87f8
push eax
call sub.VERSION.dll_GetFileVersionInfoSizeA
mov esi, eax
push 1
push esi
call fcn.004bd471
mov edi, eax
pop ecx
cmp edi, ebx
pop ecx
je 0x40fa73
push edi
push esi
push ebx
push ebx
lea ecx, [ebp - 0x10]
call fcn.004d87f8
push eax
call sub.VERSION.dll_GetFileVersionInfoA
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x2c]
push eax
push str.VarFileInfoTranslation
push edi
call sub.VERSION.dll_VerQueryValueA
cmp eax, ebx
jne 0x40faf3
or esi, 0xffffffff
jmp 0x40fba6
xor esi, esi
test dword [ebp - 0x24], 0xfffffffc
jbe 0x40fba3
mov eax, dword [ebp - 0x2c]
movzx ecx, word [eax + esi*4 + 2]
lea eax, [eax + esi*4]
push ecx
movzx eax, word [eax]
push eax
lea eax, [ebp - 0x134]
push str.StringFileInfo_04x_04xProductVersion
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x10
lea eax, [ebp - 0x34]
push eax
lea eax, [ebp - 0x30]
push eax
lea eax, [ebp - 0x134]
push eax
push edi
call sub.VERSION.dll_VerQueryValueA
cmp eax, ebx
je 0x40fba3
push dword [ebp - 0x30]
lea ecx, [ebp - 0x14]
call fcn.004d8436
push ebx
push 0x2c
lea ecx, [ebp - 0x14]
mov byte [ebp - 4], 1
call fcn.004d88c4
cmp eax, 0xffffffff
jg 0x40fb77
lea ecx, [ebp - 0x14]
mov byte [ebp - 4], bl
call fcn.004d83c8
mov eax, dword [ebp - 0x24]
inc esi
shr eax, 2
cmp esi, eax
jb 0x40fb02
jmp 0x40fba3
push eax
lea eax, [ebp - 0x1c]
push eax
lea ecx, [ebp - 0x14]
call fcn.004d2438
push dword [ebp - 0x1c]
call fcn.004bd466
pop ecx
mov dword [ebp - 0x28], eax
lea ecx, [ebp - 0x1c]
call fcn.004d83c8
lea ecx, [ebp - 0x14]
mov byte [ebp - 4], bl
call fcn.004d83c8
mov esi, dword [ebp - 0x28]
push edi
call fcn.004bbdd3
pop ecx
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x10]
call fcn.004d83c8
mov eax, esi
pop edi
pop esi
mov ecx, dword [ebp - 0xc]
pop ebx
mov dword fs:[0], ecx
leave
ret
Function at 0x41ca6e
Capabilities:
Create process on windows

Disassembly:
mov eax, 0x4e44d0
call fcn.004bb144
sub esp, 0x58
push ebx
push edi
mov edi, ecx
xor ebx, ebx
cmp dword [edi + 0x68], ebx
mov dword [ebp - 4], ebx
je 0x41cb25
lea eax, [ebp - 0x64]
push esi
push eax
call fcn.004b426d
mov word [ebp - 0x64], bx
push 8
lea ecx, [ebp - 0x4c]
push dword [ebp + 8]
mov byte [ebp - 4], 1
call fcn.004b3fba
mov esi, 0x531e00
push 8
push esi
lea ecx, [ebp - 0x3c]
mov byte [ebp - 4], 2
call fcn.004b3fba
push 8
push esi
lea ecx, [ebp - 0x2c]
mov byte [ebp - 4], 3
call fcn.004b3fba
push 3
push ebx
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 4
call fcn.004b406b
lea eax, [ebp - 0x3c]
mov ecx, dword [edi + 0x68]
push eax
lea eax, [ebp - 0x64]
push eax
lea eax, [ebp - 0x2c]
push eax
lea eax, [ebp - 0x1c]
push eax
lea eax, [ebp - 0x4c]
push eax
mov byte [ebp - 4], 5
call fcn.0044e76d
mov esi, dword [sym.imp.OLEAUT32.dll_VariantCopy]
lea eax, [ebp - 0x1c]
push eax
call esi
lea eax, [ebp - 0x2c]
push eax
call esi
lea eax, [ebp - 0x3c]
push eax
call esi
lea eax, [ebp - 0x4c]
push eax
call esi
lea eax, [ebp - 0x64]
push eax
call esi
pop esi
jmp 0x41cb48
call fcn.004131d8
cmp eax, ebx
jne 0x41cb32
xor eax, eax
jmp 0x41cb35
mov eax, dword [eax + 0x1c]
push 5
push ebx
push ebx
push dword [ebp + 8]
push 0x512d7c
push eax
call dword [sym.imp.SHELL32.dll_ShellExecuteA]
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.004d83c8
mov ecx, dword [ebp - 0xc]
pop edi
pop ebx
mov dword fs:[0], ecx
leave
ret 4
Function at 0x429cf9
Capabilities:
Print debug messages

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
push esi
push edi
mov edi, dword [sym.imp.KERNEL32.DLL_LoadLibraryA]
xor ebx, ebx
push str.DDRAW.DLL
mov dword [ebp - 0xc], ebx
call edi
cmp eax, ebx
mov dword [ebp - 4], eax
jne 0x429d22
push str.Couldnt_LoadLibrary_DDraw_r_n
jmp 0x429d5e
mov esi, dword [sym.imp.KERNEL32.DLL_GetProcAddress]
push str.DirectDrawCreate
push eax
call esi
cmp eax, ebx
jne 0x429d44
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.DLL_FreeLibrary]
push str.Couldnt_GetProcAddress_DirectDrawCreate_r_n
jmp 0x429d5e
lea ecx, [ebp - 0xc]
push ebx
push ecx
push ebx
call eax
test eax, eax
jge 0x429d6b
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.DLL_FreeLibrary]
push str.Couldnt_create_DDraw_r_n
call dword [sym.imp.KERNEL32.DLL_OutputDebugStringA]
xor eax, eax
jmp 0x429e72
push ebx
mov dword [ebp - 8], ebx
call dword [sym.imp.ole32.dll_CoInitialize]
lea eax, [ebp - 8]
push eax
push 0x4ed540
push 1
push ebx
push 0x4ed550
call dword [sym.imp.ole32.dll_CoCreateInstance]
test eax, eax
jge 0x429dae
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.DLL_FreeLibrary]
push str.Couldnt_create_CLSID_DirectMusic_r_n
call dword [sym.imp.KERNEL32.DLL_OutputDebugStringA]
mov eax, 0x600
jmp 0x429e72
mov eax, dword [ebp - 8]
push eax
mov ecx, dword [eax]
call dword [ecx + 8]
call dword [sym.imp.ole32.dll_CoUninitialize]
push str.DirectDrawCreateEx
push dword [ebp - 4]
call esi
cmp eax, ebx
jne 0x429ddb
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.DLL_FreeLibrary]
push str.Couldnt_GetProcAddress_DirectDrawCreateEx_r_n
jmp 0x429dfa
push ebx
lea ecx, [ebp - 0x10]
push 0x4ed580
push ecx
push ebx
call eax
test eax, eax
jge 0x429e07
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.DLL_FreeLibrary]
push str.Couldnt_DirectDrawCreateEx_r_n
call dword [sym.imp.KERNEL32.DLL_OutputDebugStringA]
mov eax, 0x601
jmp 0x429e72
mov eax, dword [ebp - 0x10]
push eax
mov ecx, dword [eax]
call dword [ecx + 8]
push str.D3D8.DLL
call edi
cmp eax, ebx
mov dword [ebp - 0x14], eax
jne 0x429e39
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.DLL_FreeLibrary]
push str.Couldnt_LoadLibrary_D3D8.DLL_r_n
call dword [sym.imp.KERNEL32.DLL_OutputDebugStringA]
mov eax, 0x700
jmp 0x429e72
push str.dpnhpast.dll
call edi
cmp eax, ebx
jne 0x429e5d
push ebx
call dword [sym.imp.KERNEL32.DLL_FreeLibrary]
push str.Couldnt_LoadLibrary_dpnhpast.dll_r_n
call dword [sym.imp.KERNEL32.DLL_OutputDebugStringA]
mov eax, 0x800
jmp 0x429e72
push dword [ebp - 4]
mov esi, dword [sym.imp.KERNEL32.DLL_FreeLibrary]
call esi
push dword [ebp - 0x14]
call esi
mov eax, 0x801
pop edi
pop esi
pop ebx
leave
ret
Function at 0x42fcc9
Capabilities:
Get file version info

Disassembly:
mov eax, 0x4e58d3
call fcn.004bb144
sub esp, 0x11c
push ebx
push esi
push edi
xor edi, edi
push 0x531e00
lea ecx, [ebp - 0x10]
mov dword [ebp - 0x18], edi
call fcn.004d8436
push 1
lea eax, [ebp - 0x128]
pop ebx
push 0x104
push eax
push edi
mov dword [ebp - 4], ebx
call dword [sym.imp.KERNEL32.DLL_GetModuleFileNameA]
test eax, eax
ja 0x42fd1f
mov ecx, dword [ebp + 8]
lea eax, [ebp - 0x10]
push eax
call fcn.004d813d
mov dword [ebp - 0x18], ebx
jmp 0x42fe07
lea eax, [ebp - 0x24]
mov dword [ebp - 0x24], edi
push eax
lea eax, [ebp - 0x128]
push eax
call sub.VERSION.dll_GetFileVersionInfoSizeA
cmp eax, edi
mov dword [ebp - 0x14], eax
jbe 0x42fdf8
push eax
call fcn.004d8997
mov esi, eax
pop ecx
cmp esi, edi
je 0x42fdf8
push esi
lea eax, [ebp - 0x128]
push dword [ebp - 0x14]
push dword [ebp - 0x24]
push eax
call sub.VERSION.dll_GetFileVersionInfoA
test eax, eax
je 0x42fdf1
lea eax, [ebp - 0x20]
mov dword [ebp - 0x1c], edi
push eax
lea eax, [ebp - 0x1c]
push eax
push str.VarFileInfoTranslation
push esi
mov dword [ebp - 0x20], edi
call sub.VERSION.dll_VerQueryValueA
test eax, eax
je 0x42fdf1
mov eax, dword [ebp - 0x1c]
cmp eax, edi
je 0x42fdf1
cmp dword [ebp - 0x20], 4
jb 0x42fdf1
movzx ecx, word [eax]
mov edx, dword [0x52d2c4]
movzx eax, word [eax + 2]
mov dword [ebp - 0x14], edx
push eax
push ecx
lea eax, [ebp - 0x14]
push str.StringFileInfo_04x_04xComments
push eax
mov byte [ebp - 4], 2
call fcn.004d2858
add esp, 0x10
lea eax, [ebp - 0x20]
lea ecx, [ebp - 0x14]
push eax
lea eax, [ebp - 0x1c]
push eax
push edi
call fcn.004d87f8
push eax
push esi
call sub.VERSION.dll_VerQueryValueA
test eax, eax
je 0x42fde6
cmp dword [ebp - 0x20], edi
jbe 0x42fde6
push dword [ebp - 0x1c]
lea ecx, [ebp - 0x10]
call fcn.004d8551
lea ecx, [ebp - 0x14]
mov byte [ebp - 4], bl
call fcn.004d83c8
push esi
call fcn.004d89c0
pop ecx
mov ecx, dword [ebp + 8]
lea eax, [ebp - 0x10]
push eax
call fcn.004d813d
mov dword [ebp - 0x18], ebx
and byte [ebp - 4], 0
lea ecx, [ebp - 0x10]
call fcn.004d83c8
mov ecx, dword [ebp - 0xc]
mov eax, dword [ebp + 8]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret 4
Function at 0x431568
Capabilities:
Access peb ldr_data
Get process heap flags

Disassembly:
mov eax, 0x4e5b63
call fcn.004bb144
push ecx
push ebx
push esi
mov esi, ecx
push edi
mov dword [ebp - 0x10], esi
mov eax, dword [0x52d2c4]
and dword [ebp - 4], 0
lea ecx, [esi + 0xc]
mov dword [ecx], eax
mov eax, dword [0x52d2c4]
mov dword [esi + 0x10], eax
mov eax, dword [0x52d2c4]
lea ebx, [esi + 0x14]
mov dword [ebx], eax
mov eax, dword [0x52d2c4]
mov dword [esi + 0x18], eax
mov eax, dword [0x52d2c4]
mov dword [esi + 0x30], eax
and dword [esi + 4], 0
mov edi, 0x531e00
push edi
mov byte [ebp - 4], 5
mov dword [esi], 0x4ec0b8
call fcn.004d8551
push edi
mov ecx, ebx
call fcn.004d8551
push edi
lea ecx, [esi + 0x18]
call fcn.004d8551
and dword [esi + 0x1c], 0
and dword [esi + 0x20], 0
fldz
push edi
lea ecx, [esi + 0x30]
fstp qword [esi + 0x28]
call fcn.004d8551
and byte [esi + 8], 0
mov ecx, dword [ebp - 0xc]
mov eax, esi
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret

Function at 0x43161c
Capabilities:
Access peb ldr_data
Get ntdll base address
Get process heap flags
Get process heap force flags

Disassembly:
mov eax, 0x4e5ba4
call fcn.004bb144
push ecx
push esi
mov esi, ecx
mov dword [ebp - 0x10], esi
mov dword [esi], 0x4ec0b8
lea ecx, [esi + 0x30]
mov dword [ebp - 4], 4
call fcn.004d83c8
lea ecx, [esi + 0x18]
mov byte [ebp - 4], 3
call fcn.004d83c8
lea ecx, [esi + 0x14]
mov byte [ebp - 4], 2
call fcn.004d83c8
lea ecx, [esi + 0x10]
mov byte [ebp - 4], 1
call fcn.004d83c8
and byte [ebp - 4], 0
lea ecx, [esi + 0xc]
call fcn.004d83c8
mov ecx, dword [ebp - 0xc]
pop esi
mov dword fs:[0], ecx
leave
ret

Function at 0x4344f3
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x44
push esi
xor esi, esi
push 0x44
lea eax, [ebp - 0x44]
push esi
push eax
call fcn.004bb170
add esp, 0xc
lea eax, [ebp - 0x44]
mov dword [ebp - 0x44], 0x44
mov dword [ebp - 0x18], 1
push dword [ebp + 0xc]
mov word [ebp - 0x14], 0xa
push eax
push esi
push esi
push 0x20
push esi
push esi
push esi
push dword [ebp + 8]
push esi
call dword [sym.imp.KERNEL32.DLL_CreateProcessA]
pop esi
leave
ret
Function at 0x448629
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push esi
push dword [esp + 8]
call dword [sym.imp.KERNEL32.DLL_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x448642
test al, 0x10
je 0x448642
push 1
pop esi
jmp 0x448644
xor esi, esi
lea ecx, [esp + 8]
call fcn.004d83c8
mov eax, esi
pop esi
ret 4
Function at 0x454954
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [0x51b878]
cmp dword [eax + 4], 0xc
jne 0x454967
push 1
pop eax
pop ebp
ret
lea eax, [ebp + 0xc]
push edi
push eax
push 0
push dword [ebp + 0xc]
push dword [ebp + 8]
push 0
push 0
call dword [sym.imp.KERNEL32.DLL_CreateThread]
mov edi, eax
mov eax, dword [ebp + 0x10]
cmp eax, 0xffffffff
je 0x4549a2
test eax, eax
je 0x45499e
cmp eax, 1
je 0x45499a
cmp eax, 2
jne 0x4549ab
push 0xf
jmp 0x4549a4
push 2
jmp 0x4549a4
push 0
jmp 0x4549a4
push 0xffffffffffffffff
push edi
call dword [sym.imp.KERNEL32.DLL_SetThreadPriority]
mov eax, edi
pop edi
pop ebp
ret

Function at 0x4549b0
Capabilities:
Terminate thread

Disassembly:
mov eax, dword [0x51b878]
cmp dword [eax + 4], 0xc
je 0x4549c7
push 0
push dword [esp + 8]
call dword [sym.imp.KERNEL32.DLL_TerminateThread]
ret

Function at 0x45a3b6
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x340
push ebx
push esi
lea eax, [ebp - 4]
push edi
push eax
xor edi, edi
push 1
push edi
push str.SoftwareMicrosoftWindowsCurrentVersionMultimediaMIDIMap
push SysReAllocStringLen
mov dword [ebp - 0xc], 0x100
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x45a4f6
lea eax, [ebp - 0xc]
mov esi, dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
push eax
lea eax, [ebp - 0x240]
push eax
push edi
push edi
push str.CurrentInstrument
push dword [ebp - 4]
call esi
cmp eax, edi
je 0x45a42a
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 0x240]
push eax
push edi
push edi
push str.szPname
push dword [ebp - 4]
call esi
cmp eax, edi
jne 0x45a4f6
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov dword [ebp - 8], edi
mov esi, 0x134
push esi
lea eax, [ebp - 0x140]
push edi
push eax
call fcn.004bb170
mov eax, dword [0x54862c]
add esp, 0xc
lea edx, [ebp - 0x140]
mov dword [ebp - 0x140], esi
mov ecx, dword [eax]
push edx
push dword [ebp - 8]
push eax
call dword [ecx + 0xc]
mov ebx, eax
cmp ebx, edi
jne 0x45a4bc
cmp dword [ebp - 0x128], 1
jne 0x45a4bc
push edi
push edi
lea eax, [ebp - 0x340]
push 0x100
push eax
lea eax, [ebp - 0x10c]
push 0xffffffffffffffff
push eax
push edi
push edi
call dword [sym.imp.KERNEL32.DLL_WideCharToMultiByte]
lea eax, [ebp - 0x240]
push eax
call fcn.004bd360
push eax
lea eax, [ebp - 0x240]
push eax
lea eax, [ebp - 0x340]
push eax
call fcn.004bf260
add esp, 0x10
test eax, eax
je 0x45a4c9
inc dword [ebp - 8]
cmp ebx, 1
je 0x45a4e8
jmp 0x45a43b
lea eax, [ebp - 0x138]
push 0x10
push eax
push dword [ebp + 8]
call fcn.004bb730
mov eax, dword [0x51b878]
add esp, 0xc
test byte [eax + 8], 1
je 0x45a4f6
mov eax, dword [0x54862c]
push dword [ebp + 8]
mov ecx, dword [eax]
push eax
call dword [ecx + 0x28]
pop edi
pop esi
pop ebx
leave
ret
Function at 0x46cf30
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x400
push ebx
xor ebx, ebx
cmp dword [0x56138c], ebx
jne 0x46d063
mov eax, dword [0x561388]
push esi
push edi
mov edi, dword [sym.imp.KERNEL32.DLL_LoadLibraryA]
cmp eax, ebx
jne 0x46cf65
push str.dsound.dll
call edi
mov dword [0x561388], eax
mov esi, dword [sym.imp.KERNEL32.DLL_GetProcAddress]
push str.DirectSoundCreate8
push eax
call esi
cmp eax, ebx
mov dword [0x5613ac], eax
jne 0x46cf8e
push str.DirectSoundCreate
push dword [0x561388]
call esi
mov dword [0x5613a4], eax
push str.DirectSoundEnumerateA
push dword [0x561388]
call esi
cmp dword [0x5613ac], ebx
mov dword [0x5613a8], eax
setne al
push eax
push dword [0x561388]
call fcn.00473c98
cmp dword [0x5613ac], ebx
pop ecx
pop ecx
je 0x46d02d
lea eax, [ebp - 0x400]
push 0x104
push eax
call dword [sym.imp.KERNEL32.DLL_GetSystemDirectoryA]
test eax, eax
je 0x46d021
lea eax, [ebp - 0x400]
push eax
lea eax, [ebp - 0x200]
push eax
call fcn.004bc9c0
lea eax, [ebp - 0x200]
push str.d3d9.dll
push eax
call fcn.004bc9d0
push ebx
lea eax, [ebp - 0x200]
push ebx
push eax
call fcn.00459c4a
add esp, 0x1c
cmp eax, ebx
je 0x46d057
push eax
call fcn.00459dcd
pop ecx
mov dword [0x5221ac], 9
jmp 0x46d057
mov dword [0x5221ac], 8
jmp 0x46d057
push str.ddraw.dll
call edi
mov edi, eax
cmp edi, ebx
je 0x46d057
push str.DirectDrawCreateEx
push edi
call esi
test eax, eax
je 0x46d050
mov dword [0x5221ac], 7
push edi
call dword [sym.imp.KERNEL32.DLL_FreeLibrary]
pop edi
mov dword [0x56138c], 1
pop esi
pop ebx
leave
ret

Function at 0x46e931
Capabilities:
Encode data using xor

Disassembly:
mov eax, dword [esp + 4]
xor ecx, ecx
cmp eax, ecx
je 0x46e9c8
mov edx, dword [eax]
push ebx
push esi
push edi
mov byte [edx + 0x16], cl
mov edx, dword [eax]
mov byte [edx + 0x17], cl
mov edx, dword [eax]
mov byte [edx + 0x18], cl
mov edx, dword [eax]
mov byte [edx + 0x19], cl
mov esi, dword [eax + 4]
xor edx, edx
cmp esi, ecx
jle 0x46e97d
mov edi, dword [eax]
mov ebx, ecx
shr ebx, 0x18
movzx edi, byte [edi + edx]
xor edi, ebx
shl ecx, 8
mov edi, dword [edi*4 + 0x5227ec]
xor ecx, edi
inc edx
cmp edx, esi
jl 0x46e95f
xor edx, edx
cmp dword [eax + 0xc], edx
jle 0x46e9a4
mov esi, dword [eax + 8]
movzx edi, byte [esi + edx]
mov ebx, ecx
shr ebx, 0x18
xor edi, ebx
shl ecx, 8
mov edi, dword [edi*4 + 0x5227ec]
xor ecx, edi
inc edx
cmp edx, dword [eax + 0xc]
jl 0x46e987
mov edx, dword [eax]
pop edi
mov byte [edx + 0x16], cl
mov esi, dword [eax]
mov edx, ecx
shr edx, 8
mov byte [esi + 0x17], dl
mov esi, dword [eax]
mov edx, ecx
shr edx, 0x10
mov byte [esi + 0x18], dl
mov eax, dword [eax]
shr ecx, 0x18
pop esi
mov byte [eax + 0x19], cl
pop ebx
ret
Function at 0x47a2ec
Capabilities:
Encode data using xor

Disassembly:
push ebx
push ecx
push edx
push esi
mov ebx, dword [esp + 0x14]
mov ecx, dword [esp + 0x18]
mov eax, dword [esp + 0x1c]
mov edx, ecx
cmp edx, 4
jl 0x47a333
cmp edx, 0x10
jl 0x47a31f
shr ecx, 4
nop
xor eax, dword [ebx]
mov esi, dword [ebx + 4]
xor eax, dword [ebx + 8]
xor esi, dword [ebx + 0xc]
add ebx, 0x10
xor eax, esi
dec ecx
jne 0x47a30c
mov ecx, edx
shr ecx, 2
and ecx, 3
test ecx, ecx
je 0x47a333
xor eax, dword [ebx]
add ebx, 4
dec ecx
jne 0x47a32b
and edx, 3
cmp edx, 3
jne 0x47a347
xor ecx, ecx
mov cl, byte [ebx]
inc ebx
shl ecx, 0x10
xor eax, ecx
jmp 0x47a34c
cmp edx, 2
jne 0x47a358
xor ecx, ecx
mov cl, byte [ebx]
inc ebx
shl ecx, 8
xor eax, ecx
jmp 0x47a35d
cmp edx, 1
jne 0x47a363
xor ecx, ecx
mov cl, byte [ebx]
xor eax, ecx
pop esi
pop edx
pop ecx
pop ebx
ret
Function at 0x4803d0
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
sub esp, 0x14
push ebx
push esi
push edi
mov edi, ecx
xor ebx, ebx
xor esi, esi
mov eax, dword [edi]
cmp eax, 0xffffffff
je 0x480555
push eax
call dword [sym.imp.KERNEL32.DLL_TlsGetValue]
mov esi, eax
cmp esi, ebx
jne 0x480555
push ebp
push 0xb8
call fcn.004d8997
add esp, 4
cmp eax, ebx
je 0x480503
mov cl, byte [esp + 0x13]
mov dl, byte [esp + 0x13]
mov byte [eax + 0x34], cl
mov cl, byte [esp + 0x13]
mov dword [eax + 0x38], ebx
mov dword [eax + 0x3c], ebx
mov dword [eax + 0x40], ebx
mov byte [eax + 0x44], dl
mov dl, byte [esp + 0x13]
mov dword [eax + 0x48], ebx
mov dword [eax + 0x4c], ebx
mov dword [eax + 0x50], ebx
mov byte [esp + 0x18], bl
mov word [esp + 0x1a], bx
mov ebp, dword [esp + 0x18]
lea esi, [eax + 0x28]
mov byte [eax + 0x88], cl
mov dword [eax + 0x8c], ebx
mov dword [eax + 0x90], ebx
mov dword [eax + 0x94], ebx
mov byte [eax + 0x98], dl
mov dword [eax + 0x9c], ebx
mov dword [eax + 0xa0], ebx
mov dword [eax + 0xa4], ebx
mov word [esp + 0x1c], bx
mov word [esp + 0x1e], bx
mov dword [esi], ebp
mov ebp, dword [esp + 0x1c]
xor dx, dx
mov ecx, 1
mov dword [esi + 4], ebp
mov dword [eax + 0x20], 0x33333333
mov dword [eax], ebx
mov dword [eax + 4], ebx
mov word [esi + 8], dx
mov dword [eax + 8], ecx
mov dword [eax + 0xc], ecx
mov dword [eax + 0x10], ebx
mov dword [eax + 0x14], ecx
mov dword [eax + 0x18], ecx
mov dword [eax + 0x1c], ebx
mov dword [eax + 0x24], 0x40073333
mov dword [eax + 0x54], ecx
mov dword [eax + 0x58], ecx
mov dword [eax + 0x5c], ecx
mov dword [eax + 0x60], ecx
mov dword [eax + 0x64], ecx
mov dword [eax + 0x68], ecx
mov dword [eax + 0x6c], ebx
mov dword [eax + 0x70], ecx
mov dword [eax + 0x74], ecx
mov dword [eax + 0x78], ebx
mov dword [eax + 0x7c], ecx
mov dword [eax + 0x80], ecx
mov dword [eax + 0x84], ebx
mov dword [eax + 0xa8], ebx
mov dword [eax + 0xac], ebx
mov byte [eax + 0xb0], bl
mov dword [eax + 0xb4], ebx
mov esi, eax
jmp 0x480505
xor esi, esi
mov eax, dword [edi]
push esi
push eax
call dword [sym.imp.KERNEL32.DLL_TlsSetValue]
cmp eax, ebx
jne 0x48052c
call dword [sym.imp.KERNEL32.DLL_GetLastError]
lea ecx, [esp + 0x14]
push 0x50abe8
push ecx
mov dword [esp + 0x1c], eax
call fcn.004bd204
push 8
call fcn.004d8997
add esp, 4
mov ebx, eax
lea ebp, [edi + 8]
push ebp
mov dword [ebx], esi
call dword [sym.imp.KERNEL32.DLL_EnterCriticalSection]
mov edx, dword [edi + 4]
push ebp
mov dword [ebx + 4], edx
mov dword [edi + 4], ebx
call dword [sym.imp.KERNEL32.DLL_LeaveCriticalSection]
pop ebp
mov eax, esi
pop edi
pop esi
pop ebx
add esp, 0x14
ret