joyce8/EMBER2024-capa huggingface dataset:
Function at 0x403250
Capabilities:
Get thread local storage value

Disassembly:
cmp dword [0x40648c], 0
jne 0x40325e
call fcn.004031f0
mov eax, dword [0x406488]
push ebx
push ebp
push esi
mov esi, dword [sym.imp.KERNEL32.dll_TlsGetValue]
push edi
push eax
call esi
test eax, eax
jne 0x403282
call fcn.004031f0
mov ecx, dword [0x406488]
push ecx
call esi
mov ecx, dword [eax]
mov edi, dword [eax + 4]
mov edx, dword [eax + ecx*4 + 0x4c]
mov ebp, dword [esp + 0x14]
mov esi, dword [eax + ecx*4 + 8]
mov ebx, dword [eax + edi*4 + 8]
inc ebp
ror edx, 0xd
add edx, dword [eax + edi*4 + 0x4c]
ror esi, 5
add esi, ebx
mov dword [eax + ecx*4 + 8], edx
mov dword [eax + ecx*4 + 0x4c], esi
dec edi
dec ecx
jns 0x4032b5
mov ecx, 0x10
test edi, edi
jns 0x4032be
mov edi, 0x10
mov dword [eax], ecx
mov dword [eax + 4], edi
mov eax, edx
test ebp, ebp
je 0x4032cd
mul ebp
mov eax, edx
pop edi
pop esi
pop ebp
pop ebx
ret 4

Function at 0x403300
Capabilities:
Get thread local storage value

Disassembly:
sub esp, 8
cmp dword [0x40648c], 0
jne 0x403311
call fcn.004031f0
mov eax, dword [0x406488]
push ebx
push esi
mov esi, dword [sym.imp.KERNEL32.dll_TlsGetValue]
push edi
push eax
call esi
test eax, eax
jne 0x403334
call fcn.004031f0
mov ecx, dword [0x406488]
push ecx
call esi
mov ecx, dword [esp + 0x1c]
mov ebx, dword [esp + 0x18]
cmp ecx, 8
jl 0x40339c
push ebp
mov ebp, ecx
shr ebp, 3
mov edx, ebp
neg edx
lea ecx, [ecx + edx*8]
mov dword [esp + 0x20], ecx
mov ecx, dword [eax]
mov edi, dword [eax + 4]
mov edx, dword [eax + ecx*4 + 0x4c]
mov esi, dword [eax + ecx*4 + 8]
ror edx, 0xd
add edx, dword [eax + edi*4 + 0x4c]
ror esi, 5
add esi, dword [eax + edi*4 + 8]
mov dword [eax + ecx*4 + 8], edx
mov dword [eax + ecx*4 + 0x4c], esi
dec edi
dec ecx
jns 0x40337e
mov ecx, 0x10
test edi, edi
jns 0x403387
mov edi, 0x10
mov dword [eax], ecx
mov dword [eax + 4], edi
mov dword [ebx], esi
mov dword [ebx + 4], edx
add ebx, 8
dec ebp
jne 0x403352
mov ecx, dword [esp + 0x20]
pop ebp
test ecx, ecx
jle 0x4033f5
mov ecx, dword [eax]
mov edi, dword [eax + 4]
mov edx, dword [eax + ecx*4 + 0x4c]
mov esi, dword [eax + ecx*4 + 8]
ror edx, 0xd
add edx, dword [eax + edi*4 + 0x4c]
ror esi, 5
add esi, dword [eax + edi*4 + 8]
mov dword [eax + ecx*4 + 8], edx
mov dword [eax + ecx*4 + 0x4c], esi
dec edi
dec ecx
jns 0x4033cc
mov ecx, 0x10
test edi, edi
jns 0x4033d5
mov edi, 0x10
mov dword [esp + 0x10], edx
mov edx, dword [esp + 0x1c]
mov dword [eax], ecx
mov dword [eax + 4], edi
push edx
lea eax, [esp + 0x10]
push eax
push ebx
mov dword [esp + 0x18], esi
call sub.MSVCRT.dll_memcpy
add esp, 0xc
pop edi
pop esi
pop ebx
add esp, 8
ret 8
Function at 0x403400
Capabilities:
Get thread local storage value

