joyce8/EMBER2024-capa huggingface dataset:
Function at 0x14005b880
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, [0x140091320]
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 0x14005b8d7
cmp word [rdx], r13w
jne 0x14005b8d7
or byte [rax + rdi*8 + 0x38], cl
jmp 0x14005b8dc
and byte [rax + rdi*8 + 0x38], 0xfb
lea r8, [rdx + r8*2]
mov rbx, r14
cmp r14, r8
jae 0x14005ba01
mov r11d, 0xd
lea r12d, [r11 - 0xb]
movzx ecx, word [rdx]
cmp cx, 0x1a
je 0x14005ba22
lea r9, [rdx + 2]
cmp cx, r11w
je 0x14005b915
mov rdx, r9
mov word [rbx], cx
jmp 0x14005b93c
cmp r9, r8
jae 0x14005b94c
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 0x14005b8f6
jmp 0x14005ba01
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 0x14005b9f6
cmp dword [rsp + 0x80], esi
je 0x14005b9f6
lea r8, [0x140091320]
mov rax, qword [r8 + rbp*8]
test byte [rax + rdi*8 + 0x38], 0x48
je 0x14005b9ce
movzx eax, word [rsp + 0x70]
cmp ax, r13w
jne 0x14005b99e
mov word [rbx], r13w
jmp 0x14005b9fe
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 0x14005b9ab
mov rax, qword [r8 + rbp*8]
mov byte [rax + rdi*8 + 0x3c], r13b
jmp 0x14005b9fe
cmp word [rsp + 0x70], r13w
jne 0x14005b9db
cmp rbx, r14
je 0x14005b998
mov rdx, 0xfffffffffffffffe
mov ecx, r15d
lea r8d, [rdx + 3]
call fcn.14005b104
cmp word [rsp + 0x70], r13w
je 0x14005ba01
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, [0x140091320]
mov rdx, qword [r8 + rbp*8]
mov al, byte [rdx + rdi*8 + 0x38]
test al, 0x40
jne 0x14005b9fb
or al, r12b
mov byte [rdx + rdi*8 + 0x38], al
jmp 0x14005ba01
Function at 0x14005f760
Capabilities:
Get file size

