joyce8/EMBER2024-capa huggingface dataset:
Function at 0x80a2d8
Capabilities:
Hash data using sha1

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x110
mov eax, dword [0x44d740]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
push edi
mov edi, ecx
xor eax, eax
mov dword [edi + 4], eax
lea esi, [edi + 4]
mov dword [esi + 4], eax
mov dword [esi + 8], eax
mov dword [esi + 0xc], eax
mov dword [esi + 0x10], eax
test edx, edx
je 0x80a309
mov byte [edx], al
push 0x445ba0
call dword [0x43f0e8]
test eax, eax
jne 0x80a327
push 0x445ba0
call dword [fcn.0043f100]
test eax, eax
je 0x80a357
push 0x445b88
push eax
call dword [fcn.0043f104]
test eax, eax
je 0x80a357
lea ecx, [ebp - 0x98]
push ecx
call eax
test eax, eax
jne 0x80a357
mov eax, dword [ebp - 0x8e]
mov dword [esi], eax
mov ax, word [ebp - 0x8a]
mov word [esi + 4], ax
push 0
push 0
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 8]
push eax
lea eax, [edi + 0xa]
push eax
push 0
push 0
push 0x445bac
call dword [0x43f10c]
push 0xe
lea eax, [ebp - 0x70]
mov dword [ebp - 0x68], 0x67452301
push edi
push eax
mov dword [ebp - 0x64], 0xefcdab89
mov dword [ebp - 0x60], 0x98badcfe
mov dword [ebp - 0x5c], 0x10325476
mov dword [ebp - 0x58], 0xc3d2e1f0
mov dword [ebp - 0x54], 0
mov dword [ebp - 0x70], 0
mov dword [ebp - 0x6c], 0
call fcn.00826f98
add esp, 0xc
lea eax, [ebp - 0x88]
push eax
lea eax, [ebp - 0x70]
push eax
call fcn.00827038
push 0xa
lea eax, [ebp - 0x88]
mov dword [ebp - 0xf0], 0x67452301
push eax
lea eax, [ebp - 0xf8]
mov dword [ebp - 0xec], 0xefcdab89
push eax
mov dword [ebp - 0xe8], 0x98badcfe
mov dword [ebp - 0xe4], 0x10325476
mov dword [ebp - 0xe0], 0xc3d2e1f0
mov dword [ebp - 0xdc], 0
mov dword [ebp - 0xf8], 0
mov dword [ebp - 0xf4], 0
call fcn.00826f98
add esp, 0x14
lea eax, [ebp - 0x110]
push eax
lea eax, [ebp - 0xf8]
push eax
call fcn.00827038
lea eax, [ebp - 0x110]
add esp, 8
cmp esi, eax
je 0x80a481
mov eax, dword [ebp - 0x110]
mov dword [esi], eax
mov eax, dword [ebp - 0x10c]
mov dword [esi + 4], eax
mov eax, dword [ebp - 0x108]
mov dword [esi + 8], eax
mov eax, dword [ebp - 0x104]
mov dword [esi + 0xc], eax
mov eax, dword [ebp - 0x100]
mov dword [esi + 0x10], eax
push 4
lea eax, [ebp - 0x70]
mov dword [ebp - 0x68], 0x67452301
push edi
push eax
mov dword [ebp - 0x64], 0xefcdab89
mov dword [ebp - 0x60], 0x98badcfe
mov dword [ebp - 0x5c], 0x10325476
mov dword [ebp - 0x58], 0xc3d2e1f0
mov dword [ebp - 0x54], 0
mov dword [ebp - 0x70], 0
mov dword [ebp - 0x6c], 0
call fcn.00826f98
add esp, 0xc
lea eax, [ebp - 0x88]
push eax
lea eax, [ebp - 0x70]
push eax
call fcn.00827038
add esp, 8
xor ecx, ecx
jmp 0x80a4e8
mov eax, dword [ebp + ecx - 0x88]
add dword [esi + ecx], eax
add ecx, 4
cmp ecx, 0x14
jne 0x80a4e8
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.0082b950
mov esp, ebp
pop ebp
ret
Function at 0x811fa8
Capabilities:
Access peb ldr_data

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x43c69a
mov eax, dword fs:[0]
push eax
sub esp, 0x18
mov eax, dword [0x44d740]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
mov edi, dword [ebp + 8]
push 0
mov dword [ebp - 0x18], esi
call fcn.00827ecf
mov dword [ebp - 4], 0
mov dword [esi + 4], 0
mov byte [esi + 8], 0
mov dword [esi + 0xc], 0
mov byte [esi + 0x10], 0
xor eax, eax
mov dword [esi + 0x14], 0
mov word [esi + 0x18], ax
mov dword [esi + 0x1c], eax
mov word [esi + 0x20], ax
mov dword [esi + 0x24], eax
mov byte [esi + 0x28], al
mov dword [esi + 0x2c], eax
mov byte [esi + 0x30], al
mov byte [ebp - 4], 6
test edi, edi
jne 0x81204e
lea eax, [ebp - 0x14]
mov dword [ebp - 0x14], 0x4465dc
push eax
lea ecx, [ebp - 0x24]
call fcn.0082d457
push 0x44bf38
lea eax, [ebp - 0x24]
mov dword [ebp - 0x24], 0x440324
push eax
call fcn.0082e903
push edi
push esi
call fcn.00827cda
add esp, 8
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0082b950
mov esp, ebp
pop ebp
ret 4
Function at 0x81fae8
Capabilities:
Encode data using xor
Generate random numbers using a mersenne twister

