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

Disassembly:
push 0x14
mov eax, 0x1001d960
call fcn.10004980
mov ebx, dword [ebp + 8]
xor edi, edi
xor eax, eax
mov dword [ebp - 4], edi
mov esi, edi
mov dword [ebp - 0x14], esi
mov word [ebx], ax
call fcn.100018f8
test eax, eax
je 0x10001a12
call fcn.100018ea
mov esi, eax
mov dword [ebp - 0x14], eax
push 0x104
push ebx
push esi
push edi
push 0x10021c18
call dword [sym.imp.SHELL32.dll_SHGetFolderPathEx]
mov esi, eax
test esi, esi
js 0x10001b28
jmp 0x10001a62
mov eax, dword [ebp - 0x14]
test eax, eax
je 0x10001a70
push eax
call dword [sym.imp.kernel32.dll_CloseHandle]
or dword [ebp - 4], 0xffffffff
test esi, esi
jns 0x10001b20
push ebx
push edi
push edi
push 0x1a
push edi
mov dword [ebp - 4], 2
call dword [sym.imp.SHELL32.dll_SHGetFolderPathW]
mov esi, eax
test esi, esi
jns 0x10001ad1
push esi
push str.Error:_08x_in_SHGetFolderPathW_NULL__CSIDL_APPDATA__NULL__0__pPath_
jmp 0x10001b2e
or dword [ebp - 4], 0xffffffff
test esi, esi
jns 0x10001b20
push 1
push 0x1a
push ebx
push edi
mov dword [ebp - 4], 4
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
mov esi, eax
test esi, esi
jns 0x10001b20
push esi
push str.Error:_08x_in_SHGetSpecialFolderPathW_NULL__pPath__CSIDL_APPDATA__TRUE_
jmp 0x10001b2e
mov eax, esi
call fcn.10004937
ret
push esi
push str.Error:_08x_in_SHGetFolderPathEx_FOLDERID_LocalAppDataLow__0__hToken__pPath__MAX_PATH_
call fcn.10003d44
pop ecx
pop ecx
push edi
push esi
call fcn.10015553
int3

Function at 0x10002445
Capabilities:
Query environment variable

Disassembly:
push esi
xor esi, esi
cmp dword [esp + 8], esi
je 0x10002469
push dword [esp + 0xc]
push dword [esp + 0xc]
push str.USER_JPI_PROFILE
call dword [sym.imp.kernel32.dll_GetEnvironmentVariableA]
xor ecx, ecx
inc ecx
test eax, eax
cmovne esi, ecx
mov eax, esi
pop esi
ret
Function at 0x100030b4
Capabilities:
Get common file path

Disassembly:
push ebp
lea ebp, [esp - 0x108]
sub esp, 0x108
push 0xffffffffffffffff
push 0x1001d9bb
mov eax, dword fs:[0]
push eax
sub esp, 0x10
mov eax, dword [0x1002a034]
xor eax, ebp
mov dword [ebp + 0x104], eax
push esi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
push 0x1001ec0c
lea eax, [ebp - 0x1c]
push eax
lea eax, [ebp - 0x18]
push eax
call fcn.10015553
add esp, 0xc
test eax, eax
jne 0x100031a9
push dword [ebp - 0x18]
call fcn.10015553
cmp dword [0x1002aa80], 0
pop ecx
je 0x10003122
xor eax, eax
inc eax
jmp 0x100031ab
lea eax, [ebp]
mov esi, 0x104
push eax
push esi
call dword [sym.imp.kernel32.dll_GetTempPathA]
cmp eax, esi
ja 0x100031a9
test eax, eax
je 0x100031a9
lea eax, [ebp]
push eax
lea ecx, [ebp - 0x10]
call fcn.1000330b
and dword [ebp - 4], 0
lea ecx, [ebp - 0x14]
push str.JavaDeployReg.log
call fcn.1000330b
lea eax, [ebp - 0x14]
mov byte [ebp - 4], 1
push eax
lea ecx, [ebp - 0x10]
call fcn.100033d2
mov ecx, dword [ebp - 0x14]
mov byte [ebp - 4], 0
test ecx, ecx
je 0x10003177
call fcn.100037d1
push 0x1001ec38
lea ecx, [ebp - 0x10]
call fcn.100033b4
push eax
push 0x1002aa80
call fcn.10015553
mov ecx, dword [ebp - 0x10]
add esp, 0xc
mov esi, eax
neg esi
sbb esi, esi
test ecx, ecx
je 0x100031a4
call fcn.100037d1
lea eax, [esi + 1]
jmp 0x100031ab
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
mov ecx, dword [ebp + 0x104]
xor ecx, ebp
call fcn.10004926
add ebp, 0x108
leave
ret

