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

Disassembly:
push ebx
push ebp
push esi
push edi
push dword [0xa64efc]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov esi, dword [esp + 0x14]
mov edi, eax
mov ebx, dword [esp + 0x1c]
mov ebp, dword [esp + 0x18]
mov edx, dword [edi + 0x8c]
add esi, edx
mov ecx, dword [edi + 0x90]
add ebx, edx
mov edx, dword [esp + 0x20]
add ebp, ecx
mov eax, dword [edi + 0x74]
add edx, ecx
mov dword [esp + 0x20], edx
cmp eax, 2
je 0x47341e
cmp eax, 3
je 0x47341e
cmp eax, 8
je 0x47341e
cmp eax, 0xc
jne 0x4735eb
mov dword [edi + 0x124], edx
mov eax, ebx
sub edx, ebp
mov dword [edi + 0x118], esi
sub eax, esi
mov dword [edi + 0x11c], ebp
mov ecx, edx
mov dword [esp + 0x14], eax
imul ecx, edx
imul eax, eax
mov dword [edi + 0x120], ebx
mov dword [esp + 0x1c], edx
add ecx, eax
mov dword [esp + 0x18], ecx
fild dword [esp + 0x18]
push ecx
fstp dword [esp + 0x1c]
fld dword [esp + 0x1c]
fstp dword [esp]
call fcn.004735f2
mov eax, dword [esp + 0x24]
fstp dword [edi + 0x128]
pop ecx
cmp ebp, eax
jne 0x473498
cmp esi, ebx
jg 0x473489
mov dword [edi + 0xb4], 0x4732c5
jmp 0x4735eb
mov dword [edi + 0xb4], 0x473306
jmp 0x4735eb
cmp esi, ebx
jne 0x4734be
cmp ebp, eax
jg 0x4734af
mov dword [edi + 0xb4], 0x473347
jmp 0x4735eb
mov dword [edi + 0xb4], 0x473388
jmp 0x4735eb
push dword [esp + 0x1c]
call sub.MSVCRT.dll_abs
push dword [esp + 0x18]
mov esi, eax
call sub.MSVCRT.dll_abs
xor edx, edx
pop ecx
inc edx
pop ecx
cmp eax, esi
jl 0x4734e4
and dword [edi + 0x130], 0
jmp 0x473532
mov eax, dword [edi + 0x11c]
xor dword [edi + 0x118], eax
mov eax, dword [edi + 0x118]
xor dword [edi + 0x11c], eax
mov eax, dword [edi + 0x11c]
xor dword [edi + 0x118], eax
mov eax, dword [edi + 0x124]
xor dword [edi + 0x120], eax
mov eax, dword [edi + 0x120]
xor dword [edi + 0x124], eax
mov eax, dword [edi + 0x124]
xor dword [edi + 0x120], eax
mov dword [edi + 0x130], edx
mov ecx, dword [edi + 0x118]
mov eax, dword [edi + 0x120]
cmp ecx, eax
jge 0x47354b
and dword [edi + 0x12c], 0
jmp 0x47358f
xor eax, ecx
mov dword [edi + 0x12c], edx
xor dword [edi + 0x120], eax
mov dword [edi + 0x118], eax
mov eax, dword [edi + 0x120]
xor dword [edi + 0x118], eax
mov eax, dword [edi + 0x124]
xor dword [edi + 0x11c], eax
mov eax, dword [edi + 0x11c]
xor dword [edi + 0x124], eax
mov eax, dword [edi + 0x124]
xor dword [edi + 0x11c], eax
mov eax, dword [edi + 0x124]
sub eax, dword [edi + 0x11c]
mov dword [esp + 0x20], eax
fild dword [esp + 0x20]
fstp dword [esp + 0x20]
fld dword [esp + 0x20]
mov eax, dword [edi + 0x120]
sub eax, dword [edi + 0x118]
mov dword [esp + 0x20], eax
fild dword [esp + 0x20]
fstp dword [esp + 0x20]
fdiv dword [esp + 0x20]
mov dword [edi + 0xb4], 0x4731b0
fstp dword [esp + 0x20]
fld dword [esp + 0x20]
fst dword [edi + 0x134]
fdivr qword [0x53e6a8]
fstp dword [edi + 0x138]
pop edi
pop esi
pop ebp
pop ebx
ret 0x10
Function at 0x47360c
Capabilities:
Get thread local storage value

