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

Disassembly:
push rbp
mov rbp, rsp
push rsi
push rbx
sub rsp, 0x20
mov qword [rbp + 0x10], rcx
call sym._fpreset
lea rcx, [0x140072138]
call sym.pthread_mutex_lock
mov rax, qword [rbp + 0x10]
lea rbx, [rax + 0x38]
mov rcx, rbx
call sym.pthread_mutex_lock
call sym._pthread_once_raw.constprop.0.isra.0
mov rdx, qword [rbp + 0x10]
mov ecx, dword [0x140072148]
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov rsi, qword [rbp + 0x10]
mov rcx, rbx
mov dword [rsi + 0x70], eax
call sym.pthread_mutex_unlock
mov rax, qword [rbp + 0x10]
mov rdx, rbp
lea rcx, [rax + 0xd0]
call sym._setjmp
test eax, eax
jne 0x14001049b
lea rcx, [0x140072138]
mov ebx, pe_nt_image_headers64
call sym.pthread_mutex_unlock
mov rax, qword [rbp + 0x10]
mov rax, qword [rax + 0x10]
test rax, rax
je 0x140010456
mov rdx, qword [rbp + 0x10]
mov rcx, qword [rdx + 8]
call rax
mov rbx, rax
nop
nop
lea rcx, [0x140072138]
call sym.pthread_mutex_lock
mov rax, qword [rbp + 0x10]
mov qword [rax + 8], rbx
mov rcx, qword [rax + 0x1d8]
call sym._pthread_cleanup_dest
mov rax, qword [rbp + 0x10]
lea rbx, [rax + 0x38]
mov rcx, rbx
call sym.pthread_mutex_lock
mov rax, qword [rbp + 0x10]
mov rcx, qword [rax + 0x30]
mov rsi, qword [rax + 8]
test rcx, rcx
jne 0x1400104a9
jmp 0x1400104af
lea rcx, [0x140072138]
call sym.pthread_mutex_lock
jmp 0x140010478
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rax, qword [rbp + 0x10]
xor edx, edx
cmp qword [rax + 0x28], 0
mov qword [rax + 0x30], rdx
jne 0x1400104f3
mov rax, qword [rbp + 0x10]
mov rcx, rbx
mov dword [rax], 0xdeadbeef
call sym.pthread_mutex_unlock
mov rcx, rbx
call sym.pthread_mutex_destroy
mov rcx, qword [rbp + 0x10]
call sym.push_pthread_mem
mov ecx, dword [0x140072148]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
jmp 0x140010519
mov rcx, rbx
call sym.pthread_mutex_unlock
mov rcx, rbx
call sym.pthread_mutex_destroy
mov rax, qword [rbp + 0x10]
mov qword [rax + 0x38], 0xffffffffffffffff
mov dword [rax + 0xbc], 1
lea rbx, [0x140072138]
mov rcx, rbx
call sym.pthread_mutex_unlock
test eax, eax
jne 0x140010536
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x140010520
mov ecx, esi
call qword [sym.imp.msvcrt.dll__endthreadex]
nop
Function at 0x14001068f
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push rsi
push rbx
sub rsp, 0x28
mov rsi, rcx
call sym.__pthread_self_lite
mov qword [rax + 8], rsi
mov rcx, qword [rax + 0x1d8]
mov rbx, rax
call sym._pthread_cleanup_dest
test byte [rbx + 0x40], 0x30
jne 0x1400106c8
lea rcx, [rbx + 0xd0]
mov edx, 1
call qword [sym.imp.msvcrt.dll_longjmp]
mov ecx, dword [0x140072148]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rbx, rax
test rax, rax
je 0x140010753
cmp qword [rax + 0x28], 0
mov rcx, qword [rax + 0x30]
jne 0x140010703
mov dword [rax], 0xdeadbeef
test rcx, rcx
je 0x1400106f8
call qword [sym.imp.KERNEL32.dll_CloseHandle]
xor ecx, ecx
mov esi, dword [rbx + 8]
mov qword [rbx + 0x30], rcx
jmp 0x14001073d
mov dword [rax + 0xbc], 1
mov esi, dword [rax + 8]
test rcx, rcx
je 0x14001071b
call qword [sym.imp.KERNEL32.dll_CloseHandle]
xor edx, edx
mov qword [rbx + 0x30], rdx
test byte [rbx + 0x44], 4
je 0x140010753
mov dword [rbx], 0xdeadbeef
mov rcx, qword [rbx + 0x28]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
mov qword [rbx + 0x28], rax
mov rcx, rbx
call sym.push_pthread_mem
mov ecx, dword [0x140072148]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
mov ecx, esi
call qword [sym.imp.msvcrt.dll__endthreadex]
nop
Function at 0x140010988
Capabilities:
Hijack thread execution

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x4f8
mov rdi, rcx
call sym.__pth_gpointer_locked
mov rbx, rax
test rax, rax
je 0x140010b2d
mov rcx, qword [rax + 0x28]
lea rax, [rcx - 1]
cmp rax, 0xfffffffffffffffd
ja 0x140010b2d
lea rbp, [rsp + 0x20]
mov rdx, rbp
call qword [sym.imp.KERNEL32.dll_GetHandleInformation]
test eax, eax
je 0x140010b2d
lea rsi, [rbx + 0x38]
mov rcx, rsi
call sym.pthread_mutex_lock
call sym.pthread_self
cmp rax, rdi
mov al, byte [rbx + 0x40]
jne 0x140010a3a
test al, 3
jne 0x140010a4c
and eax, 0xfffffffc
or eax, 1
mov byte [rbx + 0x40], al
lock inc dword [0x14009ed28]
mov rcx, qword [rbx + 0x30]
test rcx, rcx
je 0x140010a0b
call qword [sym.imp.KERNEL32.dll_SetEvent]
mov eax, dword [rbx + 0x44]
mov edx, eax
not edx
and dl, 3
jne 0x140010b20
and eax, 0xfffffffe
mov rcx, rsi
mov dword [rbx + 0x44], eax
mov al, byte [rbx + 0x40]
and eax, 0xfffffff3
or eax, 4
mov byte [rbx + 0x40], al
call sym.pthread_mutex_unlock
call sym._pthread_invoke_cancel
mov edx, dword [rbx + 0x44]
not edx
and dl, 3
jne 0x140010af9
test al, 0xc
je 0x140010a65
mov rcx, rsi
call sym.pthread_mutex_unlock
test byte [rbx + 0x40], 0xc
jne 0x140010b2d
xor eax, eax
jmp 0x140010b32
test al, 0xf
jne 0x140010b2d
mov rcx, qword [rbx + 0x28]
mov dword [rsp + 0x50], 0x100001
call qword [sym.imp.KERNEL32.dll_SuspendThread]
xor edx, edx
mov rcx, qword [rbx + 0x28]
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0x102
jne 0x140010b20
mov rcx, qword [rbx + 0x28]
mov rdx, rbp
call qword [sym.imp.KERNEL32.dll_GetThreadContext]
lea rax, [sym._pthread_invoke_cancel]
mov rcx, qword [rbx + 0x28]
mov rdx, rbp
mov qword [rsp + 0x118], rax
call qword [sym.imp.KERNEL32.dll_SetThreadContext]
mov al, byte [rbx + 0x40]
and dword [rbx + 0x44], 0xfffffffe
and eax, 0xfffffff0
or eax, 5
mov byte [rbx + 0x40], al
lock inc dword [0x14009ed28]
mov rcx, qword [rbx + 0x30]
test rcx, rcx
je 0x140010ae5
call qword [sym.imp.KERNEL32.dll_SetEvent]
mov rcx, rsi
call sym.pthread_mutex_unlock
mov rcx, qword [rbx + 0x28]
call qword [sym.imp.KERNEL32.dll_ResumeThread]
jmp 0x140010b20
test al, 3
jne 0x140010a4c
and eax, 0xfffffffc
or eax, 1
mov byte [rbx + 0x40], al
lock inc dword [0x14009ed28]
mov rcx, qword [rbx + 0x30]
test rcx, rcx
je 0x140010b20
call qword [sym.imp.KERNEL32.dll_SetEvent]
mov rcx, rsi
call sym.pthread_mutex_unlock
jmp 0x140010a5e
mov eax, 3
add rsp, 0x4f8
pop rbx
pop rsi
pop rdi
pop rbp
ret
Function at 0x140010b3e
Capabilities:
Hijack thread execution
Resume thread
Suspend thread

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x20
lea rdi, [0x140072138]
mov rsi, rcx
mov rcx, rdi
mov ebx, edx
call sym.pthread_mutex_lock
mov rcx, rsi
call sym.__pthread_get_pointer
test rax, rax
je 0x140010b8b
cmp qword [rax + 0x1d8], rsi
jne 0x140010b8b
test byte [rax + 0x40], 0xc
jne 0x140010b8b
cmp dword [rax + 0xbc], 0
jne 0x140010b8b
mov rax, qword [rax + 0x28]
dec rax
cmp rax, 0xfffffffffffffffd
jbe 0x140010b9a
mov rcx, rdi
mov ebx, 3
call sym.pthread_mutex_unlock
jmp 0x140010bc2
mov rcx, rdi
call sym.pthread_mutex_unlock
test ebx, ebx
je 0x140010bc2
sub ebx, 2
cmp ebx, 0x15
ja 0x140010bbd
mov rcx, rsi
add rsp, 0x20
pop rbx
pop rsi
pop rdi
jmp sym.pthread_cancel
mov ebx, 0x16
mov eax, ebx
add rsp, 0x20
pop rbx
pop rsi
pop rdi
ret
Function at 0x140010d8b
Capabilities:
Create thread
Resume thread

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x30
mov rdi, rcx
mov rsi, rdx
mov rbp, r8
mov r12, r9
call sym.pop_pthread_mem
mov rbx, rax
test rax, rax
je 0x140010e5f
test rdi, rdi
je 0x140010dc1
mov rax, qword [rax + 0x1d8]
mov qword [rdi], rax
xor r11d, r11d
mov dword [rbx + 0x44], 1
mov dword [rbx + 0xbc], r11d
mov qword [rbx + 0x28], 0xffffffffffffffff
mov qword [rbx + 8], r12
mov r12, qword [sym.imp.KERNEL32.dll_CreateEventA]
mov qword [rbx + 0x10], rbp
xor ebp, ebp
xor r9d, r9d
xor r8d, r8d
mov edx, 1
xor ecx, ecx
call r12
mov qword [rbx + 0x30], rax
test rax, rax
jne 0x140010e1a
mov eax, ebp
neg eax
sbb ecx, ecx
inc ebp
and ecx, 0x14
call qword [sym.imp.KERNEL32.dll_Sleep]
cmp ebp, 5
jne 0x140010deb
mov qword [rbx + 0x38], 0xffffffffffffffff
lea r12, [rbx + 0x68]
mov rcx, r12
call sym.replace_spin_keys.constprop.0
xor r10d, r10d
cmp qword [rbx + 0x30], 0
mov dword [rbx], 0xbab1f00d
mov dword [rbx + 0xc0], r10d
mov dword [rbx + 0xb8], r10d
jne 0x140010e69
test rdi, rdi
je 0x140010e57
xor r9d, r9d
mov qword [rdi], r9
mov rcx, rbx
call sym.push_pthread_mem
mov eax, 0xb
jmp 0x140010f6c
xor ebp, ebp
test rsi, rsi
je 0x140010e95
mov eax, dword [rsi]
mov rbp, qword [rsi + 0x10]
mov dword [rbx + 0x44], eax
test al, 8
je 0x140010e90
call sym.__pthread_self_lite
mov eax, dword [rax + 0xc0]
mov dword [rbx + 0xc0], eax
jmp 0x140010e95
mov eax, dword [rsi + 0x18]
jmp 0x140010e88
xor r8d, r8d
mov dword [rsp + 0x20], 4
mov r9, rbx
mov edx, ebp
mov qword [rsp + 0x28], r8
xor ecx, ecx
lea r8, [sym.pthread_create_wrapper]
call qword [sym.imp.msvcrt.dll__beginthreadex]
mov rsi, rax
lea rax, [rax - 1]
cmp rax, 0xfffffffffffffffd
jbe 0x140010ef5
mov rcx, qword [rbx + 0x30]
test rcx, rcx
je 0x140010ed5
call qword [sym.imp.KERNEL32.dll_CloseHandle]
lea rcx, [rbx + 0x38]
call sym.pthread_mutex_destroy
mov rcx, r12
call sym.replace_spin_keys.constprop.0
xor ecx, ecx
mov qword [rbx + 0x30], rcx
mov qword [rbx + 0x28], rcx
jmp 0x140010e4c
mov eax, dword [rbx + 0xc0]
mov edx, 0xfffffff1
cmp eax, 0xfffffff2
jl 0x140010f23
mov edx, 0xfffffffe
cmp eax, 0xffffffff
jl 0x140010f23
mov edx, 0xf
cmp eax, 0xe
jg 0x140010f23
mov edx, 2
cmp eax, edx
cmovle edx, eax
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_SetThreadPriority]
mov rcx, qword [rbx + 0x30]
call qword [sym.imp.KERNEL32.dll_ResetEvent]
test byte [rbx + 0x44], 4
mov rax, qword [sym.imp.KERNEL32.dll_ResumeThread]
je 0x140010f59
xor edx, edx
mov rcx, rsi
mov qword [rbx + 0x28], rdx
call rax
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x140010f62
mov qword [rbx + 0x28], rsi
mov rcx, rsi
call rax
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_Sleep]
xor eax, eax
add rsp, 0x30
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
Function at 0x14004e090
Capabilities:
Read file on windows

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x28
mov rbx, rcx
mov rsi, rdx
mov rdi, r8
mov rcx, rbx
call method.std::__basic_file_char_.fd__
mov r8d, edi
mov rdx, rsi
mov ecx, eax
call sym.read
movsxd rbp, eax
inc eax
jne 0x14004e0c8
call qword [sym.imp.msvcrt.dll__errno]
cmp dword [rax], 4
je 0x14004e0a1
mov rax, rbp
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
ret

