joyce8/EMBER2024-capa huggingface dataset:
Function at 0x1000fd10
Capabilities:
Query or enumerate registry value
Set registry value

Disassembly:
push ebx
mov ebx, esp
sub esp, 8
and esp, 0xfffffff0
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
sub esp, 0x70
mov eax, dword [0x1001800c]
xor eax, ebp
mov dword [ebp - 4], eax
call fcn.1000fc50
movups xmm0, xmmword [eax]
movups xmmword [ebp - 0x40], xmm0
movups xmm0, xmmword [eax + 0x10]
movups xmmword [ebp - 0x30], xmm0
mov eax, dword [eax + 0x20]
mov dword [ebp - 0x20], eax
lea eax, [ebp - 0x68]
push eax
push 0xf003f
push 0
push 0x1012021e
push closesocket
mov dword [ebp - 0x6c], 0x24
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x1000fdb3
lea eax, [ebp - 0x6c]
push eax
lea eax, [ebp - 0x64]
push eax
push 0
push 0
push str.WindowID
push dword [ebp - 0x68]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
je 0x1000fdc7
push dword [ebp - 0x6c]
lea eax, [ebp - 0x40]
push eax
push 1
push 0
push str.WindowID
push dword [ebp - 0x68]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
push dword [ebp - 0x68]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea eax, [ebp - 0x40]
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.10010f8a
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret
lea ecx, [ebp - 0x40]
lea eax, [ebp - 0x64]
nop dword [eax]
mov dl, byte [eax]
cmp dl, byte [ecx]
jne 0x1000fdf0
test dl, dl
je 0x1000fdec
mov dl, byte [eax + 1]
cmp dl, byte [ecx + 1]
jne 0x1000fdf0
add eax, 2
add ecx, 2
test dl, dl
jne 0x1000fdd0
xor eax, eax
jmp 0x1000fdf5
sbb eax, eax
or eax, 1
test eax, eax
je 0x1000fdaa
mov ecx, dword [ebp - 4]
lea eax, [ebp - 0x64]
xor ecx, ebp
call fcn.10010f8a
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret

Function at 0x1000fe10
Capabilities:
Set registry value

Disassembly:
push ebx
mov ebx, esp
sub esp, 8
and esp, 0xfffffff0
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
sub esp, 0x50
mov eax, dword [0x1001800c]
xor eax, ebp
mov dword [ebp - 4], eax
call fcn.1000fc50
movups xmm0, xmmword [eax]
movups xmmword [ebp - 0x40], xmm0
movups xmm0, xmmword [eax + 0x10]
movups xmmword [ebp - 0x30], xmm0
mov eax, dword [eax + 0x20]
mov dword [ebp - 0x20], eax
lea eax, [ebp - 0x44]
push eax
push 0xf003f
push 0
push 0x1012021e
push closesocket
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x1000fe8d
push 0x24
lea eax, [ebp - 0x40]
push eax
push 1
push 0
push str.WindowID
push dword [ebp - 0x44]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
push dword [ebp - 0x44]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.10010f8a
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret
Function at 0x1000fea0
Capabilities:
Acquire debug privileges

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
mov eax, dword [0x1001800c]
xor eax, ebp
mov dword [ebp - 4], eax
lea eax, [ebp - 0x18]
push eax
push 0x20
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
jne 0x1000fed7
xor al, al
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.10010f8a
mov esp, ebp
pop ebp
ret
lea eax, [ebp - 0x20]
push eax
push str.SeDebugPrivilege
push 0
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
test eax, eax
je 0x1000fec7
mov eax, dword [ebp - 0x20]
xorps xmm0, xmm0
push 0
movups xmmword [ebp - 0x14], xmm0
push 0
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x1c]
push 0x10
mov dword [ebp - 0xc], eax
lea eax, [ebp - 0x14]
push eax
push 0
push dword [ebp - 0x18]
mov dword [ebp - 0x14], 1
mov dword [ebp - 8], 2
call dword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
mov ecx, dword [ebp - 4]
test eax, eax
setne al
xor ecx, ebp
call fcn.10010f8a
mov esp, ebp
pop ebp
ret

