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

Disassembly:
push ebx
push ebp
mov ebp, dword [esp + 0xc]
push edi
mov edi, ebp
mov ebx, eax
call fcn.004feac0
mov eax, dword [ebx]
mov ecx, dword [eax - 4]
xor edi, edi
cmp ecx, edi
jne 0x4fe7c6
pop edi
pop ebp
mov eax, 3
pop ebx
ret 0xc
mov eax, dword [0x728c28]
cmp eax, 0xffffffff
push esi
mov esi, dword [0x728c30]
je 0x4fe7ee
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
cmp eax, edi
je 0x4fe7ee
or edx, 0xffffffff
mov ecx, esi
call fcn.004fc390
jmp 0x4fe7f7
push 0xffffffffffffffff
push esi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov eax, dword [ebx]
mov edx, dword [ebp + 0x3c]
push 0x8000
push edi
lea esi, [ebp + 0x3c]
push 1
push eax
mov ecx, esi
call dword [edx + 8]
test eax, eax
je 0x4fe81b
mov ebx, 9
jmp 0x4fe8e0
mov eax, dword [0x8ccd00]
cmp eax, edi
jne 0x4fe854
push 0x18
call fcn.005354b8
add esp, 4
cmp eax, edi
je 0x4fe84d
mov dword [eax + 8], edi
mov dword [eax + 0x14], 1
mov dword [eax + 0xc], edi
mov dword [eax + 0x10], edi
mov dword [eax + 4], edi
mov dword [eax], 0x712b24
jmp 0x4fe84f
xor eax, eax
mov dword [0x8ccd00], eax
lea ecx, [esp + 0x14]
push ecx
mov dword [esp + 0x18], ebp
call fcn.004c3730
mov eax, ebp
call fcn.004fe900
mov ebx, eax
cmp ebx, edi
jne 0x4fe8e0
push ebp
mov edi, esi
call fcn.004fe9e0
mov ebx, eax
test ebx, ebx
jne 0x4fe8e0
mov edx, dword [esi]
push 1
push eax
mov ecx, esi
call dword [edx + 0x1c]
mov dword [ebp + 0x88], eax
mov al, byte [esp + 0x18]
test al, al
je 0x4fe8d2
push 0x18
call fcn.005354b8
mov esi, eax
add esp, 4
test esi, esi
je 0x4fe8b6
mov eax, 1
mov edi, 0x10
call fcn.0045a010
jmp 0x4fe8b8
xor eax, eax
test eax, eax
mov dword [ebp + 0x70], eax
jne 0x4fe8c6
mov ebx, 0xa
jmp 0x4fe8d2
mov eax, dword [ebp + 0x84]
push ebp
call fcn.004fedb0
mov al, byte [esp + 0x1c]
test al, al
je 0x4fe8e0
mov dword [0x8ccd04], ebp
mov eax, dword [0x728c30]
push eax
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
pop esi
pop edi
pop ebp
mov eax, ebx
pop ebx
ret 0xc
Function at 0x4fec40
Capabilities:
Get thread local storage value

Disassembly:
push ecx
push ebx
push ebp
push esi
mov esi, eax
mov eax, dword [0x728c28]
xor bl, bl
cmp eax, 0xffffffff
push edi
mov edi, dword [0x728c30]
je 0x4fec70
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x4fec70
or edx, 0xffffffff
mov ecx, edi
call fcn.004fc390
jmp 0x4fec79
push 0xffffffffffffffff
push edi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov eax, dword [esi + 0x3c]
lea ebp, [esi + 0x3c]
mov ecx, ebp
call dword [eax + 0x18]
test al, al
je 0x4fed42
mov eax, dword [esp + 0x18]
cmp eax, dword [esi + 0x7c]
jae 0x4fed42
mov ecx, dword [esi + 0x80]
mov edx, dword [ebp]
add ecx, 4
imul ecx, eax
add ecx, dword [esi + 0x88]
push 0
push ecx
mov ecx, ebp
call dword [edx + 0x1c]
mov edx, dword [ebp]
push 4
lea eax, [esp + 0x1c]
push eax
mov ecx, ebp
call dword [edx + 0x20]
cmp eax, 4
jne 0x4fed42
mov eax, dword [esi + 8]
test eax, eax
mov esi, dword [esp + 0x18]
mov ebx, dword [ebp]
jne 0x4fecfc
mov edi, dword [esp + 0x1c]
push esi
call fcn.004f4730
push eax
mov ecx, ebp
call dword [ebx + 0x20]
mov ecx, dword [esp + 0x18]
cmp eax, ecx
mov eax, ecx
mov ecx, edi
sete bl
call fcn.004f4780
jmp 0x4fed42
lea ecx, [esi + esi]
push ecx
lea edi, [esp + 0x14]
mov dword [esp + 0x14], 0x8cccd0
call fcn.004f5160
push eax
mov ecx, ebp
call dword [ebx + 0x20]
mov ecx, dword [esp + 0x18]
lea edx, [ecx + ecx]
cmp eax, edx
mov eax, ecx
mov ecx, edi
sete bl
call fcn.004f51b0
mov esi, dword [esp + 0x10]
mov edi, dword [esp + 0x1c]
call fcn.004f2ef0
lea esi, [esp + 0x10]
call fcn.00412c90
mov eax, dword [0x728c30]
push eax
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
pop edi
pop esi
pop ebp
mov al, bl
pop ebx
pop ecx
ret 8

