joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4e7560
Capabilities:
Resolve function by parsing pe exports

Disassembly:
mov eax, 0x68
call fcn.00476ea0
mov eax, dword [0x548280]
xor eax, esp
mov dword [esp + 0x64], eax
mov eax, dword [esp + 0x6c]
push ebx
push ebp
mov ebp, dword [esp + 0x84]
mov dword [esp + 0xc], eax
mov eax, dword [esp + 0x7c]
push esi
mov dword [esp + 0x1c], eax
xor esi, esi
lea eax, [esp + 0x20]
mov dword [esp + 0x18], ebp
push edi
push eax
call fcn.004bb100
mov edi, dword [esp + 0x84]
add esp, 4
mov eax, dword [ebp + 8]
xor ebx, ebx
mov dword [esp + 0x18], eax
test edi, edi
jle 0x4e7670
jmp 0x4e75c0
mov eax, ebx
mov byte [esp + 0x13], bl
sar eax, 0x18
mov byte [esp + 0x10], al
mov eax, ebx
sar eax, 0x10
mov byte [esp + 0x11], al
mov eax, ebx
sar eax, 8
push 0
mov byte [esp + 0x16], al
lea eax, [esp + 0x28]
push ebp
push eax
call fcn.004baec0
push dword [esp + 0x94]
lea eax, [esp + 0x34]
push dword [esp + 0x30]
push eax
call fcn.004baf70
push 4
lea eax, [esp + 0x2c]
push eax
lea eax, [esp + 0x44]
push eax
call fcn.004baf70
mov ebp, dword [esp + 0x3c]
add esp, 0x24
add ebp, esi
push 0
cmp ebp, edi
jg 0x4e7639
mov eax, dword [esp + 0x18]
add eax, esi
push eax
lea eax, [esp + 0x2c]
push eax
call fcn.004bae50
add esp, 0xc
mov esi, ebp
jmp 0x4e7663
lea eax, [esp + 0x38]
push eax
lea eax, [esp + 0x2c]
push eax
call fcn.004bae50
mov eax, edi
sub eax, esi
push eax
lea eax, [esp + 0x44]
push eax
mov eax, dword [esp + 0x28]
add eax, esi
push eax
call fcn.0046ed30
add esp, 0x18
mov esi, edi
mov ebp, dword [esp + 0x1c]
inc ebx
cmp esi, edi
jl 0x4e75c0
lea eax, [esp + 0x24]
push eax
call fcn.004baf80
mov ecx, dword [esp + 0x78]
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.004632a9
add esp, 0x68
ret
Function at 0x4e7f80
Capabilities:
Check for software breakpoints

Disassembly:
push esi
mov esi, dword [esp + 0x14]
cmp dword [esp + 0x18], esi
jne 0x4e8049
mov ecx, dword [esp + 0x10]
mov al, byte [ecx]
cmp al, 0x6a
je 0x4e7fa1
cmp al, 0x6b
jne 0x4e8049
inc ecx
cmp al, 0x6b
jne 0x4e800b
add esi, 0xfffffffd
xor eax, eax
test esi, esi
jle 0x4e7fc2
nop
mov dl, byte [ecx]
inc ecx
cmp dl, 0xba
je 0x4e7fc2
cmp dl, 0xbb
jne 0x4e7feb
inc eax
cmp eax, esi
jl 0x4e7fb0
sub esi, eax
test eax, eax
jne 0x4e800e
push 0x83
push str..crypto_rsa_rsa_x931.c
push 0x8a
push 0x80
push 4
call fcn.004b0700
add esp, 0x14
or eax, 0xffffffff
pop esi
ret
push 0x7b
push str..crypto_rsa_rsa_x931.c
push 0x8a
push 0x80
push 4
call fcn.004b0700
add esp, 0x14
or eax, 0xffffffff
pop esi
ret
add esi, 0xfffffffe
cmp byte [esi + ecx], 0xcc
je 0x4e8037
push 0x8b
push str..crypto_rsa_rsa_x931.c
push 0x8b
push 0x80
push 4
call fcn.004b0700
add esp, 0x14
or eax, 0xffffffff
pop esi
ret
push esi
push ecx
push dword [esp + 0x10]
call fcn.0046ed30
add esp, 0xc
mov eax, esi
pop esi
ret
push 0x70
push str..crypto_rsa_rsa_x931.c
push 0x89
push 0x80
push 4
call fcn.004b0700
add esp, 0x14
or eax, 0xffffffff
pop esi
ret
Function at 0x4f45b0
Capabilities:
Encode data using xor

