joyce8/EMBER2024-capa huggingface dataset:
Function at 0x413530
Capabilities:
Read file on windows

Disassembly:
push ebx
push esi
mov esi, dword [esp + 0xc]
cmp dword [esi + 0x14], 0
push edi
jne 0x413551
push esi
call fcn.00412e20
mov dword [esi + 0x14], 1
mov dword [esi + 0xc], 0
mov ebx, dword [esi + 0xc]
mov edi, dword [esp + 0x18]
cmp ebx, edi
jl 0x4135ca
mov eax, dword [esi + 0x10]
add eax, dword [esi + 4]
mov ecx, edi
sub eax, ebx
sub ecx, 1
je 0x4135b7
sub ecx, 1
je 0x4135a2
sub ecx, 2
je 0x41358f
push edi
push eax
mov eax, dword [esp + 0x1c]
push eax
call sub.MSVCRT.dll_memcpy
add esp, 0xc
sub dword [esi + 0xc], edi
mov eax, edi
pop edi
pop esi
pop ebx
ret 0xc
mov ecx, dword [eax]
mov edx, dword [esp + 0x14]
mov dword [edx], ecx
sub dword [esi + 0xc], edi
mov eax, edi
pop edi
pop esi
pop ebx
ret 0xc
mov ax, word [eax]
mov ecx, dword [esp + 0x14]
mov word [ecx], ax
sub dword [esi + 0xc], edi
mov eax, edi
pop edi
pop esi
pop ebx
ret 0xc
mov dl, byte [eax]
mov eax, dword [esp + 0x14]
mov byte [eax], dl
sub dword [esi + 0xc], edi
mov eax, edi
pop edi
pop esi
pop ebx
ret 0xc
mov ecx, dword [esi + 0x10]
push ebp
mov ebp, dword [esp + 0x18]
sub ecx, ebx
add ecx, dword [esi + 4]
push ebx
push ecx
push ebp
call sub.MSVCRT.dll_memcpy
mov eax, dword [esi + 8]
add esp, 0xc
sub edi, ebx
add ebp, ebx
cmp edi, eax
push 0
jl 0x413613
mov eax, dword [esi]
lea edx, [esp + 0x18]
push edx
push edi
push ebp
push eax
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [esp + 0x14]
pop ebp
pop edi
mov dword [esi + 0xc], 0
pop esi
add eax, ebx
pop ebx
ret 0xc
mov edx, dword [esi + 4]
lea ecx, [esp + 0x18]
push ecx
push eax
mov eax, dword [esi]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [esp + 0x14]
cmp edi, eax
mov dword [esi + 0xc], eax
mov dword [esi + 0x10], eax
jle 0x413636
mov edi, eax
mov ecx, dword [esi + 4]
push edi
push ecx
push ebp
call sub.MSVCRT.dll_memcpy
sub dword [esi + 0xc], edi
add esp, 0xc
pop ebp
lea eax, [ebx + edi]
pop edi
pop esi
pop ebx
ret 0xc

Function at 0x413971
Capabilities:
Get thread local storage value

Disassembly:
push dword [0x49d19c]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
push dword [esp + 0xc]
push dword [esp + 0xc]
push dword [esp + 0xc]
push eax
call dword [eax + 0x24]
ret 0xc

Function at 0x414710
Capabilities:
Check os version