Function at 0x4fee40
Capabilities:
Get thread local storage value

Disassembly:
mov eax, dword [0x8ccd00]
test eax, eax
je 0x4feead
mov eax, dword [0x728c28]
cmp eax, 0xffffffff
push esi
mov esi, dword [0x728c30]
je 0x4fee71
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x4fee71
or edx, 0xffffffff
mov ecx, esi
call fcn.004fc390
jmp 0x4fee7a
push 0xffffffffffffffff
push esi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov eax, dword [0x8ccd00]
mov ecx, dword [eax + 0xc]
xor esi, esi
test ecx, ecx
jbe 0x4feeac
jmp 0x4fee90
mov eax, dword [eax + 4]
mov eax, dword [eax + esi*4]
mov edx, dword [eax + 0x3c]
lea ecx, [eax + 0x3c]
call dword [edx + 0xc]
mov eax, dword [0x8ccd00]
mov ecx, dword [eax + 0xc]
inc esi
cmp esi, ecx
jb 0x4fee90
pop esi
ret
Function at 0x4ff360
Capabilities:
Check mutex on windows

Disassembly:
push ebx
xor bl, bl
test eax, eax
push esi
mov esi, ecx
je 0x4ff3d5
cmp byte [eax], 0
je 0x4ff3d5
push eax
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateMutexA]
test eax, eax
mov ecx, dword [esp + 0xc]
mov dword [ecx], eax
je 0x4ff3d5
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
jne 0x4ff3d3
test edi, edi
je 0x4ff3d5
cmp byte [edi], 0
je 0x4ff3d5
test esi, esi
je 0x4ff3d5
cmp byte [esi], 0
je 0x4ff3d5
push esi
push edi
call dword [sym.imp.USER32.dll_FindWindowA]
mov esi, eax
test esi, esi
je 0x4ff3d5
push esi
call dword [sym.imp.USER32.dll_IsIconic]
test eax, eax
je 0x4ff3c5
push 9
push esi
call dword [sym.imp.USER32.dll_ShowWindow]
push esi
call dword [sym.imp.USER32.dll_SetForegroundWindow]
pop esi
mov al, bl
pop ebx
ret 4
mov bl, 1
pop esi
mov al, bl
pop ebx
ret 4
Function at 0x4ff910
Capabilities:
Get thread local storage value

Disassembly:
push ebx
mov ebx, eax
mov eax, dword [0x728c28]
cmp eax, 0xffffffff
push ebp
mov ebp, dword [edi + 0x30]
je 0x4ff938
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x4ff938
or edx, 0xffffffff
mov ecx, ebp
call fcn.004fc390
jmp 0x4ff941
push 0xffffffffffffffff
push ebp
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
xor ebp, ebp
test esi, esi
je 0x4ff98c
mov eax, dword [esp + 0xc]
test eax, eax
je 0x4ff98c
test ebx, ebx
jne 0x4ff956
mov ebx, dword [esi + 0x18]
mov eax, dword [esi + 0x14]
mov ecx, dword [esi + 0x18]
lea edx, [eax + ebx]
cmp edx, ecx
jbe 0x4ff967
sub ecx, eax
mov ebx, ecx
test ebx, ebx
jbe 0x4ff98c
mov ecx, dword [esi + 0x1c]
mov edx, dword [edi]
add ecx, eax
push 0
push ecx
mov ecx, edi
call dword [edx + 0x1c]
mov eax, dword [esp + 0xc]
mov edx, dword [edi]
push ebx
push eax
mov ecx, edi
call dword [edx + 0x20]
mov ebp, eax
add dword [esi + 0x14], ebp
mov ecx, dword [edi + 0x30]
push ecx
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov eax, ebp
pop ebp
pop ebx
ret 4