Disassembly:
push rbx
sub rsp, 0x20
mov edx, dword [rcx + 0x14]
nop
shr edx, 3
test dl, 1
je 0x14005f776
mov al, 1
jmp 0x14005f7d6
mov eax, dword [rcx + 0x14]
nop
test al, 0xc0
je 0x14005f787
mov rax, qword [rcx + 8]
cmp qword [rcx], rax
je 0x14005f7d4
mov ecx, dword [rcx + 0x18]
nop
call fcn.1400632b4
mov rbx, rax
cmp rax, 0xffffffffffffffff
je 0x14005f7d4
mov r9d, 1
lea r8, [rsp + 0x38]
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
je 0x14005f7d4
lea rdx, [rsp + 0x30]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
je 0x14005f7d4
mov rax, qword [rsp + 0x30]
cmp qword [rsp + 0x38], rax
sete al
jmp 0x14005f7d6
xor al, al
add rsp, 0x20
pop rbx
ret
Function at 0x1400626d4
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 0x140062704
xor eax, eax
jmp 0x1400627c7
mov rbp, rbx
cmp word [rax], si
je 0x140062729
or rax, 0xffffffffffffffff
inc rax
cmp word [rbp + rax*2], si
jne 0x140062710
lea rbp, [rbp + rax*2]
add rbp, 2
cmp word [rbp], si
jne 0x14006270c
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.1400625f4
movsxd r14, eax
test eax, eax
jne 0x140062767
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
jmp 0x1400626fd
mov rcx, r14
call fcn.14005e1e4
mov rdi, rax
test rax, rax
jne 0x140062780
xor ecx, ecx
call fcn.14005c564
jmp 0x14006275c
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.1400625f4
test eax, eax
jne 0x1400627b1
mov rcx, rdi
call fcn.14005c564
jmp 0x1400627bb
xor ecx, ecx
call fcn.14005c564
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 0x140065998
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.14005b520
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 0x140065a39
cmp ebx, dword [rsp + 0x30]
je 0x140065a32
test esi, esi
je 0x140065a32
mov r10, qword [rdi + 0x98]
mov r9d, edx
movzx r8d, word [r10]
lea rcx, [r10 + 2]
lea eax, [r8 - 0x41]
cmp ax, 0x19
jbe 0x140065a0d
sub r8w, 0x61
cmp r8w, 0x19
ja 0x140065a1a
movzx r8d, word [rcx]
inc r9d
add rcx, 2
jmp 0x1400659f7
or rax, 0xffffffffffffffff
inc rax
cmp word [r10 + rax*2], dx
jne 0x140065a1e
cmp r9d, eax
setne dl
mov eax, edx
jmp 0x140065a3b
mov eax, 1
jmp 0x140065a3b
xor eax, eax
mov rbx, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
add rsp, 0x20
pop rdi
ret
Function at 0x14006b160
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.14005b104
xor edx, edx
mov ecx, r14d
mov r12, rax
lea r8d, [rdx + 2]
call fcn.14005b104
mov rbp, rbx
sub rbp, rax
cmp r12, 0xffffffffffffffff
je 0x14006b2b0
cmp rax, 0xffffffffffffffff
je 0x14006b2b0
xor edi, edi
test rbp, rbp
jle 0x14006b25b
lea edx, [rdi + 1]
mov ecx, 0x1000
call fcn.14005c4ec
mov rbx, rax
test rax, rax
jne 0x14006b1e8
lea edi, [rax + 0xc]
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], edi
jmp 0x14006b251
mov edx, 0x8000
mov ecx, r14d
call fcn.140054f70
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.14005dad8
cmp eax, 0xffffffff
je 0x14006b231
cdqe
sub rbp, rax
test rbp, rbp
jg 0x14006b1f8
mov edx, r15d
mov ecx, r14d
call fcn.140054f70
jmp 0x14006b251
cmp byte [rsi + 0x38], dil
je 0x14006b248
cmp dword [rsi + 0x34], 5
jne 0x14006b248
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], 0xd
cmp byte [rsi + 0x30], dil
je 0x14006b251
mov edi, dword [rsi + 0x2c]
mov rcx, rbx
call fcn.14005c564
jmp 0x14006b2c4
jns 0x14006b2c4
xor r8d, r8d
mov rdx, rbx
mov ecx, r14d
call fcn.14005b104
cmp rax, 0xffffffffffffffff
jne 0x14006b27c
cmp byte [rsi + 0x30], dil
je 0x14006b2c4
mov edi, dword [rsi + 0x2c]
jmp 0x14006b2c4
mov ecx, r14d
call fcn.1400632b4
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x14006b2c4
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 0x14006b2c4
xor edi, edi
cmp byte [rsi + 0x30], dil
je 0x14006b2bd
mov eax, dword [rsi + 0x2c]
jmp 0x14006b2c2
mov eax, 0x16
mov edi, eax
xor r8d, r8d
mov rdx, r12
mov ecx, r14d
call fcn.14005b104
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 0x14006b9f0
Capabilities:
Parse pe header

