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

Disassembly:
mov r11, rsp
push rsi
push rdi
push r14
sub rsp, 0x60
mov qword [r11 - 0x48], 0xfffffffffffffffe
mov qword [r11 + 0x18], rbx
mov qword [r11 + 0x20], rbp
mov rax, qword [0x14007d038]
xor rax, rsp
mov qword [rsp + 0x58], rax
mov rdi, rdx
mov rsi, rcx
mov qword [r11 - 0x38], rcx
mov qword [r11 - 0x30], rdx
mov edx, 0x101
call fcn.140022484
mov rbp, rax
mov rdx, rdi
cmp qword [rdi + 0x18], 8
jb 0x140022b6e
mov rdx, qword [rdi]
lea rax, [rsp + 0x38]
mov qword [rsp + 0x28], rax
and qword [rsp + 0x20], 0
lea r9, [rsp + 0x50]
xor r8d, r8d
mov rcx, rbp
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
je 0x140022bb3
mov rcx, rbp
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
nop
mov rcx, rsi
call fcn.140009e30
nop
mov rcx, rdi
call fcn.140009e30
or eax, 0xffffffff
jmp 0x140022c29
cmp dword [rsp + 0x50], 4
jne 0x140022b93
mov ecx, dword [rsp + 0x38]
call fcn.1400252d4
mov r14, rax
mov rdx, rdi
cmp qword [rdi + 0x18], 8
jb 0x140022bd3
mov rdx, qword [rdi]
lea rax, [rsp + 0x38]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], r14
xor r9d, r9d
xor r8d, r8d
mov rcx, rbp
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
mov ebx, eax
mov rcx, rbp
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
test ebx, ebx
je 0x140022c05
or ebx, 0xffffffff
jmp 0x140022c08
mov ebx, dword [r14]
mov edx, 1
mov rcx, r14
call fcn.140024d14
nop
mov rcx, rsi
call fcn.140009e30
nop
mov rcx, rdi
call fcn.140009e30
mov eax, ebx
mov rcx, qword [rsp + 0x58]
xor rcx, rsp
call fcn.140024cf0
lea r11, [rsp + 0x60]
mov rbx, qword [r11 + 0x30]
mov rbp, qword [r11 + 0x38]
mov rsp, r11
pop r14
pop rdi
pop rsi
ret
Function at 0x140023148
Capabilities:
Delete registry value

Disassembly:
mov r11, rsp
push rdi
sub rsp, 0x40
mov qword [r11 - 0x28], 0xfffffffffffffffe
mov qword [r11 + 0x18], rbx
mov qword [r11 + 0x20], rsi
mov rax, qword [0x14007d038]
xor rax, rsp
mov qword [rsp + 0x38], rax
mov rbx, rdx
mov rdi, rcx
mov qword [r11 - 0x20], rcx
mov qword [r11 - 0x18], rdx
mov edx, 0x102
call fcn.140022484
mov rsi, rax
mov rdx, rbx
cmp qword [rbx + 0x18], 8
jb 0x140023197
mov rdx, qword [rbx]
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_RegDeleteValueW]
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
nop
mov rcx, rdi
call fcn.140009e30
nop
mov rcx, rbx
call fcn.140009e30
mov rcx, qword [rsp + 0x38]
xor rcx, rsp
call fcn.140024cf0
mov rbx, qword [rsp + 0x60]
mov rsi, qword [rsp + 0x68]
add rsp, 0x40
pop rdi
ret
Function at 0x1400246f0
Capabilities:
Access the windows event log

Disassembly:
mov qword [rsp + 0x10], rbx
push rbp
push rsi
push rdi
sub rsp, 0x70
mov rax, qword [0x14007d038]
xor rax, rsp
mov qword [rsp + 0x60], rax
mov rsi, rdx
mov rdi, rcx
mov rdx, qword [rcx + 0x18]
movzx ebp, r8w
xor ecx, ecx
call qword [sym.imp.ADVAPI32.dll_RegisterEventSourceW]
mov rbx, rax
test rax, rax
je 0x140024776
mov rcx, qword [rdi + 0x18]
lea rax, [rsp + 0x50]
mov qword [rsp + 0x50], rcx
mov edx, 2
xor ecx, ecx
mov qword [rsp + 0x58], rsi
mov qword [rsp + 0x40], rcx
xor r8d, r8d
mov qword [rsp + 0x38], rax
xor r9d, r9d
mov dword [rsp + 0x30], ecx
mov word [rsp + 0x28], dx
movzx edx, bp
mov qword [rsp + 0x20], rcx
mov rcx, rbx
call qword [sym.imp.ADVAPI32.dll_ReportEventW]
mov rcx, rbx
call qword [sym.imp.ADVAPI32.dll_DeregisterEventSource]
mov rcx, qword [rsp + 0x60]
xor rcx, rsp
call fcn.140024cf0
mov rbx, qword [rsp + 0x98]
add rsp, 0x70
pop rdi
pop rsi
pop rbp
ret