Disassembly:
mov ecx, dword [esp + 0xc]
push ebx
push ebp
mov ebp, dword [esp + 0x10]
push esi
mov eax, dword [ebp + 4]
cmp eax, dword [ecx + 4]
jge 0x4f45c7
mov ebx, ecx
jmp 0x4f45cb
mov ebx, ebp
mov ebp, ecx
mov esi, dword [esp + 0x10]
mov eax, dword [ebx + 4]
cmp eax, dword [esi + 8]
jg 0x4f45db
mov eax, esi
jmp 0x4f45e5
push eax
push esi
call fcn.004b77e0
add esp, 8
test eax, eax
jne 0x4f45ed
pop esi
pop ebp
pop ebx
ret
push edi
xor edi, edi
cmp dword [ebp + 4], edi
jle 0x4f460b
mov eax, dword [ebx]
mov ecx, dword [ebp]
mov edx, dword [eax + edi*4]
mov eax, dword [esi]
xor edx, dword [ecx + edi*4]
mov dword [eax + edi*4], edx
inc edi
cmp edi, dword [ebp + 4]
jl 0x4f45f5
cmp edi, dword [ebx + 4]
jge 0x4f4620
mov eax, dword [ebx]
mov ecx, dword [esi]
mov eax, dword [eax + edi*4]
mov dword [ecx + edi*4], eax
inc edi
cmp edi, dword [ebx + 4]
jl 0x4f4610
mov ecx, dword [ebx + 4]
mov dword [esi + 4], ecx
pop edi
test ecx, ecx
jle 0x4f4644
mov eax, dword [esi]
sub eax, 4
lea ecx, [eax + ecx*4]
mov eax, dword [ecx]
lea ecx, [ecx - 4]
test eax, eax
jne 0x4f4644
dec dword [esi + 4]
cmp dword [esi + 4], eax
jg 0x4f4633
pop esi
pop ebp
mov eax, 1
pop ebx
ret
Function at 0x4c8ba0
Capabilities:
Packed with generic packer