Disassembly:
push ebx
push ebp
push esi
push edi
push dword [0xa64efc]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ebp, dword [esp + 0x14]
mov esi, eax
mov eax, dword [esp + 0x18]
mov edi, dword [esp + 0x1c]
add eax, dword [esi + 0x90]
add ebp, dword [esi + 0x8c]
mov dword [esp + 0x18], eax
test edi, edi
jns 0x473642
add ebp, edi
neg edi
mov ebx, dword [esp + 0x20]
test ebx, ebx
jns 0x473652
add eax, ebx
neg ebx
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0x24]
add eax, eax
cmp eax, edi
jle 0x473667
mov eax, edi
cdq
sub eax, edx
sar eax, 1
mov dword [esp + 0x24], eax
mov ecx, dword [esp + 0x28]
add ecx, ecx
cmp ecx, ebx
jle 0x47367c
mov eax, ebx
cdq
sub eax, edx
sar eax, 1
mov dword [esp + 0x28], eax
mov eax, dword [esi + 0xa4]
cmp eax, dword [esi + 0xac]
je 0x473695
push eax
push esi
mov dword [esi + 0xac], eax
call dword [esi + 0x40]
push dword [esp + 0x28]
push dword [esp + 0x28]
push ebx
push edi
push dword [esp + 0x28]
push ebp
push esi
call dword [esi + 8]
pop edi
pop esi
pop ebp
pop ebx
ret 0x18

Function at 0x4736af
Capabilities:
Get thread local storage value

Disassembly:
push esi
push dword [0xa64efc]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov esi, eax
mov eax, dword [esi + 0xa4]
cmp eax, dword [esi + 0xac]
je 0x4736d7
push eax
push esi
mov dword [esi + 0xac], eax
call dword [esi + 0x40]
push dword [esp + 0x14]
mov eax, dword [esi + 0x90]
push dword [esp + 0x14]
add eax, dword [esp + 0x14]
push eax
mov eax, dword [esi + 0x8c]
add eax, dword [esp + 0x14]
push eax
push esi
call dword [esi + 4]
pop esi
ret 0x10

Function at 0x4736fd
Capabilities:
Get thread local storage value

Disassembly:
push dword [0xa64efc]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov edx, eax
mov ecx, dword [edx + 0x74]
cmp ecx, 2
je 0x473722
cmp ecx, 3
je 0x473722
cmp ecx, 8
je 0x473722
cmp ecx, 0xc
jne 0x473730
mov eax, dword [esp + 4]
test eax, eax
je 0x473730
mov dword [edx + 0xb8], eax
ret 4

Function at 0x473733
Capabilities:
Get thread local storage value

Disassembly:
push dword [0xa64efc]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, dword [eax + 0x90]
add ecx, dword [esp + 0xc]
push ecx
mov ecx, dword [eax + 0x8c]
add ecx, dword [esp + 0xc]
push ecx
push dword [esp + 0xc]
push eax
call dword [eax + 0x24]
ret 0xc

Function at 0x473789
Capabilities:
Get thread local storage value

Disassembly:
push dword [0xa64efc]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
push dword [esp + 0xc]
mov ecx, dword [eax + 0x90]
add ecx, dword [esp + 0xc]
push ecx
mov ecx, dword [eax + 0x8c]
add ecx, dword [esp + 0xc]
push ecx
push eax
call dword [eax + 0x50]
ret 0xc
Function at 0x4737b6
Capabilities:
Get thread local storage value

Disassembly:
push ebx
push ebp
push esi
push edi
push dword [0xa64efc]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ebp, dword [esp + 0x14]
mov edi, eax
mov eax, dword [esp + 0x18]
mov esi, dword [esp + 0x1c]
add eax, dword [edi + 0x90]
add ebp, dword [edi + 0x8c]
mov dword [esp + 0x18], eax
test esi, esi
jns 0x4737ec
add ebp, esi
neg esi
mov ebx, dword [esp + 0x20]
test ebx, ebx
jns 0x4737fc
add eax, ebx
neg ebx
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0x24]
add eax, eax
cmp eax, esi
jle 0x473811
mov eax, esi
cdq
sub eax, edx
sar eax, 1
mov dword [esp + 0x24], eax
mov ecx, dword [esp + 0x28]
add ecx, ecx
cmp ecx, ebx
jle 0x473826
mov eax, ebx
cdq
sub eax, edx
sar eax, 1
mov dword [esp + 0x28], eax
mov eax, dword [esp + 0x2c]
cmp eax, dword [edi + 0xac]
je 0x47383d
push eax
push edi
mov dword [edi + 0xac], eax
call dword [edi + 0x40]
push dword [esp + 0x28]
push dword [esp + 0x28]
push ebx
push esi
push dword [esp + 0x28]
push ebp
push edi
call dword [edi + 8]
pop edi
pop esi
pop ebp
pop ebx
ret 0x1c