Disassembly:
push ebp
mov ebp, esp
mov edx, dword [ebp + 8]
mov eax, 1
mov dword [0x451c14], edx
mov ecx, edx
shr ecx, 0x1e
xor ecx, edx
imul edx, ecx, 0x6c078965
add edx, eax
mov dword [eax*4 + 0x451c14], edx
inc eax
cmp eax, 0x270
jl 0x81faf9
mov dword [0x451c10], 0x270
pop ebp
ret 8
Function at 0x827038
Capabilities:
Enumerate pe sections

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 8]
mov ecx, dword [esi + 0x1c]
cmp ecx, 0x40
jb 0x82704f
mov eax, 0x10
pop esi
pop ebp
ret
lea eax, [ecx*8]
add dword [esi], eax
adc dword [esi + 4], 0
mov byte [ecx + esi + 0x20], 0x80
inc dword [esi + 0x1c]
mov eax, dword [esi + 0x1c]
cmp eax, 0x38
jbe 0x827099
cmp eax, 0x40
jae 0x827088
lea esp, [esp]
mov byte [esi + eax + 0x20], 0
inc dword [esi + 0x1c]
mov eax, dword [esi + 0x1c]
cmp eax, 0x40
jb 0x827078
lea edx, [esi + 0x20]
mov ecx, esi
call fcn.00826b98
mov dword [esi + 0x1c], 0
cmp dword [esi + 0x1c], 0x38
jae 0x8270b9
jmp 0x8270a8
mov eax, dword [esi + 0x1c]
mov byte [esi + eax + 0x20], 0
inc dword [esi + 0x1c]
cmp dword [esi + 0x1c], 0x38
jb 0x8270a8
movzx eax, byte [esi + 7]
lea edx, [esi + 0x20]
mov byte [esi + 0x58], al
mov ecx, esi
movzx eax, byte [esi + 6]
mov byte [esi + 0x59], al
movzx eax, byte [esi + 5]
mov byte [esi + 0x5a], al
movzx eax, byte [esi + 4]
mov byte [esi + 0x5b], al
movzx eax, byte [esi + 3]
mov byte [esi + 0x5c], al
movzx eax, byte [esi + 2]
mov byte [esi + 0x5d], al
movzx eax, byte [esi + 1]
mov byte [esi + 0x5e], al
movzx eax, byte [esi]
mov byte [esi + 0x5f], al
call fcn.00826b98
mov ecx, dword [ebp + 0xc]
movzx eax, byte [esi + 0xb]
mov byte [ecx], al
movzx eax, byte [esi + 0xa]
mov byte [ecx + 1], al
movzx eax, byte [esi + 9]
mov byte [ecx + 2], al
movzx eax, byte [esi + 8]
mov byte [ecx + 3], al
movzx eax, byte [esi + 0xf]
mov byte [ecx + 4], al
movzx eax, byte [esi + 0xe]
mov byte [ecx + 5], al
movzx eax, byte [esi + 0xd]
mov byte [ecx + 6], al
movzx eax, byte [esi + 0xc]
mov byte [ecx + 7], al
movzx eax, byte [esi + 0x13]
mov byte [ecx + 8], al
movzx eax, byte [esi + 0x12]
mov byte [ecx + 9], al
movzx eax, byte [esi + 0x11]
mov byte [ecx + 0xa], al
movzx eax, byte [esi + 0x10]
mov byte [ecx + 0xb], al
movzx eax, byte [esi + 0x17]
mov byte [ecx + 0xc], al
movzx eax, byte [esi + 0x16]
mov byte [ecx + 0xd], al
movzx eax, byte [esi + 0x15]
mov byte [ecx + 0xe], al
movzx eax, byte [esi + 0x14]
mov byte [ecx + 0xf], al
movzx eax, byte [esi + 0x1b]
mov byte [ecx + 0x10], al
movzx eax, byte [esi + 0x1a]
mov byte [ecx + 0x11], al
movzx eax, byte [esi + 0x19]
mov byte [ecx + 0x12], al
movzx eax, byte [esi + 0x18]
mov byte [ecx + 0x13], al
xor eax, eax
pop esi
pop ebp
ret
Function at 0x403003
Capabilities:
Move file

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [0x500b64]
mov ecx, dword [0x5009f8]
sub esp, 0x808
push esi
shr eax, 3
xor esi, esi
cmp eax, esi
jbe 0x4030aa
push ebx
push edi
mov edi, ecx
mov ebx, eax
cmp dword [0x500b64], 0x5d
jne 0x40309c
push esi
push esi
call dword [sym.imp.KERNEL32.dll_WriteProfileSectionA]
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsA]
push esi
lea eax, [ebp - 8]
push eax
push esi
lea eax, [ebp - 0x408]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_WriteConsoleA]
push 0x402420
push 0x402478
call dword [sym.imp.KERNEL32.dll_MoveFileW]
push 0x402490
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
push esi
push esi
call dword [sym.imp.KERNEL32.dll_SetConsoleTextAttribute]
push esi
lea eax, [ebp - 4]
push eax
push esi
lea eax, [ebp - 0x808]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_ReadConsoleW]
call dword [sym.imp.KERNEL32.dll_AllocConsole]
push esi
push esi
call dword [sym.imp.KERNEL32.dll_GetConsoleTitleA]
push edi
call fcn.004027a6
add edi, 8
dec ebx
jne 0x40302b
pop edi
pop ebx
pop esi
leave
ret
Function at 0x40a6ff
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x4b8c90]
jne 0x40a709
repz ret
jmp fcn.0040cdc9