Disassembly:
pushal
mov esi, section.UPX1
lea edi, [esi - 0x86000]
push edi
jmp 0x4c8bba
mov al, byte [esi]
inc esi
mov byte [edi], al
inc edi
add ebx, ebx
jne 0x4c8bc1
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x4c8bb0
mov eax, 1
add ebx, ebx
jne 0x4c8bd3
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
add ebx, ebx
jae 0x4c8be4
jne 0x4c8c03
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x4c8c03
dec eax
add ebx, ebx
jne 0x4c8bf0
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
jmp 0x4c8bc8
add ebx, ebx
jne 0x4c8bff
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
jmp 0x4c8c55
xor ecx, ecx
sub eax, 3
jb 0x4c8c1b
shl eax, 8
mov al, byte [esi]
inc esi
xor eax, 0xffffffff
je 0x4c8c8a
sar eax, 1
mov ebp, eax
jmp 0x4c8c26
add ebx, ebx
jne 0x4c8c26
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x4c8bf4
inc ecx
add ebx, ebx
jne 0x4c8c34
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x4c8bf4
add ebx, ebx
jne 0x4c8c41
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
jae 0x4c8c36
jne 0x4c8c52
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jae 0x4c8c36
add ecx, 2
cmp ebp, 0xfffffb00
adc ecx, 2
lea edx, [edi + ebp]
cmp ebp, 0xfffffffc
jbe 0x4c8c74
mov al, byte [edx]
inc edx
mov byte [edi], al
inc edi
dec ecx
jne 0x4c8c66
jmp 0x4c8bb6
mov eax, dword [edx]
add edx, 4
mov dword [edi], eax
add edi, 4
sub ecx, 4
ja 0x4c8c74
add edi, ecx
jmp 0x4c8bb6
pop esi
mov edi, esi
mov ecx, 0x377e
mov al, byte [edi]
inc edi
sub al, 0xe8
cmp al, 1
ja 0x4c8c92
cmp byte [edi], 0x11
jne 0x4c8c92
mov eax, dword [edi]
mov bl, byte [edi + 4]
shr ax, 8
rol eax, 0x10
xchg ah, al
sub eax, edi
sub bl, 0xe8
add eax, esi
mov dword [edi], eax
add edi, 5
mov al, bl
loop 0x4c8c97
lea edi, [esi + 0xc4000]
mov eax, dword [edi]
or eax, eax
je 0x4c8d0f
mov ebx, dword [edi + 4]
lea eax, [eax + esi + 0xdfbb4]
add ebx, esi
push eax
add edi, 8
call dword [esi + 0xdfd08]
xchg ebp, eax
mov al, byte [edi]
inc edi
or al, al
je 0x4c8cc4
mov ecx, edi
jns 0x4c8cf3
movzx eax, word [edi]
inc edi
push eax
inc edi
mov ecx, 0xaef24857
push edi
dec eax
repne scasb al, byte es:[edi]
push ebp
call dword [esi + 0xdfd0c]
or eax, eax
je 0x4c8d09
mov dword [ebx], eax
add ebx, 4
jmp 0x4c8ce1
call dword [esi + 0xdfd1c]
mov ebp, dword [esi + 0xdfd10]
lea edi, [esi - 0x1000]
mov ebx, 0x1000
push eax
push esp
push 4
push ebx
push edi
call ebp
lea eax, [edi + 0x22f]
and byte [eax], 0x7f
and byte [eax + 0x28], 0x7f
pop eax
push eax
push esp
push eax
push ebx
push edi
call ebp
pop eax
popal
lea eax, [esp - 0x80]
push 0
cmp esp, eax
jne 0x4c8d43
sub esp, 0xffffff80
jmp 0x416310
Function at 0x430006
Capabilities:
Encode data using xor
Packed with generic packer

Disassembly:
call 0x43000c
nop
nop
pop eax
nop
nop
nop
nop
add eax, 0x403daa
sub eax, 0x403d50
nop
nop
nop
nop
nop
mov ebx, dword [eax]
mov ecx, dword [eax + 4]
nop
nop
nop
nop
nop
mov edx, dword [eax + 8]
nop
nop
nop
nop
xor dword [ebx], edx
nop
nop
nop
add ebx, 4
nop
cmp ebx, ecx
nop
nop
nop
nop
nop
nop
nop
jl 0x430030
nop
nop
nop
nop
add eax, 0xc
nop
cmp dword [eax], 0
nop
nop
nop
nop
nop
jne 0x43001e
nop
nop
nop
nop
nop
nop
popal
jmp fcn.00401219
Function at 0x406278
Capabilities:
Check for time delay via gettickcount