Function at 0x4ffae0
Capabilities:
Encode data using xor

Disassembly:
mov ecx, dword [edi + 8]
mov edx, dword [ecx - 4]
or eax, 0xffffffff
test edx, edx
je 0x4ffb0f
push ebx
push esi
mov esi, edx
xor edx, edx
mov dl, byte [ecx]
xor edx, eax
and edx, 0xff
mov ebx, dword [edx*4 + 0x728c38]
shr eax, 8
xor eax, ebx
inc ecx
dec esi
jne 0x4ffaf1
pop esi
pop ebx
mov dword [edi + 0x20], eax
ret
Function at 0x4fff70
Capabilities:
Enumerate files on windows
Enumerate files recursively

Disassembly:
sub esp, 0x148
push ebx
push ebp
push esi
mov esi, dword [esp + 0x15c]
cmp byte [esi], 0
mov ebp, ecx
mov ebx, 0x8cccd0
mov dword [esp + 0x10], ebp
mov dword [esp + 0xc], ebx
je 0x500115
mov ebx, dword [esp + 0x158]
lea eax, [esp + 0xc]
call fcn.00412f10
mov eax, dword [esp + 0xc]
mov ecx, dword [eax - 4]
cmp byte [ecx + eax - 1], 0x5c
je 0x4fffc4
push 0x70e1b4
lea eax, [esp + 0x10]
call fcn.00412e50
push edi
push esi
lea eax, [esp + 0x14]
call fcn.00412e50
mov eax, dword [esp + 0x10]
mov edi, dword [sym.imp.KERNEL32.dll_FindFirstFileA]
lea edx, [esp + 0x18]
push edx
push eax
call edi
mov esi, eax
cmp esi, 0xffffffff
je 0x500024
mov bl, 0x16
lea ebx, [ebx]
test byte [esp + 0x18], bl
jne 0x50000d
call fcn.004fc2a0
mov eax, dword [esp + 0x15c]
lea ecx, [esp + 0x18]
push ecx
push ebp
call fcn.00500140
lea edx, [esp + 0x18]
push edx
push esi
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x4ffff0
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
mov ebx, dword [esp + 0x15c]
lea eax, [esp + 0x10]
call fcn.00412f10
mov eax, dword [esp + 0x10]
mov ecx, dword [eax - 4]
cmp byte [ecx + eax - 1], 0x5c
je 0x500050
push 0x70e1b4
lea eax, [esp + 0x14]
call fcn.00412e50
push 0x712b04
lea eax, [esp + 0x14]
call fcn.00412e50
mov ebx, dword [esp + 0x10]
lea edx, [esp + 0x18]
push edx
push ebx
call edi
mov ebp, eax
cmp ebp, 0xffffffff
je 0x500114
mov al, byte [esp + 0x18]
test al, 6
jne 0x5000f9
test al, 0x10
je 0x5000f9
mov edi, 0x6f7894
lea esi, [esp + 0x44]
mov ecx, 2
xor eax, eax
repe cmpsb byte [esi], byte es:[edi]
je 0x5000f9
mov edi, 0x712b00
lea esi, [esp + 0x44]
mov ecx, 3
xor edx, edx
repe cmpsb byte [esi], byte es:[edi]
je 0x5000f9
mov ebx, dword [esp + 0x15c]
lea eax, [esp + 0x10]
call fcn.00412f10
mov eax, dword [esp + 0x10]
mov ecx, dword [eax - 4]
cmp byte [ecx + eax - 1], 0x5c
je 0x5000d5
push 0x70e1b4
lea eax, [esp + 0x14]
call fcn.00412e50
lea edx, [esp + 0x44]
push edx
lea eax, [esp + 0x14]
call fcn.00412e50
mov eax, dword [esp + 0x160]
mov ebx, dword [esp + 0x10]
mov ecx, dword [esp + 0x14]
push eax
push ebx
call fcn.004fff70
lea ecx, [esp + 0x18]
push ecx
push ebp
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x500075
push ebp
call dword [sym.imp.KERNEL32.dll_FindClose]
pop edi
pop esi
lea eax, [ebx - 8]
test eax, eax
pop ebp
pop ebx
je 0x50012f
cmp eax, 0x8cccc8
je 0x50012f
push eax
call sub.MSVCR71.dll_void___cdecl_operator_delete___void__
add esp, 4
add esp, 0x148
ret 8
Function at 0x5007a0
Capabilities:
Delete file