Disassembly:
cmp dword [0x40648c], 0
jne 0x40340e
call fcn.004031f0
mov eax, dword [0x406488]
push ebx
push ebp
push esi
mov esi, dword [sym.imp.KERNEL32.dll_TlsGetValue]
push edi
push eax
call esi
test eax, eax
jne 0x403432
call fcn.004031f0
mov ecx, dword [0x406488]
push ecx
call esi
mov ecx, dword [esp + 0x14]
lea edx, [eax + 8]
mov esi, 0x11
mov edi, edi
mov edi, ecx
imul edi, edi, 0x53a9b4fb
mov ecx, 1
sub ecx, edi
mov dword [edx + 0x44], ecx
imul ecx, ecx, 0x53a9b4fb
mov edi, 1
sub edi, ecx
mov ecx, edi
mov dword [edx], ecx
add edx, 4
dec esi
jne 0x403440
mov dword [eax], esi
mov dword [eax + 4], 0xa
lea ebp, [esi + 0x1f]
mov ecx, dword [eax]
mov esi, dword [eax + 4]
mov edx, dword [eax + ecx*4 + 0x4c]
mov edi, dword [eax + ecx*4 + 8]
mov ebx, dword [eax + esi*4 + 8]
ror edx, 0xd
add edx, dword [eax + esi*4 + 0x4c]
ror edi, 5
add edi, ebx
mov dword [eax + ecx*4 + 8], edx
mov dword [eax + ecx*4 + 0x4c], edi
dec esi
dec ecx
jns 0x4034a3
mov ecx, 0x10
test esi, esi
jns 0x4034ac
mov esi, 0x10
dec ebp
mov dword [eax], ecx
mov dword [eax + 4], esi
jne 0x403475
pop edi
pop esi
pop ebp
pop ebx
ret 4

Function at 0x403539
Capabilities:
Copy file

Disassembly:
xor eax, eax
cmp dword [esp + 4], eax
je 0x403558
cmp dword [esp + 8], eax
je 0x403558
push eax
push dword [esp + 0xc]
push dword [esp + 0xc]
call dword [sym.imp.KERNEL32.dll_CopyFileA]
jmp 0x40355a
xor eax, eax
ret 8

Function at 0x403570
Capabilities:
Write file on windows

Disassembly:
push ecx
push esi
mov esi, dword [esp + 0xc]
xor eax, eax
mov dword [esp + 4], eax
cmp dword [esi + 0x14], eax
jne 0x4035a5
mov ecx, dword [esi + 8]
sub ecx, dword [esi + 0xc]
mov edx, dword [esi + 4]
push eax
lea eax, [esp + 8]
push eax
mov eax, dword [esi]
push ecx
push edx
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov ecx, dword [esi + 8]
mov eax, dword [esp + 4]
mov dword [esi + 0xc], ecx
pop esi
pop ecx
ret 4

Function at 0x4038e0
Capabilities:
Read file on windows

Disassembly:
push ecx
mov eax, dword [esp + 8]
mov ecx, dword [0x4064e4]
push eax
push ecx
mov dword [esp + 8], 0
call fcn.00403cb6
test eax, eax
je 0x403932
cmp dword [eax + 4], 0
je 0x403918
mov edx, dword [esp + 0x10]
mov ecx, dword [esp + 0xc]
push edx
push ecx
push eax
call fcn.00403a00
pop ecx
ret 0xc
mov ecx, dword [esp + 0x10]
mov eax, dword [eax]
push 0
lea edx, [esp + 4]
push edx
mov edx, dword [esp + 0x14]
push ecx
push edx
push eax
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [esp]
pop ecx
ret 0xc
Function at 0x4039a0
Capabilities:
Write file on windows

Disassembly:
push ecx
push edi
mov edi, dword [esp + 0x10]
xor eax, eax
mov dword [esp + 4], eax
test edi, edi
je 0x4039f9
push esi
mov esi, dword [esp + 0x18]
test esi, esi
je 0x4039f8
mov eax, dword [esp + 0x10]
mov ecx, dword [0x4064e4]
push eax
push ecx
call fcn.00403cb6
test eax, eax
je 0x4039f4
cmp dword [eax + 4], 0
je 0x4039e2
push esi
push edi
push eax
call fcn.00403b20
pop esi
pop edi
pop ecx
ret 0xc
mov eax, dword [eax]
push 0
lea edx, [esp + 0xc]
push edx
push esi
push edi
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [esp + 8]
pop esi
pop edi
pop ecx
ret 0xc