Function at 0x4739d7
Capabilities:
Set thread local storage value

Disassembly:
push esi
push 0x184
push 8
push dword [0xa6256c]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov esi, eax
push esi
push dword [0xa64efc]
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
push dword [esp + 8]
mov dword [0xa64f00], esi
and dword [esi + 0xa8], 0
or dword [esi + 0xac], 0xffffffff
or dword [esi + 0xb0], 0xffffffff
push esi
mov dword [esi + 0xa4], 0xffffff
mov dword [esi + 0x74], 2
mov dword [esi + 0x78], 0x3f
call fcn.004778c6
mov dword [esi + 0x58], 0x4745ea
mov eax, esi
mov dword [esi + 0x5c], 0x474636
mov dword [esi + 0x10], fcn.0047418b
mov dword [esi + 0x30], 0x47407d
mov dword [esi + 0x64], 0x4746c0
mov dword [esi + 0x60], 0x474678
mov dword [esi + 0x34], 0x473d2d
mov dword [esi + 0x24], 0x473d04
mov dword [esi + 0x28], 0x473cd9
mov dword [esi + 0x2c], 0x473c2b
mov dword [esi + 0x44], 0x4743f0
pop esi
ret 4
Function at 0x475a10
Capabilities:
Set thread local storage value

Disassembly:
push esi
push 0x10c
push 8
push dword [0xa6256c]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov esi, eax
push esi
push dword [0xa64efc]
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
mov dword [0xa64f00], esi
mov eax, esi
and dword [esi + 0xa8], 0
or dword [esi + 0xac], 0xffffffff
or dword [esi + 0xb0], 0xffffffff
mov dword [esi + 0xa4], 0xffffff
mov dword [esi + 0x74], 1
mov dword [esi + 0x78], 7
mov dword [esi], 0x474abc
mov dword [esi + 4], 0x474adc
mov dword [esi + 8], 0x47580c
mov dword [esi + 0xc], 0x474b74
mov dword [esi + 0x10], 0x47508a
mov dword [esi + 0x14], 0x47501c
mov dword [esi + 0x18], 0x47505a
mov dword [esi + 0x1c], 0x475072
mov dword [esi + 0x20], fcn.004750e6
mov dword [esi + 0x24], 0x474eeb
mov dword [esi + 0x28], fcn.00474d40
mov dword [esi + 0x2c], 0x474c57
mov dword [esi + 0x30], 0x474fb2
mov dword [esi + 0x34], 0x474f07
mov dword [esi + 0x38], 0x475163
mov dword [esi + 0x3c], 0x475274
mov dword [esi + 0x40], 0x475318
mov dword [esi + 0x44], 0x4753af
mov dword [esi + 0x48], 0x4754ad
mov dword [esi + 0x4c], 0x47568e
mov dword [esi + 0x50], 0x4754fe
mov dword [esi + 0x54], 0x475750
mov dword [esi + 0x58], 0x47584b
mov dword [esi + 0x5c], 0x475906
mov dword [esi + 0x60], 0x47597e
mov dword [esi + 0x64], 0x4759c4
pop esi
ret
Function at 0x47ab6a
Capabilities:
Encode data using xor