Disassembly:
sub esp, 0x280
push ebx
push edi
mov edi, dword [esp + 0x290]
mov eax, edi
xor bl, bl
call fcn.004f29f0
test al, al
je 0x500843
mov ecx, dword [esp + 0x28c]
push ebp
push esi
mov esi, dword [sym.imp.KERNEL32.dll_FindFirstFileA]
lea eax, [esp + 0x10]
push eax
push ecx
call esi
mov ebp, eax
cmp ebp, 0xffffffff
je 0x500834
lea edx, [esp + 0x150]
push edx
push edi
call esi
mov edi, dword [sym.imp.KERNEL32.dll_FindClose]
mov esi, eax
cmp esi, 0xffffffff
je 0x500831
mov eax, dword [esp + 0x170]
cmp eax, dword [esp + 0x30]
jne 0x50081c
lea ecx, [esp + 0x24]
push ecx
lea edx, [esp + 0x168]
push edx
call dword [sym.imp.KERNEL32.dll_CompareFileTime]
test eax, eax
jne 0x50081c
mov bl, 1
push esi
call edi
test bl, bl
jne 0x500831
mov eax, dword [esp + 0x298]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
push ebp
call edi
pop esi
pop ebp
pop edi
mov al, bl
pop ebx
add esp, 0x280
ret 8
pop edi
mov al, bl
pop ebx
add esp, 0x280
ret 8
Function at 0x500850
Capabilities:
Create directory

Disassembly:
sub esp, 0x10
push ebx
push ebp
push esi
mov esi, 0x8cccd0
mov ebx, eax
push edi
lea eax, [esp + 0x14]
mov dword [esp + 0x14], esi
mov dword [esp + 0x10], esi
call fcn.00412f10
mov eax, dword [esp + 0x24]
mov ebp, dword [eax + 0x40]
mov ebx, dword [ebp - 4]
test ebx, ebx
jl 0x5008ba
test ebp, ebp
je 0x5008ba
cmp ebp, esi
je 0x5008ba
test ebx, ebx
je 0x5008ad
mov esi, ebx
lea edi, [esp + 0x10]
call fcn.004f4a30
mov esi, dword [esp + 0x10]
push ebx
push ebp
push esi
call dword [sym.imp.MSVCR71.dll_memmove]
mov ecx, dword [esi - 4]
add esp, 0xc
mov byte [esi + ecx], 0
jmp 0x5008ba
lea ecx, [esp + 0x10]
call fcn.00412f90
mov esi, dword [esp + 0x10]
mov ebx, dword [esp + 0x14]
mov eax, dword [ebx - 4]
xor edi, edi
test eax, eax
jle 0x5009af
push 0x5c
push ebx
call dword [sym.imp.MSVCR71.dll_strchr]
add esp, 8
test eax, eax
je 0x5009af
sub eax, ebx
mov ebp, eax
cmp ebp, 0xffffffff
je 0x5009af
lea esp, [esp]
inc ebp
mov ecx, ebp
sub ecx, edi
mov edx, edi
lea edi, [esp + 0x24]
lea ebx, [esp + 0x14]
call fcn.004f2f20
mov eax, dword [eax]
mov ebx, dword [eax - 4]
test ebx, ebx
mov ecx, dword [esi - 4]
mov dword [esp + 0x1c], eax
mov dword [esp + 0x18], ecx
jle 0x500953
test ecx, ecx
jl 0x500953
test eax, eax
je 0x500953
lea edx, [ecx + ebx]
cmp edx, ecx
jle 0x500945
mov esi, edx
lea edi, [esp + 0x10]
call fcn.004f4a30
mov esi, dword [esp + 0x10]
mov edx, dword [esi - 4]
mov ecx, dword [esp + 0x18]
mov eax, dword [esp + 0x1c]
mov byte [esi + edx], 0
push ebx
push eax
add ecx, esi
push ecx
call dword [sym.imp.MSVCR71.dll_memmove]
add esp, 0xc
mov eax, dword [esp + 0x24]
add eax, 0xfffffff8
je 0x50096c
cmp eax, 0x8cccc8
je 0x50096c
push eax
call sub.MSVCR71.dll_void___cdecl_operator_delete___void__
add esp, 4
push 0
push esi
mov dword [esp + 0x2c], 0x8cccd0
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
mov ebx, dword [esp + 0x14]
cmp ebp, dword [ebx - 4]
mov edi, ebp
jge 0x5009ab
test ebp, ebp
jl 0x5009ab
push 0x5c
add ebp, ebx
push ebp
call dword [sym.imp.MSVCR71.dll_strchr]
add esp, 8
test eax, eax
je 0x5009ab
sub eax, ebx
mov ebp, eax
cmp ebp, 0xffffffff
jne 0x5008f0
mov ebx, dword [esp + 0x14]
add esi, 0xfffffff8
je 0x5009c5
cmp esi, 0x8cccc8
je 0x5009c5
push esi
call sub.MSVCR71.dll_void___cdecl_operator_delete___void__
add esp, 4
pop edi
pop esi
lea eax, [ebx - 8]
test eax, eax
pop ebp
pop ebx
je 0x5009e0
cmp eax, 0x8cccc8
je 0x5009e0
push eax
call sub.MSVCR71.dll_void___cdecl_operator_delete___void__
add esp, 4
add esp, 0x10
ret 4
Function at 0x506380
Capabilities:
Print debug messages