Function at 0x40bf86
Capabilities:
Link many functions at runtime

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
push esi
push edi
call fcn.00408960
and dword [ebp - 4], 0
cmp dword [0x4c05f8], 0
mov ebx, eax
jne 0x40c037
push 0x401a78
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
test edi, edi
je 0x40c0e8
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x401a6c
push edi
call esi
test eax, eax
je 0x40c0e8
push eax
call fcn.004088ee
mov dword [esp], 0x401a5c
push edi
mov dword [0x4c05f8], eax
call esi
push eax
call fcn.004088ee
mov dword [esp], 0x401a48
push edi
mov dword [0x4c05fc], eax
call esi
push eax
call fcn.004088ee
mov dword [esp], 0x401a2c
push edi
mov dword [0x4c0600], eax
call esi
push eax
call fcn.004088ee
pop ecx
mov dword [0x4c0608], eax
test eax, eax
je 0x40c037
push 0x401a14
push edi
call esi
push eax
call fcn.004088ee
pop ecx
mov dword [0x4c0604], eax
mov eax, dword [0x4c0604]
cmp eax, ebx
je 0x40c08f
cmp dword [0x4c0608], ebx
je 0x40c08f
push eax
call fcn.00408969
push dword [0x4c0608]
mov esi, eax
call fcn.00408969
pop ecx
pop ecx
mov edi, eax
test esi, esi
je 0x40c08f
test edi, edi
je 0x40c08f
call esi
test eax, eax
je 0x40c086
lea ecx, [ebp - 8]
push ecx
push 0xc
lea ecx, [ebp - 0x14]
push ecx
push 1
push eax
call edi
test eax, eax
je 0x40c086
test byte [ebp - 0xc], 1
jne 0x40c08f
or dword [ebp + 0x10], 0x200000
jmp 0x40c0c8
mov eax, dword [0x4c05fc]
cmp eax, ebx
je 0x40c0c8
push eax
call fcn.00408969
pop ecx
test eax, eax
je 0x40c0c8
call eax
mov dword [ebp - 4], eax
test eax, eax
je 0x40c0c8
mov eax, dword [0x4c0600]
cmp eax, ebx
je 0x40c0c8
push eax
call fcn.00408969
pop ecx
test eax, eax
je 0x40c0c8
push dword [ebp - 4]
call eax
mov dword [ebp - 4], eax
push dword [0x4c05f8]
call fcn.00408969
pop ecx
test eax, eax
je 0x40c0e8
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [ebp - 4]
call eax
jmp 0x40c0ea
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret
Function at 0x430000
Capabilities:
Encode data using xor
Packed with generic packer