Function at 0x403a00
Capabilities:
Read file on windows

Disassembly:
push ebx
push esi
mov esi, dword [esp + 0xc]
cmp dword [esi + 0x14], 0
push edi
jne 0x403a21
push esi
call fcn.00403570
mov dword [esi + 0x14], 1
mov dword [esi + 0xc], 0
mov ebx, dword [esi + 0xc]
mov edi, dword [esp + 0x18]
cmp ebx, edi
jl 0x403a96
mov eax, dword [esi + 0x10]
add eax, dword [esi + 4]
mov ecx, edi
sub eax, ebx
dec ecx
je 0x403a83
dec ecx
je 0x403a6e
sub ecx, 2
je 0x403a5b
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
push 0
cmp edi, eax
jl 0x403adf
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]
mov dword [esi + 0xc], eax
mov dword [esi + 0x10], eax
cmp edi, eax
jle 0x403b02
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 0x403b20
Capabilities:
Write file on windows

Disassembly:
push ecx
push esi
mov esi, dword [esp + 0xc]
cmp dword [esi + 0x14], 1
push edi
mov dword [esp + 8], 0
jne 0x403b55
mov eax, dword [esi + 0xc]
mov ecx, dword [esi]
push 1
push 0
neg eax
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov edx, dword [esi + 8]
mov dword [esi + 0x14], 0
mov dword [esi + 0xc], edx
mov ecx, dword [esi + 0xc]
mov edi, dword [esp + 0x18]
cmp ecx, edi
jle 0x403bca
mov eax, dword [esi + 8]
add eax, dword [esi + 4]
sub eax, ecx
mov ecx, edi
dec ecx
je 0x403bb7
dec ecx
je 0x403ba2
sub ecx, 2
je 0x403b8f
mov ecx, dword [esp + 0x14]
push edi
push ecx
push eax
call sub.MSVCRT.dll_memcpy
add esp, 0xc
sub dword [esi + 0xc], edi
mov eax, edi
pop edi
pop esi
pop ecx
ret 0xc
mov edx, dword [esp + 0x14]
mov ecx, dword [edx]
mov dword [eax], ecx
sub dword [esi + 0xc], edi
mov eax, edi
pop edi
pop esi
pop ecx
ret 0xc
mov edx, dword [esp + 0x14]
mov cx, word [edx]
mov word [eax], cx
sub dword [esi + 0xc], edi
mov eax, edi
pop edi
pop esi
pop ecx
ret 0xc
mov edx, dword [esp + 0x14]
mov cl, byte [edx]
mov byte [eax], cl
sub dword [esi + 0xc], edi
mov eax, edi
pop edi
pop esi
pop ecx
ret 0xc
push esi
call fcn.00403570
mov eax, dword [esi + 8]
cmp edi, eax
jl 0x403bf7
mov eax, dword [esp + 0x14]
mov ecx, dword [esi]
push 0
lea edx, [esp + 0xc]
push edx
push edi
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [esp + 8]
pop edi
pop esi
pop ecx
ret 0xc
mov ecx, dword [esi + 4]
sub ecx, dword [esi + 0xc]
mov edx, dword [esp + 0x14]
push edi
push edx
add ecx, eax
push ecx
call sub.MSVCRT.dll_memcpy
add esp, 0xc
sub dword [esi + 0xc], edi
mov eax, edi
pop edi
pop esi
pop ecx
ret 0xc