Function at 0x1000ff40
Capabilities:
Hide thread from debugger

Disassembly:
push esi
push edi
push str.NtSetInformationThread
push str.ntdll.dll
mov edi, ecx
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov esi, eax
test esi, esi
jne 0x1000ff66
pop edi
xor al, al
pop esi
ret
push 0
push 0
push 0x11
test edi, edi
jne 0x1000ff81
call dword [sym.imp.KERNEL32.dll_GetCurrentThread]
push eax
call esi
test eax, eax
pop edi
sete al
pop esi
ret
push edi
call esi
test eax, eax
pop edi
sete al
pop esi
ret

Function at 0x10010bc0
Capabilities:
Delete registry key

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [0x1011b100]
sub esp, 8
push ebx
push esi
mov esi, dword [0x1011b0fc]
push edi
cmp esi, eax
je 0x10010ca3
mov ebx, dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
cmp byte [esi], 2
jne 0x10010c09
lea eax, [ebp - 8]
mov dword [ebp - 8], 0
push eax
lea eax, [esi + 1]
push eax
push closesocket
call ebx
mov edi, dword [ebp - 8]
test edi, edi
jne 0x10010c1a
mov eax, dword [0x1011b100]
add esi, 0x105
cmp esi, eax
jne 0x10010be2
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov ebx, dword [0x1011b100]
xor ecx, ecx
mov esi, dword [0x1011b0fc]
mov eax, 0x7d8c42b3
mov dword [ebp - 4], ecx
mov ecx, ebx
sub ecx, esi
imul ecx
sar edx, 7
mov eax, edx
shr eax, 0x1f
add eax, edx
je 0x10010c8d
xor edi, edi
cmp byte [edi + esi], 2
jne 0x10010c67
lea eax, [esi + 1]
add eax, edi
push eax
push closesocket
call dword [sym.imp.SHLWAPI.dll_SHDeleteKeyA]
mov ebx, dword [0x1011b100]
mov esi, dword [0x1011b0fc]
inc dword [ebp - 4]
mov ecx, ebx
sub ecx, esi
mov eax, 0x7d8c42b3
imul ecx
add edi, 0x105
sar edx, 7
mov eax, edx
shr eax, 0x1f
add eax, edx
cmp dword [ebp - 4], eax
jb 0x10010c44
mov edi, dword [ebp - 8]
push edi
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor edx, edx
push 0
lea ecx, [edx + 6]
call fcn.10005780
add esp, 4
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x10010ce0
Capabilities:
Enumerate processes
Terminate process

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x13c
mov eax, dword [0x1001800c]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov esi, dword [0x1011b108]
push edi
mov dword [ebp - 0x134], esi
cmp esi, dword [0x1011b10c]
je 0x10010eb9
lea edi, [esi + 1]
movzx eax, byte [esi]
cmp eax, 3
ja case.default.0x10010d1d
jmp dword [eax*4 + 0x10010ecc]
push edi
push 0
call dword [sym.imp.USER32.dll_FindWindowA]
mov dword [ebp - 0x138], eax
test eax, eax
je case.default.0x10010d1d
lea edx, [ebp - 0x134]
mov dword [ebp - 0x134], 0
push edx
push eax
call dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
push dword [ebp - 0x134]
jmp 0x10010ea9
push 0
push edi
push 0
push 0
call dword [sym.imp.USER32.dll_FindWindowExA]
mov dword [ebp - 0x138], eax
test eax, eax
je case.default.0x10010d1d
lea ecx, [ebp - 0x134]
mov dword [ebp - 0x134], 0
push ecx
push eax
call dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
push dword [ebp - 0x134]
jmp 0x10010ea9
push 0
push 2
call dword [sym.imp.KERNEL32.dll_CreateToolhelp32Snapshot]
mov ebx, eax
mov dword [ebp - 0x130], 0x128
lea eax, [ebp - 0x130]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_Process32First]
test eax, eax
je 0x10010e65
mov esi, dword [ebp - 0x138]
nop
mov eax, edi
lea ecx, [ebp - 0x10c]
mov dl, byte [ecx]
cmp dl, byte [eax]
jne 0x10010df8
test dl, dl
je 0x10010df4
mov dl, byte [ecx + 1]
cmp dl, byte [eax + 1]
jne 0x10010df8
add ecx, 2
add eax, 2
test dl, dl
jne 0x10010dd8
xor eax, eax
jmp 0x10010dfd
sbb eax, eax
or eax, 1
test eax, eax
jne 0x10010e49
push dword [ebp - 0x128]
push eax
push 0x1f0fff
call dword [sym.imp.KERNEL32.dll_OpenProcess]
push 0
push eax
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
lea eax, [ebp - 0x13c]
mov dword [ebp - 0x13c], 0
push eax
push esi
call dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
push dword [ebp - 0x13c]
mov edx, edi
mov ecx, 8
call fcn.10005780
add esp, 4
lea eax, [ebp - 0x130]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_Process32Next]
test eax, eax
jne 0x10010dd0
mov esi, dword [ebp - 0x134]
cmp ebx, 0xffffffff
je case.default.0x10010d1d
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp case.default.0x10010d1d
push edi
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
test eax, eax
jne 0x10010ea7
add esi, 0x41
add edi, 0x41
mov dword [ebp - 0x134], esi
cmp esi, dword [0x1011b10c]
jne 0x10010d11
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.10010f8a
mov esp, ebp
pop ebp
ret
push 0
lea edx, [esi + 1]
mov ecx, 8
call fcn.10005780
add esp, 4
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.10010f8a
mov esp, ebp
pop ebp
ret

