joyce8/EMBER2024-capa huggingface dataset:
Function at 0x10147f86
Capabilities:
Decompress data using aplib

Disassembly:
push ebp
mov ebp, esp
mov esi, dword [ebp + 8]
mov edi, dword [ebp + 0xc]
cld
mov dl, 0x80
movsb byte es:[edi], byte [esi]
call fcn.10148005
jae 0x10147f92
xor ecx, ecx
call fcn.10148005
jae 0x10147fbc
xor eax, eax
call fcn.10148005
jae 0x10147fcd
mov al, 0x10
call fcn.10148005
adc al, al
jae 0x10147fae
jne 0x10147ffa
stosb byte es:[edi], al
jmp 0x10147f93
call fcn.10148011
dec ecx
loop 0x10147fd9
mov eax, ebp
call fcn.1014800f
jmp 0x10147ffb
lodsb al, byte [esi]
shr eax, 1
je 0x10148021
adc ecx, 2
mov ebp, eax
jmp 0x10147ffb
xchg ecx, eax
dec eax
shl eax, 8
lodsb al, byte [esi]
mov ebp, eax
call fcn.1014800f
cmp eax, 0x7d00
jae 0x10147ff9
cmp eax, 0x500
jae 0x10147ffa
cmp eax, 0x7f
ja 0x10147ffb
inc ecx
inc ecx
push esi
mov esi, edi
sub esi, eax
rep movsb byte es:[edi], byte [esi]
pop esi
jmp 0x10147f93
pop ebp
ret 8
Function at 0x401000
Capabilities:
Encode data using add xor sub operations
Encode data using xor
Hash data with crc32

Disassembly:
push ebp
mov ebp, esp
push esi
push ecx
push edx
mov esi, dword [ebp + 0xc]
xor edx, edx
or eax, 0xffffffff
mov ecx, dword [ebp + 8]
lea esp, [esp]
lea esp, [esp]
nop
mov dl, byte [esi]
xor dl, al
shr eax, 8
xor eax, dword [edx*4 + 0x401040]
add esi, 1
sub ecx, 1
jne 0x401020
not eax
pop edx
pop ecx
pop esi
leave
ret 8

Function at 0x401478
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffffc
pushal
mov dword [ebp - 4], 0
push 0xa
push dword [ebp + 8]
push 0
call sub.kernel32.dll_FindResourceA
or eax, eax
jne 0x401498
jmp 0x4014b8
push eax
push eax
push 0
call sub.kernel32.dll_SizeofResource
mov dword [0x404280], eax
pop eax
push eax
push 0
call sub.kernel32.dll_LoadResource
or eax, eax
jne 0x4014b5
jmp 0x4014b8
mov dword [ebp - 4], eax
popal
mov eax, dword [ebp - 4]
leave
ret 4