Disassembly:
pushal
nop
nop
nop
nop
nop
mov eax, section..text
nop
nop
mov ebx, 0x408ecc
nop
mov ecx, 0x49fc017b
nop
nop
test eax, eax
nop
nop
je 0x43004e
nop
nop
nop
nop
nop
nop
nop
nop
xor dword [eax], ecx
nop
nop
nop
nop
inc eax
nop
nop
inc eax
nop
nop
nop
nop
nop
nop
nop
inc eax
nop
nop
nop
nop
nop
inc eax
nop
nop
nop
nop
cmp eax, ebx
nop
nop
nop
nop
nop
nop
jne 0x430024
nop
mov eax, section..data
nop
mov ebx, 0x42e1d0
nop
mov ecx, 0x697c6b77
nop
nop
nop
test eax, eax
nop
je 0x430084
nop
nop
nop
nop
nop
nop
nop
xor dword [eax], ecx
nop
nop
add eax, 4
nop
nop
nop
nop
nop
nop
cmp eax, ebx
nop
jne 0x43006c
nop
nop
nop
nop
popal
nop
nop
nop
nop
jmp 0x401219
Function at 0x405d00
Capabilities:
Allocate thread local storage

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [0x522e0c]
cmp eax, 2
je 0x405d93
push esi
push 0
push 1
push 0x522e0c
call dword [sym.imp.KERNEL32.dll_InterlockedCompareExchange]
test eax, eax
jne 0x405d6f
push 4
call fcn.004a6683
mov esi, eax
add esp, 4
mov dword [ebp - 4], esi
mov dword [esi], 0
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
push 0x522e0c
mov dword [esi], eax
push 0x4061b0
mov dword [0x522e10], esi
call fcn.004041b0
mov eax, dword [0x522e10]
add esp, 8
mov dword [0x522e0c], 2
pop esi
mov esp, ebp
pop ebp
ret
cmp eax, 2
je 0x405d92
mov eax, dword [0x522e0c]
cmp eax, 2
je 0x405d92
mov esi, dword [sym.imp.KERNEL32.dll_Sleep]
push 0
call esi
mov eax, dword [0x522e0c]
cmp eax, 2
jne 0x405d84
pop esi
mov eax, dword [0x522e10]
mov esp, ebp
pop ebp
ret