Disassembly:
push ebp
lea ebp, [esp - 0x78]
sub esp, 0x94
push edi
push str.msimg32.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
xor edi, edi
cmp eax, edi
mov dword [0x49cd9c], eax
je 0x414743
push str.AlphaBlend
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [0x49cda0], eax
lea eax, [ebp - 0x1c]
push eax
mov dword [0x49cd98], 1
mov dword [ebp - 0x1c], 0x94
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
test eax, eax
je 0x414781
cmp dword [ebp - 0xc], 1
je 0x414792
cmp dword [ebp - 0xc], 2
jne 0x414781
cmp dword [ebp - 0x18], 5
jb 0x414792
jne 0x414781
cmp dword [ebp - 0x14], edi
jne 0x414781
mov dword [0x49cd98], edi
cmp dword [0x49cd98], edi
je 0x414798
call fcn.00414657
test eax, eax
jne 0x414798
mov dword [0x49cd98], edi
pop edi
add ebp, 0x78
leave
ret
Function at 0x415475
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push edi
push dword [0x49cda4]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov edi, eax
test edi, edi
jne 0x4154d6
push esi
push dword [0x49cdac]
push 8
push dword [0x49c21c]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov edi, eax
push edi
push dword [0x49cda4]
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
mov esi, dword [0x49cda8]
jmp 0x4154c6
mov eax, dword [esi + 0xc]
test eax, eax
je 0x4154c4
mov ecx, dword [esi + 8]
add ecx, edi
push ecx
call eax
pop ecx
mov esi, dword [esi]
test esi, esi
jne 0x4154b4
push edi
push 0x41543a
call fcn.0043f1ed
pop esi
mov eax, dword [esp + 8]
add eax, edi
pop edi
ret 4

Function at 0x4154e0
Capabilities:
Allocate thread local storage
Get thread local storage value
Set thread local storage value

Disassembly:
push ebx
mov ebx, dword [esp + 8]
mov eax, ebx
and eax, 3
push esi
push edi
je 0x4154f5
push 4
pop ecx
sub ecx, eax
add ebx, ecx
cmp dword [0x49cdac], 0
mov esi, dword [sym.imp.KERNEL32.dll_TlsSetValue]
jne 0x415527
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
push ebx
push 8
push dword [0x49c21c]
mov dword [0x49cda4], eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
push eax
push dword [0x49cda4]
call esi
mov edi, dword [0x49cdac]
add dword [0x49cdac], ebx
push dword [0x49cdac]
push dword [0x49cda4]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
push eax
push 8
push dword [0x49c21c]
call dword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov ebx, eax
push ebx
push dword [0x49cda4]
call esi
mov esi, dword [esp + 0x14]
test esi, esi
jne 0x41556d
cmp dword [esp + 0x18], esi
je 0x415591
push 0x14
push 0x49cda8
call fcn.00415920
test esi, esi
pop ecx
pop ecx
mov ecx, dword [esp + 0x18]
mov dword [eax], edi
mov dword [eax + 4], esi
mov dword [eax + 8], ecx
je 0x415591
add ebx, edi
push ebx
call esi
pop ecx
mov eax, edi
pop edi
pop esi
pop ebx
ret 0xc

Function at 0x415a00
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
mov eax, dword [0x48bdac]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov dword [ebp - 8], eax
mov ecx, dword [ebp - 8]
mov edx, dword [ecx + 8]
sub edx, dword [ebp + 0xc]
mov dword [ebp - 4], edx
mov eax, dword [ebp + 8]
cmp dword [eax], 0
jne 0x415a46
mov ecx, dword [ebp - 4]
add ecx, 5
push ecx
push 0
mov edx, dword [0x49d224]
push edx
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ecx, dword [ebp + 8]
mov dword [ecx], eax
jmp 0x415a67
mov edx, dword [ebp - 4]
add edx, 5
push edx
mov eax, dword [ebp + 8]
mov ecx, dword [eax]
push ecx
push 0
mov edx, dword [0x49d224]
push edx
call dword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov ecx, dword [ebp + 8]
mov dword [ecx], eax
mov edx, dword [ebp - 4]
push edx
mov eax, dword [ebp - 8]
mov ecx, dword [eax]
add ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp + 8]
mov eax, dword [edx]
push eax
call fcn.00415f70
mov ecx, dword [ebp - 8]
mov edx, dword [ebp + 0xc]
mov dword [ecx + 8], edx
mov esp, ebp
pop ebp
ret 8
Function at 0x415af0
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [0x48bdac]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 4]
mov edx, dword [ecx + 8]
add edx, 1
mov eax, dword [ebp - 4]
mov dword [eax + 8], edx
mov esp, ebp
pop ebp
ret