Function at 0x1400247a0
Capabilities:
Access the windows event log

Disassembly:
mov qword [rsp + 0x20], rbx
push rdi
sub rsp, 0x280
mov rax, qword [0x14007d038]
xor rax, rsp
mov qword [rsp + 0x270], rax
mov rdi, rcx
mov dword [rsp + 0x20], r8d
mov r9, rdx
lea r8, str._s_failed_w_err_0x_08lx
mov edx, 0x104
lea rcx, [rsp + 0x60]
call fcn.140004680
mov rdx, qword [rdi + 0x18]
xor ecx, ecx
call qword [sym.imp.ADVAPI32.dll_RegisterEventSourceW]
mov rbx, rax
test rax, rax
je 0x140024849
mov rcx, qword [rdi + 0x18]
lea rax, [rsp + 0x60]
mov r9d, 2
mov qword [rsp + 0x50], rcx
xor ecx, ecx
mov qword [rsp + 0x58], rax
mov qword [rsp + 0x40], rcx
lea rax, [rsp + 0x50]
mov qword [rsp + 0x38], rax
xor r8d, r8d
mov dword [rsp + 0x30], ecx
lea edx, [r9 - 1]
mov word [rsp + 0x28], r9w
xor r9d, r9d
mov qword [rsp + 0x20], rcx
mov rcx, rbx
call qword [sym.imp.ADVAPI32.dll_ReportEventW]
mov rcx, rbx
call qword [sym.imp.ADVAPI32.dll_DeregisterEventSource]
mov rcx, qword [rsp + 0x270]
xor rcx, rsp
call fcn.140024cf0
mov rbx, qword [rsp + 0x2a8]
add rsp, 0x280
pop rdi
ret
Function at 0x14003d164
Capabilities:
Parse pe header

