joyce8/EMBER2024-capa huggingface dataset:
Function at 0x180012634
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 0x1800126a3
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x1800126a3
mov ecx, 0x5a4d
cmp word [rax], cx
jne 0x1800126a3
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
jne 0x1800126a3
mov eax, 0x20b
cmp word [rcx + 0x18], ax
jne 0x1800126a3
cmp dword [rcx + 0x84], 0xe
jbe 0x1800126a3
cmp dword [rcx + 0xf8], 0
je 0x1800126a3
mov ecx, ebx
call fcn.180012754
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.180012530
nop
cmp dword [rbp + 0x20], 0
je 0x1800126f1
mov rbx, qword [rsp + 0x60]
add rsp, 0x50
pop rbp
ret
mov ecx, ebx
call fcn.1800126fc
int3
xor edx, edx
xor ecx, ecx
lea r8d, [rdx + 1]
jmp 0x180012634

Function at 0x180017bc4
Capabilities:
Get file size

Disassembly:
push rbx
sub rsp, 0x20
mov edx, dword [rcx + 0x14]
nop
shr edx, 3
test dl, 1
je 0x180017bda
mov al, 1
jmp 0x180017c3a
mov eax, dword [rcx + 0x14]
nop
test al, 0xc0
je 0x180017beb
mov rax, qword [rcx + 8]
cmp qword [rcx], rax
je 0x180017c38
mov ecx, dword [rcx + 0x18]
nop
call fcn.18002313c
mov rbx, rax
cmp rax, 0xffffffffffffffff
je 0x180017c38
mov r9d, 1
lea r8, [rsp + 0x38]
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
je 0x180017c38
lea rdx, [rsp + 0x30]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
je 0x180017c38
mov rax, qword [rsp + 0x30]
cmp qword [rsp + 0x38], rax
sete al
jmp 0x180017c3a
xor al, al
add rsp, 0x20
pop rbx
ret
Function at 0x18001b3e8
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.180028810
sub rsp, rax
mov rax, qword [section..data]
xor rax, rsp
mov qword [rsp + 0x1040], rax
mov r15, r8
mov rbp, rdx
mov rbx, rcx
call fcn.180017aa4
xor edi, edi
movsxd r14, eax
cmp dword [rbx + 0x10], edi
jne 0x18001b437
mov rax, rbp
jmp 0x18001b53f
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, [0x180000000]
xor r8d, r8d
mov rdx, qword [rax + rbx*8 + 0x3e150]
mov ecx, r14d
mov rdx, qword [rdx + r12*8 + 0x30]
call fcn.18001ce08
mov r13, rax
lea rax, [0x180000000]
mov rcx, qword [rax + rbx*8 + 0x3e150]
cmp r13, qword [rcx + r12*8 + 0x30]
jne 0x18001b53b
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 0x18001b53b
mov r9, r15
xor r8d, r8d
mov rdx, rbp
mov ecx, r14d
call fcn.18001ce08
test rax, rax
js 0x18001b53b
mov eax, dword [rsp + 0x30]
cmp rsi, rax
jg 0x18001b53b
lea rdx, [rsp + 0x40]
add rdx, rax
lea rcx, [rsp + 0x40]
test rsi, rsi
je 0x18001b52d
lea r8, [0x180000000]
cmp rcx, rdx
jae 0x18001b52d
cmp byte [rcx], 0xd
jne 0x18001b513
lea rax, [rdx - 1]
cmp rcx, rax
jae 0x18001b522
cmp byte [rcx + 1], 0xa
jne 0x18001b522
inc rcx
jmp 0x18001b522
movzx eax, byte [rcx]
movsx rax, byte [rax + r8 + 0x3c4a0]
add rcx, rax
inc rdi
inc rcx
cmp rdi, rsi
jne 0x18001b4f5
lea rax, [rsp + 0x40]
sub rcx, rax
lea rax, [rcx + r13]
jmp 0x18001b53f
or rax, 0xffffffffffffffff
mov rcx, qword [rsp + 0x1040]
xor rcx, rsp
call fcn.180007040
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 0x18001c1a8
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 0x20], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x30
movsxd r15, ecx
lea r9, [0x18003e150]
mov rax, r15
mov rbp, r15
and eax, 0x3f
sar rbp, 6
mov ecx, 4
xor esi, esi
mov r14, rdx
lea rdi, [rax + rax*8]
mov rax, qword [r9 + rbp*8]
lea r13d, [rcx + 6]
mov r10, qword [rax + rdi*8 + 0x28]
test r8, r8
je 0x18001c1ff
cmp word [rdx], r13w
jne 0x18001c1ff
or byte [rax + rdi*8 + 0x38], cl
jmp 0x18001c204
and byte [rax + rdi*8 + 0x38], 0xfb
lea r8, [rdx + r8*2]
mov rbx, r14
cmp r14, r8
jae 0x18001c329
mov r11d, 0xd
lea r12d, [r11 - 0xb]
movzx ecx, word [rdx]
cmp cx, 0x1a
je 0x18001c34a
lea r9, [rdx + 2]
cmp cx, r11w
je 0x18001c23d
mov rdx, r9
mov word [rbx], cx
jmp 0x18001c264
cmp r9, r8
jae 0x18001c274
cmp word [r9], r13w
mov rax, r12
mov ecx, 4
cmove rax, rcx
add rdx, rax
mov eax, r13d
cmp word [r9], r13w
cmovne ax, r11w
mov word [rbx], ax
mov rax, r12
add rbx, rax
cmp rdx, r8
jb 0x18001c21e
jmp 0x18001c329
lea r9, [rsp + 0x80]
mov qword [rsp + 0x20], rsi
mov r8d, r12d
lea rdx, [rsp + 0x70]
mov rcx, r10
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x18001c31e
cmp dword [rsp + 0x80], esi
je 0x18001c31e
lea r8, [0x18003e150]
mov rax, qword [r8 + rbp*8]
test byte [rax + rdi*8 + 0x38], 0x48
je 0x18001c2f6
movzx eax, word [rsp + 0x70]
cmp ax, r13w
jne 0x18001c2c6
mov word [rbx], r13w
jmp 0x18001c326
mov ecx, 0xd
mov word [rsp + 0x78], ax
mov word [rbx], cx
mov rax, qword [r8 + rbp*8]
lea rcx, [rax + rdi*8]
mov al, byte [rsp + rsi + 0x78]
mov byte [rcx + rsi + 0x3a], al
inc rsi
cmp rsi, r12
jl 0x18001c2d3
mov rax, qword [r8 + rbp*8]
mov byte [rax + rdi*8 + 0x3c], r13b
jmp 0x18001c326
cmp word [rsp + 0x70], r13w
jne 0x18001c303
cmp rbx, r14
je 0x18001c2c0
mov rdx, 0xfffffffffffffffe
mov ecx, r15d
lea r8d, [rdx + 3]
call fcn.18001ce10
cmp word [rsp + 0x70], r13w
je 0x18001c329
mov ecx, 0xd
mov word [rbx], cx
add rbx, r12
sub rbx, r14
sar rbx, 1
lea eax, [rbx + rbx]
mov rbx, qword [rsp + 0x88]
add rsp, 0x30
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
lea r8, [0x18003e150]
mov rdx, qword [r8 + rbp*8]
mov al, byte [rdx + rdi*8 + 0x38]
test al, 0x40
jne 0x18001c323
or al, r12b
mov byte [rdx + rdi*8 + 0x38], al
jmp 0x18001c329
Function at 0x18001e6b8
Capabilities:
Query environment variable

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
push r14
sub rsp, 0x40
call qword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
xor esi, esi
mov rbx, rax
test rax, rax
jne 0x18001e6e8
xor eax, eax
jmp 0x18001e7ab
mov rbp, rbx
cmp word [rax], si
je 0x18001e70d
or rax, 0xffffffffffffffff
inc rax
cmp word [rbp + rax*2], si
jne 0x18001e6f4
lea rbp, [rbp + rax*2]
add rbp, 2
cmp word [rbp], si
jne 0x18001e6f0
mov qword [rsp + 0x38], rsi
sub rbp, rbx
mov qword [rsp + 0x30], rsi
add rbp, 2
sar rbp, 1
mov r8, rbx
mov r9d, ebp
mov dword [rsp + 0x28], esi
xor edx, edx
mov qword [rsp + 0x20], rsi
xor ecx, ecx
call fcn.18001e5d8
movsxd r14, eax
test eax, eax
jne 0x18001e74b
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
jmp 0x18001e6e1
mov rcx, r14
call fcn.180019264
mov rdi, rax
test rax, rax
jne 0x18001e764
xor ecx, ecx
call fcn.180018de0
jmp 0x18001e740
mov qword [rsp + 0x38], rsi
mov r9d, ebp
mov qword [rsp + 0x30], rsi
mov r8, rbx
mov dword [rsp + 0x28], r14d
xor edx, edx
xor ecx, ecx
mov qword [rsp + 0x20], rdi
call fcn.18001e5d8
test eax, eax
jne 0x18001e795
mov rcx, rdi
call fcn.180018de0
jmp 0x18001e79f
xor ecx, ecx
call fcn.180018de0
mov rsi, rdi
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov rax, rsi
mov rbx, qword [rsp + 0x50]
mov rbp, qword [rsp + 0x58]
mov rsi, qword [rsp + 0x60]
mov rdi, qword [rsp + 0x68]
add rsp, 0x40
pop r14
ret