Function at 0x406f00
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x14
push ebx
mov ebx, ecx
mov dword [esp + 8], 0
mov ecx, dword [ebp + 8]
push esi
push edi
xor edi, edi
lea eax, [ecx - 1]
mov dword [esp + 0x1c], eax
sar eax, 1
mov dword [esp + 0x18], eax
test eax, eax
jle 0x406fd3
lea ecx, [edi + edi]
lea eax, [ecx*8]
mov dword [esp + 0x14], ecx
sub eax, ecx
mov ecx, dword [ebx + eax*8 + 0x70]
mov edi, dword [ebx + eax*8 + 0x74]
lea edx, [ebx + eax*8]
mov esi, dword [edx + 0x3c]
mov eax, dword [edx + 0x38]
cmp edi, esi
jl 0x406f69
jg 0x406f5b
cmp ecx, eax
jbe 0x406f5f
xor eax, eax
jmp 0x406f7b
cmp edi, esi
jg 0x406f70
jl 0x406f69
cmp ecx, eax
jae 0x406f70
mov eax, 1
jmp 0x406f7b
mov ecx, dword [edx + 0x78]
xor eax, eax
cmp ecx, dword [edx + 0x40]
setle al
mov edi, dword [esp + 0x14]
mov ecx, dword [esp + 0x10]
inc edi
add edi, eax
lea eax, [edi*8]
sub eax, edi
lea esi, [ebx + eax*8]
lea eax, [ecx*8]
sub eax, ecx
mov ecx, dword [esi + 4]
lea edx, [ebx + eax*8]
mov eax, dword [esi]
mov dword [edx], eax
mov dword [edx + 4], ecx
lea ecx, [edx + 0x10]
mov eax, dword [esi + 8]
mov dword [edx + 8], eax
mov al, byte [esi + 0xc]
mov byte [edx + 0xc], al
lea eax, [esi + 0x10]
push eax
call fcn.00406a50
mov eax, dword [esp + 0x18]
mov dword [esp + 0x10], edi
cmp edi, eax
jl 0x406f30
mov ecx, dword [ebp + 8]
mov edx, edi
cmp edi, eax
jne 0x40701e
test cl, 1
jne 0x40701e
lea eax, [ecx*8]
sub eax, ecx
mov ecx, dword [ebx + eax*8 - 0x34]
lea esi, [ebx + eax*8]
lea eax, [edi*8]
sub eax, edi
lea edx, [ebx + eax*8]
mov eax, dword [esi - 0x38]
mov dword [edx], eax
mov dword [edx + 4], ecx
lea ecx, [edx + 0x10]
mov eax, dword [esi - 0x30]
mov dword [edx + 8], eax
mov al, byte [esi - 0x2c]
mov byte [edx + 0xc], al
lea eax, [esi - 0x28]
push eax
call fcn.00406a50
mov edx, dword [esp + 0x1c]
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ecx
mov ecx, ebx
call fcn.00406920
add esp, 0xc
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x4079b0
Capabilities:
Allocate thread local storage

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [0x522e14]
cmp eax, 2
je 0x407a43
push esi
push 0
push 1
push 0x522e14
call dword [sym.imp.KERNEL32.dll_InterlockedCompareExchange]
test eax, eax
jne 0x407a1f
push 4
call fcn.004a6683
mov esi, eax
add esp, 4
mov dword [ebp - 4], esi
mov dword [esi], 0
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
push 0x522e14
mov dword [esi], eax
push 0x4061b0
mov dword [0x522e18], esi
call fcn.004041b0
mov eax, dword [0x522e18]
add esp, 8
mov dword [0x522e14], 2
pop esi
mov esp, ebp
pop ebp
ret
cmp eax, 2
je 0x407a42
mov eax, dword [0x522e14]
cmp eax, 2
je 0x407a42
mov esi, dword [sym.imp.KERNEL32.dll_Sleep]
push 0
call esi
mov eax, dword [0x522e14]
cmp eax, 2
jne 0x407a34
pop esi
mov eax, dword [0x522e18]
mov esp, ebp
pop ebp
ret