Function at 0x415bb0
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push edx
mov eax, dword [0x48bdac]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov dword [ebp - 8], eax
mov ecx, dword [ebp - 8]
mov edx, dword [ebp + 8]
mov dword [ecx + 8], edx
mov eax, dword [ebp - 8]
mov ecx, dword [eax]
mov edx, dword [ebp - 8]
add ecx, dword [edx + 8]
mov dword [ebp - 4], ecx
pop edx
mov eax, dword [ebp - 4]
mov esp, ebp
pop ebp
ret 4

Function at 0x415cc0
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [0x48bdac]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 4]
mov eax, dword [ecx]
mov edx, dword [ebp - 4]
add eax, dword [edx + 8]
mov esp, ebp
pop ebp
ret

Function at 0x415df0
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [0x48bdac]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 4]
mov edx, dword [ebp + 8]
cmp edx, dword [ecx]
jb 0x415e2e
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
mov edx, dword [ebp - 4]
add ecx, dword [edx + 8]
cmp dword [ebp + 8], ecx
ja 0x415e2e
mov eax, dword [ebp - 4]
mov ecx, dword [ebp + 8]
sub ecx, dword [eax]
add ecx, 1
mov eax, ecx
jmp 0x415e30
xor eax, eax
mov esp, ebp
pop ebp
ret 4

Function at 0x415e40
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [0x48bdac]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 4]
mov eax, dword [ecx]
add eax, dword [ebp + 8]
mov esp, ebp
pop ebp
ret 4
Function at 0x415e70
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
mov eax, dword [0x48bdac]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov dword [ebp - 0xc], eax
cmp dword [ebp + 0xc], 0xffffffff
jne 0x415e94
mov ecx, dword [ebp - 0xc]
mov edx, dword [ecx + 8]
mov dword [ebp + 0xc], edx
mov eax, dword [ebp - 0xc]
mov ecx, dword [eax + 8]
add ecx, dword [ebp + 8]
mov dword [ebp - 8], ecx
mov edx, dword [ebp - 0xc]
mov eax, dword [edx + 4]
sub eax, 4
cmp dword [ebp - 8], eax
jl 0x415ee1
mov ecx, dword [ebp - 8]
add ecx, 0x4000
mov edx, dword [ebp - 0xc]
mov dword [edx + 4], ecx
mov eax, dword [ebp - 0xc]
mov ecx, dword [eax + 4]
add ecx, 5
push ecx
mov edx, dword [ebp - 0xc]
mov eax, dword [edx]
push eax
push 0
mov ecx, dword [0x49d224]
push ecx
call dword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov edx, dword [ebp - 0xc]
mov dword [edx], eax
mov eax, dword [ebp - 0xc]
mov ecx, dword [eax]
add ecx, dword [ebp + 0xc]
mov dword [ebp - 4], ecx
mov edx, dword [ebp + 0xc]
add edx, dword [ebp + 8]
mov eax, dword [ebp - 0xc]
mov dword [eax + 8], edx
mov eax, dword [ebp - 4]
mov esp, ebp
pop ebp
ret 8
Function at 0x42f1e0
Capabilities:
Encode data using xor