Disassembly:
sub esp, 0x40c
push ebx
mov ebx, dword [0x8ccd14]
test ebx, ebx
push ebp
push esi
push edi
je 0x506418
mov eax, dword [ebx + 0xc]
test eax, eax
je 0x506418
mov ecx, ebx
call fcn.00572a10
test eax, eax
mov dword [esp + 0x10], eax
je 0x506418
mov ebp, dword [sym.imp.USER32.dll_wsprintfA]
lea eax, [esp + 0x10]
push eax
lea edi, [esp + 0x18]
lea ecx, [esp + 0x1c]
mov dword [esp + 0x18], 0
call fcn.004c2db0
mov esi, dword [esp + 0x14]
mov ecx, dword [esi + 4]
mov edx, dword [esp + 0x18]
push ecx
push edx
lea eax, [esp + 0x24]
push str._nERROR:__s_still_in_sequence_map__refCnt_d_n
push eax
call ebp
add esp, 0x10
lea ecx, [esp + 0x1c]
push ecx
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
mov edx, dword [esi]
push 1
mov ecx, esi
call dword [edx]
dec dword [esi + 4]
jne 0x50640a
mov eax, dword [esi]
push 1
mov ecx, esi
call dword [eax]
mov eax, dword [esp + 0x10]
test eax, eax
mov ebx, dword [0x8ccd14]
jne 0x5063b4
mov ecx, dword [0x8ccd18]
test ecx, ecx
je 0x5064cc
mov esi, dword [ecx + 4]
xor eax, eax
test esi, esi
jbe 0x506441
mov edi, dword [ecx + 8]
mov edx, edi
cmp dword [edx], 0
jne 0x50645f
inc eax
add edx, 4
cmp eax, esi
jb 0x506434
xor eax, eax
test eax, eax
mov esi, eax
je 0x5064b2
lea esp, [esp]
mov eax, dword [esi]
test eax, eax
mov ebx, dword [esi + 8]
mov edi, ecx
je 0x506464
mov esi, eax
jmp 0x506496
mov eax, dword [edi + eax*4]
jmp 0x506443
mov eax, dword [esi + 4]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov edx, dword [edi + 4]
inc eax
cmp eax, edx
jae 0x50648e
mov ecx, dword [edi + 8]
lea ecx, [ecx + eax*4]
jmp 0x506480
mov esi, dword [ecx]
test esi, esi
jne 0x506490
inc eax
add ecx, 4
cmp eax, edx
jb 0x506480
xor esi, esi
mov ecx, dword [0x8ccd18]
test ebx, ebx
je 0x5064a8
mov edx, dword [ebx]
push 1
mov ecx, ebx
call dword [edx]
mov ecx, dword [0x8ccd18]
test esi, esi
jne 0x506450
mov ebx, dword [0x8ccd14]
test ecx, ecx
je 0x5064cc
mov eax, dword [ecx]
push 1
call dword [eax]
mov ebx, dword [0x8ccd14]
mov dword [0x8ccd18], 0
test ebx, ebx
je 0x5064e2
mov edx, dword [ebx]
push 1
mov ecx, ebx
call dword [edx]
mov dword [0x8ccd14], 0
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x40c
ret
Function at 0x50b5c0
Capabilities:
Write file on windows