Disassembly:
push ecx
push ecx
mov edx, dword [esp + 0x2c]
push esi
mov esi, dword [esp + 0x10]
mov eax, dword [esi + 0xd4]
mov dword [esp + 4], eax
test edx, edx
je 0x47ac20
imul eax, dword [esp + 0x1c]
mov ecx, dword [esp + 0x18]
imul ecx, dword [esp + 0x28]
push ebx
mov ebx, dword [esp + 0x24]
mov dword [esp + 0x20], eax
mov eax, dword [esp + 0x1c]
neg eax
add ecx, dword [esp + 0x18]
mov dword [esp + 0xc], eax
mov eax, dword [esp + 0x28]
push ebp
push edi
lea edi, [ecx + eax*4]
mov eax, dword [esp + 0x28]
mov ecx, dword [esi + 0xcc]
mov ebp, edi
imul ecx, ebx
add ecx, dword [esi + 0xc8]
add ecx, eax
cmp dword [esp + 0x38], 0
jle 0x47ac00
mov edx, dword [esp + 0x38]
mov esi, dword [esp + 0x10]
mov al, byte [ebp + 2]
xor byte [ecx + 2], al
mov al, byte [ebp + 1]
xor byte [ecx + 1], al
mov al, byte [ebp]
lea ebp, [ebp + 4]
xor byte [ecx], al
add ecx, esi
dec edx
jne 0x47abdb
mov edx, dword [esp + 0x3c]
mov esi, dword [esp + 0x1c]
mov eax, dword [esp + 0x28]
dec edx
inc ebx
cmp dword [esi + 0xe8], 0
mov dword [esp + 0x3c], edx
jne 0x47ac15
add edi, dword [esp + 0x14]
jmp 0x47ac19
add edi, dword [esp + 0x24]
test edx, edx
jne 0x47abb9
pop edi
pop ebp
pop ebx
pop esi
pop ecx
pop ecx
ret 0x24

Function at 0x47af2b
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
push ecx
push ecx
imul edx, dword [esp + 0x28], 3
push ebx
mov ebx, dword [esp + 0x30]
mov dword [esp + 8], edx
test ebx, ebx
je 0x47b005
imul eax, dword [esp + 0x1c], 3
mov ecx, dword [esp + 0x18]
push ebp
mov ebp, dword [esp + 0x24]
neg ecx
push esi
mov dword [esp + 0x24], eax
mov eax, dword [esp + 0x20]
imul eax, dword [esp + 0x30]
push edi
imul edi, dword [esp + 0x30], 3
mov dword [esp + 0x10], ecx
add eax, dword [esp + 0x20]
add edi, eax
mov eax, dword [esp + 0x1c]
mov dword [esp + 0x38], edi
mov esi, dword [eax + 0xcc]
imul esi, ebp
mov dword [esp + 0x34], edi
add esi, dword [eax + 0xc8]
add esi, dword [esp + 0x28]
test edx, edx
jle 0x47afdb
mov ebp, dword [esp + 0x34]
mov ebx, 0xff
sub ebx, dword [esp + 0x40]
mov edi, edx
movzx eax, byte [esi]
movzx ecx, byte [ebp]
imul ecx, dword [esp + 0x40]
imul eax, ebx
add eax, ecx
mov ecx, 0xff
cdq
idiv ecx
inc ebp
mov byte [esi], al
inc esi
dec edi
jne 0x47afa3
mov edi, dword [esp + 0x38]
mov ebx, dword [esp + 0x3c]
mov ebp, dword [esp + 0x2c]
mov eax, dword [esp + 0x1c]
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0x14]
dec ebx
inc ebp
cmp dword [eax + 0xe8], 0
mov dword [esp + 0x3c], ebx
mov dword [esp + 0x2c], ebp
jne 0x47aff2
add edi, ecx
jmp 0x47aff6
add edi, dword [esp + 0x24]
mov dword [esp + 0x38], edi
test ebx, ebx
jne 0x47af79
pop edi
pop esi
pop ebp
pop ebx
pop ecx
pop ecx
ret 0x28
Function at 0x47b625
Capabilities:
Encode data using xor

Disassembly:
push ecx
push ecx
push esi
mov esi, dword [esp + 0x30]
push edi
mov edi, dword [esp + 0x14]
mov eax, dword [edi + 0xd4]
mov dword [esp + 8], eax
test esi, esi
je 0x47b6da
imul eax, dword [esp + 0x20]
imul edx, dword [esp + 0x28], 3
push ebx
mov ebx, dword [esp + 0x28]
push ebp
mov dword [esp + 0x28], eax
mov eax, dword [esp + 0x24]
neg eax
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0x24]
imul eax, dword [esp + 0x34]
add eax, dword [esp + 0x20]
add edx, eax
mov eax, dword [esp + 0x28]
mov ecx, dword [edi + 0xcc]
mov ebp, edx
imul ecx, ebx
add ecx, dword [edi + 0xc8]
add ecx, eax
cmp dword [esp + 0x38], 0
jle 0x47b6bb
mov esi, dword [esp + 0x38]
mov edi, dword [esp + 0x10]
mov al, byte [ebp + 2]
xor byte [ecx + 2], al
mov al, byte [ebp + 1]
xor byte [ecx + 1], al
mov al, byte [ebp]
lea ebp, [ebp + 3]
xor byte [ecx], al
add ecx, edi
dec esi
jne 0x47b696
mov esi, dword [esp + 0x3c]
mov edi, dword [esp + 0x1c]
mov eax, dword [esp + 0x28]
dec esi
inc ebx
cmp dword [edi + 0xe8], 0
mov dword [esp + 0x3c], esi
jne 0x47b6d0
add edx, dword [esp + 0x14]
jmp 0x47b6d4
add edx, dword [esp + 0x24]
test esi, esi
jne 0x47b674
pop ebp
pop ebx
pop edi
pop esi
pop ecx
pop ecx
ret 0x24
Function at 0x47d9b4
Capabilities:
Resolve function by parsing pe exports