Function at 0x1800228dc
Capabilities:
Get geographical location

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x20
mov esi, edx
mov ebx, ecx
call fcn.180015ad8
mov ecx, ebx
lea r8, [rsp + 0x30]
and ecx, 0x3ff
mov r9d, 2
bts ecx, 0xa
mov edx, 0x20000001
mov rdi, rax
call qword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
xor edx, edx
test eax, eax
je 0x18002297d
cmp ebx, dword [rsp + 0x30]
je 0x180022976
test esi, esi
je 0x180022976
mov r10, qword [rdi + 0x98]
mov r9d, edx
movzx r8d, word [r10]
lea rcx, [r10 + 2]
lea eax, [r8 - 0x41]
cmp ax, 0x19
jbe 0x180022951
sub r8w, 0x61
cmp r8w, 0x19
ja 0x18002295e
movzx r8d, word [rcx]
inc r9d
add rcx, 2
jmp 0x18002293b
or rax, 0xffffffffffffffff
inc rax
cmp word [r10 + rax*2], dx
jne 0x180022962
cmp r9d, eax
setne dl
mov eax, edx
jmp 0x18002297f
mov eax, 1
jmp 0x18002297f
xor eax, eax
mov rbx, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
add rsp, 0x20
pop rdi
ret
Function at 0x180027828
Capabilities:
Clear file content

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
push r12
push r14
push r15
sub rsp, 0x20
mov rbx, rdx
mov rsi, r8
xor edx, edx
mov r14d, ecx
lea r8d, [rdx + 1]
call fcn.18001ce10
xor edx, edx
mov ecx, r14d
mov r12, rax
lea r8d, [rdx + 2]
call fcn.18001ce10
mov rbp, rbx
sub rbp, rax
cmp r12, 0xffffffffffffffff
je 0x180027978
cmp rax, 0xffffffffffffffff
je 0x180027978
xor edi, edi
test rbp, rbp
jle 0x180027923
lea edx, [rdi + 1]
mov ecx, 0x1000
call fcn.180017f80
mov rbx, rax
test rax, rax
jne 0x1800278b0
lea edi, [rax + 0xc]
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], edi
jmp 0x180027919
mov edx, 0x8000
mov ecx, r14d
call fcn.1800276ac
mov r15d, eax
mov eax, 0x1000
mov r8d, ebp
cmp rbp, rax
mov r9, rsi
mov rdx, rbx
mov ecx, r14d
cmovge r8d, eax
call fcn.180018ad8
cmp eax, 0xffffffff
je 0x1800278f9
cdqe
sub rbp, rax
test rbp, rbp
jg 0x1800278c0
mov edx, r15d
mov ecx, r14d
call fcn.1800276ac
jmp 0x180027919
cmp byte [rsi + 0x38], dil
je 0x180027910
cmp dword [rsi + 0x34], 5
jne 0x180027910
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], 0xd
cmp byte [rsi + 0x30], dil
je 0x180027919
mov edi, dword [rsi + 0x2c]
mov rcx, rbx
call fcn.180018de0
jmp 0x18002798c
jns 0x18002798c
xor r8d, r8d
mov rdx, rbx
mov ecx, r14d
call fcn.18001ce10
cmp rax, 0xffffffffffffffff
jne 0x180027944
cmp byte [rsi + 0x30], dil
je 0x18002798c
mov edi, dword [rsi + 0x2c]
jmp 0x18002798c
mov ecx, r14d
call fcn.18002313c
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x18002798c
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov byte [rsi + 0x38], 1
mov edi, 0xd
mov dword [rsi + 0x34], eax
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], 0xd
jmp 0x18002798c
xor edi, edi
cmp byte [rsi + 0x30], dil
je 0x180027985
mov eax, dword [rsi + 0x2c]
jmp 0x18002798a
mov eax, 0x16
mov edi, eax
xor r8d, r8d
mov rdx, r12
mov ecx, r14d
call fcn.18001ce10
mov rbx, qword [rsp + 0x40]
mov eax, edi
mov rdi, qword [rsp + 0x58]
mov rbp, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
add rsp, 0x20
pop r15
pop r14
pop r12
ret