Function at 0x40151f
Capabilities:
Set environment variable

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffbfc
mov byte [ebp - 0x401], 0
pushal
mov esi, dword [ebp + 0xc]
lea ebx, [ebp - 0x400]
push esi
push ebx
call sub.kernel32.dll_lstrcpyA
xor ecx, ecx
jmp 0x401545
inc ecx
cmp byte [ecx + ebx], 0x5c
jne 0x401544
mov byte [ecx + ebx], 0
lea esi, [ecx + esi + 1]
push ebx
call fcn.00401631
or eax, eax
je 0x4015ac
mov byte [ebx], 0
test dword [ebp + 0x14], 8
je 0x401570
mov edx, 1
jmp 0x401572
xor edx, edx
push edx
push dword [ebp + 0x10]
push esi
push eax
push ebx
call fcn.004025e0
push section..data
push ebx
call fcn.004015e1
test dword [ebp + 0x14], 1
je 0x401598
push ebx
call fcn.004015b8
cmp byte [ebx], 0
je 0x4015ac
push ebx
push dword [ebp + 8]
call sub.kernel32.dll_SetEnvironmentVariableA
mov byte [ebp - 0x401], al
popal
movzx eax, byte [ebp - 0x401]
leave
ret 0x10
Function at 0x40176d
Capabilities:
Create process on windows
Delete file
Get common file path

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffbf8
push esi
push edi
push ebx
lea eax, [ebp - 0x400]
push eax
push 0x400
call sub.kernel32.dll_GetTempPathA
push str._regpatch.reg
lea eax, [ebp - 0x400]
push eax
call sub.kernel32.dll_lstrcatA
mov esi, dword [ebp + 8]
test dword [esi + 5], 1
je 0x4017e7
mov eax, dword [esi + 1]
add eax, 0x100000
mov dword [ebp - 0x408], eax
push 4
push 0x1000
push eax
push 0
call sub.kernel32.dll_VirtualAlloc
mov dword [ebp - 0x404], eax
lea eax, [esi + 9]
push dword [ebp - 0x408]
push dword [ebp - 0x404]
push eax
call fcn.00401879
mov ecx, dword [ebp - 0x404]
jmp 0x4017ed
mov eax, dword [esi + 1]
lea ecx, [esi + 9]
push eax
push ecx
lea eax, [ebp - 0x400]
push eax
call fcn.004024b4
test eax, eax
je 0x40183d
mov edi, 0x404a8c
push str._s__
push edi
call sub.kernel32.dll_lstrcpyA
lea eax, [ebp - 0x400]
push eax
push edi
call sub.kernel32.dll_lstrcatA
push 0x4040d8
push edi
call sub.kernel32.dll_lstrcatA
push 5
push 0
push edi
push str.regedit.exe
push str.open
push 0
call sub.shell32.dll_ShellExecuteA
push 0x1f4
call sub.kernel32.dll_Sleep
test dword [esi + 5], 1
je 0x401866
push 0x4000
push dword [ebp - 0x408]
push dword [ebp - 0x404]
call sub.kernel32.dll_VirtualFree
lea eax, [ebp - 0x400]
push eax
call sub.kernel32.dll_DeleteFileA
pop ebx
pop edi
pop esi
leave
ret 4