Function at 0x10003656
Capabilities:
Query or enumerate registry key

Disassembly:
sub esp, 0x11c
mov eax, dword [0x1002a034]
xor eax, esp
mov dword [esp + 0x118], eax
push ebx
mov ebx, dword [esp + 0x124]
push ebp
push esi
push edi
mov edi, ecx
xor ebp, ebp
lea ecx, [esp + 0x14]
mov dword [esp + 0x14], ebp
mov dword [esp + 0x18], ebp
mov dword [esp + 0x1c], ebp
mov eax, dword [edi + 4]
or eax, 0x2001f
push eax
push ebx
push dword [edi]
call fcn.10015553
mov esi, eax
test esi, esi
jne 0x10003705
lea eax, [esp + 0x20]
push eax
push ebp
push ebp
push ebp
lea eax, [esp + 0x20]
push eax
lea eax, [esp + 0x3c]
push eax
push ebp
mov ebp, dword [sym.imp.ADVAPI32.dll_RegEnumKeyExA]
jmp 0x100036e0
lea eax, [esp + 0x28]
push eax
call fcn.10003656
mov esi, eax
test esi, esi
jne 0x10003705
lea eax, [esp + 0x20]
xor ecx, ecx
push eax
push ecx
push ecx
push ecx
lea eax, [esp + 0x20]
push eax
lea eax, [esp + 0x3c]
push eax
push ecx
push dword [esp + 0x30]
mov dword [esp + 0x30], pe_nt_image_headers32
call ebp
lea ecx, [esp + 0x14]
test eax, eax
je 0x100036bb
call fcn.1000342b
push ebx
mov ecx, edi
call fcn.10003445
mov esi, eax
lea ecx, [esp + 0x14]
call fcn.1000342b
mov ecx, dword [esp + 0x128]
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.10004926
add esp, 0x11c
ret 4
Function at 0x10003bc2
Capabilities:
Print debug messages