Function at 0x403d61
Capabilities:
Encode data using xor

Disassembly:
push eax
push ebx
mov eax, 0x499
mov ecx, 0x404498
mov bl, byte [ecx]
sub bl, 0xf2
rol bl, 2
sub bl, cl
ror bl, 1
mov byte [ecx], bl
dec ecx
dec eax
jne 0x403d6d
mov eax, 0x261d
mov ecx, 0x403764
mov bl, byte [ecx]
rol bl, 7
ror bl, 2
sub bl, cl
xor bl, 0x91
mov byte [ecx], bl
dec ecx
dec eax
jne 0x403d8a
pop ebx
pop eax
add ecx, 0x2c1a
jmp ecx
Function at 0x4a2050
Capabilities:
Get disk information

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x57615e
mov eax, dword fs:[0]
push eax
sub esp, 0x304
mov eax, dword [0x5edd38]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, dword [ebp + 0xc]
xor eax, eax
mov esi, dword [ebp + 8]
mov ecx, edi
mov dword [ebp - 0x254], 0
mov dword [ebp - 0x240], 0
mov dword [ebp - 0x23c], 7
mov word [ebp - 0x250], ax
lea edx, [ecx + 2]
nop
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4a20b0
sub ecx, edx
sar ecx, 1
push ecx
push edi
lea ecx, [ebp - 0x250]
call fcn.00408f30
xor eax, eax
mov dword [ebp - 4], 0
mov dword [ebp - 0x228], 0
invalid
test esp, ebx
std
invalid
inc dword [edi]
Function at 0x403d61
Capabilities:
Encode data using xor

Disassembly:
push eax
push ebx
mov eax, 0x499
mov ecx, 0x404498
mov bl, byte [ecx]
sub bl, 0xf2
rol bl, 2
sub bl, cl
ror bl, 1
mov byte [ecx], bl
dec ecx
dec eax
jne 0x403d6d
mov eax, 0x261d
mov ecx, 0x403764
mov bl, byte [ecx]
rol bl, 7
ror bl, 2
sub bl, cl
xor bl, 0x91
mov byte [ecx], bl
dec ecx
dec eax
jne 0x403d8a
pop ebx
pop eax
add ecx, 0x2c1a
jmp ecx

Function at 0x403d61
Capabilities:
Encode data using xor