Disassembly:
mov eax, 0x5a4d
cmp word [rcx], ax
jne 0x14006ba18
movsxd rdx, dword [rcx + 0x3c]
add rdx, rcx
cmp dword [rdx], 0x4550
jne 0x14006ba18
xor eax, eax
mov ecx, 0x20b
cmp word [rdx + 0x18], cx
sete al
ret
xor eax, eax
ret
Function at 0x140001010
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
mov rax, qword [0x140063fe0]
xor ecx, ecx
mov dword [rax], 1
mov rax, qword [0x140063ff0]
mov dword [rax], 1
mov rax, qword [0x140064000]
mov dword [rax], 1
mov rax, qword [0x140063fd0]
mov dword [rax], 1
mov rax, qword [0x140063ea0]
cmp word [rax], 0x5a4d
jne 0x140001067
movsxd rdx, dword [rax + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
je 0x1400010d0
mov rax, qword [0x140063fc0]
mov dword [0x14006700c], ecx
mov eax, dword [rax]
test eax, eax
jne 0x1400010c0
mov ecx, 1
call sym.__set_app_type
call dbg.__p__fmode
mov rdx, qword [0x140063f80]
mov edx, dword [rdx]
mov dword [rax], edx
call dbg.__p__commode
mov rdx, qword [0x140063f60]
mov edx, dword [rdx]
mov dword [rax], edx
call dbg._setargv
mov rax, qword [0x140063e50]
cmp dword [rax], 1
je 0x140001108
xor eax, eax
add rsp, 0x28
ret
mov ecx, 2
call sym.__set_app_type
jmp 0x140001084
movzx edx, word [rax + 0x18]
cmp dx, 0x10b
je 0x140001120
cmp dx, 0x20b
jne 0x140001067
cmp dword [rax + 0x84], 0xe
jbe 0x140001067
mov edx, dword [rax + 0xf8]
xor ecx, ecx
test edx, edx
setne cl
jmp 0x140001067
lea rcx, [dbg._matherr]
call dbg.__mingw_setusermatherr
xor eax, eax
add rsp, 0x28
ret
cmp dword [rax + 0x74], 0xe
jbe 0x140001067
mov r8d, dword [rax + 0xe8]
xor ecx, ecx
test r8d, r8d
setne cl
jmp 0x140001067

Function at 0x14005f7df
Capabilities:
Write file on windows

Disassembly:
push rbp
push rbx
sub rsp, 0x48
lea rbp, [rsp + 0x40]
mov qword [rbp + 0x20], rcx
mov dword [rbp - 0x10], 0
mov rax, qword [rbp + 0x20]
mov qword [rbp - 8], rax
mov dword [rbp - 0xc], 0
jmp 0x14005f80f
add qword [rbp - 8], 1
add dword [rbp - 0xc], 1
mov rax, qword [rbp - 8]
movzx eax, byte [rax]
test al, al
jne 0x14005f806
mov ebx, dword [rbp - 0xc]
mov ecx, 0xfffffff5
mov rax, qword [sym.imp.KERNEL32.dll_GetStdHandle]
call rax
lea rdx, [rbp - 0x10]
mov qword [rsp + 0x20], 0
mov r9, rdx
mov r8d, ebx
mov rdx, qword [rbp + 0x20]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_WriteFile]
call rax
nop
add rsp, 0x48
pop rbx
pop rbp
ret

Function at 0x14005fca0
Capabilities:
Write file on windows