Disassembly:
push ecx
mov eax, dword [esp + 0xc]
push ebp
push esi
push edi
push eax
call dword [sym.imp.MSVCR71.dll_wcslen]
mov ecx, dword [ebx + 0x4c]
mov dword [esp + 0x10], eax
mov eax, dword [ecx + 0x40]
mov edx, dword [eax + 0x3c]
mov ecx, dword [edx]
mov dword [ebx + 0xc], ecx
mov edx, dword [eax + 0x38]
mov ecx, dword [esp + 0x18]
mov eax, dword [edx]
lea ebp, [ebx + 0xc]
push 0x70e0a4
push ecx
mov dword [ebx + 8], eax
call dword [sym.imp.MSVCR71.dll_fopen]
mov edi, dword [sym.imp.MSVCR71.dll_fwrite]
mov esi, eax
push esi
push 4
lea edx, [esp + 0x20]
push 1
push edx
call edi
mov eax, dword [esp + 0x28]
mov ecx, dword [esp + 0x34]
push esi
push 2
push eax
push ecx
call edi
push esi
push 4
lea eax, [ebx + 8]
push 1
push eax
call edi
push esi
push 4
push 1
push ebp
call edi
add esp, 0x4c
push esi
push 4
lea edx, [ebx + 4]
push 1
push edx
call edi
mov eax, dword [esp + 0x1c]
mov ecx, dword [ebx + 0x48]
push esi
push 0x18
inc eax
push eax
push ecx
call edi
push esi
call dword [sym.imp.MSVCR71.dll_fclose]
add esp, 0x24
pop edi
pop esi
pop ebp
pop ecx
ret 8
Function at 0x517460
Capabilities:
Get thread local storage value

Disassembly:
mov eax, dword [0x728c28]
cmp eax, 0xffffffff
push esi
mov esi, dword [0x72905c]
je 0x517488
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x517488
or edx, 0xffffffff
mov ecx, esi
call fcn.004fc390
jmp 0x517491
push 0xffffffffffffffff
push esi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov eax, dword [0x8ccd30]
test eax, eax
pop esi
jne 0x5174be
push 0x180
call fcn.005354b8
add esp, 4
test eax, eax
je 0x5174b7
push ebx
mov ebx, eax
call fcn.005198e0
pop ebx
jmp 0x5174b9
xor eax, eax
mov dword [0x8ccd30], eax
mov byte [eax + 0xcd], 1
mov eax, dword [0x72905c]
push eax
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov eax, dword [0x8ccd30]
ret
Function at 0x518640
Capabilities:
Get thread local storage value