Function at 0x407f00
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4da90d
mov eax, dword fs:[0]
push eax
sub esp, 0xc
push ebx
push esi
push edi
mov eax, dword [0x51a500]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
call fcn.00407d90
mov edi, dword [ebp + 8]
test edi, edi
js 0x407fa7
call fcn.004079b0
push dword [eax]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ebx, eax
test ebx, ebx
je 0x407fa7
call fcn.00407d90
mov esi, eax
push esi
mov dword [ebp - 0x10], esi
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov dword [ebp - 4], 0
mov eax, dword [ebx]
mov dword [ebp - 0x18], edi
mov dword [ebp - 0x14], eax
call fcn.00407d90
mov edi, eax
lea eax, [ebp - 0x18]
push eax
lea ecx, [edi + 0x18]
call fcn.00408700
push eax
add eax, 0x10
push eax
push ecx
lea eax, [ebp - 0x18]
push eax
lea ecx, [edi + 0x18]
call fcn.00408720
cmp byte [ebp - 0x14], 0
jne 0x407fbb
mov eax, dword [ebp - 0x18]
mov eax, dword [eax + 0x14]
cmp eax, dword [ebx]
je 0x407fbb
test esi, esi
je 0x407fa7
push esi
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
xor al, al
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
inc dword [ebx + 8]
mov eax, dword [ebp + 8]
mov dword [ebx + 0xc], eax
test esi, esi
je 0x407fcf
push esi
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov al, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x407ff0
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4da93d
mov eax, dword fs:[0]
push eax
sub esp, 8
push ebx
push esi
push edi
mov eax, dword [0x51a500]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
call fcn.00407d90
call fcn.004079b0
push dword [eax]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov edi, eax
test edi, edi
je 0x4080c0
mov eax, dword [edi + 8]
cmp eax, 1
jl 0x4080c0
add eax, 0xffffffff
mov dword [edi + 8], eax
jne 0x4080ac
call fcn.00407d90
mov esi, eax
push esi
mov dword [ebp - 0x14], esi
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
lea ebx, [edi + 0xc]
mov dword [ebp - 4], 0
lea eax, [ebp - 0x10]
push ebx
push eax
call fcn.00407d90
lea ecx, [eax + 0x18]
call fcn.00408180
call fcn.00407d90
mov edi, dword [ebp - 0x10]
cmp edi, dword [eax + 0x18]
je 0x40809b
call fcn.00407d90
push edi
lea ecx, [eax + 0x18]
call fcn.004082d0
push 0x18
push eax
call fcn.004a66b3
add esp, 8
mov dword [ebx], 0xffffffff
test esi, esi
je 0x4080ac
push esi
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov al, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
xor al, al
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x4098b0
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
push ebx
push esi
mov esi, ecx
call fcn.00405d00
push dword [eax]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
push 1
cmp byte [eax + 0x14], 0
lea eax, [ebp - 0x1c]
je 0x409915
push 0xf
push 0xf
push 0
push eax
call dword [sym.imp.USER32.dll_PeekMessageW]
test eax, eax
jne 0x409911
push 1
push 0x113
push 0x113
push eax
lea eax, [ebp - 0x1c]
push eax
call dword [sym.imp.USER32.dll_PeekMessageW]
test eax, eax
jne 0x409911
push eax
lea eax, [esi + 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedExchange]
pop esi
xor al, al
pop ebx
mov esp, ebp
pop ebp
ret
mov bl, 1
jmp 0x409927
push 0
push 0
push 0
push eax
call dword [sym.imp.USER32.dll_PeekMessageW]
test eax, eax
setne bl
push 0
lea eax, [esi + 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedExchange]
test bl, bl
jne 0x40993f
pop esi
xor al, al
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [esi]
mov ecx, esi
call dword [eax + 0xc]
lea eax, [ebp - 0x1c]
mov ecx, esi
push eax
call fcn.00409800
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x40a270
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4daabd
mov eax, dword fs:[0]
push eax
push ecx
push ebx
push esi
push edi
mov eax, dword [0x51a500]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
lea esi, [edi + 0xc]
push esi
mov dword [ebp - 0x10], esi
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov dword [ebp - 4], 0
cmp dword [edi + 0x24], 0
je 0x40a2c8
call fcn.00405d00
push dword [eax]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
cmp eax, dword [edi + 0x24]
jne 0x40a2c8
mov bl, 1
jmp 0x40a2ca
xor bl, bl
test esi, esi
je 0x40a2d5
push esi
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x40a320
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4daaf5
mov eax, dword fs:[0]
push eax
sub esp, 0x44
mov eax, dword [0x51a500]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, ecx
lea esi, [ebx + 0xc]
mov byte [ebp - 0x39], 0
push esi
mov dword [ebp - 0x40], esi
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov dword [ebp - 4], 0
cmp dword [ebx + 0x24], 0
je 0x40a3f5
call fcn.00405d00
push dword [eax]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
cmp eax, dword [ebx + 0x24]
je 0x40a3f5
lea eax, [ebp - 0x48]
mov ecx, ebx
push eax
call fcn.00407080
mov edi, dword [ebp - 0x44]
test edi, edi
je 0x40a3ac
lock inc dword [edi + 8]
test edi, edi
je 0x40a3ac
or eax, 0xffffffff
lock xadd dword [edi + 8], eax
jne 0x40a3ac
mov eax, dword [edi]
mov ecx, edi
call dword [eax + 4]
mov eax, dword [ebp - 0x48]
mov dword [ebp - 0x34], eax
lea eax, [ebp - 0x38]
mov dword [ebp - 0x38], vtable.._AV___Func_impl_no_alloc_V__WeakCallback_V___Binder_U_Unforced_std__AAP8MessageLoopProxy_nbase__BEXXZAAPBV34__std___nbase__X__V_std__.0
mov dword [ebp - 0x30], edi
mov dword [ebp - 0x2c], 0x40a430
mov dword [ebp - 0x28], ebx
mov dword [ebp - 0x14], eax
mov byte [ebp - 4], 1
mov ecx, dword [ebx + 0x24]
push eax
call fcn.00405250
mov ecx, dword [ebp - 0x14]
test ecx, ecx
je 0x40a3f1
mov edx, dword [ecx]
lea eax, [ebp - 0x38]
cmp ecx, eax
setne al
movzx eax, al
push eax
call dword [edx + 0x10]
mov byte [ebp - 0x39], 1
test esi, esi
je 0x40a400
push esi
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
cmp byte [ebp - 0x39], 0
jne 0x40a40e
mov eax, dword [ebx]
mov ecx, ebx
push 1
call dword [eax]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004a6675
mov esp, ebp
pop ebp
ret
Function at 0x40a560
Capabilities:
Terminate thread

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, ecx
mov eax, dword [esi + 8]
mov dword [esi], vtable.nbase::Thread.0
test eax, eax
je 0x40a5a7
push 0xffffffffffffffff
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
test eax, eax
je 0x40a590
mov eax, dword [esi + 8]
test eax, eax
je 0x40a5a7
push 0
push eax
call dword [sym.imp.KERNEL32.dll_TerminateThread]
push dword [esi + 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [esi + 4], 0
mov dword [esi + 8], 0
test byte [ebp + 8], 1
je 0x40a5b8
push 0x10
push esi
call fcn.004a66b3
add esp, 8
mov eax, esi
pop esi
pop ebp
ret 4

Function at 0x40a610
Capabilities:
Create thread

Disassembly:
push esi
push edi
mov esi, ecx
lea edi, [esi + 4]
push edi
push 0
push esi
push 0x40a6c0
push 0
push 0
call fcn.004ba580
mov edx, eax
add esp, 0x18
mov dword [esi + 8], edx
cmp edx, 2
jae 0x40a645
mov dword [esi + 8], 0
xor edx, edx
mov dword [edi], 0
mov ecx, dword [esi + 0xc]
test ecx, ecx
jle 0x40a6b4
or eax, 0xffffffff
cmp ecx, 1
jne 0x40a66b
mov eax, 0xfffffffe
push eax
push edx
call dword [sym.imp.KERNEL32.dll_SetThreadPriority]
cmp dword [esi + 8], 1
pop edi
seta al
pop esi
ret
cmp ecx, 2
jne 0x40a685
or eax, 0xffffffff
push eax
push edx
call dword [sym.imp.KERNEL32.dll_SetThreadPriority]
cmp dword [esi + 8], 1
pop edi
seta al
pop esi
ret
cmp ecx, 3
jne 0x40a6a1
mov eax, 2
push eax
push edx
call dword [sym.imp.KERNEL32.dll_SetThreadPriority]
cmp dword [esi + 8], 1
pop edi
seta al
pop esi
ret
cmp ecx, 4
mov edi, 0xf
cmove eax, edi
push eax
push edx
call dword [sym.imp.KERNEL32.dll_SetThreadPriority]
cmp dword [esi + 8], 1
pop edi
seta al
pop esi
ret
Function at 0x40be50
Capabilities:
Hide graphical window

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, ecx
push dword [esi + 0x10]
call dword [sym.imp.USER32.dll_IsWindow]
test eax, eax
je 0x40be95
cmp byte [ebp + 8], 0
je 0x40be89
cmp byte [ebp + 0xc], 0
mov ecx, 1
mov eax, 4
cmovne eax, ecx
push eax
push dword [esi + 0x10]
call dword [sym.imp.USER32.dll_ShowWindow]
pop esi
pop ebp
ret 8
xor eax, eax
push eax
push dword [esi + 0x10]
call dword [sym.imp.USER32.dll_ShowWindow]
pop esi
pop ebp
ret 8