Function at 0x403dd4
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 0x403de9
push 4
pop ecx
sub ecx, eax
add ebx, ecx
cmp dword [0x40649c], 0
mov esi, dword [sym.imp.KERNEL32.dll_TlsSetValue]
jne 0x403e1b
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
push ebx
push 8
push dword [0x406464]
mov dword [0x406494], eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
push eax
push dword [0x406494]
call esi
mov edi, dword [0x40649c]
add dword [0x40649c], ebx
push dword [0x40649c]
push dword [0x406494]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
push eax
push 8
push dword [0x406464]
call dword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov ebx, eax
push ebx
push dword [0x406494]
call esi
mov esi, dword [esp + 0x14]
test esi, esi
jne 0x403e61
cmp dword [esp + 0x18], esi
je 0x403e85
push 0x14
push 0x406498
call fcn.00403f4b
pop ecx
pop ecx
mov ecx, dword [esp + 0x18]
mov dword [eax], edi
mov dword [eax + 4], esi
mov dword [eax + 8], ecx
test esi, esi
je 0x403e85
add ebx, edi
push ebx
call esi
pop ecx
mov eax, edi
pop edi
pop esi
pop ebx
ret 0xc
Function at 0x404050
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
mov eax, dword [0x40605c]
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 0x404096
mov ecx, dword [ebp - 4]
add ecx, 5
push ecx
push 0
mov edx, dword [0x4064e8]
push edx
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ecx, dword [ebp + 8]
mov dword [ecx], eax
jmp 0x4040b7
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 [0x4064e8]
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.00404620
mov ecx, dword [ebp - 8]
mov edx, dword [ebp + 0xc]
mov dword [ecx + 8], edx
mov esp, ebp
pop ebp
ret 8