Disassembly:
push eax
push ebx
mov eax, 0x499
mov ecx, 0x404498
mov bl, byte [ecx]
sub bl, 0xf2
rol bl, 2
sub bl, cl
ror bl, 1
mov byte [ecx], bl
dec ecx
dec eax
jne 0x403d6d
mov eax, 0x261d
mov ecx, 0x403764
mov bl, byte [ecx]
rol bl, 7
ror bl, 2
sub bl, cl
xor bl, 0x91
mov byte [ecx], bl
dec ecx
dec eax
jne 0x403d8a
pop ebx
pop eax
add ecx, 0x2c1a
jmp ecx

Function at 0x4659a0
Capabilities:
Packed with generic packer

Disassembly:
pushal
mov esi, 0x457015
lea edi, [esi - 0x56015]
push edi
or ebp, 0xffffffff
jmp 0x4659c2
mov al, byte [esi]
inc esi
mov byte [edi], al
inc edi
add ebx, ebx
jne 0x4659c9
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x4659b8
mov eax, 1
add ebx, ebx
jne 0x4659db
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
add ebx, ebx
jae 0x4659d0
jne 0x4659ec
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jae 0x4659d0
xor ecx, ecx
sub eax, 3
jb 0x465a00
shl eax, 8
mov al, byte [esi]
inc esi
xor eax, 0xffffffff
je 0x465a72
mov ebp, eax
add ebx, ebx
jne 0x465a0b
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
jne 0x465a18
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
jne 0x465a3c
inc ecx
add ebx, ebx
jne 0x465a28
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
jae 0x465a1d
jne 0x465a39
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jae 0x465a1d
add ecx, 2
cmp ebp, 0xfffff300
adc ecx, 1
lea edx, [edi + ebp]
cmp ebp, 0xfffffffc
jbe 0x465a5c
mov al, byte [edx]
inc edx
mov byte [edi], al
inc edi
dec ecx
jne 0x465a4d
jmp 0x4659be
mov eax, dword [edx]
add edx, 4
mov dword [edi], eax
add edi, 4
sub ecx, 4
ja 0x465a5c
add edi, ecx
jmp 0x4659be
pop esi
mov edi, esi
mov ecx, 0x33e
mov al, byte [edi]
inc edi
sub al, 0xe8
cmp al, 1
ja 0x465a7a
cmp byte [edi], 0
jne 0x465a7a
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 eax, ebx
loop 0x465a7f
lea edi, [esi + 0x63000]
mov eax, dword [edi]
or eax, eax
je 0x465aee
mov ebx, dword [edi + 4]
lea eax, [eax + esi + 0x651f0]
add ebx, esi
push eax
add edi, 8
call dword [esi + 0x65254]
xchg ebp, eax
mov al, byte [edi]
inc edi
or al, al
je 0x465aac
mov ecx, edi
push edi
dec eax
repne scasb al, byte es:[edi]
push ebp
call dword [esi + 0x65258]
or eax, eax
je 0x465ae8
mov dword [ebx], eax
add ebx, 4
jmp 0x465ac9
call dword [esi + 0x6525c]
popal
jmp 0x40da18
Function at 0x40ce80
Capabilities:
Get thread local storage value

Disassembly:
push esi
push ebx
sub esp, 0x14
mov dword [esp], 0x4fdd08
call sym._EnterCriticalSection_4
mov ebx, dword [0x4fdd00]
sub esp, 4
test ebx, ebx
je 0x40cecb
nop
mov eax, dword [ebx]
mov dword [esp], eax
call sym._TlsGetValue_4
sub esp, 4
mov esi, eax
call sym._GetLastError_0
test eax, eax
jne 0x40cec4
test esi, esi
je 0x40cec4
mov eax, dword [ebx + 4]
mov dword [esp], esi
call eax
mov ebx, dword [ebx + 8]
test ebx, ebx
jne 0x40cea0
mov dword [esp], 0x4fdd08
call sym._LeaveCriticalSection_4
sub esp, 4
add esp, 0x14
pop ebx
pop esi
ret

Function at 0x40d0b0
Capabilities:
Write file on windows