Function at 0x1800282e8
Capabilities:
Enumerate pe sections

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
mov qword [rsp + 0x18], rdi
movsxd r8, dword [0x18000003c]
lea rsi, [0x180000000]
add r8, rsi
mov rbx, rdx
mov rdi, rcx
cmp dword [r8 + 0x84], 0xd
jbe 0x180028361
mov r10d, dword [r8 + 0xf0]
xor r9d, r9d
test r10d, r10d
je 0x180028361
movzx ecx, word [r8 + 0x14]
movzx r11d, word [r8 + 6]
add rcx, 0x18
mov r10d, dword [r10 + rsi + 0xc]
add rcx, r8
cmp r9w, r11w
jae 0x180028361
mov eax, dword [rcx + 0xc]
cmp r10d, eax
jb 0x180028355
mov edx, dword [rcx + 8]
add eax, edx
cmp r10d, eax
jb 0x180028373
inc r9d
add rcx, 0x28
cmp r9d, r11d
jb 0x180028343
xor eax, eax
mov rbx, qword [rsp + 8]
mov rsi, qword [rsp + 0x10]
mov rdi, qword [rsp + 0x18]
ret
mov dword [rdi], edx
mov eax, dword [rcx + 0x24]
mov dword [rbx], eax
mov eax, dword [rcx + 0xc]
add rax, rsi
jmp 0x180028363
Function at 0x180028900
Capabilities:
Parse pe header