Disassembly:
sub esp, 8
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push ebp
mov ebp, dword [esp + 0x14]
push esi
push edi
mov byte [ebp + 0xcd], 1
jmp 0x518660
mov eax, dword [0x728c28]
cmp eax, 0xffffffff
mov edi, dword [0x72905c]
je 0x5186cc
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov esi, eax
test esi, esi
je 0x5186cc
mov eax, dword [esi + 0x20]
mov dword [esp + 0x10], eax
mov eax, dword [esi + 0x14]
test eax, eax
mov dword [esp + 0x14], edi
je 0x5186cc
cmp eax, 3
je 0x5186cc
push 0
push 0
lea ecx, [esp + 0x18]
push ecx
push 2
call dword [sym.imp.KERNEL32.dll_WaitForMultipleObjects]
mov ecx, eax
sub ecx, 0
je 0x5186b1
dec ecx
je 0x5186c8
jmp 0x5186d1
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
cmp dword [esi + 0x30], eax
jne 0x5186c8
mov dword [esi + 0x14], 3
call fcn.004fc230
xor eax, eax
jmp 0x5186d1
push 0
push edi
call ebx
test eax, eax
je 0x5186df
push ebp
xor eax, eax
call fcn.005174e0
jmp 0x518660
mov eax, dword [0x728c28]
cmp eax, 0xffffffff
mov esi, dword [ebp + 0xf4]
je 0x518706
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x518706
or edx, 0xffffffff
mov ecx, esi
call fcn.004fc390
jmp 0x51870b
push 0xffffffffffffffff
push esi
call ebx
mov eax, dword [0x728c28]
cmp eax, 0xffffffff
mov esi, dword [ebp + 0xdc]
je 0x518732
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x518732
or edx, 0xffffffff
mov ecx, esi
call fcn.004fc390
jmp 0x518737
push 0xffffffffffffffff
push esi
call ebx
mov ebx, dword [esp + 0x20]
push 1
push 1
push ebp
mov eax, ebx
call fcn.00518f40
mov edi, eax
mov eax, dword [ebp + 0x13c]
test eax, eax
mov dword [esp + 0x1c], eax
je 0x5187b9
mov esi, dword [eax + 8]
cmp dword [esi + 4], ebx
jne 0x5187af
mov ecx, dword [esi]
mov ebx, dword [ebx + 0x80]
mov eax, dword [ecx + 0x28]
xor edx, edx
dec ebx
div ebx
mov edx, dword [esp + 0x20]
mov ebx, eax
mov eax, dword [edx + 0x7c]
dec eax
mov dword [esp + 0x10], eax
mov eax, dword [ecx + 0x24]
mov ecx, dword [esp + 0x10]
xor edx, edx
div ecx
push eax
mov eax, dword [esp + 0x24]
call fcn.00514180
mov byte [esi + 8], 0
lea esi, [ebp + 0x138]
lea ecx, [esp + 0x1c]
call fcn.00507ce0
mov eax, dword [esp + 0x1c]
mov ebx, dword [esp + 0x20]
jmp 0x5187b5
mov eax, dword [eax]
mov dword [esp + 0x1c], eax
test eax, eax
jne 0x518757
lea esi, [edi + 0x10]
call fcn.004cd7e0
mov ecx, edi
call fcn.006b4e20
mov eax, dword [ebp + 0x10c]
test eax, eax
mov dword [esp + 0x1c], eax
je 0x518801
mov ecx, dword [eax + 8]
cmp dword [ecx + 4], ebx
jne 0x5187f7
mov byte [ecx + 8], 0
lea esi, [ebp + 0x108]
lea ecx, [esp + 0x1c]
call fcn.00507ce0
mov eax, dword [esp + 0x1c]
jmp 0x5187fd
mov eax, dword [eax]
mov dword [esp + 0x1c], eax
test eax, eax
jne 0x5187d6
mov eax, dword [edi + 0x20]
mov ecx, dword [eax + 0x38]
mov esi, dword [sym.imp.KERNEL32.dll_ReleaseMutex]
push ecx
call esi
mov edx, dword [ebp + 0xdc]
push edx
call esi
mov eax, dword [ebp + 0xf4]
push eax
call esi
mov ecx, dword [0x72905c]
push ecx
call esi
push ebp
xor eax, eax
call fcn.005174e0
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret 8
Function at 0x518880
Capabilities:
Get thread local storage value