Disassembly:
push esi
push ebx
sub esp, 0x14
mov eax, dword [sym.imp.msvcrt.dll__iob]
mov dword [esp + 8], 0x17
lea esi, [esp + 0x24]
lea ebx, [eax + 0x40]
mov dword [esp + 4], 1
mov dword [esp + 0xc], ebx
mov dword [esp], str.Mingw_runtime_failure:_n
call sym._fwrite
mov eax, dword [esp + 0x20]
mov dword [esp + 8], esi
mov dword [esp], ebx
mov dword [esp + 4], eax
call sym._vfprintf
call sym._abort
lea esi, [esi]

Function at 0x40d100
Capabilities:
Allocate or change rwx memory

Disassembly:
push ebp
push edi
mov edi, edx
push esi
mov esi, ecx
push ebx
mov ebx, eax
sub esp, 0x3c
lea eax, [esp + 0x14]
mov dword [esp + 8], 0x1c
mov dword [esp + 4], eax
mov dword [esp], ebx
call sym._VirtualQuery_12
sub esp, 0xc
test eax, eax
je 0x40d1d4
mov eax, dword [esp + 0x28]
cmp eax, 0x40
je 0x40d13e
cmp eax, 4
jne 0x40d160
test esi, esi
je 0x40d152
xor eax, eax
movzx ecx, byte [edi + eax]
mov byte [ebx + eax], cl
add eax, 1
cmp eax, esi
jb 0x40d144
add esp, 0x3c
pop ebx
pop esi
pop edi
pop ebp
ret
mov eax, dword [esp + 0x20]
lea ebp, [esp + 0x10]
mov dword [esp + 8], 0x40
mov dword [esp + 0xc], ebp
mov dword [esp + 4], eax
mov eax, dword [esp + 0x14]
mov dword [esp], eax
call sym._VirtualProtect_16
sub esp, 0x10
mov ecx, dword [esp + 0x28]
test esi, esi
je 0x40d19f
xor edx, edx
movzx eax, byte [edi + edx]
mov byte [ebx + edx], al
add edx, 1
cmp edx, esi
jb 0x40d191
cmp ecx, 0x40
je 0x40d152
cmp ecx, 4
je 0x40d152
mov eax, dword [esp + 0x10]
mov dword [esp + 0xc], ebp
mov dword [esp + 8], eax
mov eax, dword [esp + 0x20]
mov dword [esp + 4], eax
mov eax, dword [esp + 0x14]
mov dword [esp], eax
call sym._VirtualProtect_16
sub esp, 0x10
add esp, 0x3c
pop ebx
pop esi
pop edi
pop ebp
ret
mov dword [esp + 8], ebx
mov dword [esp + 4], 0x1c
mov dword [esp], str.__VirtualQuery_failed_for__d_bytes_at_address__p
call fcn.0040d0b0
lea esi, [esi]
Function at 0x416a60
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push edi
xor edi, edi
push esi
push ebx
sub esp, 0x3c
mov dword [esp + 4], 0
mov dword [esp], 2
call sym._setlocale
test eax, eax
je 0x416b34
mov dword [esp], eax
mov esi, eax
mov ebx, esp
call sym._strlen
lea edx, [eax + 1]
add eax, 0x10
shr eax, 4
shl eax, 4
call fcn.004189b0
sub esp, eax
lea eax, [esp + 0xc]
mov dword [esp + 8], edx
mov dword [esp + 4], esi
mov dword [esp], eax
call sym._memcpy
mov dword [esp + 4], 0x4b8004
mov dword [esp], 2
mov esi, eax
call sym._setlocale
mov dword [esp], esi
mov dword [esp + 4], eax
call sym._strcmp
test eax, eax
je 0x416b40
mov dword [esp + 4], esi
mov dword [esp], 2
call sym._setlocale
mov eax, esi
mov dword [esp + 4], 0x2e
mov dword [esp], eax
call sym._strchr
test eax, eax
je 0x416b30
add eax, 1
mov dword [esp], eax
call sym._atoi
mov edi, eax
lea eax, [ebp - 0x2c]
mov dword [esp + 4], eax
mov dword [esp], edi
call sym._GetCPInfo_8
sub esp, 8
test eax, eax
je 0x416b30
mov eax, dword [ebp - 0x2c]
test eax, eax
jne 0x416b80
xor edi, edi
mov esp, ebx
lea esp, [ebp - 0xc]
mov eax, edi
pop ebx
pop esi
pop edi
pop ebp
ret
mov dword [esp], str.LC_ALL
call sym._getenv
test eax, eax
jne 0x416af2
mov dword [esp], str.LC_CTYPE
call sym._getenv
test eax, eax
jne 0x416af2
mov dword [esp], str.LANG
call sym._getenv
test eax, eax
jne 0x416af2
mov eax, esi
jmp 0x416af2
mov esp, ebx
jmp 0x416b34