Function at 0x401879
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff8
push esi
push edi
mov eax, dword [ebp + 0x10]
add eax, 0x100000
mov dword [ebp - 8], eax
push 4
push 0x1000
push eax
push 0
call sub.kernel32.dll_VirtualAlloc
mov dword [ebp - 4], eax
mov esi, dword [ebp + 8]
mov edi, dword [ebp + 0xc]
push dword [ebp - 8]
push dword [ebp - 4]
push esi
call sub.kernel32.dll_ExpandEnvironmentStringsA
mov esi, dword [ebp - 4]
or eax, eax
je 0x401905
push dword [ebp + 8]
push esi
call sub.kernel32.dll_lstrcmpA
or eax, eax
je 0x4018fa
mov bl, 0
jmp 0x4018f0
lodsb al, byte [esi]
cmp word [esi], 0x5b0a
jne 0x4018d2
mov bl, 1
cmp al, 0x5c
jne 0x4018e6
or bl, bl
jne 0x4018e6
cmp byte [esi], 0x5c
je 0x4018e6
cmp byte [esi - 2], 0x5c
je 0x4018e6
stosb byte es:[edi], al
stosb byte es:[edi], al
cmp word [esi], 0xd5d
jne 0x4018f0
mov bl, 0
cmp byte [esi], 0
jne 0x4018c8
mov byte [edi], 0
jmp 0x401905
push dword [ebp + 8]
push dword [ebp + 0xc]
call sub.kernel32.dll_lstrcpyA
push 0x4000
push dword [ebp - 8]
push dword [ebp - 4]
call sub.kernel32.dll_VirtualFree
push dword [ebp + 0xc]
call sub.kernel32.dll_lstrlenA
pop edi
pop esi
leave
ret 0xc
Function at 0x401d78
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff4
push ecx
push edx
push esi
push edi
push dword [ebp + 8]
call fcn.00402480
cmp eax, 0xffffffff
je 0x401e01
mov dword [ebp - 4], eax
push 0
push 0
push 3
push 0
push 1
push 0x80000000
push dword [ebp + 8]
call sub.kernel32.dll_CreateFileA
cmp eax, 0xffffffff
je 0x401dfb
mov dword [ebp - 0xc], eax
push 4
push 0x1000
push dword [ebp - 4]
push 0
call sub.kernel32.dll_VirtualAlloc
mov esi, eax
push 0
lea eax, [ebp - 8]
push eax
push dword [ebp - 4]
push esi
push dword [ebp - 0xc]
call sub.kernel32.dll_ReadFile
add esi, dword [esi + 0x3c]
mov eax, dword [esi + 0x34]
mov ebx, dword [esi + 0x50]
push eax
push ebx
push dword [ebp - 0xc]
call sub.kernel32.dll_CloseHandle
push 0x4000
push dword [ebp - 4]
push esi
call sub.kernel32.dll_VirtualFree
pop ebx
pop eax
jmp 0x401e05
xor eax, eax
xor ebx, ebx
jmp 0x401e05
xor eax, eax
xor ebx, ebx
pop edi
pop esi
pop edx
pop ecx
leave
ret 4
Function at 0x4022aa
Capabilities:
Get file size
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff0
pushal
push 0
push 0
push 3
push 0
push 1
push 0x80000000
push dword [ebp + 8]
call sub.kernel32.dll_CreateFileA
cmp eax, 0xffffffff
je 0x40232a
mov dword [ebp - 4], eax
push 0
push 0
push 0
push 2
push 0
push eax
call sub.kernel32.dll_CreateFileMappingA
or eax, eax
je 0x402322
mov dword [ebp - 8], eax
push 0
push 0
push 0
push 4
push eax
call sub.kernel32.dll_MapViewOfFile
or eax, eax
je 0x40231a
mov dword [ebp - 0xc], eax
push 0
push dword [ebp - 4]
call sub.kernel32.dll_GetFileSize
push dword [ebp - 0xc]
push eax
call fcn.00401000
mov dword [ebp - 0x10], eax
push dword [ebp - 0xc]
call sub.kernel32.dll_UnmapViewOfFile
push dword [ebp - 8]
call sub.kernel32.dll_CloseHandle
push dword [ebp - 4]
call sub.kernel32.dll_CloseHandle
popal
mov eax, dword [ebp - 0x10]
leave
ret 4

Function at 0x4024b4
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff8
push 0
push 0x80
push 2
push 0
push 0
push 0x40000000
push dword [ebp + 8]
call sub.kernel32.dll_CreateFileA
cmp eax, 0xffffffff
jne 0x4024df
xor eax, eax
leave
ret 0xc
mov dword [ebp - 4], eax
push 0
lea eax, [ebp - 8]
push eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp - 4]
call sub.kernel32.dll_WriteFile
push dword [ebp - 4]
call sub.kernel32.dll_FlushFileBuffers
push dword [ebp - 4]
call sub.kernel32.dll_CloseHandle
mov eax, dword [ebp - 8]
leave
ret 0xc

Function at 0x4025e0
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff4
cmp dword [ebp + 0x18], 1
jne 0x4025f3
mov ecx, 0x101
jmp 0x4025f8
mov ecx, 1
lea eax, [ebp - 4]
push eax
push ecx
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
call sub.advapi32.dll_RegOpenKeyExA
or eax, eax
jne 0x40263f
mov eax, 1
mov dword [ebp - 8], eax
mov dword [ebp - 0xc], 0x400
lea eax, [ebp - 0xc]
push eax
push dword [ebp + 8]
lea eax, [ebp - 8]
push eax
push 0
push dword [ebp + 0x14]
push dword [ebp - 4]
call sub.advapi32.dll_RegQueryValueExA
push eax
push dword [ebp - 4]
call sub.advapi32.dll_RegCloseKey
pop eax
leave
ret 0x14