Disassembly:
sub esp, 0x824
mov eax, dword [0x1002a034]
xor eax, esp
mov dword [esp + 0x820], eax
push ebx
push ebp
mov ebp, dword [esp + 0x830]
lea eax, [esp + 0x428]
push esi
mov esi, dword [esp + 0x838]
xor ebx, ebx
push edi
mov edi, 0x400
push edi
push ebx
push eax
call fcn.10005d80
push esi
push ebx
push ebp
push 0xffffffffffffffff
lea eax, [esp + 0x44c]
push edi
push eax
call fcn.10015553
movzx ecx, byte [esp + 0x853]
lea edi, [esp + 0x34]
xor edx, edx
test eax, eax
push 8
cmovs ecx, edx
xor eax, eax
mov byte [esp + 0x857], cl
pop ecx
rep stosd dword es:[edi], eax
lea eax, [esp + 0x34]
push 0x20
push eax
call fcn.10015553
push 0x10021be8
lea eax, [esp + 0x40]
push 0x20
push eax
call fcn.10015553
push 0x400
lea eax, [esp + 0x6c]
push ebx
push eax
call fcn.10005d80
mov ecx, ebp
add esp, 0x44
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x10003c67
sub ecx, edx
cmp ecx, 6
jbe 0x10003c8e
lea eax, [ebp - 6]
add eax, ecx
push str.__08x_
push eax
call fcn.10015553
pop ecx
pop ecx
test eax, eax
jne 0x10003c8e
xor ebx, ebx
inc ebx
lea esi, [esp + 0x10]
lea ecx, [esi + 1]
mov al, byte [esi]
inc esi
test al, al
jne 0x10003c95
sub esi, ecx
lea eax, [esp + 0x430]
push eax
mov ecx, 0x10020533
test ebx, ebx
mov eax, str.Error:
cmove eax, ecx
push eax
call dword [sym.imp.kernel32.dll_GetCurrentThreadId]
push eax
call dword [sym.imp.kernel32.dll_GetCurrentProcessId]
push eax
push str.P:_04d_T:_04d__s_s
mov eax, 0x3ff
sub eax, esi
push 0xffffffffffffffff
push eax
lea eax, [esp + 0x4c]
add eax, esi
push eax
call fcn.10015553
mov ecx, dword [esp + 0x44b]
test eax, eax
push esi
lea eax, [esp + 0x34]
mov edx, 0x2e2e2e
push eax
lea eax, [esp + 0x58]
cmovs ecx, edx
push eax
mov dword [esp + 0x457], ecx
call fcn.10005800
lea edi, [esp + 0x5c]
add esp, 0x2c
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x10003d0f
mov ax, word [0x10021c14]
mov word [edi], ax
lea eax, [esp + 0x30]
push eax
call dword [sym.imp.kernel32.dll_OutputDebugStringA]
mov ecx, dword [esp + 0x830]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.10004926
add esp, 0x824
ret
Function at 0x10015553
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30
pushal
call 0x10015562
pop dword [ebp - 0x20]
mov eax, 0xfadffd0b
add eax, 0x15215857
sub dword [ebp - 0x20], eax
mov dword [ebp - 0x30], 0xba12f24e
add dword [ebp - 0x30], 0x943f52fd
mov dword [ebp - 0x2c], 0x3d90b836
add dword [ebp - 0x2c], 0xf4a2940f
mov dword [ebp - 0x28], 0x44ae4061
sub dword [ebp - 0x28], 0xf861fc33
mov dword [ebp - 0x24], 0x642a82cd
sub dword [ebp - 0x24], 0x642a82cd
lea eax, [ebp - 0x30]
push eax
mov eax, 0x421a2efe
sub eax, 0x32184e7e
add eax, dword [ebp - 0x20]
call dword [eax]
mov dword [ebp - 0x30], 0x2033749f
add dword [ebp - 0x30], 0x543ef4b7
mov dword [ebp - 0x2c], 0xe12f4781
sub dword [ebp - 0x2c], 0x9fc2e60c
mov dword [ebp - 0x28], 0x4ea9df5f
sub dword [ebp - 0x28], 0xeb3a72f3
mov dword [ebp - 0x24], 0x3c68b12
add dword [ebp - 0x24], 0xfc3974ee
lea ebx, [ebp - 0x30]
push ebx
push eax
mov eax, 0x3d963fb2
sub eax, 0x2d945f2e
add eax, dword [ebp - 0x20]
call dword [eax]
push 0x40
push 0x1000
push 0x442d6
push 0
call eax
mov ecx, 0xd131cff
add ecx, 0xf2ed465f
mov ebx, eax
mov edx, 0x9a630409
sub edx, 0x8a5fac09
add edx, dword [ebp - 0x20]
mov edi, 0x4c74f855
sub edi, 0xe884d4a2
xor dword [ebp - 0x18], 0x1c596b58
mov esi, dword [edx]
add dword [ebp - 0xc], 0x627f72a7
sub esi, edi
xor dword [ebp - 0x18], 0xe21f4ada
mov dword [ebx], esi
xor dword [ebp - 4], ebx
add ebx, 0x1595b5ef
sub ebx, 0x1595b5eb
add edx, 0xa3266011
add edx, 0x5cd99ff3
loop 0x10015684
add eax, 0xe9b27068
sub eax, 0xe9b0f01d
xor ebx, ebx
add ebx, eax
add eax, 0x2e2819a1
sub eax, 0x2e28199c
mov ecx, 0x10000000
add ecx, dword [ebp - 0x20]
call ebx
leave
ret
Function at 0x401a50
Capabilities:
Write file on windows