Function at 0x140059ce0
Capabilities:
Read file on windows

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x30
mov rax, qword [rcx + 8]
mov rbx, rcx
test rax, rax
je 0x140059d00
mov rcx, qword [rcx]
add rsp, 0x30
pop rbx
pop rsi
pop rdi
jmp rax
mov esi, 4
lea rdi, [rsp + 0x2c]
mov ecx, dword [rbx + 0x10]
mov r8d, esi
mov rdx, rdi
call sym.read
test eax, eax
jle 0x140059d32
cdqe
add rdi, rax
sub rsi, rax
jne 0x140059d0a
mov eax, dword [rsp + 0x2c]
add rsp, 0x30
pop rbx
pop rsi
pop rdi
ret
inc eax
je 0x140059d42
lea rcx, str.random_device_could_not_be_read
call method.std.__throw_runtime_error_char_const_
call qword [sym.imp.msvcrt.dll__errno]
cmp dword [rax], 4
je 0x140059d0a
jmp 0x140059d36
Function at 0x14005e660
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
mov rsi, rcx
mov ecx, dword [rcx]
mov rbx, rdx
mov eax, ecx
not eax
test ax, 0x101
jne 0x14005e680
add dword [rdx + 8], 0xc
mov r9b, byte [rsi]
test r9b, r9b
jns 0x14005e6ab
xor edx, edx
test byte [rsi + 1], 2
je 0x14005e69d
mov eax, dword [rbx + 0x14]
mov r8d, 0x64
cdq
idiv r8d
mov eax, dword [rsi + 4]
sub eax, 0x13
imul eax, eax, 0x64
add eax, edx
mov dword [rbx + 0x14], eax
and cx, 0x402
cmp cx, 0x400
jne 0x14005e756
mov eax, r9d
not eax
test al, 0x18
je 0x14005e73a
test r9d, 4
je 0x14005e73a
mov eax, dword [rbx + 0x14]
lea r11, [0x140079520]
xor r10d, r10d
lea ecx, [rax + 0x76c]
call method.std._anonymous_namespace_::is_leap_int_
mov ecx, dword [rbx + 0x1c]
mov r8, rax
neg r8
and r8d, 0x1a
add r8, r11
movzx edi, word [r8 + r10*2]
mov rdx, r10
lea r10, [r10 + 1]
cmp edi, ecx
jle 0x14005e6f5
test r9d, 8
jne 0x14005e716
lea r8d, [rdx - 1]
mov dword [rbx + 0x10], r8d
and r9d, 0x10
jne 0x14005e737
movzx eax, al
dec edx
imul rax, rax, 0xd
movsxd rdx, edx
add rax, rdx
movzx eax, word [r11 + rax*2]
sub ecx, eax
inc ecx
mov dword [rbx + 0xc], ecx
or byte [rsi], 0x18
mov edx, dword [rbx + 0x10]
test byte [rsi], 8
jne 0x14005e747
cmp edx, 0xb
ja 0x14005e756
mov ecx, dword [rbx + 0x14]
mov r8d, dword [rbx + 0xc]
call method.std._anonymous_namespace_::day_of_the_week_int__int__int_
mov dword [rbx + 0x18], eax
mov eax, dword [rsi]
mov dil, byte [rsi]
and ax, 0x404
cmp ax, 0x400
jne 0x14005e7a4
movsxd r9, dword [rbx + 0x10]
test edi, 8
jne 0x14005e777
cmp r9d, 0xb
ja 0x14005e7a4
mov eax, dword [rbx + 0x14]
lea ecx, [rax + 0x76c]
call method.std._anonymous_namespace_::is_leap_int_
lea rcx, [0x140079520]
mov edx, dword [rbx + 0xc]
movzx eax, al
imul rax, rax, 0xd
add rax, r9
movzx eax, word [rcx + rax*2]
lea eax, [rdx + rax - 1]
mov dword [rbx + 0x1c], eax
test edi, 0x60
je 0x14005e887
test edi, 2
je 0x14005e887
mov ebp, dword [rbx + 0x14]
test edi, 4
jne 0x14005e819
mov r12d, edi
mov r8d, 1
xor edx, edx
mov ecx, ebp
call method.std._anonymous_namespace_::day_of_the_week_int__int__int_
shr r12b, 5
mov r8d, 7
xor r12d, 1
and r12d, 1
sub eax, r12d
mov edx, eax
mov eax, r8d
sub eax, edx
cdq
idiv r8d
mov al, byte [rsi + 2]
and eax, 0x3f
dec eax
imul eax, eax, 7
lea ecx, [rdx + rax]
mov eax, dword [rbx + 0x18]
sub eax, r12d
add eax, 7
cdq
idiv r8d
add ecx, edx
mov dword [rbx + 0x1c], ecx
mov eax, edi
not eax
test al, 0x18
je 0x14005e887
lea ecx, [rbp + 0x76c]
lea r10, [0x140079520]
xor r9d, r9d
call method.std._anonymous_namespace_::is_leap_int_
mov ecx, dword [rbx + 0x1c]
mov r8, rax
neg r8
and r8d, 0x1a
add r8, r10
movzx r11d, word [r8 + r9*2]
mov rdx, r9
lea r9, [r9 + 1]
cmp r11d, ecx
jle 0x14005e846
test edi, 8
jne 0x14005e867
lea r8d, [rdx - 1]
mov dword [rbx + 0x10], r8d
and edi, 0x10
jne 0x14005e887
movzx eax, al
dec edx
imul rax, rax, 0xd
movsxd rdx, edx
add rax, rdx
movzx eax, word [r10 + rax*2]
sub ecx, eax
inc ecx
mov dword [rbx + 0xc], ecx
add rsp, 0x20
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
Function at 0x140070c80
Capabilities:
Query environment variable

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x88
xor edx, edx
lea rcx, [0x140072760]
call sym.pthread_mutex_init
xor r8d, r8d
lea rbp, [rsp + 0x40]
lea rcx, str.GLIBCXX_TUNABLES
mov qword [0x140072768], r8
mov qword [0x140072770], r8
mov qword [0x140072778], r8
call sym.getenv
xor r9d, r9d
mov dword [rsp + 0x78], 0x100
mov rbx, rax
lea rax, str.glibcxx.eh_pool
mov dword [rsp + 0x60], r9d
mov qword [rsp + 0x48], rax
lea rax, str.obj_size
mov qword [rsp + 0x58], rax
lea rax, str.obj_count
mov qword [rsp + 0x40], 0xf
mov qword [rsp + 0x50], 8
mov qword [rsp + 0x68], 9
mov qword [rsp + 0x70], rax
test rbx, rbx
je 0x140070dc7
cmp byte [rbx], 0x3a
jne 0x140070d25
inc rbx
xor edx, edx
mov r9, rbx
mov r8d, 0xf
mov rcx, rbp
mov qword [rsp + 0x20], 0xf
call method.std::basic_string_view_char__std::char_traits_char___.compare_unsigned_long_long__unsigned_long_long__char_const__unsigned_long_long__const
test eax, eax
jne 0x140070db2
cmp byte [rbx + 0xf], 0x2e
jne 0x140070db2
add rbx, 0x10
lea rsi, [rsp + 0x50]
mov rdi, qword [rsi]
xor edx, edx
mov r9, rbx
mov rcx, rsi
mov qword [rsp + 0x20], rdi
mov r8, rdi
call method.std::basic_string_view_char__std::char_traits_char___.compare_unsigned_long_long__unsigned_long_long__char_const__unsigned_long_long__const
test eax, eax
jne 0x140070d76
cmp byte [rbx + rdi], 0x3d
je 0x140070d89
add rsi, 0x18
lea rax, [rsp + 0x80]
cmp rsi, rax
je 0x140070db2
jmp 0x140070d54
lea rdx, [rsp + 0x38]
lea rcx, [rbx + rdi + 1]
xor r8d, r8d
call sym.strtoul
mov rbx, qword [rsp + 0x38]
mov dl, byte [rbx]
cmp dl, 0x3a
je 0x140070dab
test dl, dl
jne 0x140070db2
test eax, eax
js 0x140070db2
mov dword [rsi + 0x10], eax
mov rcx, rbx
mov edx, 0x3a
call sym.strchr
mov rbx, rax
jmp 0x140070d14
mov eax, dword [rsp + 0x78]
mov edx, 0x1000
cmp eax, edx
cmovle edx, eax
mov eax, dword [rsp + 0x60]
test eax, eax
jne 0x140070de2
mov eax, 6
movsxd rbx, eax
movsxd rax, edx
add rbx, 0x26
imul rbx, rax
shl rbx, 3
mov qword [0x140072778], rbx
je 0x140070e2c
mov rcx, rbx
call sym.malloc
mov qword [0x140072770], rax
test rax, rax
jne 0x140070e1c
xor ecx, ecx
mov qword [0x140072778], rcx
jmp 0x140070e2c
xor edx, edx
mov qword [0x140072768], rax
mov qword [rax], rbx
mov qword [rax + 8], rdx
lea rcx, [sym.__tcf_0]
add rsp, 0x88
pop rbx
pop rsi
pop rdi
pop rbp
jmp sym.atexit
Function at 0x100401730
Capabilities:
Write file on windows

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x20
test rcx, rcx
mov rbx, rcx
je 0x1004017b9
mov edx, 0x2f
call sub.cygwin1.dll_strrchr
test rax, rax
je 0x1004017a0
lea rdx, [rax + 1]
mov rcx, rdx
sub rcx, rbx
cmp rcx, 6
jle 0x1004017a0
lea rsi, [rax - 6]
lea rdi, str._.libs_
mov ecx, 7
repe cmpsb byte [rsi], byte [rdi]
jne 0x1004017a0
lea rdi, [0x1004079d0]
mov ecx, 3
mov rsi, rdx
mov rbx, rdx
repe cmpsb byte [rsi], byte [rdi]
seta r8b
setb cl
cmp r8b, cl
jne 0x1004017a0
lea rbx, [rax + 4]
mov rax, qword [sym.imp.cygwin1.dll_program_invocation_short_name]
mov qword [rax], rbx
mov rax, qword [sym.imp.cygwin1.dll_program_invocation_name]
mov qword [0x10040c080], rbx
mov qword [rax], rbx
add rsp, 0x20
pop rbx
pop rsi
pop rdi
ret
call sub.cygwin1.dll___getreent
mov r9, qword [rax + 0x18]
lea rcx, str.A_NULL_argv_0__was_passed_through_an_exec_system_call._n
mov r8d, 0x37
mov edx, 1
call sub.cygwin1.dll_fwrite
call sub.cygwin1.dll_abort
nop
nop