Disassembly:
push r12
push rbx
sub rsp, 0x38
mov r12, rcx
lea rax, [rsp + 0x58]
mov ecx, 2
mov qword [rsp + 0x58], rdx
mov qword [rsp + 0x60], r8
mov qword [rsp + 0x68], r9
mov qword [rsp + 0x28], rax
call dbg.__acrt_iob_func
mov r8d, 0x1b
mov edx, 1
lea rcx, str.Mingw_w64_runtime_failure:_n
mov r9, rax
call sym.fwrite
mov rbx, qword [rsp + 0x28]
mov ecx, 2
call dbg.__acrt_iob_func
mov rdx, r12
mov rcx, rax
mov r8, rbx
call sym.vfprintf
call sym.abort
nop
nop word [rax + rax]
Function at 0x14005fd10
Capabilities:
Allocate or change rwx memory

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rdi, dword [0x1400670c4]
mov r12, rcx
mov rsi, rdx
mov rbx, r8
test edi, edi
jle 0x14005fec0
mov rax, qword [0x1400670c8]
xor ecx, ecx
add rax, 0x18
nop
mov rdx, qword [rax]
cmp r12, rdx
jb 0x14005fd5c
mov r8, qword [rax + 8]
mov r8d, dword [r8 + 8]
add rdx, r8
cmp r12, rdx
jb 0x14005fde7
add ecx, 1
add rax, 0x28
cmp ecx, edi
jne 0x14005fd40
mov rcx, r12
call dbg.__mingw_GetSectionForAddress
mov rbp, rax
test rax, rax
je 0x14005ff1d
mov rax, qword [0x1400670c8]
lea rdi, [rdi + rdi*4]
shl rdi, 3
add rax, rdi
mov qword [rax + 0x20], rbp
mov dword [rax], 0
call dbg._GetPEImageBase
mov ecx, dword [rbp + 0xc]
lea rdx, [rsp + 0x20]
mov r8d, 0x30
add rcx, rax
mov rax, qword [0x1400670c8]
mov qword [rax + rdi + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x14005ff02
mov eax, dword [rsp + 0x44]
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x14005fde0
lea edx, [rax - 4]
and edx, 0xfffffffb
jne 0x14005fe70
add dword [0x1400670c4], 1
cmp ebx, 8
jae 0x14005fe18
test bl, 4
jne 0x14005fed0
test ebx, ebx
je 0x14005fe09
movzx eax, byte [rsi]
mov byte [r12], al
test bl, 2
jne 0x14005fef0
add rsp, 0x50
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
mov rax, qword [rsi]
lea rcx, [r12 + 8]
and rcx, 0xfffffffffffffff8
mov qword [r12], rax
mov eax, ebx
mov rdx, qword [rsi + rax - 8]
mov qword [r12 + rax - 8], rdx
sub r12, rcx
add ebx, r12d
sub rsi, r12
and ebx, 0xfffffff8
cmp ebx, 8
jb 0x14005fe09
and ebx, 0xfffffff8
xor eax, eax
mov edx, eax
add eax, 8
mov r8, qword [rsi + rdx]
mov qword [rcx + rdx], r8
cmp eax, ebx
jb 0x14005fe4a
add rsp, 0x50
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
cmp eax, 2
mov rcx, qword [rsp + 0x20]
mov rdx, qword [rsp + 0x38]
mov r8d, 4
mov eax, 0x40
cmovne r8d, eax
add rdi, qword [0x1400670c8]
mov qword [rdi + 8], rcx
mov r9, rdi
mov qword [rdi + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x14005fde0
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call dbg.__report_error
xor edi, edi
jmp 0x14005fd67
mov eax, dword [rsi]
mov ebx, ebx
mov dword [r12], eax
mov eax, dword [rsi + rbx - 4]
mov dword [r12 + rbx - 4], eax
jmp 0x14005fe09
mov ebx, ebx
movzx eax, word [rsi + rbx - 2]
mov word [r12 + rbx - 2], ax
jmp 0x14005fe09
mov rax, qword [0x1400670c8]
mov edx, dword [rbp + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rdi + 0x18]
call dbg.__report_error
mov rdx, r12
lea rcx, str.Address__p_has_no_image_section
call dbg.__report_error
nop
nop dword [rax]
Function at 0x140060430
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rdi
push rsi
push rbx
sub rsp, 0x28
lea rcx, [0x140067120]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x140067100]
test rbx, rbx
je 0x140060484
mov rdi, qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rsi, qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [rbx]
call rdi
mov r12, rax
call rsi
test eax, eax
jne 0x14006047b
test r12, r12
je 0x14006047b
mov rax, qword [rbx + 8]
mov rcx, r12
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x140060460
lea rcx, [0x140067120]
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop r12
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]

Function at 0x1400606b0
Capabilities:
Parse pe header

Disassembly:
cmp word [rcx], 0x5a4d
jne 0x1400606c0
jmp sym._ValidateImageBase.part.0
xor eax, eax
ret

Function at 0x1400606d0
Capabilities:
Enumerate pe sections

Disassembly:
movsxd rax, dword [rcx + 0x3c]
add rcx, rax
movzx eax, word [rcx + 0x14]
lea rax, [rcx + rax + 0x18]
movzx ecx, word [rcx + 6]
test ecx, ecx
je 0x140060715
sub ecx, 1
lea rcx, [rcx + rcx*4]
lea r9, [rax + rcx*8 + 0x28]
nop dword [rax]
mov r8d, dword [rax + 0xc]
mov rcx, r8
cmp r8, rdx
ja 0x14006070c
add ecx, dword [rax + 8]
cmp rcx, rdx
ja 0x140060717
add rax, 0x28
cmp rax, r9
jne 0x1400606f8
xor eax, eax
ret

Function at 0x1400607c0
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r10, qword [0x140063ea0]
xor r8d, r8d
cmp word [r10], 0x5a4d
mov r9, rcx
jne 0x140060839
mov rcx, r10
call sym._ValidateImageBase.part.0
test eax, eax
je 0x140060839
movsxd rax, dword [r10 + 0x3c]
mov rcx, r9
sub rcx, r10
add r10, rax
movzx eax, word [r10 + 0x14]
lea r8, [r10 + rax + 0x18]
movzx eax, word [r10 + 6]
test eax, eax
je 0x140060836
sub eax, 1
lea rax, [rax + rax*4]
lea r9, [r8 + rax*8 + 0x28]
nop dword [rax]
mov edx, dword [r8 + 0xc]
mov rax, rdx
cmp rcx, rdx
jb 0x14006082d
add eax, dword [r8 + 8]
cmp rcx, rax
jb 0x140060839
add r8, 0x28
cmp r8, r9
jne 0x140060818
xor r8d, r8d
mov rax, r8
add rsp, 0x28
ret