Disassembly:
mov dword [rsp + 0x18], r8d
mov dword [rsp + 0x10], edx
push rbp
mov rbp, rsp
sub rsp, 0x50
mov qword [rbp - 0x20], 0xfffffffffffffffe
mov qword [rsp + 0x60], rbx
mov ebx, ecx
test r8d, r8d
jne 0x14003cfc3
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x14003cfc3
mov ecx, 0x5a4d
cmp word [rax], cx
jne 0x14003cfc3
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
jne 0x14003cfc3
mov eax, 0x20b
cmp word [rcx + 0x18], ax
jne 0x14003cfc3
cmp dword [rcx + 0x84], 0xe
jbe 0x14003cfc3
cmp dword [rcx + 0xf8], 0
je 0x14003cfc3
mov ecx, ebx
call fcn.14003d080
mov byte [rbp + 0x28], 0
lea rax, [rbp + 0x18]
mov qword [rbp - 0x18], rax
lea rax, [rbp + 0x20]
mov qword [rbp - 0x10], rax
lea rax, [rbp + 0x28]
mov qword [rbp - 8], rax
mov eax, 2
mov dword [rbp - 0x2c], eax
mov dword [rbp - 0x28], eax
lea r9, [rbp - 0x2c]
lea r8, [rbp - 0x18]
lea rdx, [rbp - 0x28]
lea rcx, [rbp - 0x30]
call fcn.14003ce50
nop
cmp dword [rbp + 0x20], 0
je 0x14003d011
mov rbx, qword [rsp + 0x60]
add rsp, 0x50
pop rbp
ret
mov ecx, ebx
call fcn.14003d01c
int3
xor r8d, r8d
xor edx, edx
jmp 0x14003cf54
Function at 0x14004499c
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
mov qword [rsp + 0x18], rdi
push r14
sub rsp, 0x20
mov rsi, rcx
test rcx, rcx
jne 0x1400449ce
call fcn.140035bfc
mov dword [rax], 0x16
call fcn.14002a9e4
jmp 0x140044aed
mov eax, dword [rcx + 0x14]
shr eax, 0xd
test al, 1
je 0x140044aed
mov eax, dword [rcx + 0x14]
shr eax, 0xc
test al, 1
jne 0x140044aed
mov eax, dword [rcx + 0x14]
shr eax, 1
test al, 1
je 0x1400449fd
lock or dword [rcx + 0x14], 0x10
jmp 0x140044aed
lock or dword [rcx + 0x14], 1
mov eax, dword [rcx + 0x14]
test eax, 0x4c0
jne 0x140044a11
call fcn.140045174
mov rdi, qword [rsi + 8]
mov rcx, rsi
mov ebx, dword [rsi + 0x20]
mov qword [rsi], rdi
call fcn.140044974
mov r8d, ebx
mov rdx, rdi
mov ecx, eax
call fcn.14004836c
mov dword [rsi + 0x10], eax
lea ecx, [rax + 1]
cmp ecx, 1
jbe 0x140044adb
mov eax, dword [rsi + 0x14]
or edi, 0xffffffff
test al, 6
jne 0x140044aa6
mov rcx, rsi
call fcn.140044974
cmp eax, edi
je 0x140044a91
mov rcx, rsi
call fcn.140044974
cmp eax, 0xfffffffe
je 0x140044a91
mov rcx, rsi
call fcn.140044974
movsxd rbx, eax
lea r14, [0x14007f7d0]
mov rcx, rsi
sar rbx, 6
call fcn.140044974
and eax, 0x3f
lea rcx, [rax + rax*8]
mov rax, qword [r14 + rbx*8]
lea rdx, [rax + rcx*8]
jmp 0x140044a98
lea rdx, [0x14007d450]
mov al, byte [rdx + 0x38]
and al, 0x82
cmp al, 0x82
jne 0x140044aa6
lock or dword [rsi + 0x14], 0x20
cmp dword [rsi + 0x20], 0x200
jne 0x140044aca
mov eax, dword [rsi + 0x14]
shr eax, 6
test al, 1
je 0x140044aca
mov eax, dword [rsi + 0x14]
shr eax, 8
test al, 1
jne 0x140044aca
mov dword [rsi + 0x20], 0x1000
mov rax, qword [rsi]
add dword [rsi + 0x10], edi
movzx edi, byte [rax]
inc rax
mov qword [rsi], rax
jmp 0x140044af0
neg eax
sbb eax, eax
and eax, 8
add eax, 8
lock or dword [rsi + 0x14], eax
and dword [rsi + 0x10], 0
or edi, 0xffffffff
mov rbx, qword [rsp + 0x30]
mov eax, edi
mov rdi, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x38]
add rsp, 0x20
pop r14
ret
Function at 0x140047c40
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 8], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
mov eax, 0x1050
call fcn.1400256f0
sub rsp, rax
mov rax, qword [0x14007d038]
xor rax, rsp
mov qword [rsp + 0x1040], rax
mov r15, r8
mov rbp, rdx
mov rbx, rcx
call fcn.140044974
xor edi, edi
movsxd r14, eax
cmp dword [rbx + 0x10], edi
jne 0x140047c8f
mov rax, rbp
jmp 0x140047d97
mov rax, qword [rbx]
mov rcx, r14
sub rax, qword [rbx + 8]
and ecx, 0x3f
cqo
mov rbx, r14
sub rax, rdx
sar rbx, 6
sar rax, 1
mov r9, r15
lea r12, [rcx + rcx*8]
mov rsi, rax
lea rax, [0x140000000]
xor r8d, r8d
mov rdx, qword [rax + rbx*8 + 0x7f7d0]
mov ecx, r14d
mov rdx, qword [rdx + r12*8 + 0x30]
call fcn.140047884
mov r13, rax
lea rax, [0x140000000]
mov rcx, qword [rax + rbx*8 + 0x7f7d0]
cmp r13, qword [rcx + r12*8 + 0x30]
jne 0x140047d93
mov rcx, qword [rcx + r12*8 + 0x28]
lea r9, [rsp + 0x30]
mov r8d, 0x1000
mov qword [rsp + 0x20], rdi
lea rdx, [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x140047d93
mov r9, r15
xor r8d, r8d
mov rdx, rbp
mov ecx, r14d
call fcn.140047884
test rax, rax
js 0x140047d93
mov eax, dword [rsp + 0x30]
cmp rsi, rax
jg 0x140047d93
lea rdx, [rsp + 0x40]
add rdx, rax
lea rcx, [rsp + 0x40]
test rsi, rsi
je 0x140047d85
lea r8, [0x140000000]
cmp rcx, rdx
jae 0x140047d85
cmp byte [rcx], 0xd
jne 0x140047d6b
lea rax, [rdx - 1]
cmp rcx, rax
jae 0x140047d7a
cmp byte [rcx + 1], 0xa
jne 0x140047d7a
inc rcx
jmp 0x140047d7a
movzx eax, byte [rcx]
movsx rax, byte [rax + r8 + 0x7d4a0]
add rcx, rax
inc rdi
inc rcx
cmp rdi, rsi
jne 0x140047d4d
lea rax, [rsp + 0x40]
sub rcx, rax
lea rax, [rcx + r13]
jmp 0x140047d97
or rax, 0xffffffffffffffff
mov rcx, qword [rsp + 0x1040]
xor rcx, rsp
call fcn.140024cf0
mov rbx, qword [rsp + 0x1090]
add rsp, 0x1050
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
Function at 0x140047ec0
Capabilities:
Read file on windows

Disassembly:
push rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
sub rsp, 0x30
movsxd rbp, ecx
mov r9, r8
mov rax, rbp
lea rcx, [0x14007f7d0]
and eax, 0x3f
mov r10, rbp
sar r10, 6
xor edi, edi
mov rsi, rdx
mov r14, rbp
lea r8, [rax + rax*8]
mov rax, qword [rcx + r10*8]
mov ecx, 4
mov qword [rsp + 0x78], rcx
mov r11, qword [rax + r8*8 + 0x28]
lea r12d, [rcx + 6]
test r9, r9
je 0x140047f1e
cmp word [rdx], r12w
jne 0x140047f1e
or byte [rax + r8*8 + 0x38], cl
jmp 0x140047f24
and byte [rax + r8*8 + 0x38], 0xfb
lea rdx, [rdx + r9*2]
mov rcx, rsi
mov rbx, rsi
cmp rsi, rdx
jae 0x14004807f
mov r9d, 0x1a
lea r13d, [r9 - 0xd]
movzx eax, word [rcx]
cmp ax, r9w
je 0x14004805a
lea r9, [rcx + 2]
cmp ax, r13w
je 0x140047f5d
mov rcx, r9
jmp 0x140047f80
cmp r9, rdx
jae 0x140047f97
cmp word [r9], r12w
mov eax, 2
cmove rax, qword [rsp + 0x78]
add rcx, rax
mov eax, r12d
cmp word [r9], r12w
cmovne ax, r13w
mov word [rbx], ax
mov r9d, 0x1a
add rbx, 2
cmp rcx, rdx
jb 0x140047f41
jmp 0x14004807f
lea r9, [rsp + 0x80]
mov qword [rsp + 0x20], rdi
mov r8d, 2
lea rdx, [rsp + 0x70]
mov rcx, r11
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x140048054
cmp dword [rsp + 0x80], edi
je 0x140048054
mov rdx, r14
lea r11, [0x14007f7d0]
sar rdx, 6
and r14d, 0x3f
mov rax, qword [r11 + rdx*8]
lea r8, [r14 + r14*8]
test byte [rax + r8*8 + 0x38], 0x48
je 0x14004802d
movzx eax, word [rsp + 0x70]
cmp ax, r12w
jne 0x140048000
mov word [rbx], r12w
jmp 0x14004807b
mov word [rbx], r13w
mov word [rsp + 0x78], ax
mov rax, qword [r11 + rdx*8]
lea rcx, [rax + r8*8]
mov al, byte [rsp + rdi + 0x78]
mov byte [rcx + rdi + 0x3a], al
inc rdi
cmp rdi, 2
jl 0x140048009
mov rax, qword [r11 + rdx*8]
mov byte [rax + r8*8 + 0x3c], r12b
jmp 0x14004807b
cmp word [rsp + 0x70], r12w
jne 0x14004803a
cmp rbx, rsi
je 0x140047ffa
mov rdx, 0xfffffffffffffffe
mov ecx, ebp
lea r8d, [rdx + 3]
call fcn.14004788c
cmp word [rsp + 0x70], r12w
je 0x14004807f
mov word [rbx], r13w
jmp 0x14004807b
lea r11, [0x14007f7d0]
mov rcx, qword [r11 + r10*8]
mov al, byte [rcx + r8*8 + 0x38]
test al, 0x40
jne 0x140048077
or al, 2
mov byte [rcx + r8*8 + 0x38], al
jmp 0x14004807f
mov word [rbx], r9w
add rbx, 2
sub rbx, rsi
sar rbx, 1
lea eax, [rbx + rbx]
add rsp, 0x30
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret
Function at 0x14004aa90
Capabilities:
Query environment variable

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x20
call qword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
xor ebp, ebp
mov rbx, rax
test rax, rax
je 0x14004ab17
mov rsi, rbx
cmp word [rax], bp
je 0x14004aad6
or rax, 0xffffffffffffffff
inc rax
cmp word [rsi + rax*2], bp
jne 0x14004aac0
lea rsi, [rsi + rax*2]
add rsi, 2
cmp word [rsi], bp
jne 0x14004aabc
sub rsi, rbx
add rsi, 2
sar rsi, 1
add rsi, rsi
mov rcx, rsi
call fcn.1400451e0
mov rdi, rax
test rax, rax
je 0x14004ab04
mov r8, rsi
mov rdx, rbx
mov rcx, rax
call fcn.140027dd0
mov rbp, rdi
xor ecx, ecx
call fcn.140044938
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov rax, rbp
mov rbx, qword [rsp + 0x30]
mov rbp, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
add rsp, 0x20
pop rdi
ret
Function at 0x13813c0
Capabilities:
Terminate process

Disassembly:
cld
pop r11
jmp 0x13813cd
inc rsi
mov byte [rdi], dl
inc rdi
mov dl, byte [rsi]
add ebx, ebx
jne 0x13813dd
mov ebx, dword [rsi]
sub rsi, 0xfffffffffffffffc
adc ebx, ebx
mov dl, byte [rsi]
jb 0x13813c5
lea eax, [rcx + 1]
jmp 0x13813eb
dec eax
call r11
adc eax, eax
call r11
adc eax, eax
add ebx, ebx
jne 0x13813fe
mov ebx, dword [rsi]
sub rsi, 0xfffffffffffffffc
adc ebx, ebx
mov dl, byte [rsi]
jae 0x13813e4
sub eax, 3
jb 0x138141e
shl eax, 8
movzx edx, dl
or eax, edx
inc rsi
xor eax, 0xffffffff
je 0x138146d
sar eax, 1
movsxd rbp, eax
jb 0x1381454
jmp 0x138142c
add ebx, ebx
jne 0x138142a
mov ebx, dword [rsi]
sub rsi, 0xfffffffffffffffc
adc ebx, ebx
jb 0x1381454
inc ecx
add ebx, ebx
jne 0x138143a
mov ebx, dword [rsi]
sub rsi, 0xfffffffffffffffc
adc ebx, ebx
jb 0x1381454
call r11
adc ecx, ecx
add ebx, ebx
jne 0x138144d
mov ebx, dword [rsi]
sub rsi, 0xfffffffffffffffc
adc ebx, ebx
jae 0x138143c
add ecx, 2
jmp 0x1381459
call r11
adc ecx, ecx
cmp rbp, 0xfffffffffffffb00
adc ecx, 2
call fcn.01381382
jmp 0x13813cd
pop rsi
sub rsp, 0x28
lea rdi, [rsi + 0xf6c000]
mov eax, dword [rdi]
or eax, eax
je 0x13814c9
mov ebx, dword [rdi + 4]
lea rcx, [rax + rsi + 0xf81000]
add rbx, rsi
add rdi, 8
call qword [sym.imp.KERNEL32.DLL_LoadLibraryA]
xchg rbp, rax
mov al, byte [rdi]
inc rdi
or al, al
je 0x1381479
mov rcx, rdi
mov rdx, rdi
dec eax
repne scasb al, byte [rdi]
mov rcx, rbp
call qword [sym.imp.KERNEL32.DLL_GetProcAddress]
or rax, rax
je 0x13814c3
mov qword [rbx], rax
add rbx, 8
jmp 0x1381499
jmp qword [sym.imp.KERNEL32.DLL_ExitProcess]
add rsp, 0x28
add rdi, 4
lea rbx, [rsi - 4]
xor eax, eax
mov al, byte [rdi]
inc rdi
or eax, eax
je 0x138150d
cmp al, 0xef
ja 0x13814f5
add rbx, rax
mov rax, qword [rbx]
bswap rax
add rax, rsi
mov qword [rbx], rax
jmp 0x13814d5
and al, 0xf
shl eax, 0x10
mov ax, word [rdi]
add rdi, 2
or eax, eax
jne 0x13814e4
mov eax, dword [rdi]
add rdi, 4
jmp 0x13814e4
mov rbp, qword [sym.imp.KERNEL32.DLL_VirtualProtect]
lea rdi, [rsi - 0x1000]
mov ebx, 0x1000
push rax
mov r9, rsp
mov r8d, 4
mov rdx, rbx
mov rcx, rdi
sub rsp, 0x20
call rbp
lea rax, [rdi + 0x1af]
and byte [rax], 0x7f
and byte [rax + 0x28], 0x7f
lea r9, [rsp + 0x20]
mov r8, qword [r9]
mov rdx, rbx
mov rcx, rdi
call rbp
add rsp, 0x28
pop rbp
pop rdi
pop rsi
pop rbx
lea rax, [rsp - 0x80]
push 0
cmp rsp, rax
jne 0x1381561
sub rsp, 0xffffffffffffff80
jmp 0x45d0a0
Function at 0x140015c70
Capabilities:
Query environment variable

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
mov qword [rsp + 0x20], rsi
push rdi
mov eax, 0x10090
call fcn.14003ea40
sub rsp, rax
mov rax, qword [0x140055040]
xor rax, rsp
mov qword [rsp + 0x10080], rax
movzx eax, byte [rcx]
lea rbx, [rsp + 0x30]
xor ebp, ebp
mov rsi, rcx
mov word [rsp + 0x80], bp
mov word [rsp + 0x30], bp
lea edi, [rbp + 0x28]
test al, al
je 0x140015d22
mov r8d, 2
mov byte [rsp + 0x20], al
lea rdx, [rsp + 0x20]
mov byte [rsp + 0x21], bpl
lea rcx, [rsp + 0x24]
call fcn.1400325cc
cmp rax, 1
jne 0x140015d7e
mov rcx, rdi
mov rax, rbx
cmp word [rbx], bp
je 0x140015cff
add rax, 2
dec rcx
cmp word [rax], bp
jne 0x140015cf3
cmp rcx, 1
jb 0x140015d7e
movzx ecx, word [rsp + 0x24]
inc rsi
mov word [rax], cx
add rbx, 2
mov word [rax + 2], bp
dec rdi
movzx eax, byte [rsi]
test al, al
jne 0x140015cc0
mov r8d, 0x10000
lea rdx, [rsp + 0x80]
lea rcx, [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
dec eax
cmp eax, 0xffff
ja 0x140015d53
lea rcx, [rsp + 0x80]
call fcn.140033b0c
jmp 0x140015d55
xor eax, eax
mov rcx, qword [rsp + 0x10080]
xor rcx, rsp
call fcn.140022cd0
lea r11, [rsp + 0x10090]
mov rbx, qword [r11 + 0x18]
mov rbp, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rsp, r11
pop rdi
ret
call fcn.1400275d4
int3

Function at 0x140015d90
Capabilities:
Set environment variable

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x90
mov rax, qword [0x140055040]
xor rax, rsp
mov qword [rsp + 0x80], rax
xor ebp, ebp
lea rsi, str.NUITKA_PYTHONPATH
mov word [rsp + 0x30], bp
lea rbx, [rsp + 0x30]
mov al, 0x4e
lea edi, [rbp + 0x28]
mov r8d, 2
mov byte [rsp + 0x20], al
lea rdx, [rsp + 0x20]
mov byte [rsp + 0x21], bpl
lea rcx, [rsp + 0x24]
call fcn.1400325cc
cmp rax, 1
jne 0x140015e65
mov rcx, rdi
mov rax, rbx
cmp word [rbx], bp
je 0x140015e0c
add rax, 2
dec rcx
cmp word [rax], bp
jne 0x140015e00
cmp rcx, 1
jb 0x140015e65
movzx ecx, word [rsp + 0x24]
inc rsi
mov word [rax], cx
add rbx, 2
mov word [rax + 2], bp
dec rdi
movzx eax, byte [rsi]
test al, al
jne 0x140015dd1
xor edx, edx
lea rcx, [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
mov rcx, qword [rsp + 0x80]
xor rcx, rsp
call fcn.140022cd0
lea r11, [rsp + 0x90]
mov rbx, qword [r11 + 0x10]
mov rbp, qword [r11 + 0x18]
mov rsi, qword [r11 + 0x20]
mov rsp, r11
pop rdi
ret
call fcn.1400275d4
int3
Function at 0x14001dc20
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x20
cmp byte [0x14005a196], 0
mov rsi, r8
mov rdi, rdx
mov rbp, rcx
jne 0x14001dca1
mov edx, 3
xor ecx, ecx
lea r8d, [rdx + 7]
call qword [sym.imp.KERNEL32.dll_FindResourceA]
mov rdx, rax
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_LoadResource]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_LockResource]
mov qword [0x140059fc8], rax
mov ebx, dword [rax]
lea rdx, [rax + 4]
mov qword [0x140059fc8], rdx
mov r8d, dword [rdx]
add rdx, 4
mov qword [0x140059fc8], rdx
call fcn.14001c090
cmp eax, ebx
jne 0x14001de0d
mov byte [0x14005a196], 1
lea rdx, [0x1400493c8]
mov rcx, rsi
call fcn.14003ec00
test eax, eax
je 0x14001dd2c
cmp byte [0x14005a197], 1
je 0x14001dd2c
call qword [sym.imp.python312.dll_PyDict_New]
mov qword [0x14005a5a8], rax
call qword [sym.imp.python312.dll_PyDict_New]
mov qword [0x14005aa70], rax
call qword [sym.imp.python312.dll_PyDict_New]
mov qword [0x14005a2b8], rax
call qword [sym.imp.python312.dll_PyDict_New]
mov qword [0x14005a218], rax
call qword [sym.imp.python312.dll_PyDict_New]
mov qword [0x14005aac8], rax
call qword [sym.imp.python312.dll_PyDict_New]
mov qword [0x14005a350], rax
call qword [sym.imp.python312.dll_PyDict_New]
mov qword [0x14005aa78], rax
call qword [sym.imp.python312.dll_PyDict_New]
mov qword [0x14005aa88], rax
mov byte [0x14005a197], 1
mov r8, qword [0x140059fc8]
mov rax, rsi
mov rdx, r8
sub rdx, rsi
nop dword [rax]
movzx ecx, byte [rax]
xor r9d, r9d
cmp cl, byte [rax + rdx]
jne 0x14001dd57
inc rax
test cl, cl
jne 0x14001dd40
mov ecx, r9d
jmp 0x14001dd5c
sbb ecx, ecx
or ecx, 1
mov rax, 0xffffffffffffffff
cmp byte [r8 + rax + 1], r9b
lea rax, [rax + 1]
jne 0x14001dd63
lea rdx, [r8 + rax]
mov eax, dword [r8 + rax + 1]
add rdx, 5
test ecx, ecx
je 0x14001ddc8
nop
add rdx, rax
mov rax, rsi
mov r8, rdx
sub r8, rsi
nop dword [rax]
movzx ecx, byte [rax]
cmp cl, byte [rax + r8]
jne 0x14001dda5
inc rax
test cl, cl
jne 0x14001dd90
mov ecx, r9d
jmp 0x14001ddaa
sbb ecx, ecx
or ecx, 1
mov rax, 0xffffffffffffffff
inc rax
cmp byte [rdx + rax], r9b
jne 0x14001ddb1
add rdx, rax
mov eax, dword [rdx + 1]
add rdx, 5
test ecx, ecx
jne 0x14001dd80
movzx ecx, word [rdx]
lea rax, [rdx + 2]
cmp r9w, cx
jae 0x14001ddf8
mov ebx, ecx
nop word [rax + rax]
mov r8, rax
mov rdx, rdi
mov rcx, rbp
call fcn.14001cca0
add rdi, 8
sub rbx, 1
jne 0x14001dde0
mov rbx, qword [rsp + 0x30]
mov rbp, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
add rsp, 0x20
pop rdi
ret
lea rcx, str.Error__corrupted_constants_object
call fcn.14002f0fc
call fcn.1400275d4
int3

Function at 0x1400236a4
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x1400236ee
mov ecx, 0x5a4d
cmp word [rax], cx
jne 0x1400236ee
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
jne 0x1400236ee
mov eax, 0x20b
cmp word [rcx + 0x18], ax
jne 0x1400236ee
cmp dword [rcx + 0x84], 0xe
jbe 0x1400236ee
cmp dword [rcx + 0xf8], 0
setne al
jmp 0x1400236f0
xor al, al
add rsp, 0x28
ret
Function at 0x1400275c8
Capabilities:
Parse pe header

Disassembly:
mov dword [rsp + 0x18], r8d
mov dword [rsp + 0x10], edx
push rbp
mov rbp, rsp
sub rsp, 0x50
mov qword [rbp - 0x20], 0xfffffffffffffffe
mov qword [rsp + 0x60], rbx
mov ebx, ecx
test r8d, r8d
jne 0x140027433
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x140027433
mov ecx, 0x5a4d
cmp word [rax], cx
jne 0x140027433
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
jne 0x140027433
mov eax, 0x20b
cmp word [rcx + 0x18], ax
jne 0x140027433
cmp dword [rcx + 0x84], 0xe
jbe 0x140027433
cmp dword [rcx + 0xf8], 0
je 0x140027433
mov ecx, ebx
call fcn.1400274e4
mov byte [rbp + 0x28], 0
lea rax, [rbp + 0x18]
mov qword [rbp - 0x18], rax
lea rax, [rbp + 0x20]
mov qword [rbp - 0x10], rax
lea rax, [rbp + 0x28]
mov qword [rbp - 8], rax
mov eax, 2
mov dword [rbp - 0x2c], eax
mov dword [rbp - 0x28], eax
lea r9, [rbp - 0x2c]
lea r8, [rbp - 0x18]
lea rdx, [rbp - 0x28]
lea rcx, [rbp - 0x30]
call fcn.1400272c0
nop
cmp dword [rbp + 0x20], 0
je 0x140027481
mov rbx, qword [rsp + 0x60]
add rsp, 0x50
pop rbp
ret
mov ecx, ebx
call fcn.14002748c
int3
xor r8d, r8d
xor edx, edx
jmp 0x1400273c4
Function at 0x140038520
Capabilities:
Query environment variable

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x20
call qword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
xor ebp, ebp
mov rbx, rax
test rax, rax
je 0x1400385a7
mov rsi, rbx
cmp word [rax], bp
je 0x140038566
or rax, 0xffffffffffffffff
inc rax
cmp word [rsi + rax*2], bp
jne 0x140038550
lea rsi, [rsi + rax*2]
add rsi, 2
cmp word [rsi], bp
jne 0x14003854c
sub rsi, rbx
add rsi, 2
sar rsi, 1
add rsi, rsi
mov rcx, rsi
call fcn.140036128
mov rdi, rax
test rax, rax
je 0x140038594
mov r8, rsi
mov rdx, rbx
mov rcx, rax
call fcn.14003f0a0
mov rbp, rdi
xor ecx, ecx
call fcn.140034178
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov rax, rbp
mov rbx, qword [rsp + 0x30]
mov rbp, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
add rsp, 0x20
pop rdi
ret
Function at 0x14003acac
Capabilities:
Get file size

Disassembly:
push rbx
sub rsp, 0x20
mov edx, dword [rcx + 0x14]
nop
shr edx, 3
test dl, 1
je 0x14003acc2
mov al, 1
jmp 0x14003ad22
mov eax, dword [rcx + 0x14]
nop
test al, 0xc0
je 0x14003acd3
mov rax, qword [rcx + 8]
cmp qword [rcx], rax
je 0x14003ad20
mov ecx, dword [rcx + 0x18]
nop
call fcn.140038cc4
mov rbx, rax
cmp rax, 0xffffffffffffffff
je 0x14003ad20
mov r9d, 1
lea r8, [rsp + 0x38]
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
je 0x14003ad20
lea rdx, [rsp + 0x30]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
je 0x14003ad20
mov rax, qword [rsp + 0x30]
cmp qword [rsp + 0x38], rax
sete al
jmp 0x14003ad22
xor al, al
add rsp, 0x20
pop rbx
ret

Function at 0x14003e950
Capabilities:
Parse pe header

Disassembly:
mov eax, 0x5a4d
cmp word [rcx], ax
jne 0x14003e978
movsxd rdx, dword [rcx + 0x3c]
add rdx, rcx
cmp dword [rdx], 0x4550
jne 0x14003e978
xor eax, eax
mov ecx, 0x20b
cmp word [rdx + 0x18], cx
sete al
ret
xor eax, eax
ret