Disassembly:
sub esp, 0x50
push ebx
mov ebx, dword [esp + 0x5c]
push ebp
xor ebp, ebp
push esi
test ebx, ebx
je 0x47d9c8
mov esi, ebx
jmp 0x47d9d2
push 0
call dword [sym.imp.GDI32.dll_CreateCompatibleDC]
mov esi, eax
test esi, esi
je 0x47dac3
lea eax, [esp + 0x18]
push eax
push 0x18
pop eax
push eax
push dword [esp + 0x68]
call dword [sym.imp.GDI32.dll_GetObjectW]
test eax, eax
je 0x47dab8
mov ebp, dword [esp + 0x1c]
lea eax, [esp + 0x30]
push edi
mov edi, dword [esp + 0x24]
push 0x2c
push 0
push eax
mov dword [esp + 0x20], ebp
call sub.MSVCRT.dll_memset
add esp, 0xc
mov dword [esp + 0x34], 0x28
xor eax, eax
mov dword [esp + 0x38], ebp
inc eax
mov dword [esp + 0x3c], edi
mov word [esp + 0x40], ax
xor ecx, ecx
push 0x18
pop eax
push ecx
push ecx
mov word [esp + 0x4a], ax
lea eax, [esp + 0x18]
push eax
push ecx
lea eax, [esp + 0x44]
mov dword [esp + 0x54], ecx
push eax
push esi
call dword [sym.imp.GDI32.dll_CreateDIBSection]
mov ebp, eax
mov dword [esp + 0x18], ebp
test ebp, ebp
je 0x47dab7
push 0
lea eax, [esp + 0x38]
push eax
push dword [esp + 0x18]
push edi
push 0
push dword [esp + 0x78]
push esi
call dword [sym.imp.GDI32.dll_GetDIBits]
imul edi, dword [esp + 0x14]
test edi, edi
jle 0x47dab7
mov ebx, dword [esp + 0x10]
push 3
pop ebp
movzx ecx, byte [ebx + 1]
movzx eax, byte [ebx + 2]
add eax, ecx
movzx ecx, byte [ebx]
add eax, ecx
cdq
idiv ebp
mov byte [ebx], al
mov ecx, dword [esp + 0x10]
mov byte [ecx + 1], al
mov ecx, dword [esp + 0x10]
mov byte [ecx + 2], al
mov ebx, dword [esp + 0x10]
add ebx, ebp
mov dword [esp + 0x10], ebx
dec edi
jne 0x47da80
mov ebx, dword [esp + 0x68]
mov ebp, dword [esp + 0x18]
pop edi
test ebx, ebx
jne 0x47dac3
push esi
call dword [sym.imp.GDI32.dll_DeleteDC]
pop esi
mov eax, ebp
pop ebp
pop ebx
add esp, 0x50
ret 8

Function at 0x47f4c7
Capabilities:
Check os version

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x114
push 0x53e6e4
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov dword [0xa64414], eax
test eax, eax
je 0x47f4f5
push str.AlphaBlend
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [0xa64410], eax
lea eax, [ebp - 0x114]
mov dword [0xa64418], 1
push eax
mov dword [ebp - 0x114], 0x114
call dword [sym.imp.KERNEL32.dll_GetVersionExW]
test eax, eax
je 0x47f557
cmp dword [ebp - 0x104], 1
jne 0x47f52c
and dword [0xa64418], 0
jmp 0x47f56f
cmp dword [ebp - 0x104], 2
jne 0x47f557
cmp dword [ebp - 0x110], 5
jb 0x47f523
jne 0x47f557
mov eax, dword [ebp - 0x10c]
neg eax
sbb eax, eax
and eax, dword [0xa64418]
mov dword [0xa64418], eax
jmp 0x47f55c
mov eax, dword [0xa64418]
test eax, eax
je 0x47f56f
call fcn.0047eccd
neg eax
sbb eax, eax
and dword [0xa64418], eax
mov esp, ebp
pop ebp
ret
Function at 0x4805d0
Capabilities:
Write file on windows