Function at 0x140060920
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r9, qword [0x140063ea0]
xor eax, eax
cmp word [r9], 0x5a4d
mov r8, rcx
jne 0x14006098f
mov rcx, r9
call sym._ValidateImageBase.part.0
test eax, eax
je 0x14006098f
movsxd rax, dword [r9 + 0x3c]
mov rcx, r8
sub rcx, r9
add r9, rax
movzx eax, word [r9 + 0x14]
movzx edx, word [r9 + 6]
lea rax, [r9 + rax + 0x18]
test edx, edx
je 0x14006098d
sub edx, 1
lea rdx, [rdx + rdx*4]
lea r9, [rax + rdx*8 + 0x28]
mov r8d, dword [rax + 0xc]
mov rdx, r8
cmp rcx, r8
jb 0x140060984
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x140060998
add rax, 0x28
cmp rax, r9
jne 0x140060970
xor eax, eax
add rsp, 0x28
ret
mov eax, dword [rax + 0x24]
not eax
shr eax, 0x1f
add rsp, 0x28
ret
Function at 0x1400609b0
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r11, qword [0x140063ea0]
xor r9d, r9d
cmp word [r11], 0x5a4d
mov r8d, ecx
jne 0x140060a28
mov rcx, r11
call sym._ValidateImageBase.part.0
test eax, eax
je 0x140060a28
movsxd rcx, dword [r11 + 0x3c]
add rcx, r11
mov eax, dword [rcx + 0x90]
test eax, eax
je 0x140060a28
movzx edx, word [rcx + 0x14]
lea rdx, [rcx + rdx + 0x18]
movzx ecx, word [rcx + 6]
test ecx, ecx
je 0x140060a28
sub ecx, 1
lea rcx, [rcx + rcx*4]
lea r10, [rdx + rcx*8 + 0x28]
nop dword [rax + rax]
mov r9d, dword [rdx + 0xc]
mov rcx, r9
cmp rax, r9
jb 0x140060a1c
add ecx, dword [rdx + 8]
cmp rax, rcx
jb 0x140060a30
add rdx, 0x28
cmp rdx, r10
jne 0x140060a08
xor r9d, r9d
mov rax, r9
add rsp, 0x28
ret
add rax, r11
jmp 0x140060a40
sub r8d, 1
add rax, 0x14
mov ecx, dword [rax + 4]
test ecx, ecx
jne 0x140060a4e
mov edx, dword [rax + 0xc]
test edx, edx
je 0x140060a25
test r8d, r8d
jg 0x140060a38
mov r9d, dword [rax + 0xc]
add r9, r11
mov rax, r9
add rsp, 0x28
ret
Function at 0x140001487
Capabilities:
Parse pe header

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x20
mov rax, qword [0x1401770c0]
mov dword [rax], 1
mov rax, qword [0x1401770d0]
mov dword [rax], 1
mov rax, qword [0x1401770e0]
mov dword [rax], 1
mov rax, qword [0x140177050]
mov qword [rbp - 8], rax
mov rax, qword [rbp - 8]
movzx eax, word [rax]
cmp ax, 0x5a4d
je 0x1400014d8
mov eax, 0
jmp 0x140001585
mov rax, qword [rbp - 8]
mov eax, dword [rax + 0x3c]
movsxd rdx, eax
mov rax, qword [rbp - 8]
add rax, rdx
mov qword [rbp - 0x10], rax
mov rax, qword [rbp - 0x10]
mov eax, dword [rax]
cmp eax, 0x4550
je 0x140001504
mov eax, 0
jmp 0x140001585
mov rax, qword [rbp - 0x10]
add rax, 0x18
mov qword [rbp - 0x18], rax
mov rax, qword [rbp - 0x18]
movzx eax, word [rax]
movzx eax, ax
cmp eax, 0x10b
je 0x14000152a
cmp eax, 0x20b
je 0x140001551
jmp 0x140001580
mov rax, qword [rbp - 0x18]
mov eax, dword [rax + 0x5c]
cmp eax, 0xe
ja 0x14000153d
mov eax, 0
jmp 0x140001585
mov rax, qword [rbp - 0x18]
mov eax, dword [rax + 0xd0]
test eax, eax
setne al
movzx eax, al
jmp 0x140001585
mov rax, qword [rbp - 0x18]
mov qword [rbp - 0x20], rax
mov rax, qword [rbp - 0x20]
mov eax, dword [rax + 0x6c]
cmp eax, 0xe
ja 0x14000156c
mov eax, 0
jmp 0x140001585
mov rax, qword [rbp - 0x20]
mov eax, dword [rax + 0xe0]
test eax, eax
setne al
movzx eax, al
jmp 0x140001585
mov eax, 0
add rsp, 0x20
pop rbp
ret