Disassembly:
mov ecx, dword [esp + 4]
xor edx, edx
cmp ecx, edx
je 0x42f281
push ebx
push ebp
push esi
mov esi, dword [ecx]
mov byte [esi + 0x16], dl
mov esi, dword [ecx]
mov byte [esi + 0x17], dl
mov esi, dword [ecx]
mov byte [esi + 0x18], dl
mov esi, dword [ecx]
mov byte [esi + 0x19], dl
mov esi, dword [ecx + 4]
xor eax, eax
cmp esi, edx
push edi
jle 0x42f22f
mov edi, dword [ecx]
movzx ebx, byte [edi + edx]
mov ebp, eax
shr ebp, 0x18
xor ebx, ebp
shl eax, 8
xor eax, dword [ebx*4 + 0x4495a8]
add edx, 1
cmp edx, esi
jl 0x42f211
xor edx, edx
mov esi, dword [ecx + 0xc]
cmp esi, edx
jle 0x42f25c
mov edi, dword [ecx + 8]
lea esp, [esp]
movzx ebx, byte [edi + edx]
mov ebp, eax
shr ebp, 0x18
xor ebx, ebp
shl eax, 8
xor eax, dword [ebx*4 + 0x4495a8]
add edx, 1
cmp edx, esi
jl 0x42f240
mov edx, dword [ecx]
mov byte [edx + 0x16], al
mov esi, dword [ecx]
mov edx, eax
shr edx, 8
mov byte [esi + 0x17], dl
mov esi, dword [ecx]
mov edx, eax
shr edx, 0x10
pop edi
mov byte [esi + 0x18], dl
mov ecx, dword [ecx]
pop esi
shr eax, 0x18
pop ebp
mov byte [ecx + 0x19], al
pop ebx
ret
Function at 0x43f1ed
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push esi
xor ebx, ebx
push edi
mov dword [ebp - 4], ebx
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
cmp dword [0x49cdf8], ebx
mov esi, eax
mov dword [ebp - 0xc], esi
jne 0x43f223
push 0x49cddc
call dword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
mov dword [0x49cdf8], 1
push 0x49cddc
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov eax, dword [0x49cdf4]
cmp eax, ebx
mov edi, eax
je 0x43f287
cmp dword [ebp - 4], ebx
jne 0x43f3c7
xor eax, eax
inc eax
lea ecx, [edi + 0x114]
cmp esi, dword [ecx]
je 0x43f25a
inc eax
add ecx, 4
cmp eax, 0x40
jl 0x43f24b
jmp 0x43f278
push dword [ebp + 0xc]
lea esi, [edi + eax*4 + 0x210]
push dword [ebp + 8]
call fcn.0043f03f
mov esi, dword [ebp - 0xc]
pop ecx
pop ecx
mov dword [ebp - 4], 1
mov edi, dword [edi]
cmp edi, ebx
jne 0x43f239
cmp dword [ebp - 4], ebx
jne 0x43f3c7
mov edi, dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push ebx
push ebx
push 0x100000
lea eax, [ebp - 8]
push eax
call edi
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentThread]
push eax
call edi
push eax
call dword [sym.imp.KERNEL32.dll_DuplicateHandle]
test eax, eax
je 0x43f3c7
mov edi, dword [0x49cdf4]
jmp 0x43f2c7
cmp dword [edi + 0xc], 0x3f
jl 0x43f361
mov edi, dword [edi]
cmp edi, ebx
jne 0x43f2bb
push 0x310
push 8
push dword [0x49c21c]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov edi, eax
cmp edi, ebx
je 0x43f3be
push ebx
push 1
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_CreateSemaphoreA]
cmp eax, ebx
mov dword [edi + 8], eax
je 0x43f3b0
push ebx
push ebx
push edi
push 0x43f090
mov dword [edi + 0x10], eax
mov eax, dword [ebp - 8]
mov dword [edi + 0x114], esi
push 0x1000
lea esi, [edi + 0x214]
push ebx
mov dword [edi + 0x14], eax
mov dword [esi], ebx
mov dword [edi + 0xc], 2
call dword [sym.imp.KERNEL32.dll_CreateThread]
cmp eax, ebx
je 0x43f3a7
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.0043f03f
mov eax, dword [0x49cdf4]
cmp eax, ebx
pop ecx
pop ecx
mov dword [edi + 4], ebx
mov dword [edi], eax
je 0x43f359
mov dword [eax + 4], edi
mov dword [0x49cdf4], edi
jmp 0x43f3c7
mov eax, dword [edi + 0xc]
mov ecx, dword [ebp - 8]
push dword [ebp + 0xc]
mov dword [edi + eax*4 + 0x10], ecx
mov eax, dword [edi + 0xc]
push dword [ebp + 8]
mov dword [edi + eax*4 + 0x110], esi
mov eax, dword [edi + 0xc]
mov dword [edi + eax*4 + 0x210], ebx
mov eax, dword [edi + 0xc]
lea esi, [edi + eax*4 + 0x210]
call fcn.0043f03f
inc dword [edi + 0xc]
pop ecx
pop ecx
push ebx
push 1
push dword [edi + 8]
call dword [sym.imp.KERNEL32.dll_ReleaseSemaphore]
jmp 0x43f3c7
push dword [edi + 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
push ebx
push dword [0x49c21c]
call dword [sym.imp.KERNEL32.dll_HeapFree]
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 0x49cddc
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop edi
pop esi
pop ebx
leave
ret 8
Function at 0x4406ec
Capabilities:
Set thread local storage value

Disassembly:
push esi
push 0x154
push 8
push dword [0x49c21c]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov esi, eax
push esi
push dword [0x49d19c]
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
push dword [esp + 8]
mov dword [0x49d1a0], esi
and dword [esi + 0x88], 0
or dword [esi + 0x8c], 0xffffffff
or dword [esi + 0x90], 0xffffffff
push esi
mov dword [esi + 0x84], 0xffffff
mov dword [esi + 0x6c], 2
mov dword [esi + 0x70], 0x3f
call fcn.00445aa1
mov dword [esi + 0x58], 0x44066b
mov dword [esi + 0x5c], 0x4406aa
mov dword [esi + 0x10], fcn.0043f839
mov dword [esi + 0x30], 0x43f9b8
mov dword [esi + 0x64], 0x43fac1
mov dword [esi + 0x60], 0x43fb0c
mov dword [esi + 0x34], 0x44020a
mov dword [esi + 0x24], 0x4400a9
mov dword [esi + 0x28], 0x4400d2
mov dword [esi + 0x2c], 0x4400fd
mov dword [esi + 0x44], 0x4404fb
mov eax, esi
pop esi
ret 4

Function at 0x4413db
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push ecx
cmp dword [ebp + 0x20], 0
push esi
mov esi, dword [ecx + 0xb4]
mov dword [ebp - 4], esi
je 0x44144e
mov eax, dword [ebp + 0xc]
imul esi, dword [ebp + 0x10]
imul eax, dword [ebp + 0x18]
add eax, dword [ebp + 8]
push ebx
lea edx, [eax + edx*4]
push edi
mov eax, dword [ecx + 0xac]
imul eax, dword [ebp + 0x14]
add eax, dword [ecx + 0xa8]
mov edi, edx
add eax, esi
cmp dword [ebp + 0x1c], 0
jle 0x44143d
mov ebx, dword [ebp + 0x1c]
mov dword [ebp + 0x10], ebx
mov bl, byte [edi + 2]
xor byte [eax + 2], bl
mov bl, byte [edi + 1]
xor byte [eax + 1], bl
mov bl, byte [edi]
xor byte [eax], bl
add eax, dword [ebp - 4]
add edi, 4
dec dword [ebp + 0x10]
jne 0x441422
dec dword [ebp + 0x20]
inc dword [ebp + 0x14]
add edx, dword [ebp + 0xc]
cmp dword [ebp + 0x20], 0
jne 0x441402
pop edi
pop ebx
pop esi
leave
ret 0x1c

Function at 0x4421da
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
cmp dword [ebp + 0x20], 0
mov edx, dword [ecx + 0xb4]
je 0x442256
push ebx
imul eax, eax, 3
push esi
push edi
mov edi, dword [ebp + 0xc]
imul edi, dword [ebp + 0x18]
add edi, dword [ebp + 8]
mov esi, edx
imul esi, dword [ebp + 0x10]
add eax, edi
mov edi, eax
mov dword [ebp + 0x18], eax
mov eax, dword [ecx + 0xac]
imul eax, dword [ebp + 0x14]
add eax, dword [ecx + 0xa8]
add eax, esi
cmp dword [ebp + 0x1c], 0
jle 0x44223e
mov ebx, dword [ebp + 0x1c]
mov dword [ebp + 0x10], ebx
mov bl, byte [edi + 2]
xor byte [eax + 2], bl
mov bl, byte [edi + 1]
xor byte [eax + 1], bl
mov bl, byte [edi]
xor byte [eax], bl
add edi, 3
add eax, edx
dec dword [ebp + 0x10]
jne 0x442224
mov edi, dword [ebp + 0x18]
dec dword [ebp + 0x20]
add edi, dword [ebp + 0xc]
inc dword [ebp + 0x14]
cmp dword [ebp + 0x20], 0
mov dword [ebp + 0x18], edi
jne 0x442206
pop edi
pop esi
pop ebx
pop ebp
ret 0x1c
Function at 0x4422b2
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
imul eax, eax, 3
cmp dword [ebp + 0x1c], 0
mov dword [ebp - 4], eax
je 0x442342
mov eax, dword [ebp + 0x10]
imul ecx, ecx, 3
imul eax, dword [ebp + 0x18]
add eax, dword [ebp + 0xc]
push ebx
push esi
mov esi, edx
imul esi, esi, 3
add ecx, eax
push edi
mov edi, ecx
mov dword [ebp + 0xc], ecx
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0xac]
imul ecx, dword [ebp + 0x14]
add ecx, dword [eax + 0xa8]
mov edx, dword [ebp - 4]
add ecx, esi
test edx, edx
jle 0x44232a
mov eax, 0xff
sub eax, dword [ebp + 0x20]
mov dword [ebp + 0x18], edx
mov dword [ebp - 8], eax
movzx eax, byte [ecx]
movzx edx, byte [edi]
imul eax, dword [ebp - 8]
imul edx, dword [ebp + 0x20]
add eax, edx
cdq
mov ebx, 0xff
idiv ebx
inc edi
mov byte [ecx], al
inc ecx
dec dword [ebp + 0x18]
jne 0x442309
mov edi, dword [ebp + 0xc]
dec dword [ebp + 0x1c]
add edi, dword [ebp + 0x10]
inc dword [ebp + 0x14]
cmp dword [ebp + 0x1c], 0
mov dword [ebp + 0xc], edi
jne 0x4422df
pop edi
pop esi
pop ebx
leave
ret 0x1c
Function at 0x401b90
Capabilities:
Delete directory
Enumerate files on windows
Get common file path
Set current directory