Disassembly:
push esi
mov esi, dword [esp + 0x10]
push edi
mov edi, dword [esp + 0xc]
mov eax, dword [edi]
test eax, eax
je 0x480602
push 0
lea ecx, [esp + 0x10]
push ecx
push esi
push dword [esp + 0x1c]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x4805fd
cmp dword [esp + 0xc], esi
je 0x480619
pop edi
xor eax, eax
pop esi
ret
mov eax, dword [edi + 4]
add eax, dword [edi + 8]
push esi
push dword [esp + 0x14]
push eax
call sub.MSVCRT.dll_memcpy
add esp, 0xc
add dword [edi + 8], esi
pop edi
mov eax, 1
pop esi
ret
Function at 0x480f6f
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
sub esp, 0xc
push ebx
push esi
mov esi, dword [esp + 0x3c]
xor ebx, ebx
cmp esi, 1
je 0x480f9f
cmp esi, 2
je 0x480f9f
cmp esi, 4
je 0x480f9f
cmp esi, 8
je 0x480f9f
cmp esi, 0x18
je 0x480f9f
cmp esi, 0x20
je 0x480f9f
xor eax, eax
jmp 0x481169
mov ecx, dword [0xa64474]
push ebp
push edi
xor edi, edi
mov dword [esp + 0x10], edi
test ecx, ecx
jle 0x481165
mov edx, dword [esp + 0x28]
mov eax, dword [edi*4 + 0xa64f8c]
cmp dword [eax], edx
je 0x480fd2
inc edi
mov dword [esp + 0x10], edi
cmp edi, ecx
jl 0x480fb9
jmp 0x481165
cmp dword [esp + 0x38], 0x20
jne 0x48113c
mov eax, dword [eax + 8]
test eax, eax
je 0x481012
cmp esi, 0x20
je 0x480fee
cmp esi, 0xffffffff
jne 0x481012
push esi
push dword [esp + 0x44]
push dword [esp + 0x44]
push dword [esp + 0x40]
push dword [esp + 0x40]
push dword [esp + 0x40]
push dword [esp + 0x3c]
push dword [esp + 0x3c]
call eax
jmp 0x481163
mov eax, dword [esp + 0x2c]
inc eax
imul ebp, eax, 3
and ebp, 0xfffffffc
mov eax, ebp
mov dword [esp + 0x14], ebp
imul eax, dword [esp + 0x30]
push eax
push 0
push dword [0xa6256c]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov dword [esp + 0x18], eax
test eax, eax
je 0x481165
mov ebx, dword [esp + 0x30]
test ebx, ebx
jle 0x481107
mov edx, dword [esp + 0x24]
mov ecx, eax
mov eax, dword [esp + 0x2c]
mov dword [esp + 0x38], ecx
mov dword [esp + 0x30], edx
mov dword [esp + 0x24], ebx
mov dword [esp + 0x28], ecx
mov esi, edx
test eax, eax
jle 0x4810e7
mov ebp, ecx
mov edi, eax
mov ecx, 0xff
movzx eax, byte [esi + 2]
sub eax, ecx
movzx ecx, byte [esi + 3]
imul eax, ecx
mov ecx, 0xff
add eax, 0xfe01
cdq
idiv ecx
mov byte [ebp + 2], al
movzx eax, byte [esi + 1]
sub eax, ecx
movzx ecx, byte [esi + 3]
imul eax, ecx
mov ecx, 0xff
add eax, 0xfe01
cdq
idiv ecx
mov byte [ebp + 1], al
movzx eax, byte [esi]
lea esi, [esi + 4]
sub eax, ecx
movzx ecx, byte [esi - 1]
imul eax, ecx
mov ecx, 0xff
add eax, 0xfe01
cdq
idiv ecx
mov byte [ebp], al
lea ebp, [ebp + 3]
dec edi
jne 0x481078
mov ebp, dword [esp + 0x14]
mov eax, dword [esp + 0x2c]
mov ecx, dword [esp + 0x38]
mov edx, dword [esp + 0x30]
add edx, dword [esp + 0x34]
add ecx, ebp
dec dword [esp + 0x24]
mov dword [esp + 0x30], edx
mov dword [esp + 0x38], ecx
jne 0x481065
mov esi, dword [esp + 0x44]
mov edi, dword [esp + 0x10]
mov eax, dword [edi*4 + 0xa64f8c]
push esi
push dword [esp + 0x44]
mov esi, dword [esp + 0x20]
push dword [esp + 0x44]
push ebp
push ebx
push dword [esp + 0x40]
push esi
push dword [esp + 0x3c]
call dword [eax + 4]
push esi
push 0
push dword [0xa6256c]
mov ebx, eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
jmp 0x481165
cmp dword [esp + 0x38], 0x18
jne 0x481165
push esi
push dword [esp + 0x44]
push dword [esp + 0x44]
push dword [esp + 0x40]
push dword [esp + 0x40]
push dword [esp + 0x40]
push dword [esp + 0x3c]
push dword [esp + 0x3c]
call dword [eax + 4]
mov ebx, eax
pop edi
mov eax, ebx
pop ebp
pop esi
pop ebx
add esp, 0xc
ret 0x28
Function at 0x486a99
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push edi
push dword [0xa64690]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov edi, eax
test edi, edi
jne 0x486afa
push esi
push dword [0xa6468c]
push 8
push dword [0xa6256c]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov edi, eax
push edi
push dword [0xa64690]
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
mov esi, dword [0xa64688]
jmp 0x486aea
mov ecx, dword [esi + 0xc]
test ecx, ecx
je 0x486ae8
mov eax, dword [esi + 8]
add eax, edi
push eax
call ecx
pop ecx
mov esi, dword [esi]
test esi, esi
jne 0x486ad8
push edi
push 0x486a37
call fcn.00521f2d
pop esi
mov eax, dword [esp + 8]
add eax, edi
pop edi
ret 4

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