Function at 0x1400c71e0
Capabilities:
Query environment variable

Disassembly:
push r13
mov eax, 0x10078
push r12
call fcn.140154480
sub rsp, rax
xor eax, eax
mov r8d, 0x28
mov rdx, rcx
lea r12, [rsp + 0x20]
xor ecx, ecx
mov word [rsp + 0x70], ax
mov word [rsp + 0x20], cx
lea r13, [rsp + 0x70]
mov rcx, r12
call fcn.1400ec0e0
mov rdx, r13
mov r8d, 0x10000
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
lea edx, [rax - 1]
xor eax, eax
cmp edx, 0xffff
ja 0x1400c7241
mov rcx, r13
call sub.msvcrt.dll__wcsdup
add rsp, 0x10078
pop r12
pop r13
ret

Function at 0x1400c7250
Capabilities:
Set environment variable

Disassembly:
push r13
push r12
sub rsp, 0x78
xor eax, eax
mov r8d, 0x28
lea r13, [rsp + 0x20]
mov r12, rdx
mov rdx, rcx
mov word [rsp + 0x20], ax
mov rcx, r13
call fcn.1400ec0e0
mov rdx, r12
mov rcx, r13
call qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
nop
add rsp, 0x78
pop r12
pop r13
ret
Function at 0x1400c73a0
Capabilities:
Set environment variable

Disassembly:
push r15
push r14
push r13
push r12
push rbx
sub rsp, 0x70
mov rbx, rdx
mov r14, r8
mov r15, rcx
call fcn.1400e64c0
lea rdx, str.environ
mov rcx, rax
call qword [sym.imp.python37.dll_PyObject_GetAttrString]
mov rcx, rbx
mov r12, rax
call qword [sym.imp.python37.dll_PyUnicode_FromString]
mov r13, rax
test r14, r14
je 0x1400c746d
mov rdx, r14
mov rcx, rbx
call fcn.1400c7250
mov rcx, r14
mov rdx, 0xffffffffffffffff
call sub.python37.dll_PyUnicode_FromWideChar
mov rdx, r13
mov rcx, r12
mov r14, rax
mov r8, rax
call qword [sym.imp.python37.dll_PyObject_SetItem]
test eax, eax
jne 0x1400c74b6
sub qword [r14], 1
je 0x1400c7461
sub qword [r13], 1
je 0x1400c7455
sub qword [r12], 1
je 0x1400c7439
add rsp, 0x70
pop rbx
pop r12
pop r13
pop r14
pop r15
ret
mov rax, qword [r12 + 8]
mov rcx, r12
mov rax, qword [rax + 0x30]
add rsp, 0x70
pop rbx
pop r12
pop r13
pop r14
pop r15
jmp rax
mov rax, qword [r13 + 8]
mov rcx, r13
call qword [rax + 0x30]
jmp 0x1400c7424
mov rax, qword [r14 + 8]
mov rcx, r14
call qword [rax + 0x30]
jmp 0x1400c741d
lea r14, [rsp + 0x20]
mov r8d, 0x28
mov rdx, rbx
mov word [rsp + 0x20], 0
mov rcx, r14
call fcn.1400ec0e0
xor edx, edx
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
mov rdx, r13
mov rcx, r12
call qword [sym.imp.python37.dll_PyObject_DelItem]
test eax, eax
je 0x1400c741d
mov rcx, r15
call fcn.1400c70c0
jmp 0x1400c741d
mov ecx, 1
call qword [sym.imp.python37.dll_PyErr_PrintEx]
mov ecx, 1
call qword [sym.imp.python37.dll_Py_Exit]
nop
nop dword [rax]
Function at 0x140150d00
Capabilities:
Encode data using xor
Extract resource via kernel32 functions
Hash data with crc32