Disassembly:
push ebx
sub esp, 0x18
mov eax, dword [sym.imp.msvcrt.dll__iob]
mov dword [esp + 8], 0x1b
mov dword [esp + 4], 1
lea ebx, [esp + 0x24]
mov dword [esp], str.Mingw_w64_runtime_failure:_n
add eax, 0x40
mov dword [esp + 0xc], eax
call sym._fwrite
mov eax, dword [esp + 0x20]
mov dword [esp + 8], ebx
mov dword [esp + 4], eax
mov eax, dword [sym.imp.msvcrt.dll__iob]
add eax, 0x40
mov dword [esp], eax
call sym._vfprintf
call sym._abort
jmp dbg.mark_section_writable

Function at 0x401ab0
Capabilities:
Allocate or change rwx memory

Disassembly:
push edi
push esi
push ebx
sub esp, 0x30
mov esi, dword [0x40505c]
test esi, esi
jle 0x401b9d
mov edi, dword [0x405060]
xor ebx, ebx
lea edx, [edi + 4]
nop
mov ecx, dword [edx]
cmp ecx, eax
ja 0x401ae4
mov edi, dword [edx + 4]
add ecx, dword [edi + 8]
cmp eax, ecx
jb 0x401b96
add ebx, 1
add edx, 0xc
cmp ebx, esi
jne 0x401ad0
mov dword [esp], eax
mov ebx, eax
call dbg.__mingw_GetSectionForAddress
test eax, eax
mov edi, eax
je 0x401bda
lea ebx, [esi + esi*2]
mov esi, dword [0x405060]
shl ebx, 2
add esi, ebx
mov dword [esi + 8], eax
mov dword [esi], 0
call dbg._GetPEImageBase
add eax, dword [edi + 0xc]
mov dword [esi + 4], eax
lea eax, [esp + 0x14]
mov dword [esp + 8], 0x1c
mov dword [esp + 4], eax
mov eax, dword [0x405060]
mov eax, dword [eax + ebx + 4]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
sub esp, 0xc
test eax, eax
je 0x401bba
mov eax, dword [esp + 0x28]
lea edx, [eax - 4]
and edx, 0xfffffffb
je 0x401b8f
sub eax, 0x40
and eax, 0xffffffbf
je 0x401b8f
mov eax, dword [esp + 0x20]
add ebx, dword [0x405060]
mov dword [esp + 8], 0x40
mov dword [esp + 4], eax
mov eax, dword [esp + 0x14]
mov dword [esp + 0xc], ebx
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
sub esp, 0x10
test eax, eax
je 0x401ba4
add dword [0x40505c], 1
add esp, 0x30
pop ebx
pop esi
pop edi
ret
xor esi, esi
jmp 0x401aee
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [esp], str.__VirtualProtect_failed_with_code_0x_x
mov dword [esp + 4], eax
call dbg.__report_error
mov eax, dword [0x405060]
mov eax, dword [eax + ebx + 4]
mov dword [esp + 8], eax
mov eax, dword [edi + 8]
mov dword [esp], str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov dword [esp + 4], eax
call dbg.__report_error
mov dword [esp + 4], ebx
mov dword [esp], str.Address__p_has_no_image_section
call dbg.__report_error
lea esi, [esi]
Function at 0x4020a0
Capabilities:
Get thread local storage value

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x1c
mov dword [esp], 0x405408
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov ebx, dword [0x405400]
sub esp, 4
mov ebp, dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
test ebx, ebx
je 0x4020f5
lea esi, [esi]
mov eax, dword [ebx]
mov dword [esp], eax
call ebp
sub esp, 4
mov esi, eax
call edi
test eax, eax
jne 0x4020ee
test esi, esi
je 0x4020ee
mov eax, dword [ebx + 4]
mov dword [esp], esi
call eax
mov ebx, dword [ebx + 8]
test ebx, ebx
jne 0x4020d0
mov dword [esp], 0x405408
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
sub esp, 4
add esp, 0x1c
pop ebx
pop esi
pop edi
pop ebp
ret