Disassembly:
push ebx
push ebp
push esi
mov esi, dword [esp + 0x10]
mov ecx, esi
push edi
and ecx, 3
je 0x486b1a
push 4
pop eax
sub eax, ecx
add esi, eax
mov eax, dword [0xa6468c]
mov ebx, dword [sym.imp.KERNEL32.dll_TlsSetValue]
test eax, eax
jne 0x486b51
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
push esi
push 8
push dword [0xa6256c]
mov dword [0xa64690], eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
push eax
push dword [0xa64690]
call ebx
mov eax, dword [0xa6468c]
mov edi, eax
add eax, esi
push eax
push dword [0xa64690]
mov dword [0xa6468c], eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
push eax
push 8
push dword [0xa6256c]
call dword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov ebp, eax
push ebp
push dword [0xa64690]
call ebx
mov esi, dword [esp + 0x18]
mov ebx, dword [esp + 0x1c]
test esi, esi
jne 0x486b91
test ebx, ebx
je 0x486bb2
push 0x14
push 0xa64688
call fcn.00487416
pop ecx
pop ecx
mov dword [eax], edi
mov dword [eax + 4], esi
mov dword [eax + 8], ebx
test esi, esi
je 0x486bb2
lea ecx, [edi + ebp]
push ecx
call esi
pop ecx
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
ret 0xc

Function at 0x487590
Capabilities:
Get thread local storage value

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
mov eax, dword [0xa5cf88]
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 0x4875d6
mov ecx, dword [ebp - 4]
add ecx, 0xa
push ecx
push 0
mov edx, dword [0xa65010]
push edx
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ecx, dword [ebp + 8]
mov dword [ecx], eax
jmp 0x4875f7
mov edx, dword [ebp - 4]
add edx, 0xa
push edx
mov eax, dword [ebp + 8]
mov ecx, dword [eax]
push ecx
push 0
mov edx, dword [0xa65010]
push edx
call dword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov ecx, dword [ebp + 8]
mov dword [ecx], eax
mov edx, dword [ebp - 4]
shr edx, 1
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.00487f50
mov ecx, dword [ebp - 8]
mov edx, dword [ebp + 0xc]
mov dword [ecx + 8], edx
mov esp, ebp
pop ebp
ret 8