Disassembly:
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x28
cmp byte [0x140190ef9], 0
mov r12, rcx
mov r13, rdx
mov rdi, r8
je 0x140150d88
lea rdx, [0x14017570a]
mov rcx, rdi
call sub.msvcrt.dll_strcmp
test eax, eax
jne 0x140150ea0
mov rsi, qword [0x140190db8]
jmp 0x140150d45
lea rsi, [rdx + rax + 4]
mov rdx, rsi
mov rcx, rdi
call sub.msvcrt.dll_strcmp
mov rcx, rsi
mov ebx, eax
call sub.msvcrt.dll_strlen
lea rdx, [rsi + rax + 1]
mov eax, dword [rdx]
test ebx, ebx
jne 0x140150d40
movzx r9d, word [rdx + 4]
lea r8, [rdx + 6]
mov rcx, r12
mov rdx, r13
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
jmp fcn.14013e300
mov r8d, 0xa
mov edx, 3
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_FindResourceA]
xor ecx, ecx
mov rdx, rax
call qword [sym.imp.KERNEL32.dll_LoadResource]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_LockResource]
mov qword [0x140190db8], rax
mov rdx, rax
mov r9d, dword [rax]
lea rax, [rax + 4]
mov qword [0x140190db8], rax
mov eax, dword [rdx + 4]
lea rcx, [rdx + 8]
mov qword [0x140190db8], rcx
test eax, eax
je 0x140150e88
sub eax, 1
lea r8, [rdx + rax + 9]
mov eax, 0xffffffff
nop word [rax + rax]
movzx edx, byte [rcx]
xor edx, eax
mov eax, edx
and edx, 1
neg edx
shr eax, 1
and edx, 0xedb88320
xor eax, edx
mov edx, eax
and eax, 1
neg eax
shr edx, 1
and eax, 0xedb88320
xor edx, eax
mov eax, edx
and edx, 1
neg edx
shr eax, 1
and edx, 0xedb88320
xor eax, edx
mov edx, eax
and eax, 1
neg eax
shr edx, 1
and eax, 0xedb88320
xor edx, eax
mov eax, edx
and edx, 1
neg edx
shr eax, 1
and edx, 0xedb88320
xor eax, edx
mov edx, eax
and eax, 1
neg eax
shr edx, 1
and eax, 0xedb88320
xor edx, eax
mov eax, edx
shr eax, 1
and edx, 1
add rcx, 1
neg edx
and edx, 0xedb88320
xor eax, edx
mov edx, eax
and eax, 1
neg eax
shr edx, 1
and eax, 0xedb88320
xor eax, edx
cmp r8, rcx
jne 0x140150df0
not eax
cmp r9d, eax
jne 0x140150f39
mov byte [0x140190ef9], 1
jmp 0x140150d1e
cmp byte [0x140190ef8], 0
jne 0x140150d35
mov rbx, qword [sym.imp.python37.dll_PyDict_New]
lea rsi, [0x1401905a8]
call rbx
mov qword [0x140191828], rax
call rbx
mov qword [0x140191820], rax
call rbx
mov qword [0x140191818], rax
call rbx
mov qword [0x140191810], rax
call rbx
mov qword [0x140191808], rax
call rbx
mov qword [0x140191800], rax
call rbx
mov qword [0x1401917f8], rax
call rbx
mov rbp, qword [sym.imp.python37.dll_PyLong_FromLong]
mov rbx, 0xfffffffffffffffb
mov qword [0x1401917f0], rax
nop dword [rax]
mov ecx, ebx
call rbp
mov qword [rsi + rbx*8], rax
add rbx, 1
cmp rbx, 0x101
jne 0x140150f18
mov byte [0x140190ef8], 1
jmp 0x140150d35
lea rcx, str.Error__corrupted_constants_object
call sub.msvcrt.dll_puts
call sub.msvcrt.dll_abort
nop
nop dword [rax + rax]