Function at 0x402310
Capabilities:
Enumerate pe sections

Disassembly:
push esi
push ebx
mov edx, dword [esp + 0xc]
mov ebx, dword [esp + 0x10]
add edx, dword [edx + 0x3c]
movzx esi, word [edx + 6]
movzx eax, word [edx + 0x14]
test esi, esi
lea eax, [edx + eax + 0x18]
je 0x402348
xor ecx, ecx
nop
mov edx, dword [eax + 0xc]
cmp edx, ebx
ja 0x40233e
add edx, dword [eax + 8]
cmp ebx, edx
jb 0x40234a
add ecx, 1
add eax, 0x28
cmp ecx, esi
jne 0x402330
xor eax, eax
pop ebx
pop esi
ret
Function at 0x402849
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
push ebp
mov ebp, esp
mov edx, dword [ebp + 0xc]
test edx, edx
jne 0x402857
xor eax, eax
pop ebp
ret
mov eax, dword [ebp + 8]
cmp dword [ebp + 0x10], 8
push esi
push edi
not eax
mov ecx, 0xff
jb 0x402938
mov edi, dword [ebp + 0x10]
push ebx
shr edi, 3
movzx ebx, byte [edx]
mov esi, eax
sub dword [ebp + 0x10], 8
and esi, ecx
xor esi, ebx
mov ebx, eax
shr ebx, 8
mov eax, dword [esi*4 + 0x40e79c]
xor eax, ebx
inc edx
mov esi, eax
movzx ebx, byte [edx]
and esi, ecx
xor esi, ebx
movzx ebx, byte [edx + 1]
mov esi, dword [esi*4 + 0x40e79c]
shr eax, 8
xor esi, eax
inc edx
mov eax, esi
and eax, ecx
xor eax, ebx
movzx ebx, byte [edx + 1]
mov eax, dword [eax*4 + 0x40e79c]
shr esi, 8
xor eax, esi
inc edx
mov esi, eax
and esi, ecx
xor esi, ebx
movzx ebx, byte [edx + 1]
mov esi, dword [esi*4 + 0x40e79c]
shr eax, 8
xor esi, eax
inc edx
mov eax, esi
and eax, ecx
xor eax, ebx
movzx ebx, byte [edx + 1]
mov eax, dword [eax*4 + 0x40e79c]
shr esi, 8
xor eax, esi
inc edx
mov esi, eax
and esi, ecx
xor esi, ebx
movzx ebx, byte [edx + 1]
mov esi, dword [esi*4 + 0x40e79c]
shr eax, 8
xor esi, eax
inc edx
mov eax, esi
and eax, ecx
xor eax, ebx
movzx ebx, byte [edx + 1]
mov eax, dword [eax*4 + 0x40e79c]
shr esi, 8
xor eax, esi
inc edx
mov esi, eax
and esi, ecx
xor esi, ebx
shr eax, 8
mov esi, dword [esi*4 + 0x40e79c]
xor eax, esi
inc edx
dec edi
jne 0x402874
pop ebx
cmp dword [ebp + 0x10], 0
je 0x402959
movzx edi, byte [edx]
mov esi, eax
and esi, ecx
xor esi, edi
shr eax, 8
mov esi, dword [esi*4 + 0x40e79c]
xor eax, esi
inc edx
dec dword [ebp + 0x10]
jne 0x40293e
pop edi
pop esi
not eax
pop ebp
ret