Function at 0x402650
Capabilities:
Set current directory

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffe00
pushal
cmp dword [ebp + 8], 0
jne 0x402690
push 0
call sub.kernel32.dll_GetModuleHandleA
lea esi, [ebp - 0x200]
push 0x200
push esi
push eax
call sub.kernel32.dll_GetModuleFileNameA
push esi
call sub.kernel32.dll_lstrlenA
push esi
add esi, eax
jmp 0x402685
dec esi
cmp byte [esi], 0x5c
jne 0x402684
mov byte [esi], 0
pop esi
jmp 0x402693
mov esi, dword [ebp + 8]
push esi
call sub.kernel32.dll_SetCurrentDirectoryA
popal
leave
ret 4
Function at 0x401521
Capabilities:
Allocate or change rwx memory

Disassembly:
push ebx
push ecx
push edx
push esi
push edi
enter 4, 0
mov esi, eax
mov ebx, eax
test eax, eax
je 0x40153c
mov edx, dword [0x40a050]
add edx, edx
jmp 0x401542
mov edx, dword [0x40a050]
mov eax, 0x40a054
call fcn.0040146c
lea edx, [ebp - 4]
push edx
mov edx, esi
or dl, 0x40
mov edi, 0x401f33
push edx
sub edi, fcn.004016fe
push edi
xor eax, eax
push fcn.004016fe
mov dword [ebp - 4], eax
call dword [sym.imp.KERNEL32.DLL_VirtualProtect]
cmp dword [ebp - 4], 0
je 0x401597
mov eax, fcn.004016fe
mov ebx, esi
mov edx, edi
call fcn.0040146c
mov edx, 0x1ba00
mov eax, 0x40a054
mov ebx, esi
call fcn.00401337
leave
pop edi
pop esi
pop edx
pop ecx
pop ebx
ret

Function at 0x401646
Capabilities:
Encode data using base64 via winapi

Disassembly:
push ebx
push ecx
push edx
enter 0x13c, 0
xor eax, eax
push eax
mov dword [ebp - 0x38], eax
mov dword [ebp - 0x34], eax
call dword [sym.imp.KERNEL32.DLL_GetModuleHandleA]
push 0x7f00
mov dword [ebp - 0x28], eax
xor eax, eax
mov dword [ebp - 0x1c], 6
push eax
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x18], eax
call dword [sym.imp.USER32.DLL_LoadIconA]
push 0x7f00
push 0
mov dword [ebp - 0x24], eax
call dword [sym.imp.USER32.DLL_LoadCursorA]
mov dword [ebp - 0x20], eax
lea eax, [ebp - 0x38]
push eax
call dword [sym.imp.USER32.DLL_RegisterClassW]
push 0
push 0
call dword [sym.imp.USER32.DLL_LoadAcceleratorsA]
push 0
call dword [sym.imp.OLE32.DLL_CoInitialize]
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x10]
push eax
push 1
push 1
lea eax, [ebp - 0x13c]
push eax
mov dword [ebp - 4], 0xa
mov byte [ebp - 0x13c], 0
call dword [sym.imp.CRYPT32.DLL_CryptBinaryToStringA]
movzx eax, byte [ebp - 0x10]
lea ebx, [eax - 0x47]
call dword [sym.imp.OLE32.DLL_CoUninitialize]
mov eax, dword [ebp - 4]
add eax, ebx
leave
pop edx
pop ecx
pop ebx
ret
Function at 0x4010f0
Capabilities:
Read file on windows

Disassembly:
sub esp, 0x104
push esi
push str.playsnap.conf
push str.sysconfig
push 0
call fcn.00418770
add esp, 4
push eax
lea eax, [esp + 0x10]
push str._s_s_s
push eax
call dword [sym.imp.MSVCRT.dll_sprintf]
lea ecx, [esp + 0x18]
push 0x42804c
push ecx
call dword [sym.imp.MSVCRT.dll_fopen]
mov esi, eax
add esp, 0x1c
test esi, esi
jne 0x401153
mov esi, dword [esp + 0x10c]
push esi
call fcn.00401040
push esi
call fcn.00401180
add esp, 8
pop esi
add esp, 0x104
ret
mov edx, dword [esp + 0x10c]
push esi
push 0x318
push 1
push edx
call dword [sym.imp.MSVCRT.dll_fread]
push esi
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 0x14
pop esi
add esp, 0x104
ret

Function at 0x401180
Capabilities:
Write file on windows