Disassembly:
push ecx
mov eax, dword [0x728c28]
cmp eax, 0xffffffff
push ebx
mov ebx, dword [esp + 0xc]
push ebp
push esi
mov esi, dword [ebx + 0xf4]
push edi
je 0x5188b0
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x5188b0
or edx, 0xffffffff
mov ecx, esi
call fcn.004fc390
jmp 0x5188b9
push 0xffffffffffffffff
push esi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov esi, dword [ebx + 0x13c]
test esi, esi
je 0x518907
mov edi, dword [esi + 8]
mov ecx, dword [edi + 4]
mov ebp, dword [edi]
mov ebx, dword [ecx + 0x80]
lea eax, [esi + 8]
mov eax, dword [ebp + 0x28]
xor edx, edx
dec ebx
div ebx
xor edx, edx
mov esi, dword [esi]
mov ebx, eax
mov eax, dword [ecx + 0x7c]
dec eax
mov dword [esp + 0x10], eax
mov eax, dword [ebp + 0x24]
mov ebp, dword [esp + 0x10]
div ebp
push eax
mov eax, ecx
call fcn.00514180
test esi, esi
mov byte [edi + 8], 0
jne 0x5188c3
mov ebx, dword [esp + 0x18]
mov esi, dword [ebx + 0x13c]
lea edi, [ebx + 0x138]
xor ebp, ebp
cmp esi, ebp
je 0x518930
lea esp, [esp]
mov edx, dword [edi]
mov eax, esi
mov esi, dword [esi]
push eax
mov ecx, edi
call dword [edx + 8]
cmp esi, ebp
jne 0x518920
mov dword [edi + 0xc], ebp
mov dword [edi + 4], ebp
mov dword [edi + 8], ebp
mov eax, dword [ebx + 0xf4]
pop edi
pop esi
pop ebp
pop ebx
add esp, 4
mov dword [esp + 4], eax
jmp dword [sym.imp.KERNEL32.dll_ReleaseMutex]
Function at 0x519090
Capabilities:
Get thread local storage value

Disassembly:
push ebx
movzx ebx, word [esp + 8]
push ebp
push esi
push edi
movzx eax, ax
push 1
mov edi, ecx
mov esi, edx
shl ebx, 0x10
push 1
or ebx, eax
push esi
mov eax, edi
call fcn.00518f40
mov ebp, eax
mov al, byte [edi + 0xa0]
test al, al
jne 0x51910c
mov ecx, dword [ebp + 0x20]
mov al, byte [ecx + 1]
test al, al
jne 0x5190cf
push esi
mov eax, edi
call fcn.0051aff0
mov edx, dword [ebp + 0x20]
mov eax, dword [edx + 0x38]
push eax
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov eax, dword [0x728c28]
cmp eax, 0xffffffff
mov ecx, dword [ebp + 0x20]
mov edi, dword [ecx + 0x38]
je 0x519103
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x519103
or edx, 0xffffffff
mov ecx, edi
call fcn.004fc390
jmp 0x51910c
push 0xffffffffffffffff
push edi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
lea edx, [esp + 0x14]
lea edi, [ebp + 0x10]
push edx
call fcn.0051bd30
test al, al
jne 0x5191c6
mov eax, dword [0x728c28]
cmp eax, 0xffffffff
mov edi, dword [esi + 0x38]
je 0x519145
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x519145
or edx, 0xffffffff
mov ecx, edi
call fcn.004fc390
jmp 0x51914e
push 0xffffffffffffffff
push edi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov eax, dword [esi + 0x160]
lea edi, [esi + 0x160]
mov ecx, edi
call dword [eax + 4]
mov dword [eax + 8], ebp
mov dword [eax + 4], 0
mov ecx, dword [edi + 4]
mov dword [eax], ecx
mov ecx, dword [edi + 4]
test ecx, ecx
je 0x51917a
mov dword [ecx + 4], eax
jmp 0x51917d
mov dword [edi + 8], eax
mov dword [edi + 4], eax
inc dword [edi + 0xc]
mov edx, dword [esi + 0x38]
push edx
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov eax, dword [ebp]
mov ecx, ebp
call dword [eax + 4]
mov dword [eax + 8], ebx
mov dword [eax], 0
mov ecx, dword [ebp + 8]
mov dword [eax + 4], ecx
mov ecx, dword [ebp + 8]
test ecx, ecx
je 0x5191af
mov dword [ecx], eax
jmp 0x5191b2
mov dword [ebp + 4], eax
mov ecx, dword [ebp + 0xc]
inc ecx
push 0
lea esi, [ebp + 0x10]
mov dword [ebp + 8], eax
mov dword [ebp + 0xc], ecx
call fcn.005197c0
mov edx, dword [ebp + 0x20]
mov eax, dword [edx + 0x38]
pop edi
pop esi
pop ebp
pop ebx
mov dword [esp + 4], eax
jmp dword [sym.imp.KERNEL32.dll_ReleaseMutex]