Function at 0x40295f
Capabilities:
Generate random numbers using the delphi lcg
Hash data with crc32

Disassembly:
mov ecx, dword [esp + 4]
push esi
push edi
mov edx, 0xff
mov esi, dword [ecx]
movzx edi, byte [esp + 0x10]
mov eax, esi
and eax, edx
xor eax, edi
shr esi, 8
mov eax, dword [eax*4 + 0x40e79c]
xor eax, esi
mov esi, dword [ecx + 8]
mov dword [ecx], eax
and eax, edx
add eax, dword [ecx + 4]
mov edi, esi
and edi, edx
imul eax, eax, 0x8088405
inc eax
mov dword [ecx + 4], eax
shr eax, 0x18
xor eax, edi
pop edi
shr esi, 8
mov eax, dword [eax*4 + 0x40e79c]
xor eax, esi
pop esi
mov dword [ecx + 8], eax
ret

Function at 0x403199
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 0x14]
push edi
mov edi, dword [ebp + 0xc]
imul edi, dword [ebp + 0x10]
cmp byte [esi], 0
je 0x4031cd
lea eax, [ebp + 8]
push 0
push eax
push edi
push dword [ebp + 8]
push dword [esi + 4]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x4031c8
mov byte [esi + 8], 1
mov eax, dword [ebp + 8]
jmp 0x4031f5
mov ecx, dword [esi + 0x1c]
mov eax, dword [esi + 0x18]
lea edx, [ecx + edi]
cmp edx, eax
jbe 0x4031de
sub eax, ecx
mov edi, eax
mov eax, dword [esi + 0x14]
push edi
add eax, ecx
push eax
push dword [ebp + 8]
call sub.MSVCRT.dll_memcpy
add esp, 0xc
add dword [esi + 0x1c], edi
mov eax, edi
xor edx, edx
pop edi
div dword [ebp + 0xc]
pop esi
pop ebp
ret
Function at 0x403fa0
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
mov esi, ecx
cmp dword [esi], 0
jne 0x404048
cmp dword [esi + 4], 0xffffffff
jne 0x404048
push edi
lea edi, [esi + 0x140]
push edi
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
push edi
call sub.MSVCRT.dll_strlen
mov al, byte [eax + esi + 0x13f]
pop ecx
cmp al, 0x5c
je 0x403ff0
cmp al, 0x2f
je 0x403ff0
push 0x4122a0
push edi
call sub.MSVCRT.dll_strcat
pop ecx
pop ecx
cmp dword [ebp + 0x10], 1
pop edi
jne 0x404012
push 1
push 0
push 0
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp eax, 0xffffffff
jne 0x404012
mov eax, 0x2000000
jmp 0x40404d
lea eax, [ebp - 4]
push eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.00402fbd
add esp, 0x10
test eax, eax
jne 0x404030
mov eax, dword [ebp - 4]
jmp 0x40404d
push eax
call fcn.004033f1
mov dword [esi], eax
pop ecx
neg eax
sbb eax, eax
and ax, 0xfe00
add eax, 0x200
jmp 0x40404d
mov eax, 0x1000000
pop esi
leave
ret 0xc