Function at 0x100404560
Capabilities:
Query environment variable

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x28
xor ecx, ecx
call sub.cygwin1.dll_nl_langinfo
test rax, rax
mov rbp, rax
je 0x1004046f0
lea rdi, str.US_ASCII
mov ecx, 9
mov rsi, rax
repe cmpsb byte [rsi], byte [rdi]
je 0x100404602
mov rbx, qword [0x10040c1f0]
test rbx, rbx
jne 0x1004045ba
jmp 0x100404677
mov rcx, rbx
call sub.cygwin1.dll_strlen
lea rbx, [rbx + rax + 1]
mov rcx, rbx
call sub.cygwin1.dll_strlen
lea rbx, [rbx + rax + 1]
movzx esi, byte [rbx]
test sil, sil
je 0x1004045ea
mov rdx, rbx
mov rcx, rbp
call sub.cygwin1.dll_strcmp
test eax, eax
je 0x1004045dd
cmp sil, 0x2a
jne 0x1004045a0
cmp byte [rbx + 1], 0
jne 0x1004045a0
mov rcx, rbx
call sub.cygwin1.dll_strlen
lea rbp, [rbx + rax + 1]
cmp byte [rbp], 0
lea rax, str.ASCII
cmovne rax, rbp
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
ret
lea rcx, str.LC_ALL
call sub.cygwin1.dll_getenv
test rax, rax
je 0x100404618
cmp byte [rax], 0
jne 0x100404690
lea rcx, str.LC_CTYPE
call sub.cygwin1.dll_getenv
test rax, rax
je 0x10040462e
cmp byte [rax], 0
jne 0x100404690
lea rcx, str.LANG
call sub.cygwin1.dll_getenv
test rax, rax
je 0x100404644
cmp byte [rax], 0
jne 0x100404690
call qword [sym.imp.KERNEL32.dll_GetACP]
lea rdx, str.CP_u
lea rcx, [0x10040c1e0]
mov r8d, eax
lea rbp, [0x10040c1e0]
call sub.cygwin1.dll_sprintf
mov rbx, qword [0x10040c1f0]
test rbx, rbx
jne 0x1004045ba
lea rax, str.CP936
mov qword [0x10040c1f0], rax
mov rbx, rax
jmp 0x1004045ba
mov edx, 0x2e
mov rcx, rax
call sub.cygwin1.dll_strchr
test rax, rax
je 0x100404644
lea rbx, [rax + 1]
mov edx, 0x40
mov rcx, rbx
call sub.cygwin1.dll_strchr
test rax, rax
je 0x1004046fc
sub rax, rbx
cmp rax, 0xc
mov rsi, rax
ja 0x100404644
lea rbp, [0x10040c1e0]
mov r8, rax
mov rdx, rbx
mov rcx, rbp
call fcn.100404bb0
mov byte [rbp + rsi], 0
mov rax, rbp
jmp 0x1004045f9
lea rbp, [0x100408390]
jmp 0x10040458e
mov rax, rbx
jmp 0x1004045f9
Function at 0x140002120
Capabilities:
Enumerate processes

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x260
xor edx, edx
mov dword [rsp + 0x20], 0x238
mov rdi, rcx
lea ecx, [rdx + 2]
call qword [sym.imp.KERNEL32.dll_CreateToolhelp32Snapshot]
mov rcx, rax
lea rdx, [rsp + 0x20]
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_Process32FirstW]
cmp eax, 1
jne 0x140002195
lea rdx, [rsp + 0x20]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_Process32NextW]
cmp eax, 1
jne 0x140002195
nop dword [rax]
mov rdx, rdi
lea rcx, [rsp + 0x4c]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll__wcsicmp]
mov rcx, rbx
test eax, eax
je 0x1400021b1
lea rdx, [rsp + 0x20]
call qword [sym.imp.KERNEL32.dll_Process32NextW]
cmp eax, 1
je 0x140002170
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
mov rbx, qword [rsp + 0x270]
add rsp, 0x260
pop rdi
ret
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [rsp + 0x28]
mov rbx, qword [rsp + 0x270]
add rsp, 0x260
pop rdi
ret
Function at 0x140002a80
Capabilities:
Write file on windows