Disassembly:
push ebx
push esi
push edi
push ebp
add esp, 0xfffffff0
mov edi, edx
mov esi, eax
mov ebp, dword [esi + 0x10]
mov eax, esi
call fcn.00406728
mov byte [esp], al
cmp byte [esp], 0
jne 0x406401
test edi, edi
je 0x406401
mov byte [esp + 1], 0
test ebp, ebp
jle 0x406341
call sub.kernel32.dll_GetTickCount
mov dword [esp + 4], eax
xor eax, eax
mov dword [esp + 0xc], eax
test ebp, ebp
jle 0x40631c
cmp edi, 0xffffffff
je 0x4062dd
call sub.kernel32.dll_GetTickCount
sub eax, dword [esp + 4]
cmp edi, eax
ja 0x4062dd
mov byte [esp], 0
jmp 0x406401
cmp dword [esi], 1
jg 0x40631c
cmp dword [esi], 0
jne 0x40630e
xor eax, eax
mov edx, 1
lock cmpxchg dword [esi], edx
test eax, eax
jne 0x40630e
call sub.kernel32.dll_GetCurrentThreadId
mov dword [esi + 8], eax
mov dword [esi + 4], 1
mov byte [esp], 1
jmp 0x406401
lea eax, [esp + 0xc]
call fcn.00405f28
dec ebp
test ebp, ebp
jg 0x4062c2
cmp edi, 0xffffffff
je 0x406341
call sub.kernel32.dll_GetTickCount
mov dword [esp + 8], eax
mov eax, dword [esp + 8]
sub eax, dword [esp + 4]
cmp edi, eax
ja 0x40633f
mov byte [esp], 0
jmp 0x406401
sub edi, eax
mov ebx, dword [esi]
test ebx, ebx
je 0x406286
lea edx, [ebx + 2]
mov eax, ebx
lock cmpxchg dword [esi], edx
cmp ebx, eax
jne 0x406341
call sub.kernel32.dll_GetTickCount
mov dword [esp + 4], eax
mov eax, esi
call fcn.0040647c
mov edx, eax
mov ebx, dword [0x40d8e0]
mov ecx, edi
xor eax, eax
call dword [ebx + 0x10]
test eax, eax
sete byte [esp]
cmp edi, 0xffffffff
je 0x4063a5
call sub.kernel32.dll_GetTickCount
mov dword [esp + 8], eax
mov eax, dword [esp + 8]
sub eax, dword [esp + 4]
cmp edi, eax
jbe 0x4063a3
mov eax, dword [esp + 8]
sub eax, dword [esp + 4]
sub edi, eax
jmp 0x4063a5
xor edi, edi
cmp byte [esp], 0
je 0x4063cb
mov ebx, dword [esi]
test bl, 1
jne 0x4063e1
mov edx, ebx
sub edx, 2
or edx, 1
mov eax, ebx
lock cmpxchg dword [esi], edx
cmp ebx, eax
jne 0x4063ab
mov byte [esp + 1], 1
jmp 0x4063e1
mov ebx, dword [esi]
mov edx, ebx
sub edx, 2
mov eax, ebx
lock cmpxchg dword [esi], edx
cmp ebx, eax
jne 0x4063cb
mov byte [esp + 1], 1
cmp byte [esp + 1], 0
je 0x406358
cmp byte [esp], 0
je 0x406401
call sub.kernel32.dll_GetCurrentThreadId
mov dword [esi + 8], eax
mov dword [esi + 4], 1
movzx eax, byte [esp]
add esp, 0x10
pop ebp
pop edi
pop esi
pop ebx
ret

Function at 0x406f44
Capabilities:
Write file on windows

Disassembly:
push ecx
cmp byte [0x40d040], 0
je 0x406fab
cmp word [0x40d32c], 0xd7b2
jne 0x406f6d
cmp dword [0x40d334], 0
jbe 0x406f6d
mov eax, 0x40d328
call dword [0x40d344]
push 0
lea eax, [esp + 4]
push eax
push 0x1d
push str.Runtime_error_____at_00000000
push 0xfffffffffffffff5
call sub.kernel32.dll_GetStdHandle
push eax
call sub.kernel32.dll_WriteFile
push 0
lea eax, [esp + 4]
push eax
push 2
mov eax, 0x406fd8
call fcn.00407604
push eax
push 0xfffffffffffffff5
call sub.kernel32.dll_GetStdHandle
push eax
call sub.kernel32.dll_WriteFile
pop edx
ret
cmp byte [0x40c01e], 0
jne 0x406fc7
push 0
push str.Error
push str.Runtime_error_____at_00000000
push 0
call sub.user32.dll_MessageBoxA
pop edx
ret
Function at 0x4099f0
Capabilities:
Get system information on windows

Disassembly:
add esp, 0xffffffdc
push esp
call sub.kernel32.dll_GetSystemInfo
mov eax, dword [esp + 0x14]
add esp, 0x24
ret
Function at 0x40d010
Capabilities:
Write file on windows