Disassembly:
sub esp, 0x340
lea eax, [esp + 0x240]
push ebx
push ebp
push esi
push edi
push eax
push 0xff
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
or ecx, 0xffffffff
lea edi, [esp + 0x250]
xor eax, eax
lea edx, [esp + 0x10]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
shr ecx, 2
mov edi, edx
lea edx, [esp + 0x10]
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
or ecx, 0xffffffff
mov edi, 0x408588
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov ebx, ecx
mov esi, edi
or ecx, 0xffffffff
mov edi, edx
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
lea edx, [esp + 0x10]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, dword [esp + 0x354]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
lea edx, [esp + 0x10]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, 0x408588
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
lea eax, [esp + 0x10]
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
mov ebp, dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
call ebp
test eax, eax
je 0x401cdf
lea ecx, [esp + 0x110]
push ecx
push 0x408584
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov ebx, dword [sym.imp.KERNEL32.dll_FindNextFileA]
mov esi, eax
cmp esi, 0xffffffff
je 0x401cc3
lea edi, [esp + 0x13c]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp ecx, 3
jbe 0x401cb4
lea edx, [esp + 0x13c]
push edx
call fcn.004021d0
add esp, 4
lea eax, [esp + 0x110]
push eax
push esi
call ebx
test eax, eax
jne 0x401c89
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
lea ecx, [esp + 0x250]
push ecx
call ebp
lea edx, [esp + 0x10]
push edx
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x340
ret
Function at 0x401d20
Capabilities:
Create process on windows
Create thread
Get common file path