Disassembly:
push rbx
push rdi
push r15
sub rsp, 0x20
cmp qword [rcx + 0x68], 0
mov rbx, r8
mov r15, rdx
mov rdi, rcx
je 0x140002aa8
add rsp, 0x20
pop r15
pop rdi
pop rbx
jmp qword [sym.imp.MSVCP140.dll_protected_virtual:_long_long___int64____cdecl_std::basic_streambuf_char__struct_std::char_traits_char__::xsputn_char_const____ptr64__long_long___int64_____ptr64]
mov rax, qword [rcx + 0x40]
mov qword [rsp + 0x40], rbp
mov qword [rsp + 0x48], rsi
mov rsi, rbx
mov qword [rsp + 0x58], r14
mov r9, qword [rax]
test r9, r9
je 0x140002ace
mov rax, qword [rcx + 0x58]
mov ecx, dword [rax]
jmp 0x140002ad0
xor ecx, ecx
movsxd rbp, ecx
test rbx, rbx
jle 0x140002b29
test ecx, ecx
jle 0x140002b09
cmp rbx, rbp
mov rcx, r9
cmovl rbp, rbx
mov r8, rbp
call sub.VCRUNTIME140.dll_memcpy
mov rax, qword [rdi + 0x58]
add r15, rbp
sub rbx, rbp
sub dword [rax], ebp
mov rcx, qword [rdi + 0x40]
movsxd rax, ebp
add qword [rcx], rax
test rbx, rbx
jle 0x140002b29
mov r9, qword [rdi + 0x80]
test r9, r9
je 0x140002b29
mov r8, rbx
mov edx, 1
mov rcx, r15
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
sub rbx, rax
mov r14, qword [rsp + 0x58]
sub rsi, rbx
mov rbp, qword [rsp + 0x40]
mov rax, rsi
mov rsi, qword [rsp + 0x48]
add rsp, 0x20
pop r15
pop rdi
pop rbx
ret
Function at 0x140002b50
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 0x18], rbp
mov qword [rsp + 0x20], rsi
push r14
sub rsp, 0x20
mov rbp, r8
mov r14, rdx
mov rsi, rcx
test r8, r8
jg 0x140002b81
xor eax, eax
mov rbp, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x48]
add rsp, 0x20
pop r14
ret
cmp qword [rcx + 0x68], 0
je case.default.0x140002b98
mov rbp, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x48]
add rsp, 0x20
pop r14
jmp qword [sym.imp.MSVCP140.dll_protected_virtual:_long_long___int64____cdecl_std::basic_streambuf_char__struct_std::char_traits_char__::xsgetn_char____ptr64__long_long___int64_____ptr64]
mov rax, qword [rcx + 0x38]
mov qword [rsp + 0x30], rbx
mov rbx, rbp
mov rdx, qword [rax]
test rdx, rdx
je 0x140002bbb
mov rax, qword [rcx + 0x50]
mov ecx, dword [rax]
jmp 0x140002bbd
xor ecx, ecx
movsxd rax, ecx
test ecx, ecx
je 0x140002bf9
mov qword [rsp + 0x38], rdi
cmp rax, rbp
mov rdi, rbp
mov rcx, r14
cmovb rdi, rax
mov r8, rdi
call sub.VCRUNTIME140.dll_memcpy
mov rax, qword [rsi + 0x50]
add r14, rdi
sub rbx, rdi
sub dword [rax], edi
mov rcx, qword [rsi + 0x38]
movsxd rax, edi
mov rdi, qword [rsp + 0x38]
add qword [rcx], rax
cmp qword [rsi + 0x80], 0
je 0x140002c8e
mov r8, qword [rsi + 0x18]
lea rax, [rsi + 0x70]
cmp qword [r8], rax
jne 0x140002c34
mov rcx, qword [rsi + 0x88]
mov rdx, qword [rsi + 0x90]
mov qword [r8], rcx
sub edx, ecx
mov rax, qword [rsi + 0x38]
mov qword [rax], rcx
mov rax, qword [rsi + 0x50]
mov dword [rax], edx
cmp rbx, 0xfff
jbe 0x140002c6e
nop dword [rax]
mov r9, qword [rsi + 0x80]
mov edx, 1
mov r8d, 0xfff
mov rcx, r14
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
add r14, rax
sub rbx, rax
cmp rax, 0xfff
jne 0x140002c8e
cmp rbx, rax
ja 0x140002c40
test rbx, rbx
je 0x140002c8e
mov r9, qword [rsi + 0x80]
mov r8, rbx
mov edx, 1
mov rcx, r14
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
sub rbx, rax
mov rsi, qword [rsp + 0x48]
sub rbp, rbx
mov rbx, qword [rsp + 0x30]
mov rax, rbp
mov rbp, qword [rsp + 0x40]
add rsp, 0x20
pop r14
ret
add byte [rax], al
add byte [rax], al
add byte [rax], al
add byte [rax], al
add byte [rax], al
add byte [rax], al
add byte [rax], al
add byte [rax], al
add byte [rax], al
add byte [rax], al
add byte [rax], al
add byte [rax], al
add byte [rax], al
add byte [rax], al
add byte [rax], al
add byte [rax], al
add byte [rax], al
add byte [rax], al
add byte [rax], al
add byte [rax], al
add byte [rax], al
add byte [rax], al
add byte [rax], al