Disassembly:
push ebx
sub esp, 0x18
mov eax, dword [sym.imp.msvcrt.dll__iob]
mov dword [esp + 8], 0x1b
mov dword [esp + 4], 1
lea ebx, [esp + 0x24]
mov dword [esp], str.Mingw_w64_runtime_failure:_n
add eax, 0x40
mov dword [esp + 0xc], eax
call sym._fwrite
mov eax, dword [esp + 0x20]
mov dword [esp + 8], ebx
mov dword [esp + 4], eax
mov eax, dword [sym.imp.msvcrt.dll__iob]
add eax, 0x40
mov dword [esp], eax
call sym._vfprintf
call sym._abort
jmp dbg.mark_section_writable

Function at 0x40d070
Capabilities:
Allocate or change rwx memory

Disassembly:
push edi
push esi
push ebx
sub esp, 0x30
mov esi, dword [0x491054]
test esi, esi
jle 0x40d15d
mov edi, dword [0x491058]
xor ebx, ebx
lea edx, [edi + 4]
nop
mov ecx, dword [edx]
cmp ecx, eax
ja 0x40d0a4
mov edi, dword [edx + 4]
add ecx, dword [edi + 8]
cmp eax, ecx
jb 0x40d156
add ebx, 1
add edx, 0xc
cmp ebx, esi
jne 0x40d090
mov dword [esp], eax
mov ebx, eax
call dbg.__mingw_GetSectionForAddress
test eax, eax
mov edi, eax
je 0x40d19a
lea ebx, [esi + esi*2]
mov esi, dword [0x491058]
shl ebx, 2
add esi, ebx
mov dword [esi + 8], eax
mov dword [esi], 0
call dbg._GetPEImageBase
add eax, dword [edi + 0xc]
mov dword [esi + 4], eax
lea eax, [esp + 0x14]
mov dword [esp + 8], 0x1c
mov dword [esp + 4], eax
mov eax, dword [0x491058]
mov eax, dword [eax + ebx + 4]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
sub esp, 0xc
test eax, eax
je 0x40d17a
mov eax, dword [esp + 0x28]
lea edx, [eax - 4]
and edx, 0xfffffffb
je 0x40d14f
sub eax, 0x40
and eax, 0xffffffbf
je 0x40d14f
mov eax, dword [esp + 0x20]
add ebx, dword [0x491058]
mov dword [esp + 8], 0x40
mov dword [esp + 4], eax
mov eax, dword [esp + 0x14]
mov dword [esp + 0xc], ebx
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
sub esp, 0x10
test eax, eax
je 0x40d164
add dword [0x491054], 1
add esp, 0x30
pop ebx
pop esi
pop edi
ret
xor esi, esi
jmp 0x40d0ae
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [esp], str.__VirtualProtect_failed_with_code_0x_x
mov dword [esp + 4], eax
call dbg.__report_error
mov eax, dword [0x491058]
mov eax, dword [eax + ebx + 4]
mov dword [esp + 8], eax
mov eax, dword [edi + 8]
mov dword [esp], str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov dword [esp + 4], eax
call dbg.__report_error
mov dword [esp + 4], ebx
mov dword [esp], str.Address__p_has_no_image_section
call dbg.__report_error
lea esi, [esi]
Function at 0x40d660
Capabilities:
Get thread local storage value

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x1c
mov dword [esp], 0x491408
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov ebx, dword [0x491400]
sub esp, 4
mov ebp, dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
test ebx, ebx
je 0x40d6b5
lea esi, [esi]
mov eax, dword [ebx]
mov dword [esp], eax
call ebp
sub esp, 4
mov esi, eax
call edi
test eax, eax
jne 0x40d6ae
test esi, esi
je 0x40d6ae
mov eax, dword [ebx + 4]
mov dword [esp], esi
call eax
mov ebx, dword [ebx + 8]
test ebx, ebx
jne 0x40d690
mov dword [esp], 0x491408
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
sub esp, 4
add esp, 0x1c
pop ebx
pop esi
pop edi
pop ebp
ret