Function at 0x404260
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [0x40605c]
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 0x404430
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
mov eax, dword [0x40605c]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov dword [ebp - 0xc], eax
cmp dword [ebp + 0xc], 0xffffffff
jne 0x404454
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 0x4044a1
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 [0x4064e8]
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 0x404500
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [0x40605c]
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 0x40453e
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 0x40453e
mov eax, dword [ebp - 4]
mov ecx, dword [ebp + 8]
sub ecx, dword [eax]
add ecx, 1
mov eax, ecx
jmp 0x404540
xor eax, eax
mov esp, ebp
pop ebp
ret 4
Function at 0x404811
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]
mov esi, eax
mov dword [ebp - 0xc], esi
cmp dword [0x4064bc], ebx
jne 0x404847
push 0x4064a0
call dword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
mov dword [0x4064bc], 1
push 0x4064a0
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov eax, dword [0x4064b8]
mov edi, eax
cmp eax, ebx
je 0x4048ab
cmp dword [ebp - 4], ebx
jne 0x4049eb
xor eax, eax
inc eax
lea ecx, [edi + 0x114]
cmp esi, dword [ecx]
je 0x40487e
inc eax
add ecx, 4
cmp eax, 0x40
jl 0x40486f
jmp 0x40489c
push dword [ebp + 0xc]
lea esi, [edi + eax*4 + 0x210]
push dword [ebp + 8]
call fcn.00404666
mov esi, dword [ebp - 0xc]
pop ecx
pop ecx
mov dword [ebp - 4], 1
mov edi, dword [edi]
cmp edi, ebx
jne 0x40485d
cmp dword [ebp - 4], ebx
jne 0x4049eb
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 0x4049eb
mov edi, dword [0x4064b8]
jmp 0x4048eb
cmp dword [edi + 0xc], 0x3f
jl 0x404985
mov edi, dword [edi]
cmp edi, ebx
jne 0x4048df
push 0x310
push 8
push dword [0x406464]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov edi, eax
cmp edi, ebx
je 0x4049e2
push ebx
push 1
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_CreateSemaphoreA]
mov dword [edi + 8], eax
cmp eax, ebx
je 0x4049d4
push ebx
push ebx
push edi
push 0x4046b7
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 0x4049cb
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.00404666
mov eax, dword [0x4064b8]
pop ecx
pop ecx
mov dword [edi + 4], ebx
mov dword [edi], eax
cmp eax, ebx
je 0x40497d
mov dword [eax + 4], edi
mov dword [0x4064b8], edi
jmp 0x4049eb
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.00404666
inc dword [edi + 0xc]
pop ecx
pop ecx
push ebx
push 1
push dword [edi + 8]
call dword [sym.imp.KERNEL32.dll_ReleaseSemaphore]
jmp 0x4049eb
push dword [edi + 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
push ebx
push dword [0x406464]
call dword [sym.imp.KERNEL32.dll_HeapFree]
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 0x4064a0
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop edi
pop esi
pop ebx
leave
ret 8
Function at 0x403371
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [ebp + 8]
push ebx
push esi
xor esi, esi
cmp eax, esi
jl 0x40339c
mov ecx, dword [0x4702b8]
push esi
add eax, ecx
push esi
push eax
mov dword [0x4326f4], eax
push dword [0x40a01c]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 4
call fcn.00403479
cmp eax, esi
jl 0x403473
lea eax, [ebp + 8]
push 4
push eax
push dword [0x40a01c]
call fcn.004061db
test eax, eax
je 0x403463
push dword [ebp + 8]
add dword [0x4326f4], 4
call fcn.00403479
mov ebx, eax
cmp ebx, esi
jl 0x403471
cmp dword [ebp + 0x10], esi
jne 0x40343f
cmp dword [ebp + 8], esi
jle 0x403471
mov esi, 0x4266f0
cmp dword [ebp + 8], 0x4000
mov eax, dword [ebp + 8]
jl 0x403401
mov eax, 0x4000
push eax
push esi
push dword [0x40a01c]
mov dword [ebp - 4], eax
call fcn.004061db
test eax, eax
je 0x403463
push dword [ebp - 4]
push esi
push dword [ebp + 0xc]
call fcn.0040620a
test eax, eax
je 0x40343b
mov eax, dword [ebp - 4]
sub dword [ebp + 8], eax
add dword [0x4326f4], eax
add ebx, eax
cmp dword [ebp + 8], 0
jg 0x4033f0
jmp 0x403471
push 0xfffffffffffffffe
jmp 0x403465
mov eax, dword [ebp + 8]
cmp eax, dword [ebp + 0x14]
jl 0x40344a
mov eax, dword [ebp + 0x14]
lea ecx, [ebp - 4]
push esi
push ecx
push eax
push dword [ebp + 0x10]
push dword [0x40a01c]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x403468
push 0xfffffffffffffffd
pop eax
jmp 0x403473
mov ebx, dword [ebp - 4]
add dword [0x4326f4], ebx
mov eax, ebx
pop esi
pop ebx
leave
ret 0x10
Function at 0x406133
Capabilities:
Check if file exists
Get file attributes
Set file attributes

Disassembly:
push esi
push dword [esp + 8]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
mov esi, eax
cmp esi, 0xffffffff
je 0x406152
and al, 0xfe
push eax
push dword [esp + 0xc]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
mov eax, esi
pop esi
ret 4

Function at 0x406158
Capabilities:
Get file attributes

Disassembly:
push dword [esp + 4]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
mov ecx, eax
push 0
inc ecx
neg ecx
sbb ecx, ecx
and ecx, eax
push ecx
push dword [esp + 0x14]
push 0
push 1
push dword [esp + 0x1c]
push dword [esp + 0x1c]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
ret 0xc

Function at 0x406187
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push esi
mov esi, dword [ebp + 8]
push edi
push 0x64
pop edi
mov eax, dword [0x40a5a8]
dec edi
mov dword [ebp - 8], eax
mov eax, dword [0x40a5ac]
mov dword [ebp - 4], eax
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push 0x1a
xor edx, edx
pop ecx
div ecx
push esi
lea eax, [ebp - 8]
push 0
push eax
push dword [ebp + 0xc]
add word [ebp - 4], dx
call dword [sym.imp.KERNEL32.dll_GetTempFileNameW]
test eax, eax
jne 0x4061d7
test edi, edi
jne 0x406194
and word [esi], di
pop edi
pop esi
leave
ret 8
mov eax, esi
jmp 0x4061d1
Function at 0x4062ae
Capabilities:
Get file size

Disassembly:
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_GetShortPathNameW]
push ebp
push esi
mov esi, dword [esp + 0x14]
push edi
test esi, esi
mov dword [0x45ede8], 0x55004e
mov dword [0x45edec], 0x4c
mov edi, 0x400
mov ebp, 0x45ede8
je 0x406304
push 1
push 0
push esi
call fcn.00406158
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
push ebp
push esi
call ebx
test eax, eax
je 0x406423
cmp eax, edi
jg 0x406423
mov esi, 0x45f5e8
push edi
push esi
push dword [esp + 0x1c]
call ebx
test eax, eax
je 0x406423
cmp eax, edi
jg 0x406423
push esi
push ebp
push str._ls_ls_r_n
push 0x45e9e8
call dword [sym.imp.USER32.dll_wsprintfA]
mov ebx, eax
mov eax, dword [0x470270]
add esp, 0x10
push dword [eax + 0x128]
push esi
call fcn.004066a5
push 4
push 0xc0000000
push esi
call fcn.00406158
mov ebp, eax
cmp ebp, 0xffffffff
mov dword [esp + 0x18], ebp
je 0x406423
push 0
push ebp
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
lea eax, [edi + ebx + 0xa]
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov esi, eax
test esi, esi
je 0x40641c
push edi
push esi
push ebp
call fcn.004061db
test eax, eax
je 0x40641c
push str._Rename__r_n
push esi
call fcn.004060bd
test eax, eax
jne 0x4063ba
lea eax, [esi + edi]
push str._Rename__r_n
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
add edi, 0xa
jmp 0x4063ef
add eax, 0xa
push 0x40a5b0
push eax
call fcn.004060bd
mov ebp, eax
test ebp, ebp
je 0x4063eb
lea ecx, [esi + edi]
lea eax, [ecx + ebx]
jmp 0x4063dc
mov dl, byte [ecx]
mov byte [eax], dl
dec eax
dec ecx
cmp ecx, ebp
ja 0x4063d6
sub ebp, esi
inc ebp
mov eax, ebp
mov ebp, dword [esp + 0x18]
jmp 0x4063f1
mov ebp, dword [esp + 0x18]
mov eax, edi
push ebx
add eax, esi
push 0x45e9e8
push eax
call fcn.00406113
xor eax, eax
push eax
push eax
push eax
push ebp
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
add edi, ebx
push edi
push esi
push ebp
call fcn.0040620a
push esi
call dword [sym.imp.KERNEL32.dll_GlobalFree]
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
pop ebx
ret