Function at 0x418d30
Capabilities:
Get thread local storage value

Disassembly:
push esi
push ebx
sub esp, 0x14
call sym._GetLastError_0
mov esi, eax
mov eax, dword [esp + 0x20]
mov dword [esp], eax
call sym._TlsGetValue_4
sub esp, 4
mov ebx, eax
mov dword [esp], esi
call sym._SetLastError_4
mov eax, ebx
sub esp, 4
add esp, 0x14
pop ebx
pop esi
ret

Function at 0x418d60
Capabilities:
Set thread local storage value

Disassembly:
sub esp, 0x1c
mov eax, dword [esp + 0x24]
mov dword [esp + 4], eax
mov eax, dword [esp + 0x20]
mov dword [esp], eax
call sym._TlsSetValue_8
sub esp, 8
test eax, eax
je 0x418d88
xor eax, eax
add esp, 0x1c
ret
add esp, 0x1c
jmp sym._GetLastError_0
Function at 0x41cf70
Capabilities:
Allocate thread local storage

Disassembly:
sub esp, 0x1c
mov dword [0x4fe724], 0xffffffff
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0xffff
mov dword [esp + 4], 0
mov dword [esp], 0
call sym._CreateSemaphoreW_16
sub esp, 0x10
mov dword [0x4fe728], eax
call sym._TlsAlloc_0
cmp eax, 0xffffffff
je 0x41cfd8
mov dword [esp + 4], dbg.emutls_destroy
mov dword [esp], eax
mov dword [0x4fe720], eax
call sym.___mingwthr_key_dtor
test eax, eax
jne sym._emutls_init.cold
add esp, 0x1c
ret
call sym._GetLastError_0
jmp 0x41cfc8
Function at 0x41cfe0
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x2c
mov ebp, dword [0x4fdcec]
mov esi, dword [esp + 0x40]
test ebp, ebp
jne 0x41d008
mov eax, dword [esi + 8]
test eax, eax
je 0x41d060
add esp, 0x2c
pop ebx
pop esi
pop edi
pop ebp
ret
mov edi, dword [esi + 8]
test edi, edi
je 0x41d070
mov ebx, dword [0x4fe720]
call sym._GetLastError_0
mov dword [esp], ebx
mov ebp, eax
call sym._TlsGetValue_4
sub esp, 4
mov ebx, eax
mov dword [esp], ebp
call sym._SetLastError_4
sub esp, 4
test ebx, ebx
je 0x41d100
mov ebp, dword [ebx]
cmp ebp, edi
jb 0x41d150
lea ebx, [ebx + edi*4]
mov eax, dword [ebx]
test eax, eax
jne 0x41cffc
mov eax, esi
call sym._emutls_alloc
mov dword [ebx], eax
jmp 0x41cffc
mov eax, esi
call sym._emutls_alloc
mov dword [esi + 8], eax
jmp 0x41cffc
mov edi, dword [0x4fdcec]
test edi, edi
je 0x41d1d8
mov ebx, dword [0x4b20a8]
test ebx, ebx
je 0x41d1a8
mov dword [esp], 0x4fe724
call sym._InterlockedIncrement_4
sub esp, 4
test eax, eax
jne 0x41d21b
mov edi, dword [esi + 8]
test edi, edi
je 0x41d1e3
mov eax, dword [0x4fdcec]
test eax, eax
je 0x41d00f
mov dword [esp], 0x4fe724
call sym._InterlockedDecrement_4
sub esp, 4
test eax, eax
js 0x41d00f
mov eax, dword [0x4fe728]
mov dword [esp + 8], 0
mov dword [esp + 4], 1
mov dword [esp], eax
call sym._ReleaseSemaphore_12
sub esp, 0xc
jmp 0x41d00f
lea eax, [edi + 0x21]
mov dword [esp + 4], 4
lea ebp, [edi + 0x20]
mov dword [esp], eax
call sym._calloc
mov ebx, eax
test eax, eax
je sym.___emutls_get_address.cold
mov dword [eax], ebp
mov eax, dword [0x4fe720]
mov dword [esp + 4], ebx
mov dword [esp], eax
call sym._TlsSetValue_8
sub esp, 8
test eax, eax
jne 0x41d046
call sym._GetLastError_0
jmp 0x41d046
lea edx, [ebp + ebp]
cmp edi, edx
jbe 0x41d15b
lea edx, [edi + 0x20]
lea eax, [edx*4 + 4]
mov dword [esp], ebx
mov dword [esp + 4], eax
mov dword [esp + 0x1c], edx
call sym.___mingw_realloc
mov ebx, eax
test eax, eax
je sym.___emutls_get_address.cold
mov edx, dword [esp + 0x1c]
mov dword [eax], edx
sub edx, ebp
lea eax, [eax + ebp*4 + 4]
shl edx, 2
mov dword [esp + 4], 0
mov dword [esp + 8], edx
mov dword [esp], eax
call sym._memset
jmp 0x41d122
mov dword [esp], 0x4b20ac
call sym._InterlockedIncrement_4
sub esp, 4
test eax, eax
jne 0x41d20f
call sym._emutls_init
mov dword [0x4b20a8], 1
mov edx, dword [0x4fdcec]
test edx, edx
jne 0x41d08c
mov edi, dword [esi + 8]
test edi, edi
jne 0x41d00f
mov eax, dword [0x4fe71c]
lea edi, [eax + 1]
mov dword [0x4fe71c], edi
mov dword [esi + 8], edi
jmp 0x41d0ae
mov dword [esp], 0
call sym._Sleep_4
sub esp, 4
mov ecx, dword [0x4b20a8]
test ecx, ecx
je 0x41d200
jmp 0x41d1ca
mov eax, dword [0x4fe728]
mov dword [esp + 4], 0xffffffff
mov dword [esp], eax
call sym._WaitForSingleObject_8
sub esp, 8
test eax, eax
je 0x41d0a3
mov dword [esp], 0x4fe724
call sym._InterlockedDecrement_4
sub esp, 4
jmp 0x41d0a3
Function at 0x420430
Capabilities:
Write file on windows

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x2c
cmp byte [0x4b3b1c], 0
jne method.__gnu_cxx.__verbose_terminate_handler____clone_.cold_
mov byte [0x4b3b1c], 1
call sym.___cxa_current_exception_type
test eax, eax
je 0x4aabbe
mov ebx, dword [eax + 4]
xor eax, eax
cmp byte [ebx], 0x2a
mov dword [esp + 8], 0
sete al
mov dword [esp + 4], 0
add ebx, eax
lea eax, [esp + 0x1c]
mov dword [esp + 0x1c], 0xffffffff
mov dword [esp + 0xc], eax
mov dword [esp], ebx
call sym.___cxa_demangle
mov edi, dword [sym.imp.msvcrt.dll__iob]
mov dword [esp + 8], 0x30
mov dword [esp + 4], 1
mov esi, eax
lea ebp, [edi + 0x40]
mov dword [esp], str.terminate_called_after_throwing_an_instance_of_
mov dword [esp + 0xc], ebp
call sym._fwrite
mov edx, dword [esp + 0x1c]
mov dword [esp + 4], ebp
test edx, edx
jne 0x420508
mov dword [esp], esi
call sym._fputs
lea eax, [edi + 0x40]
mov dword [esp + 8], 2
mov dword [esp + 0xc], eax
mov dword [esp + 4], 1
mov dword [esp], 0x4b5845
call sym._fwrite
mov eax, dword [esp + 0x1c]
test eax, eax
jne 0x4aabb9
mov dword [esp], esi
call sym.___mingw_aligned_free
jmp 0x4aabb9
mov dword [esp], ebx
call sym._fputs
jmp 0x4204cc