Function at 0x40d8d0
Capabilities:
Enumerate pe sections

Disassembly:
push esi
push ebx
mov edx, dword [esp + 0xc]
mov ebx, dword [esp + 0x10]
add edx, dword [edx + 0x3c]
movzx esi, word [edx + 6]
movzx eax, word [edx + 0x14]
test esi, esi
lea eax, [edx + eax + 0x18]
je 0x40d908
xor ecx, ecx
nop
mov edx, dword [eax + 0xc]
cmp edx, ebx
ja 0x40d8fe
add edx, dword [eax + 8]
cmp ebx, edx
jb 0x40d90a
add ecx, 1
add eax, 0x28
cmp ecx, esi
jne 0x40d8f0
xor eax, eax
pop ebx
pop esi
ret
Function at 0x40efb0
Capabilities:
Check mutex on windows
Contain obfuscated stackstrings

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x2c
mov ebx, dword [ebp + 8]
mov dword [esp], ebx
call sym._strlen
mov esi, eax
lea eax, [eax + 0x41]
and eax, 0xfffffff0
call fcn.0040dbe0
mov edx, 0x326d
sub esp, eax
lea eax, [esp + 0x1b]
mov dword [esp + 8], esi
mov dword [esp + 4], ebx
lea edi, [esp + 0xc]
mov word [esp + 0x18], dx
mov dword [esp + 0xc], 0x2d636367
mov dword [esp], eax
mov dword [esp + 0x10], 0x656d6873
mov dword [esp + 0x14], 0x64742d6d
mov byte [esp + 0x1a], 0x2d
call sym._memcpy
lea eax, [esi + 0x10]
lea edx, [edi + eax]
mov dword [ebp - 0x20], eax
mov dword [edx], 0x61616161
mov dword [edx + 4], 0x61616161
mov dword [edx + 8], 0x61616161
mov dword [edx + 0xc], 0x61616161
mov dword [edx + 0x10], 0x61616161
mov dword [edx + 0x14], 0x61616161
mov dword [edx + 0x18], 0x61616161
mov dword [edx + 0x1c], 0x61616161
mov dword [ebp - 0x24], edx
mov byte [esp + esi + 0x3c], 0
mov byte [esp + esi + 0x1b], 0
mov dword [esp + 8], edi
mov dword [esp + 4], 0
mov dword [esp], 0
call dword [sym.imp.KERNEL32.dll_CreateMutexA]
sub esp, 0xc
mov byte [edi + esi + 0xf], 0x2d
mov dword [ebp - 0x1c], eax
mov dword [esp + 4], 0xffffffff
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
sub esp, 8
test eax, eax
mov edx, dword [ebp - 0x24]
je 0x40f09f
int3
mov dword [ebp - 0x24], edx
mov dword [esp], edi
call dword [sym.imp.KERNEL32.dll_FindAtomA]
sub esp, 4
test ax, ax
mov edx, dword [ebp - 0x24]
jne 0x40f143
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x24], edx
mov dword [esp], eax
call sym._malloc
mov edx, dword [ebp - 0x24]
mov ebx, eax
mov eax, 0x20
bt ebx, eax
jae 0x40f0da
mov byte [edx], 0x41
add edx, 1
sub eax, 1
jne 0x40f0d2
mov dword [esp], edi
call dword [sym.imp.KERNEL32.dll_AddAtomA]
sub esp, 4
test ax, ax
je 0x40f140
lea ecx, [esi + 0x31]
mov esi, dword [ebp - 0x20]
movzx eax, ax
mov edx, edi
mov dword [esp], esi
call dbg.get_ptr_from_atom
cmp eax, ebx
mov esi, eax
je 0x40f15a
mov dword [esp], ebx
call sym._free
mov edi, dword [ebp - 0x1c]
mov dword [esp], edi
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
sub esp, 4
mov dword [esp], edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
sub esp, 4
lea esp, [ebp - 0xc]
mov eax, esi
pop ebx
pop esi
pop edi
pop ebp
ret
int3
lea ecx, [esi + 0x31]
mov esi, dword [ebp - 0x20]
movzx eax, ax
mov edx, edi
mov dword [esp], esi
call dbg.get_ptr_from_atom
mov esi, eax
jmp 0x40f114
mov eax, dword [ebp + 0xc]
mov dword [esp + 4], 0
mov dword [esp], ebx
mov dword [esp + 8], eax
call sym._memset
mov eax, dword [ebp + 0x10]
test eax, eax
je 0x40f114
mov dword [esp], ebx
call dword [ebp + 0x10]
jmp 0x40f114
Function at 0x41b720
Capabilities:
Allocate thread local storage