Disassembly:
sub esp, 0x120
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
lea ecx, [esp]
push ecx
push 0
push eax
push 0x401cf0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateThread]
push 0
push 0
lea edx, [esp + 0xc]
push 0
push edx
call dword [sym.imp.USER32.dll_GetMessageA]
lea eax, [esp + 0x20]
push eax
push 0xff
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
xor eax, eax
cmp byte [esp + eax + 0x20], 0x5c
jne 0x401d72
mov byte [esp + eax + 0x20], 0x5f
inc eax
cmp eax, 0xff
jl 0x401d66
lea ecx, [esp + 0x20]
push esi
push ecx
call fcn.00406b06
add esp, 4
lea edx, [esp + 0x24]
push edx
push 0
push 0x1f0003
call dword [sym.imp.KERNEL32.dll_OpenEventA]
mov esi, eax
test esi, esi
jne 0x401db1
lea eax, [esp + 0x24]
push eax
push esi
push 1
push esi
call dword [sym.imp.KERNEL32.dll_CreateEventA]
mov esi, eax
push esi
call dword [sym.imp.KERNEL32.dll_SetEvent]
push 0x7d0
call dword [sym.imp.KERNEL32.dll_Sleep]
push str.temppath
call fcn.00401e30
add esp, 4
push 0x1040
push 0x4085a0
push 0x40858c
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
test esi, esi
je 0x401df2
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [esp + 0x128]
push 0x20
push ecx
call fcn.004022a0
add esp, 8
test eax, eax
pop esi
je 0x401e1a
mov cl, byte [eax + 1]
inc eax
test cl, cl
je 0x401e1a
push 5
push eax
call dword [sym.imp.KERNEL32.dll_WinExec]
add esp, 0x120
ret
Function at 0x4040a5
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1a4
mov edx, dword [ebp + 8]
xor ecx, ecx
mov eax, 0x4087d8
cmp edx, dword [eax]
je 0x4040c7
add eax, 8
inc ecx
cmp eax, 0x408868
jl 0x4040b8
push esi
mov esi, ecx
shl esi, 3
cmp edx, dword [esi + 0x4087d8]
jne 0x4041f5
mov eax, dword [0x408e30]
cmp eax, 1
je 0x4041cf
test eax, eax
jne 0x4040f8
cmp dword [0x4085b4], 1
je 0x4041cf
cmp edx, 0xfc
je 0x4041f5
lea eax, [ebp - 0x1a4]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x40412f
lea eax, [ebp - 0x1a4]
push str._program_name_unknown_
push eax
call fcn.00405af0
pop ecx
pop ecx
lea eax, [ebp - 0x1a4]
push edi
push eax
lea edi, [ebp - 0x1a4]
call fcn.00403260
inc eax
pop ecx
cmp eax, 0x3c
jbe 0x404172
lea eax, [ebp - 0x1a4]
push eax
call fcn.00403260
mov edi, eax
lea eax, [ebp - 0x1a4]
sub eax, 0x3b
push 3
add edi, eax
push 0x4073f8
push edi
call fcn.00405fa0
add esp, 0x10
lea eax, [ebp - 0xa0]
push str.Runtime_Error__n_nProgram:
push eax
call fcn.00405af0
lea eax, [ebp - 0xa0]
push edi
push eax
call fcn.00405b00
lea eax, [ebp - 0xa0]
push 0x4073d8
push eax
call fcn.00405b00
push dword [esi + 0x4087dc]
lea eax, [ebp - 0xa0]
push eax
call fcn.00405b00
push 0x12010
lea eax, [ebp - 0xa0]
push str.Microsoft_Visual_C_Runtime_Library
push eax
call fcn.00405f15
add esp, 0x2c
pop edi
jmp 0x4041f5
lea eax, [ebp + 8]
lea esi, [esi + 0x4087dc]
push 0
push eax
push dword [esi]
call fcn.00403260
pop ecx
push eax
push dword [esi]
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
pop esi
leave
ret