Disassembly:
sub esp, 0x104
push esi
push edi
push str.playsnap.conf
push str.sysconfig
push 0
call fcn.00418770
add esp, 4
push eax
lea eax, [esp + 0x14]
push str._s_s_s
push eax
call dword [sym.imp.MSVCRT.dll_sprintf]
lea ecx, [esp + 0x1c]
push ecx
call fcn.00418a80
mov edi, dword [sym.imp.MSVCRT.dll_fopen]
lea edx, [esp + 0x20]
push 0x42805c
push edx
call edi
mov esi, eax
add esp, 0x20
test esi, esi
jne 0x4011f1
lea eax, [esp + 8]
push eax
call fcn.00418a80
lea ecx, [esp + 0xc]
push 0x42805c
push ecx
call edi
mov esi, eax
add esp, 0xc
test esi, esi
je 0x401211
mov edx, dword [esp + 0x110]
push esi
push 0x318
push 1
push edx
call dword [sym.imp.MSVCRT.dll_fwrite]
push esi
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 0x14
pop edi
pop esi
add esp, 0x104
ret

Function at 0x401470
Capabilities:
Read file on windows

Disassembly:
sub esp, 0x114
push ebx
push edi
push str.bookmark.conf
push str.sysconfig
push 0
call fcn.00418770
add esp, 4
push eax
lea eax, [esp + 0x24]
push str._s_s_s
push eax
call dword [sym.imp.MSVCRT.dll_sprintf]
lea ecx, [esp + 0x2c]
push 0x42804c
push ecx
call dword [sym.imp.MSVCRT.dll_fopen]
mov edi, eax
add esp, 0x1c
test edi, edi
je 0x40154f
mov ebx, dword [sym.imp.MSVCRT.dll_fread]
push edi
push 0x10
lea edx, [esp + 0x10]
push 1
push edx
call ebx
add esp, 0x10
cmp eax, 0x10
jne 0x401545
cmp dword [esp + 0xc], 0x50
ja 0x401545
mov eax, dword [esp + 8]
push ebp
xor ebp, ebp
push esi
test eax, eax
jle 0x40152b
push 0x50
call sub.MFC42.DLL_operatornew
mov esi, eax
mov eax, dword [esp + 0x18]
push edi
push eax
push 1
push esi
call ebx
mov ecx, dword [esp + 0x28]
add esp, 0x14
cmp ecx, eax
push esi
jne 0x401523
mov ecx, dword [esi + 4]
mov edx, dword [esi]
push ecx
push edx
mov ecx, 0x429da8
call fcn.00419a40
mov eax, dword [esp + 0x10]
inc ebp
cmp ebp, eax
jl 0x4014e7
jmp 0x40152b
call sub.MFC42.DLL_operatordelete
add esp, 4
push edi
call dword [sym.imp.MSVCRT.dll_fclose]
mov eax, dword [0x429db0]
add esp, 4
pop esi
pop ebp
pop edi
pop ebx
add esp, 0x114
ret
push edi
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 4
pop edi
xor eax, eax
pop ebx
add esp, 0x114
ret
Function at 0x401560
Capabilities:
Write file on windows

Disassembly:
sub esp, 0x114
push esi
push str.bookmark.conf
push str.sysconfig
push 0
call fcn.00418770
add esp, 4
push eax
lea eax, [esp + 0x20]
push str._s_s_s
push eax
call dword [sym.imp.MSVCRT.dll_sprintf]
lea ecx, [esp + 0x28]
push 0x42805c
push ecx
call dword [sym.imp.MSVCRT.dll_fopen]
mov esi, eax
add esp, 0x1c
test esi, esi
je 0x401618
mov eax, dword [0x429db0]
xor edx, edx
push ebx
mov ebx, dword [sym.imp.MSVCRT.dll_fwrite]
mov dword [esp + 8], edx
push edi
mov dword [esp + 0x10], edx
push esi
push 0x10
lea ecx, [esp + 0x14]
mov dword [esp + 0x1c], edx
push 1
push ecx
mov dword [esp + 0x28], edx
mov dword [esp + 0x1c], eax
mov dword [esp + 0x20], 0x50
call ebx
mov eax, dword [esp + 0x1c]
add esp, 0x10
xor edi, edi
test eax, eax
jle 0x40160c
push edi
mov ecx, 0x429da8
call fcn.00419ba0
test eax, eax
je 0x401603
push esi
push 0x50
push 1
push eax
call ebx
add esp, 0x10
mov eax, dword [esp + 0xc]
inc edi
cmp edi, eax
jl 0x4015e9
push esi
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 4
pop edi
pop ebx
pop esi
add esp, 0x114
ret