Disassembly:
push ebx
sub esp, 0x18
mov ebx, dword [0x491e50]
test ebx, ebx
je 0x41b750
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
mov dword [ebx], eax
mov eax, dword [0x491e50]
test eax, eax
je 0x41b775
cmp dword [eax], 0xffffffff
je 0x41b798
add esp, 0x18
pop ebx
ret
mov dword [esp + 8], sym.___shmem_winpthreads_init__pthread_tls_shmem
mov dword [esp + 4], 4
mov dword [esp], str._pthread_tls_shmem
call sym.___shmem_winpthreads_grab
mov ebx, eax
mov dword [0x491e50], eax
jmp 0x41b72e
mov dword [esp + 8], sym.___shmem_winpthreads_init__pthread_tls_shmem
mov dword [esp + 4], 4
mov dword [esp], str._pthread_tls_shmem
call sym.___shmem_winpthreads_grab
mov dword [0x491e50], eax
jmp 0x41b73f
call sym._abort
lea esi, [esi]
Function at 0x41bc30
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x2c
mov eax, dword [0x491e54]
test eax, eax
je 0x41bd84
call sym.__pthread_once_raw.constprop.5
mov eax, dword [0x491e50]
test eax, eax
je 0x41bdb0
mov eax, dword [eax]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
sub esp, 4
test eax, eax
je 0x41bc70
add esp, 0x2c
pop ebx
pop esi
pop edi
pop ebp
ret
call sym._pop_pthread_mem
test eax, eax
mov ebx, eax
je 0x41bdfc
mov eax, dword [entry3]
test eax, eax
je 0x41bdfc
mov dword [ebx + 0x24], 1
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov dword [ebx + 0x38], eax
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 1
mov dword [esp], 0
call dword [sym.imp.KERNEL32.dll_CreateEventA]
mov esi, dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
sub esp, 0x10
mov dword [ebx + 0x18], eax
mov dword [ebx + 0x1c], 0xffffffff
mov dword [ebx + 0x34], 0xffffffff
mov dword [ebx + 0x60], 0
mov dword [ebx + 0x14], 0
call esi
mov ebp, eax
call dword [sym.imp.KERNEL32.dll_GetCurrentThread]
mov edi, eax
call esi
mov edx, eax
lea eax, [ebx + 0x14]
mov dword [esp + 0x18], 2
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], eax
mov dword [esp + 8], ebp
mov dword [esp + 4], edi
mov dword [esp], edx
call dword [sym.imp.KERNEL32.dll_DuplicateHandle]
sub esp, 0x1c
test eax, eax
je 0x41be03
mov eax, dword [ebx + 0x14]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_GetThreadPriority]
mov dword [ebx + 0x68], eax
movzx eax, byte [ebx + 0x20]
sub esp, 4
mov dword [ebx + 0x64], 0
and eax, 0xffffffcf
or eax, 0x10
mov byte [ebx + 0x20], al
mov eax, dword [0x491e50]
test eax, eax
je 0x41bdd6
mov dword [esp + 4], ebx
mov eax, dword [eax]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
sub esp, 8
test eax, eax
je 0x41be03
mov eax, ebx
jmp 0x41bc68
mov dword [esp + 8], 0
mov dword [esp + 4], 4
mov dword [esp], str._pthread_tls_once_shmem
call sym.___shmem_winpthreads_grab
mov dword [0x491e54], eax
jmp 0x41bc44
mov dword [esp + 8], sym.___shmem_winpthreads_init__pthread_tls_shmem
mov dword [esp + 4], 4
mov dword [esp], str._pthread_tls_shmem
call sym.___shmem_winpthreads_grab
mov dword [0x491e50], eax
jmp 0x41bc56
mov dword [esp + 8], sym.___shmem_winpthreads_init__pthread_tls_shmem
mov dword [esp + 4], 4
mov dword [esp], str._pthread_tls_shmem
call sym.___shmem_winpthreads_grab
mov dword [0x491e50], eax
jmp 0x41bd63
xor eax, eax
jmp 0x41bc68
call sym._abort
nop
lea esi, [esi]
Function at 0x41c370
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push esi
push ebx
sub esp, 0x14
cmp dword [esp + 0x24], 3
je 0x41c390
add esp, 0x14
mov eax, 1
pop ebx
pop esi
ret 0xc
mov eax, dword [0x491e50]
test eax, eax
je 0x41c500
mov eax, dword [eax]
cmp eax, 0xffffffff
je 0x41c37c
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
sub esp, 4
test eax, eax
mov ebx, eax
je 0x41c37c
test byte [eax + 0x20], 0x30
je 0x41c450
mov eax, dword [eax + 0xb0]
test eax, eax
jne 0x41c4f0
mov eax, dword [ebx + 0x14]
test eax, eax
je 0x41c400
mov dword [esp], eax
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
mov eax, dword [ebx + 0x18]
sub esp, 4
test eax, eax
je 0x41c3f2
mov dword [esp], eax
call esi
sub esp, 4
mov dword [ebx + 0x18], 0
mov dword [ebx + 0x14], 0
lea eax, [ebx + 0x1c]
mov dword [esp], eax
call sym._pthread_mutex_destroy
mov edx, dword [ebx + 0xac]
mov dword [ebx + 0x34], 0xffffffff
test edx, edx
je 0x41c556
mov eax, dword [0x491e50]
test eax, eax
je 0x41c530
mov dword [esp + 4], 0
mov eax, dword [eax]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
sub esp, 8
mov eax, 1
add esp, 0x14
pop ebx
pop esi
ret 0xc
mov eax, dword [eax + 0x64]
test eax, eax
mov eax, dword [ebx + 0x18]
jne 0x41c4b0
test eax, eax
je 0x41c46a
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
sub esp, 4
mov eax, dword [ebx + 0xb0]
mov dword [ebx + 0x18], 0
mov dword [ebx + 0x64], 1
test eax, eax
jne 0x41c4e0
test byte [ebx + 0x24], 4
je 0x41c4c7
mov eax, dword [ebx + 0x14]
mov dword [ebx], 0xdeadbeef
test eax, eax
je 0x41c3f9
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
sub esp, 4
jmp 0x41c3f9
test eax, eax
je 0x41c4c0
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
sub esp, 4
mov dword [ebx + 0x18], 0
lea eax, [ebx + 0x1c]
mov dword [esp], eax
call sym._pthread_mutex_destroy
mov dword [ebx + 0x34], 0xffffffff
jmp 0x41c37c
call sym.__pthread_cleanup_dest.part.3
jmp 0x41c482
call sym.__pthread_cleanup_dest.part.3
jmp 0x41c3ce
mov dword [esp + 8], sym.___shmem_winpthreads_init__pthread_tls_shmem
mov dword [esp + 4], 4
mov dword [esp], str._pthread_tls_shmem
call sym.___shmem_winpthreads_grab
mov dword [0x491e50], eax
jmp 0x41c39d
mov dword [esp + 8], sym.___shmem_winpthreads_init__pthread_tls_shmem
mov dword [esp + 4], 4
mov dword [esp], str._pthread_tls_shmem
call sym.___shmem_winpthreads_grab
mov dword [0x491e50], eax
jmp 0x41c42d
mov eax, ebx
call sym._push_pthread_mem.part.0
jmp 0x41c420