Function at 0x4044c2
Capabilities:
Check if file exists
Create directory
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x208
push ebx
mov ebx, dword [ebp + 8]
test ebx, ebx
push edi
je 0x4044e9
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x4044e9
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
mov edi, dword [ebp + 0xc]
mov al, byte [edi]
test al, al
je 0x404584
push esi
mov esi, edi
mov ecx, edi
cmp al, 0x2f
je 0x404503
cmp al, 0x5c
jne 0x404505
mov esi, ecx
mov al, byte [ecx + 1]
inc ecx
test al, al
jne 0x4044fb
cmp esi, edi
je 0x404539
sub esi, edi
lea eax, [ebp - 0x208]
push esi
push edi
push eax
call sub.MSVCRT.dll_memcpy
and byte [ebp + esi - 0x208], 0
lea eax, [ebp - 0x208]
push eax
push ebx
call fcn.004044c2
add esp, 0x14
and byte [ebp - 0x104], 0
pop esi
test ebx, ebx
je 0x404554
lea eax, [ebp - 0x104]
push ebx
push eax
call sub.MSVCRT.dll_strcpy
pop ecx
pop ecx
lea eax, [ebp - 0x104]
push edi
push eax
call sub.MSVCRT.dll_strcat
pop ecx
lea eax, [ebp - 0x104]
pop ecx
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x404584
lea eax, [ebp - 0x104]
push 0
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
pop edi
pop ebx
leave
ret
Function at 0x40528f
Capabilities:
Get common file path

Disassembly:
mov eax, 0x40cb28
call fcn.0040c6c0
sub esp, 0x138
push esi
xor esi, esi
cmp dword [ebp + 8], esi
mov dword [ebp - 4], esi
je 0x405430
lea eax, [ebp - 0x20]
push eax
call dword [sym.imp.SHELL32.dll_SHGetMalloc]
test eax, eax
jne 0x405430
mov esi, dword [sym.imp.MSVCRT.dll__mbscmp]
and byte [ebp - 0xd], al
push ebx
push edi
push 0x422f44
push dword [ebp + 0xc]
call esi
pop ecx
mov edi, 0x4122a0
test eax, eax
pop ecx
je 0x405337
lea eax, [ebp - 0x14]
push 1
push eax
lea ecx, [ebp + 0xc]
call sub.MFC42.DLL_CString::Right
mov eax, dword [eax]
push edi
push eax
call esi
mov ebx, eax
pop ecx
neg ebx
pop ecx
sbb bl, bl
lea ecx, [ebp - 0x14]
inc bl
call fcn.0040c440
test bl, bl
je 0x405337
mov eax, dword [ebp + 0xc]
lea ecx, [ebp + 0xc]
mov eax, dword [eax - 8]
dec eax
push eax
lea eax, [ebp - 0x14]
push eax
call sub.MFC42.DLL_CString::Left
push eax
lea ecx, [ebp + 0xc]
mov byte [ebp - 4], 1
call sub.MFC42.DLL_CString::operator_1
and byte [ebp - 4], 0
lea ecx, [ebp - 0x14]
call fcn.0040c440
lea eax, [ebp - 0x18]
xor ebx, ebx
push eax
push ebx
push ebx
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderLocation]
push 0x20
lea eax, [ebp - 0x40]
push ebx
push eax
call sub.MSVCRT.dll_memset
mov eax, dword [ebp - 0x18]
add esp, 0xc
mov dword [ebp - 0x3c], eax
lea eax, [ebp - 0x144]
push 1
lea ecx, [ebp + 0xc]
pop ebx
mov dword [ebp - 0x38], eax
push 0
mov dword [ebp - 0x34], 0x4123ac
mov dword [ebp - 0x30], ebx
mov dword [ebp - 0x2c], 0x40544d
call sub.MFC42.DLL_CString::GetBuffer
mov dword [ebp - 0x28], eax
lea eax, [ebp - 0x40]
push eax
call dword [sym.imp.SHELL32.dll_SHBrowseForFolderA]
test eax, eax
mov dword [ebp - 0x1c], eax
je 0x405412
lea ecx, [ebp - 0x144]
push ecx
push eax
call dword [sym.imp.SHELL32.dll_SHGetPathFromIDListA]
test eax, eax
je 0x405405
mov ecx, dword [ebp + 8]
push 0x422f44
call sub.MFC42.DLL_CString::operator
mov ecx, dword [ebp + 8]
lea eax, [ebp - 0x144]
push eax
call sub.MFC42.DLL_CString::operator
mov eax, dword [ebp + 8]
push 0x422f44
mov eax, dword [eax]
push eax
call esi
pop ecx
test eax, eax
pop ecx
je 0x405405
mov ecx, dword [ebp + 8]
lea eax, [ebp - 0x14]
push ebx
push eax
call sub.MFC42.DLL_CString::Right
mov eax, dword [eax]
push edi
push eax
call esi
pop ecx
pop ecx
test eax, eax
lea ecx, [ebp - 0x14]
setne bl
call fcn.0040c440
test bl, bl
je 0x405405
mov ecx, dword [ebp + 8]
push edi
call fcn.0040c494
push dword [ebp - 0x1c]
mov byte [ebp - 0xd], 1
call dword [sym.imp.ole32.dll_CoTaskMemFree]
cmp dword [ebp - 0x18], 0
pop edi
pop ebx
je 0x405423
push dword [ebp - 0x18]
call dword [sym.imp.ole32.dll_CoTaskMemFree]
mov eax, dword [ebp - 0x20]
push eax
mov ecx, dword [eax]
call dword [ecx + 8]
movzx esi, byte [ebp - 0xd]
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0xc]
call fcn.0040c440
mov ecx, dword [ebp - 0xc]
mov eax, esi
pop esi
mov dword fs:[0], ecx
leave
ret 8
Function at 0x406f85
Capabilities:
Encode data using xor
Encrypt data using rc4 prga