Function at 0x401d50
Capabilities:
Create thread

Disassembly:
push ecx
mov ecx, dword [0x42a0f4]
test ecx, ecx
je 0x401da4
call fcn.00402e30
mov ecx, dword [0x42a0f4]
call fcn.00402d30
mov eax, dword [0x42a0f4]
lea ecx, [esp]
push ecx
push 0
push eax
push 0x401cf0
push 0
push 0
mov dword [0x42a0f4], 0
mov dword [esp + 0x18], 0
call dword [sym.imp.KERNEL32.dll_CreateThread]
test eax, eax
je 0x401da4
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop ecx
ret

Function at 0x402b10
Capabilities:
Create thread

Disassembly:
push esi
mov esi, ecx
push edi
xor edi, edi
cmp dword [esi + 8], edi
jne 0x402bca
mov eax, dword [esp + 0xc]
push eax
call dword [sym.imp.DixPlayApi.dll_dplayChannelCreate]
cmp eax, edi
mov dword [esi + 8], eax
jne 0x402b3f
mov ecx, esi
call fcn.00402c00
pop edi
xor eax, eax
pop esi
ret 4
push edi
push edi
push 1
push edi
call dword [sym.imp.KERNEL32.dll_CreateEventA]
cmp eax, edi
mov dword [esi + 0x1c], eax
jne 0x402b5f
mov ecx, esi
call fcn.00402c00
pop edi
xor eax, eax
pop esi
ret 4
push 0x80000
call sub.MFC42.DLL_operatornew
add esp, 4
cmp eax, edi
mov dword [esi + 0x12c], eax
jne 0x402b84
mov ecx, esi
call fcn.00402c00
pop edi
xor eax, eax
pop esi
ret 4
lea ecx, [esp + 0xc]
mov dword [esi + 0xc], 1
push ecx
push edi
push esi
push 0x402be0
push edi
push edi
mov dword [esi + 0x154], edi
mov dword [esi + 0x158], edi
mov dword [esi + 0x16c], edi
mov dword [esp + 0x24], edi
call dword [sym.imp.KERNEL32.dll_CreateThread]
cmp eax, edi
mov dword [esi + 0x18], eax
jne 0x402bca
mov ecx, esi
call fcn.00402c00
pop edi
xor eax, eax
pop esi
ret 4
pop edi
mov eax, 1
pop esi
ret 4
Function at 0x402c00
Capabilities:
Terminate thread

Disassembly:
push esi
push edi
mov esi, ecx
call fcn.00402e50
mov eax, dword [esi + 0x1c]
xor edi, edi
cmp eax, edi
mov dword [esi + 0xc], edi
je 0x402c1c
push eax
call dword [sym.imp.KERNEL32.dll_SetEvent]
mov eax, dword [esi + 0x18]
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp eax, edi
je 0x402c4e
push 0x64
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0x102
jne 0x402c45
mov eax, dword [esi + 0x18]
push edi
push eax
call dword [sym.imp.KERNEL32.dll_TerminateThread]
mov ecx, dword [esi + 0x18]
push ecx
call ebx
mov dword [esi + 0x18], edi
mov eax, dword [esi + 8]
cmp eax, edi
je 0x402c5f
push eax
call dword [sym.imp.DixPlayApi.dll_dplayChannelDestroy]
mov dword [esi + 8], edi
mov eax, dword [esi + 0x1c]
cmp eax, edi
je 0x402c6c
push eax
call ebx
mov dword [esi + 0x1c], edi
mov edx, dword [esi + 0x20]
lea ecx, [esi + 0x20]
call dword [edx + 8]
mov eax, dword [esi + 0x12c]
pop ebx
cmp eax, edi
je 0x402c8f
push eax
call sub.MFC42.DLL_operatordelete
add esp, 4
mov dword [esi + 0x12c], edi
mov dword [esi + 0x154], edi
mov dword [esi + 0x158], edi
mov dword [esi + 0x16c], edi
pop edi
pop esi
ret
Function at 0x403070
Capabilities:
Delete file