Disassembly:
mov eax, 0x5a4d
cmp word [rcx], ax
jne 0x180028928
movsxd rdx, dword [rcx + 0x3c]
add rdx, rcx
cmp dword [rdx], 0x4550
jne 0x180028928
xor eax, eax
mov ecx, 0x20b
cmp word [rdx + 0x18], cx
sete al
ret
xor eax, eax
ret
Function at 0x1400218a0
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.140025a10
sub rsp, rax
mov rax, qword [0x14005f2c0]
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 edi, 0x28
mov word [rsp + 0x30], bp
test al, al
je 0x140021962
nop dword [rax]
nop word [rax + rax]
mov r8d, 2
mov byte [rsp + 0x20], al
lea rdx, [rsp + 0x20]
mov byte [rsp + 0x21], bpl
lea rcx, [rsp + 0x24]
call fcn.1400343a8
cmp rax, 1
jne 0x1400219be
mov rcx, rdi
mov rax, rbx
cmp word [rbx], bp
je 0x14002193f
add rax, 2
dec rcx
cmp word [rax], bp
jne 0x140021933
cmp rcx, 1
jb 0x1400219be
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 0x140021900
mov r8d, 0x10000
lea rdx, [rsp + 0x80]
lea rcx, [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
dec eax
cmp eax, 0xffff
ja 0x140021993
lea rcx, [rsp + 0x80]
call fcn.140035480
jmp 0x140021995
xor eax, eax
mov rcx, qword [rsp + 0x10080]
xor rcx, rsp
call fcn.140025740
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.140034158
int3
Function at 0x140022630
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 [0x140060e0e], 0
mov rsi, r8
mov rdi, rdx
mov rbp, rcx
jne 0x1400226b5
mov edx, 3
xor ecx, ecx
mov r8d, 0xa
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 [0x140060bd8], rax
xor ecx, ecx
mov ebx, dword [rax]
lea rdx, [rax + 4]
mov qword [0x140060bd8], rdx
mov r8d, dword [rdx]
add rdx, 4
mov qword [0x140060bd8], rdx
call fcn.140020660
cmp eax, ebx
jne 0x14002281d
mov byte [0x140060e0e], 1
lea rdx, [0x140044408]
mov rcx, rsi
call fcn.140040cd0
test eax, eax
je 0x140022740
cmp byte [0x140060e0d], 1
je 0x140022740
call qword [sym.imp.python312.dll_PyDict_New]
mov qword [0x140061b68], rax
call qword [sym.imp.python312.dll_PyDict_New]
mov qword [0x140061b70], rax
call qword [sym.imp.python312.dll_PyDict_New]
mov qword [0x140061b78], rax
call qword [sym.imp.python312.dll_PyDict_New]
mov qword [0x140061b80], rax
call qword [sym.imp.python312.dll_PyDict_New]
mov qword [0x140061b88], rax
call qword [sym.imp.python312.dll_PyDict_New]
mov qword [0x140061b90], rax
call qword [sym.imp.python312.dll_PyDict_New]
mov qword [0x140061b98], rax
call qword [sym.imp.python312.dll_PyDict_New]
mov qword [0x140061ba0], rax
mov byte [0x140060e0d], 1
mov r8, qword [0x140060bd8]
mov rax, rsi
mov rdx, r8
sub rdx, rsi
movzx ecx, byte [rax]
xor r9d, r9d
cmp cl, byte [rax + rdx]
jne 0x140022767
inc rax
test cl, cl
jne 0x140022750
mov ecx, r9d
jmp 0x14002276c
sbb ecx, ecx
or ecx, 1
mov rax, 0xffffffffffffffff
cmp byte [r8 + rax + 1], r9b
lea rax, [rax + 1]
jne 0x140022773
lea rdx, [r8 + rax]
mov eax, dword [r8 + rax + 1]
add rdx, 5
test ecx, ecx
je 0x1400227d8
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 0x1400227b5
inc rax
test cl, cl
jne 0x1400227a0
mov ecx, r9d
jmp 0x1400227ba
sbb ecx, ecx
or ecx, 1
mov rax, 0xffffffffffffffff
inc rax
cmp byte [rdx + rax], r9b
jne 0x1400227c1
add rdx, rax
mov eax, dword [rdx + 1]
add rdx, 5
test ecx, ecx
jne 0x140022790
movzx ecx, word [rdx]
lea rax, [rdx + 2]
cmp r9w, cx
jae 0x140022808
mov ebx, ecx
nop word [rax + rax]
mov r8, rax
mov rdx, rdi
mov rcx, rbp
call fcn.14001ece0
add rdi, 8
sub rbx, 1
jne 0x1400227f0
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.140030be0
call fcn.140034158
int3
Function at 0x1400252d0
Capabilities:
Set environment variable

Disassembly:
mov qword [rsp + 0x18], rbx
mov qword [rsp + 0x20], rbp
push rsi
push rdi
push r14
sub rsp, 0x90
mov rax, qword [0x14005f2c0]
xor rax, rsp
mov qword [rsp + 0x80], rax
movzx eax, byte [rcx]
lea rbx, [rsp + 0x30]
xor r14d, r14d
mov rbp, rdx
mov word [rsp + 0x30], r14w
mov rsi, rcx
mov edi, 0x28
test al, al
je 0x140025381
nop word [rax + rax]
mov r8d, 2
mov byte [rsp + 0x20], al
lea rdx, [rsp + 0x20]
mov byte [rsp + 0x21], r14b
lea rcx, [rsp + 0x24]
call fcn.1400343a8
cmp rax, 1
jne 0x1400253b7
mov rcx, rdi
mov rax, rbx
cmp word [rbx], r14w
je 0x14002535d
add rax, 2
dec rcx
cmp word [rax], r14w
jne 0x140025350
cmp rcx, 1
jb 0x1400253b7
movzx ecx, word [rsp + 0x24]
inc rsi
mov word [rax], cx
add rbx, 2
mov word [rax + 2], r14w
dec rdi
movzx eax, byte [rsi]
test al, al
jne 0x140025320
mov rdx, rbp
lea rcx, [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
mov rcx, qword [rsp + 0x80]
xor rcx, rsp
call fcn.140025740
lea r11, [rsp + 0x90]
mov rbx, qword [r11 + 0x30]
mov rbp, qword [r11 + 0x38]
mov rsp, r11
pop r14
pop rdi
pop rsi
ret
call fcn.140034158
int3
Function at 0x140025480
Capabilities:
Set environment variable

Disassembly:
push rbx
push rbp
push rdi
sub rsp, 0xb0
mov rax, qword [0x14005f2c0]
xor rax, rsp
mov qword [rsp + 0x80], rax
mov rax, qword [0x140061280]
mov rbx, r8
mov rdi, rdx
mov rbp, rcx
test rax, rax
jne 0x1400254cf
lea rcx, [0x1400440f4]
call qword [sym.imp.python312.dll_PyImport_ImportModule]
mov qword [0x140061280], rax
test rax, rax
je 0x1400256ab
mov qword [rsp + 0xa8], rsi
lea rdx, str.environ
mov qword [rsp + 0xa0], r12
mov rcx, rax
mov qword [rsp + 0x98], r14
mov qword [rsp + 0x90], r15
call qword [sym.imp.python312.dll_PyObject_GetAttrString]
mov rcx, rdi
mov r14, rax
call qword [sym.imp.python312.dll_PyUnicode_FromString]
mov r15, rax
test rbx, rbx
je 0x140025576
mov rdx, rbx
mov rcx, rdi
call fcn.1400252d0
mov rdx, 0xffffffffffffffff
mov rcx, rbx
call qword [sym.imp.python312.dll_PyUnicode_FromWideChar]
mov rdx, r15
mov rcx, r14
mov r8, rax
mov rbx, rax
call qword [sym.imp.python312.dll_PyObject_SetItem]
test eax, eax
je 0x14002555b
mov ecx, 1
call qword [sym.imp.python312.dll_PyErr_PrintEx]
mov ecx, 1
call qword [sym.imp.python312.dll_Py_Exit]
int3
cmp dword [rbx], 0
jl 0x140025640
sub qword [rbx], 1
jne 0x140025640
mov rcx, rbx
jmp 0x14002563a
movzx eax, byte [rdi]
lea rbx, [rsp + 0x30]
xor r12d, r12d
mov esi, 0x28
mov word [rsp + 0x30], r12w
test al, al
je 0x140025605
mov r8d, 2
mov byte [rsp + 0x20], al
lea rdx, [rsp + 0x20]
mov byte [rsp + 0x21], r12b
lea rcx, [rsp + 0x28]
call fcn.1400343a8
cmp rax, 1
jne 0x1400256a5
mov rcx, rsi
mov rax, rbx
cmp word [rbx], r12w
je 0x1400255dd
nop dword [rax]
nop dword [rax + rax]
add rax, 2
dec rcx
cmp word [rax], r12w
jne 0x1400255d0
cmp rcx, 1
jb 0x1400256a5
movzx ecx, word [rsp + 0x28]
inc rdi
mov word [rax], cx
add rbx, 2
mov word [rax + 2], r12w
dec rsi
movzx eax, byte [rdi]
test al, al
jne 0x140025590
xor edx, edx
lea rcx, [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
mov rdx, r15
mov rcx, r14
call qword [sym.imp.python312.dll_PyObject_DelItem]
test eax, eax
je 0x140025640
mov rcx, qword [rbp + 0x60]
mov qword [rbp + 0x60], r12
test rcx, rcx
je 0x140025640
cmp dword [rcx], r12d
jl 0x140025640
sub qword [rcx], 1
jne 0x140025640
call qword [sym.imp.python312.dll__Py_Dealloc]
cmp dword [r15], 0
jl 0x140025655
sub qword [r15], 1
jne 0x140025655
mov rcx, r15
call qword [sym.imp.python312.dll__Py_Dealloc]
cmp dword [r14], 0
jl 0x14002566a
sub qword [r14], 1
jne 0x14002566a
mov rcx, r14
call qword [sym.imp.python312.dll__Py_Dealloc]
mov r14, qword [rsp + 0x98]
mov r12, qword [rsp + 0xa0]
mov rsi, qword [rsp + 0xa8]
mov r15, qword [rsp + 0x90]
mov rcx, qword [rsp + 0x80]
xor rcx, rsp
call fcn.140025740
add rsp, 0xb0
pop rdi
pop rbp
pop rbx
ret
call fcn.140034158
int3
call fcn.140034158
int3
Function at 0x1400261a8
Capabilities:
Parse pe header

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

Function at 0x14002a0f0
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 0x14002a15f
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x14002a15f
mov ecx, 0x5a4d
cmp word [rax], cx
jne 0x14002a15f
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
jne 0x14002a15f
mov eax, 0x20b
cmp word [rcx + 0x18], ax
jne 0x14002a15f
cmp dword [rcx + 0x84], 0xe
jbe 0x14002a15f
cmp dword [rcx + 0xf8], 0
je 0x14002a15f
mov ecx, ebx
call fcn.14002a204
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.140029ff8
nop
cmp dword [rbp + 0x20], 0
jne 0x14002a1c0
call fcn.1400361e0
cmp eax, 1
jne 0x14002a1b0
xor dl, dl
jmp 0x14002a1ba
call fcn.1400361ac
test al, al
sete dl
cmp dword [rbp + 0x20], 0
je 0x14002a1cb
mov rbx, qword [rsp + 0x60]
add rsp, 0x50
pop rbp
ret
mov ecx, ebx
call fcn.14002a1d4
int3
xor r8d, r8d
xor edx, edx
jmp 0x14002a0f0

Function at 0x14002a2d8
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 0x14002a15f
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x14002a15f
mov ecx, 0x5a4d
cmp word [rax], cx
jne 0x14002a15f
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
jne 0x14002a15f
mov eax, 0x20b
cmp word [rcx + 0x18], ax
jne 0x14002a15f
cmp dword [rcx + 0x84], 0xe
jbe 0x14002a15f
cmp dword [rcx + 0xf8], 0
je 0x14002a15f
mov ecx, ebx
call fcn.14002a204
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.140029ff8
nop
cmp dword [rbp + 0x20], 0
jne 0x14002a1c0
call fcn.1400361e0
cmp eax, 1
jne 0x14002a1b0
xor dl, dl
jmp 0x14002a1ba
call fcn.1400361ac
test al, al
sete dl
cmp dword [rbp + 0x20], 0
je 0x14002a1cb
mov rbx, qword [rsp + 0x60]
add rsp, 0x50
pop rbp
ret
mov ecx, ebx
call fcn.14002a1d4
int3
xor r8d, r8d
xor edx, edx
jmp 0x14002a0f0
Function at 0x14003a348
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 0x14003a3cf
mov rsi, rbx
cmp word [rax], bp
je 0x14003a38e
or rax, 0xffffffffffffffff
inc rax
cmp word [rsi + rax*2], bp
jne 0x14003a378
lea rsi, [rsi + rax*2]
add rsi, 2
cmp word [rsi], bp
jne 0x14003a374
sub rsi, rbx
add rsi, 2
sar rsi, 1
add rsi, rsi
mov rcx, rsi
call fcn.140035580
mov rdi, rax
test rax, rax
je 0x14003a3bc
mov r8, rsi
mov rdx, rbx
mov rcx, rax
call fcn.14003ffa0
mov rbp, rdi
xor ecx, ecx
call fcn.140036290
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