Disassembly:
push ebx
mov ebx, dword [esp + 0xc]
push esi
push edi
push 1
xor edi, edi
pop eax
cmp ebx, eax
jl 0x406f9a
cmp ebx, 8
jle 0x406f9c
xor eax, eax
mov esi, dword [esp + 0x10]
push str.bad_pack_level
push eax
push esi
call fcn.00405b22
lea ecx, [esi + 0x6af70]
lea eax, [esi + 0x6af78]
add esp, 0xc
cmp dword [ecx], edi
mov dword [eax], edi
jne 0x406fcd
mov dword [eax], 1
mov dword [ecx], 0x10000
push 0x1fffc
lea eax, [esi + 0x4af70]
push edi
push eax
mov dword [esi + 0x6af6c], edi
call sub.MSVCRT.dll_memset
mov eax, ebx
add esp, 0xc
shl eax, 3
cmp ebx, 2
movzx ecx, word [eax + 0x40ef1a]
mov dword [esi + 0x6af98], ecx
movzx ecx, word [eax + 0x40ef18]
mov dword [esi + 0x6af9c], ecx
movzx ecx, word [eax + 0x40ef1c]
mov dword [esi + 0x6afa0], ecx
movzx eax, word [eax + 0x40ef1e]
mov dword [esi + 0x6af94], eax
jg 0x40702f
mov eax, dword [esp + 0x18]
or byte [eax], 4
jmp 0x40703b
cmp ebx, 8
jl 0x40703b
mov eax, dword [esp + 0x18]
or byte [eax], 2
lea ebx, [esi + 0x1af70]
push 0x10000
push ebx
push esi
mov dword [esi + 0x6af84], edi
mov dword [esi + 0x6af74], edi
call dword [esi + 0xc]
add esp, 0xc
cmp eax, edi
mov dword [esi + 0x6af90], eax
je 0x4070ab
cmp eax, 0xffffffff
je 0x4070ab
cmp eax, 0x106
mov dword [esi + 0x6af8c], edi
jae 0x40707d
push esi
call fcn.00407282
pop ecx
mov dword [esi + 0x6af7c], edi
movzx eax, byte [ebx + edi]
mov ecx, dword [esi + 0x6af7c]
and eax, 0x7fff
and ecx, 0x3ff
shl ecx, 5
xor eax, ecx
inc edi
cmp edi, 2
mov dword [esi + 0x6af7c], eax
jb 0x407083
jmp 0x4070bb
mov dword [esi + 0x6af8c], 1
mov dword [esi + 0x6af90], edi
pop edi
pop esi
pop ebx
ret