Function at 0x406428
Capabilities:
Move file

Disassembly:
push 5
push dword [esp + 0xc]
push dword [esp + 0xc]
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
test eax, eax
jne 0x40644b
push dword [esp + 8]
push dword [esp + 8]
call fcn.004062ae
pop ecx
pop ecx
inc dword [0x4702f0]
ret 8
Function at 0x406536
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push ecx
lea eax, [ebp + 0x18]
push esi
push eax
mov eax, dword [ebp + 0x18]
neg eax
sbb eax, eax
mov dword [ebp - 4], 0x4000
and eax, 0x100
or eax, 0x20019
push eax
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.004064d5
mov esi, dword [ebp + 0x14]
test eax, eax
jne 0x4065a6
lea eax, [ebp - 4]
push edi
push eax
lea eax, [ebp + 0xc]
push esi
push eax
push 0
push dword [ebp + 0x10]
push dword [ebp + 0x18]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
push dword [ebp + 0x18]
mov edi, eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
and word [esi + 0x3ffe], 0
test edi, edi
pop edi
jne 0x4065a6
cmp dword [ebp + 0xc], 1
je 0x4065aa
cmp dword [ebp + 0xc], 2
je 0x4065aa
and word [esi], 0
pop esi
leave
ret 0x14
Function at 0x4069c5
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x23c
push esi
mov esi, 0x104
lea eax, [ebp - 0x23c]
push esi
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
cmp eax, esi
pop esi
jbe 0x4069e9
xor eax, eax
test eax, eax
je 0x4069fc
cmp word [ebp + eax*2 - 0x23e], 0x5c
je 0x4069fc
xor ecx, ecx
jmp 0x4069ff
xor ecx, ecx
inc ecx
push dword [ebp + 8]
lea ecx, [ecx*2 + 0x40a014]
lea eax, [ebp + eax*2 - 0x23c]
push ecx
push str._s_S.dll
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x10
lea eax, [ebp - 0x23c]
push 8
push 0
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
leave
ret 4

Function at 0x406b22
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
cmp dword [0x45fdec], 0
push esi
jne 0x406b59
xor ecx, ecx
push 8
mov eax, ecx
pop esi
mov edx, eax
and dl, 1
neg dl
sbb edx, edx
and edx, 0xedb88320
shr eax, 1
xor eax, edx
dec esi
jne 0x406b33
mov dword [ecx*4 + 0x45fde8], eax
inc ecx
cmp ecx, 0x100
jl 0x406b2e
mov edx, dword [esp + 0x10]
mov eax, dword [esp + 8]
test edx, edx
not eax
jbe 0x406b8a
mov ecx, dword [esp + 0xc]
push edi
movzx edi, byte [ecx]
mov esi, eax
and esi, 0xff
xor esi, edi
shr eax, 8
mov esi, dword [esi*4 + 0x45fde8]
xor eax, esi
inc ecx
dec edx
jne 0x406b6c
pop edi
not eax
pop esi
ret 0xc