Disassembly:
mov eax, dword [esp + 0x20]
sub esp, 0x104
test eax, eax
push ebx
mov ebx, dword [esp + 0x120]
push ebp
push esi
je 0x40308a
neg ebx
mov al, byte [0x42a24c]
push edi
mov byte [esp + 0x10], al
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0x11]
rep stosd dword es:[edi], eax
mov ebp, dword [esp + 0x118]
lea edx, [esp + 0x10]
stosw word es:[edi], ax
stosb byte es:[edi], al
mov eax, ebp
sub edx, ebp
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x4030b3
mov esi, dword [esp + 0x128]
cmp esi, 0x190
je 0x4030fc
cmp esi, 0x1a0
je 0x4030fc
cmp ebx, 0xf0
je 0x4030e4
cmp ebx, 0xffffff10
jne 0x403124
cmp esi, 0x280
je 0x4030fc
cmp esi, 0x2d0
je 0x4030fc
cmp esi, 0x168
jne 0x403124
lea edi, [esp + 0x10]
or ecx, 0xffffffff
xor eax, eax
mov edx, 0x42809c
repne scasb al, byte es:[edi]
not ecx
lea eax, [esp + 0x10]
dec ecx
sub eax, 3
add ecx, eax
sub ecx, edx
mov al, byte [edx]
mov byte [ecx + edx], al
inc edx
test al, al
jne 0x40311a
mov edx, dword [esp + 0x130]
mov eax, dword [esp + 0x124]
lea ecx, [esp + 0x10]
push ecx
mov ecx, dword [esp + 0x124]
push edx
mov edx, dword [esp + 0x124]
push ebx
push esi
push eax
push ecx
push edx
call dword [sym.imp.DixPlayApi.dll_dplayImageSaveToFile]
test eax, eax
pop edi
jne 0x403162
pop esi
pop ebp
pop ebx
add esp, 0x104
ret 0x20
cmp esi, 0x190
je 0x4031ca
cmp esi, 0x1a0
je 0x4031ca
cmp ebx, 0xf0
je 0x403182
cmp ebx, 0xffffff10
jne 0x4031fe
cmp esi, 0x280
je 0x40319c
cmp esi, 0x2d0
je 0x40319c
cmp esi, 0x168
jne 0x4031fe
jmp 0x4031a4
cmp esi, 0x168
jne 0x4031a9
mov esi, 0x2d0
lea eax, [ebx + ebx]
cdq
xor eax, edx
sub eax, edx
push eax
push esi
lea eax, [esp + 0x14]
push ebp
push eax
call dword [sym.imp.DixPlayApi.dll_dplayImageStrectchFile]
test eax, eax
je 0x4031fe
lea ecx, [esp + 0xc]
push ecx
jmp 0x4031f8
sub esi, 0x190
push 0x1e0
neg esi
sbb esi, esi
lea edx, [esp + 0x10]
and esi, 0x50
add esi, 0x280
push esi
push ebp
push edx
call dword [sym.imp.DixPlayApi.dll_dplayImageStrectchFile]
test eax, eax
je 0x4031fe
lea eax, [esp + 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x104
ret 0x20
Function at 0x404c80
Capabilities:
Encrypt data using rc4 prga

Disassembly:
sub esp, 8
mov eax, dword [esp + 0x20]
mov edx, dword [esp + 0xc]
and eax, 0xff
push ebx
mov ebx, dword [esp + 0x20]
mov dword [esp + 4], eax
mov eax, dword [esp + 0x28]
push ebp
push esi
mov esi, dword [esp + 0x1c]
and eax, 0xff
push edi
add eax, 0x20
lea ecx, [esi + ebx]
mov dword [esp + 0x14], eax
lea eax, [edx + ebx]
lea edi, [ecx + 1]
cmp edx, esi
lea ebp, [eax + 1]
mov dword [esp + 0x30], edi
je 0x404d39
mov edx, dword [esp + 0x24]
lea esi, [eax + edx - 1]
lea edi, [ecx + edx - 1]
mov edx, dword [esp + 0x28]
dec edx
cmp edx, 1
jle 0x404cfb
sub ecx, eax
dec edx
mov dword [esp + 0x34], edx
mov dl, byte [eax]
mov byte [ecx + eax], dl
mov dl, byte [esi]
mov byte [edi], dl
mov edx, dword [esp + 0x34]
add eax, ebx
add esi, ebx
add edi, ebx
dec edx
mov dword [esp + 0x34], edx
jne 0x404ce1
mov edx, dword [esp + 0x1c]
mov edi, dword [esp + 0x20]
mov ecx, ebx
mov esi, edx
mov eax, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x28]
lea eax, [ecx - 1]
mov ecx, ebx
imul eax, ebx
lea esi, [eax + edx]
mov edx, dword [esp + 0x20]
lea edi, [eax + edx]
mov eax, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x28]
mov eax, dword [esp + 0x24]
dec ecx
cmp ecx, 1
jle 0x404e50
dec ecx
mov dword [esp + 0x28], ecx
lea ecx, [eax - 1]
cmp ecx, 1
jle 0x404e29
mov edi, ebp
sub edi, ebx
inc edi
dec ecx
mov dword [esp + 0x20], ecx
mov al, byte [ebp]
xor edx, edx
mov dl, byte [ebx + ebp - 1]
mov esi, eax
xor eax, eax
xor ecx, ecx
mov al, byte [ebx + ebp]
mov cl, byte [ebx + edi - 2]
add edx, eax
xor eax, eax
mov al, byte [edi + ebx]
add edx, ecx
xor ecx, ecx
add edx, eax
mov cl, byte [ebx + ebp + 1]
xor eax, eax
mov al, byte [edi - 2]
add edx, ecx
xor ecx, ecx
add edx, eax
mov cl, byte [edi - 1]
and esi, 0xff
mov eax, ecx
xor ecx, ecx
mov cl, byte [edi]
add eax, esi
add eax, edx
add ecx, eax
mov eax, 0x38e38e39
imul ecx
sar edx, 1
mov ecx, edx
shr ecx, 0x1f
add edx, ecx
mov ecx, edx
sub esi, ecx
mov eax, esi
cdq
xor eax, edx
sub eax, edx
mov edx, dword [esp + 0x10]
cmp eax, edx
jle 0x404e02
mov eax, esi
imul eax, dword [esp + 0x14]
cdq
and edx, 0x1f
add eax, edx
sar eax, 5
add eax, ecx
jns 0x404dee
mov edx, dword [esp + 0x30]
xor eax, eax
mov byte [edx], al
jmp 0x404e0b
cmp eax, 0xff
jle 0x404dfa
mov eax, 0xff
mov edx, dword [esp + 0x30]
mov byte [edx], al
jmp 0x404e0b
mov ecx, dword [esp + 0x30]
mov al, byte [ebp]
mov byte [ecx], al
mov ecx, dword [esp + 0x30]
mov eax, dword [esp + 0x20]
inc ebp
inc edi
inc ecx
dec eax
mov dword [esp + 0x30], ecx
mov dword [esp + 0x20], eax
jne 0x404d66
mov eax, dword [esp + 0x24]
mov edx, ebx
mov ecx, ebx
sub edx, eax
sub ecx, eax
lea ebp, [edx + ebp + 2]
mov edx, dword [esp + 0x30]
lea ecx, [edx + ecx + 2]
mov dword [esp + 0x30], ecx
mov ecx, dword [esp + 0x28]
dec ecx
mov dword [esp + 0x28], ecx
jne 0x404d50
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret