joyce8/EMBER2024-capa huggingface dataset:
Function at 0x40169a
Capabilities:
Read file on windows
Write file on windows

Disassembly:
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x2e8
mov r12d, edx
mov edi, r8d
lea rdx, str..PHYSICALDRIVE_d
mov r8d, ecx
lea rcx, [rsp + 0x60]
mov r13d, r9d
call sub.msvcrt.dll_sprintf
xor r9d, r9d
lea rcx, [rsp + 0x60]
mov qword [rsp + 0x30], 0
mov dword [rsp + 0x28], 0
mov dword [rsp + 0x20], 3
mov r8d, 3
mov edx, 0xc0000000
call qword [sym.imp.KERNEL32.dll_CreateFileA]
cmp rax, 0xffffffffffffffff
mov rbp, rax
lea rcx, str.Accessing_physical_drive
je 0x4018c7
jmp 0x4018d0
mov rcx, rbp
call fcn.00401594
mov dword [rsp + 0x48], eax
call qword [sym.imp.msvcrt.dll___iob_func]
mov r8d, dword [rsp + 0x48]
lea rcx, [rax + 0x60]
lea rdx, str.Error:_Sector_size_of_this_drive_is__d__must_be__d_n
mov r9d, 0x200
call sub.msvcrt.dll_fprintf
jmp 0x401925
lea rcx, str.Reading_raw_drive
call fcn.00401621
jmp 0x401925
mov esi, dword [rsp + 0x5c]
cmp esi, 0x200
je 0x401918
call qword [sym.imp.msvcrt.dll___iob_func]
lea rdx, str.Error:_ReadFile_on_drive_only_got__d_of__d_bytes_n
lea rcx, [rax + 0x60]
mov r9d, 0x200
mov r8d, esi
call sub.msvcrt.dll_fprintf
jmp 0x401925
mov ecx, dword [0x004145f4]
cmp ecx, 0x1bd
jbe 0x4017b1
call qword [sym.imp.msvcrt.dll___iob_func]
lea rcx, str.Error:_MBR_will_not_fit__not_writing_n
lea rdx, [rax + 0x60]
call sub.msvcrt.dll_fputs
jmp 0x401925
lea rsi, [0x0040a020]
mov rdi, rbx
rep movsb byte [rdi], byte [rsi]
mov ebx, 1
test r13d, r13d
je 0x401826
lea edx, [r12 - 1]
mov eax, edx
shl eax, 4
add eax, 0x1be
cdqe
cmp byte [rsp + rax + 0xe0], 0x80
je 0x401826
cmp edx, 1
sbb eax, eax
xor ecx, ecx
and eax, 0xffffff80
cmp edx, 1
mov byte [rsp + 0x29e], al
mov al, pe_nt_image_headers64
mov r8d, eax
cmovne r8d, ecx
cmp edx, 2
mov byte [rsp + 0x2ae], r8b
mov r8d, eax
cmovne r8d, ecx
cmp edx, 3
cmovne eax, ecx
mov byte [rsp + 0x2be], r8b
mov byte [rsp + 0x2ce], al
test ebx, ebx
je 0x4018b3
xor r9d, r9d
xor r8d, r8d
xor edx, edx
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
mov qword [rsp + 0x20], 0
lea r9, [rsp + 0x5c]
mov r8d, 0x200
lea rdx, [rsp + 0xe0]
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x401878
lea rcx, str.Writing_MBR
xor ebx, ebx
call fcn.00401621
jmp 0x4018b3
mov r8d, dword [rsp + 0x5c]
mov ebx, 1
cmp r8d, 0x200
je 0x4018b3
mov dword [rsp + 0x48], r8d
xor bl, bl
call qword [sym.imp.msvcrt.dll___iob_func]
mov r8d, dword [rsp + 0x48]
lea rcx, [rax + 0x60]
lea rdx, str.Error:_WriteFile_on_drive_only_wrote__d_of__d_bytes_n
mov r9d, 0x200
call sub.msvcrt.dll_fprintf
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_CloseHandle]
test eax, eax
jne 0x40192c
lea rcx, str.CloseFile_on_drive
call fcn.00401621
xor ebx, ebx
jmp 0x40192c
mov rcx, rax
call fcn.00401594
cmp eax, 0x200
jne 0x401711
lea rbx, [rsp + 0xe0]
mov qword [rsp + 0x20], 0
lea r9, [rsp + 0x5c]
mov r8d, 0x200
mov rcx, rbp
mov rdx, rbx
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x401754
jmp 0x401743
test edi, edi
jne 0x401788
jmp 0x4017bd
xor ebx, ebx
jmp 0x4017c2
mov eax, ebx
add rsp, 0x2e8
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
ret
Function at 0x40193e
Capabilities:
Get disk information via ioctl

Disassembly:
sub rsp, 0x58
xor r9d, r9d
xor r8d, r8d
lea rax, [rsp + 0x4c]
mov qword [rsp + 0x20], rdx
mov qword [rsp + 0x38], 0
mov edx, 0x2d1080
mov dword [rsp + 0x28], 0xc
mov qword [rsp + 0x30], rax
call qword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
mov edx, 1
jne 0x40198a
lea rcx, str.GetDriveNumber:_DeviceIoControl_failed
call fcn.00401621
xor edx, edx
mov eax, edx
add rsp, 0x58
ret
Function at 0x403b00
Capabilities:
Allocate or change rwx memory
Execute shellcode via indirect call

Disassembly:
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x60
mov rsi, rcx
mov ecx, dword [0x00418580]
mov rdi, rdx
mov rbp, r8
test ecx, ecx
jle 0x403ce0
mov rax, qword [0x00418578]
xor ebx, ebx
nop
mov r9, qword [rax + 8]
cmp rsi, r9
jb 0x403b4c
mov rdx, qword [rax + 0x10]
mov edx, dword [rdx + 8]
add r9, rdx
cmp rsi, r9
jb 0x403c20
add ebx, 1
add rax, 0x18
cmp ebx, ecx
jne 0x403b30
mov rcx, rsi
call fcn.00404130
test rax, rax
mov r12, rax
je 0x403d04
movsxd rbx, ebx
lea r13, [rsp + 0x30]
lea r14, [rbx + rbx*2]
mov rbx, qword [0x00418578]
shl r14, 3
add rbx, r14
mov qword [rbx + 0x10], rax
mov dword [rbx], 0
call fcn.00404210
mov edx, dword [r12 + 0xc]
mov r8d, 0x30
add rax, rdx
mov rdx, r13
mov qword [rbx + 8], rax
mov rax, qword [0x00418578]
mov rbx, qword [sym.imp.KERNEL32.dll_VirtualQuery]
mov rcx, qword [rax + r14 + 8]
call rbx
test rax, rax
je 0x403ce7
mov eax, dword [rsp + 0x54]
cmp eax, 4
jne 0x403c95
add dword [0x00418580], 1
mov r8d, 0x30
mov rdx, r13
mov rcx, rsi
call rbx
test rax, rax
je 0x403d13
mov eax, dword [rsp + 0x54]
cmp eax, 4
jne 0x403c30
mov r8, rbp
mov rdx, rdi
mov rcx, rsi
add rsp, 0x60
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
jmp sub.msvcrt.dll_memcpy
lea r13, [rsp + 0x30]
mov rbx, qword [sym.imp.KERNEL32.dll_VirtualQuery]
jmp 0x403bdb
cmp eax, 0x40
je 0x403bfb
lea r9, [rsp + 0x2c]
mov r8d, 0x40
mov rdx, qword [rsp + 0x48]
mov rcx, qword [rsp + 0x30]
mov rbx, qword [sym.imp.KERNEL32.dll_VirtualProtect]
call rbx
mov r8, rbp
mov rdx, rdi
mov rcx, rsi
call sub.msvcrt.dll_memcpy
mov eax, dword [rsp + 0x54]
cmp eax, 0x40
je 0x403c86
cmp eax, 4
je 0x403c86
lea r9, [rsp + 0x2c]
mov r8d, dword [rsp + 0x2c]
mov rdx, qword [rsp + 0x48]
mov rcx, qword [rsp + 0x30]
call rbx
nop
add rsp, 0x60
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
ret
cmp eax, 0x40
je 0x403bd4
mov r9, qword [0x00418578]
mov r8d, 0x40
mov rdx, qword [rsp + 0x48]
mov rcx, qword [rsp + 0x30]
add r9, r14
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x403bd4
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call fcn.00403aa0
nop word [rax + rax]
xor ebx, ebx
jmp 0x403b57
mov rax, qword [0x00418578]
mov edx, dword [r12 + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + r14 + 8]
call fcn.00403aa0
lea rcx, str.Address__p_has_no_image_section
mov rdx, rsi
call fcn.00403aa0
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, rsi
mov edx, 0x30
call fcn.00403aa0
nop
nop dword [rax + rax]

Function at 0x404020
Capabilities:
Parse pe header

Disassembly:
xor eax, eax
cmp word [rcx], 0x5a4d
je 0x404030
repz ret
movsxd rdx, dword [rcx + 0x3c]
add rcx, rdx
cmp dword [rcx], 0x4550
jne 0x404029
xor eax, eax
cmp word [rcx + 0x18], 0x20b
sete al
ret
Function at 0x404050
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 0x404090
lea ecx, [rcx - 1]
lea rcx, [rcx + rcx*4]
lea r9, [rax + rcx*8 + 0x28]
mov ecx, dword [rax + 0xc]
mov r8d, ecx
cmp r8, rdx
ja 0x404087
add ecx, dword [rax + 8]
cmp rdx, rcx
jb 0x404092
add rax, 0x28
cmp rax, r9
jne 0x404074
xor eax, eax
repz ret

Function at 0x404130
Capabilities:
Enumerate pe sections

Disassembly:
push rbx
sub rsp, 0x20
mov rbx, rcx
lea rcx, [0x00400000]
call fcn.00404020
test eax, eax
je 0x404160
lea rcx, [0x00400000]
mov rdx, rbx
sub rdx, rcx
add rsp, 0x20
pop rbx
jmp fcn.00404050
xor eax, eax
add rsp, 0x20
pop rbx
ret

Function at 0x404680
Capabilities:
Get thread local storage value

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x28
lea rcx, [0x00418b60]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x00418b88]
test rbx, rbx
je 0x4046d4
mov rbp, qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, qword [sym.imp.KERNEL32.dll_GetLastError]
nop
mov ecx, dword [rbx]
call rbp
mov rsi, rax
call rdi
test eax, eax
jne 0x4046cb
test rsi, rsi
je 0x4046cb
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x4046b0
mov rax, qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
lea rcx, [0x00418b60]
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
jmp rax
Function at 0x140089df0
Capabilities:
Parse pe header

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rsi
mov qword [rax + 0x18], rdi
mov qword [rax + 0x20], r14
push r15
sub rsp, 0x20
mov esi, r8d
mov ebx, edx
mov r14d, ecx
test r8d, r8d
jne 0x140089bc4
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x140089bc4
mov ecx, 0x5a4d
cmp word [rax], cx
jne 0x140089bc4
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
jne 0x140089bc4
mov eax, 0x20b
cmp word [rcx + 0x18], ax
jne 0x140089bc4
cmp dword [rcx + 0x84], 0xe
jbe 0x140089bc4
cmp dword [rcx + 0xf8], esi
je 0x140089bc4
mov ecx, r14d
call fcn.140089d0c
mov ecx, 2
call fcn.140082b6c
nop
cmp byte [0x1400ee628], 0
jne 0x140089c8e
mov r15d, 1
mov eax, r15d
xchg dword [0x1400ee618], eax
test ebx, ebx
jne 0x140089c37
mov rdi, qword [0x1400e9088]
mov edx, edi
and edx, 0x3f
lea ecx, [rbx + 0x40]
sub ecx, edx
xor eax, eax
ror rax, cl
xor rax, rdi
mov rcx, qword [0x1400ee620]
cmp rcx, rax
je 0x140089c2e
xor rdi, rcx
mov ecx, edx
ror rdi, cl
mov rcx, rdi
call qword [fcn.14000fd40]
xor r8d, r8d
xor edx, edx
xor ecx, ecx
call rdi
lea rcx, [0x1400ee860]
jmp 0x140089c43
cmp ebx, r15d
jne 0x140089c49
lea rcx, [0x1400ee878]
call fcn.14008ab0c
nop
test ebx, ebx
jne 0x140089c60
lea rdx, [0x1400a87a8]
lea rcx, [0x1400a8778]
call fcn.14008add4
lea rdx, [0x1400a87b8]
lea rcx, [0x1400a87b0]
call fcn.14008add4
movzx eax, byte [0x1400ee628]
test esi, esi
cmove eax, r15d
mov byte [0x1400ee628], al
jmp 0x140089c8e
mov ecx, 2
call fcn.140082bc0
test esi, esi
jne 0x140089ca5
mov ecx, r14d
call fcn.140089cc0
int3
mov rbx, qword [rsp + 0x30]
mov rsi, qword [rsp + 0x38]
mov rdi, qword [rsp + 0x40]
mov r14, qword [rsp + 0x48]
add rsp, 0x20
pop r15
ret
xor r8d, r8d
xor edx, edx
jmp 0x140089b54
Function at 0x14000f470
Capabilities:
Encrypt data using rc4 prga

Disassembly:
mov dword [rsp + 0x20], r9d
mov dword [rsp + 0x18], r8d
mov qword [rsp + 0x10], rdx
mov qword [rsp + 8], rcx
sub rsp, 0x38
mov dword [rsp + 0x20], 0
jmp 0x14000f49c
mov eax, dword [rsp + 0x20]
inc eax
mov dword [rsp + 0x20], eax
mov eax, dword [rsp + 0x50]
cmp dword [rsp + 0x20], eax
jae 0x14000f4e7
mov eax, dword [rsp + 0x20]
mov ecx, dword [rsp + 0x58]
and ecx, 0xff
mov rdx, qword [rsp + 0x48]
movzx eax, byte [rdx + rax]
xor eax, ecx
mov ecx, dword [rsp + 0x20]
mov rdx, qword [rsp + 0x48]
mov byte [rdx + rcx], al
mov eax, dword [rsp + 0x58]
shr eax, 8
mov ecx, dword [rsp + 0x58]
and ecx, 0xff
shl ecx, 0x18
or eax, ecx
mov dword [rsp + 0x58], eax
jmp 0x14000f492
mov rax, qword [rsp + 0x40]
mov qword [rsp + 0x28], rax
mov rax, qword [rsp + 0x28]
mov rcx, rax
call fcn.140027aa0
mov eax, dword [rsp + 0x50]
xor edx, edx
mov ecx, 2
div rcx
mov r8, rax
mov rdx, qword [rsp + 0x48]
mov rcx, qword [rsp + 0x40]
call fcn.1400267c0
mov rax, qword [rsp + 0x40]
add rsp, 0x38
ret
Function at 0x140028b44
Capabilities:
Parse pe header

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

Function at 0x14002d470
Capabilities:
Parse pe header

Disassembly:
xor r8d, r8d
xor edx, edx
jmp 0x14002d26c
Function at 0x1400305d0
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 0x140030657
mov rsi, rbx
cmp word [rax], bp
je 0x140030616
or rax, 0xffffffffffffffff
inc rax
cmp word [rsi + rax*2], bp
jne 0x140030600
lea rsi, [rsi + rax*2]
add rsi, 2
cmp word [rsi], bp
jne 0x1400305fc
sub rsi, rbx
add rsi, 2
sar rsi, 1
add rsi, rsi
mov rcx, rsi
call fcn.14002f1f8
mov rdi, rax
test rax, rax
je 0x140030644
mov r8, rsi
mov rdx, rbx
mov rcx, rax
call fcn.14002a1c0
mov rbp, rdi
xor ecx, ecx
call fcn.14002f334
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 0x140035210
Capabilities:
Parse pe header

Disassembly:
mov eax, 0x5a4d
cmp word [rcx], ax
jne 0x140035238
movsxd rdx, dword [rcx + 0x3c]
add rdx, rcx
cmp dword [rdx], 0x4550
jne 0x140035238
xor eax, eax
mov ecx, 0x20b
cmp word [rdx + 0x18], cx
sete al
ret
xor eax, eax
ret
Function at 0x6d7d3ef0
Capabilities:
Allocate or change rwx memory

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rsi, dword [0x6d7f55e4]
test esi, esi
mov rbx, rcx
mov rbp, rdx
mov rdi, r8
jle 0x6d7d4078
mov rax, qword [0x6d7f55e8]
xor ecx, ecx
add rax, 0x18
nop
mov rdx, qword [rax]
cmp rbx, rdx
jb 0x6d7d3f3c
mov r8, qword [rax + 8]
mov r8d, dword [r8 + 8]
add rdx, r8
cmp rbx, rdx
jb 0x6d7d3fc5
add ecx, 1
add rax, 0x28
cmp ecx, esi
jne 0x6d7d3f20
mov rcx, rbx
call sym.__mingw_GetSectionForAddress
test rax, rax
mov r12, rax
je 0x6d7d40ad
mov rax, qword [0x6d7f55e8]
lea rsi, [rsi + rsi*4]
shl rsi, 3
add rax, rsi
mov qword [rax + 0x20], r12
mov dword [rax], 0
call sym._GetPEImageBase
mov ecx, dword [r12 + 0xc]
lea rdx, [rsp + 0x20]
mov r8d, 0x30
add rcx, rax
mov rax, qword [0x6d7f55e8]
mov qword [rax + rsi + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x6d7d4090
mov eax, dword [rsp + 0x44]
lea edx, [rax - 4]
and edx, 0xfffffffb
je 0x6d7d3fbe
sub eax, 0x40
and eax, 0xffffffbf
jne 0x6d7d4020
add dword [0x6d7f55e4], 1
cmp edi, 8
jae 0x6d7d3ff3
test dil, 4
jne 0x6d7d4064
test edi, edi
je 0x6d7d3fe8
movzx eax, byte [rbp]
test dil, 2
mov byte [rbx], al
jne 0x6d7d407f
add rsp, 0x50
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
mov eax, edi
sub edi, 1
mov rdx, qword [rbp + rax - 8]
cmp edi, 8
mov qword [rbx + rax - 8], rdx
jb 0x6d7d3fe8
and edi, 0xfffffff8
xor eax, eax
mov edx, eax
add eax, 8
mov rcx, qword [rbp + rdx]
cmp eax, edi
mov qword [rbx + rdx], rcx
jb 0x6d7d400c
jmp 0x6d7d3fe8
add rsi, qword [0x6d7f55e8]
mov r8d, 0x40
mov rcx, qword [rsp + 0x20]
mov rdx, qword [rsp + 0x38]
mov r9, rsi
mov qword [rsi + 8], rcx
mov qword [rsi + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x6d7d3fbe
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call sym.__report_error
mov eax, dword [rbp]
mov edi, edi
mov dword [rbx], eax
mov eax, dword [rbp + rdi - 4]
mov dword [rbx + rdi - 4], eax
jmp 0x6d7d3fe8
xor esi, esi
jmp 0x6d7d3f47
mov edi, edi
movzx eax, word [rbp + rdi - 2]
mov word [rbx + rdi - 2], ax
jmp 0x6d7d3fe8
mov rax, qword [0x6d7f55e8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov edx, dword [r12 + 8]
mov r8, qword [rax + rsi + 0x18]
call sym.__report_error
lea rcx, str.Address__p_has_no_image_section
mov rdx, rbx
call sym.__report_error
nop
nop dword [rax]

Function at 0x6d7d4800
Capabilities:
Get thread local storage value

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x28
lea rcx, [0x6d7f58c0]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x6d7f58a0]
test rbx, rbx
je 0x6d7d4854
mov rbp, qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, qword [sym.imp.KERNEL32.dll_GetLastError]
nop
mov ecx, dword [rbx]
call rbp
mov rsi, rax
call rdi
test eax, eax
jne 0x6d7d484b
test rsi, rsi
je 0x6d7d484b
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x6d7d4830
lea rcx, [0x6d7f58c0]
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
Function at 0x6d7d4a90
Capabilities:
Parse pe header

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

Function at 0x6d7d4ab0
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 0x6d7d4af1
sub ecx, 1
lea rcx, [rcx + rcx*4]
lea r9, [rax + rcx*8 + 0x28]
mov r8d, dword [rax + 0xc]
cmp r8, rdx
mov rcx, r8
ja 0x6d7d4ae8
add ecx, dword [rax + 8]
cmp rcx, rdx
ja 0x6d7d4af3
add rax, 0x28
cmp rax, r9
jne 0x6d7d4ad4
xor eax, eax
ret

Function at 0x6d7d4b90
Capabilities:
Enumerate pe sections

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

Function at 0x6d7d4d00
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r8, qword [0x6d7f21f0]
xor eax, eax
cmp word [r8], 0x5a4d
mov rdx, rcx
je 0x6d7d4d20
add rsp, 0x28
ret
mov rcx, r8
call sym._ValidateImageBase.part.0
test eax, eax
je 0x6d7d4d18
movsxd rax, dword [r8 + 0x3c]
mov rcx, rdx
sub rcx, r8
add r8, rax
movzx edx, word [r8 + 6]
movzx eax, word [r8 + 0x14]
test edx, edx
lea rax, [r8 + rax + 0x18]
je 0x6d7d4d7d
sub edx, 1
lea rdx, [rdx + rdx*4]
lea r9, [rax + rdx*8 + 0x28]
nop dword [rax + rax]
mov r8d, dword [rax + 0xc]
cmp rcx, r8
mov rdx, r8
jb 0x6d7d4d74
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x6d7d4d84
add rax, 0x28
cmp rax, r9
jne 0x6d7d4d60
xor eax, eax
add rsp, 0x28
ret
mov eax, dword [rax + 0x24]
not eax
shr eax, 0x1f
add rsp, 0x28
ret

Function at 0x6d7d4da0
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r11, qword [0x6d7f21f0]
cmp word [r11], 0x5a4d
mov r9d, ecx
jne 0x6d7d4e0e
mov rcx, r11
call sym._ValidateImageBase.part.0
test eax, eax
je 0x6d7d4e0e
movsxd rax, dword [r11 + 0x3c]
add rax, r11
mov edx, dword [rax + 0x90]
test edx, edx
je 0x6d7d4e0e
movzx ecx, word [rax + 0x14]
lea rcx, [rax + rcx + 0x18]
movzx eax, word [rax + 6]
test eax, eax
je 0x6d7d4e0e
sub eax, 1
lea rax, [rax + rax*4]
lea rax, [rcx + rax*8 + 0x28]
mov r10d, dword [rcx + 0xc]
cmp rdx, r10
mov r8, r10
jb 0x6d7d4e05
add r8d, dword [rcx + 8]
cmp rdx, r8
jb 0x6d7d4e15
add rcx, 0x28
cmp rcx, rax
jne 0x6d7d4df0
xor eax, eax
add rsp, 0x28
ret
add rdx, r11
jne 0x6d7d4e28
jmp 0x6d7d4e0e
sub r9d, 1
add rdx, 0x14
mov ecx, dword [rdx + 4]
test ecx, ecx
jne 0x6d7d4e36
mov eax, dword [rdx + 0xc]
test eax, eax
je 0x6d7d4e0e
test r9d, r9d
jg 0x6d7d4e20
mov eax, dword [rdx + 0xc]
add rax, r11
add rsp, 0x28
ret
Function at 0x6d7d5170
Capabilities:
Write file on windows

Disassembly:
push rsi
push rbx
sub rsp, 0x38
lea rax, [rsp + 0x58]
mov rbx, rcx
mov ecx, 2
mov qword [rsp + 0x58], rdx
mov qword [rsp + 0x60], r8
mov qword [rsp + 0x68], r9
mov qword [rsp + 0x28], rax
call sym.__acrt_iob_func
mov r8d, 0x1b
mov edx, 1
lea rcx, str.Mingw_w64_runtime_failure:_n
mov r9, rax
call sym.fwrite
mov rsi, qword [rsp + 0x28]
mov ecx, 2
call sym.__acrt_iob_func
mov rdx, rbx
mov rcx, rax
mov r8, rsi
call sym.vfprintf
call sym.abort
nop
nop
nop
nop
nop
nop
nop
nop
Function at 0x1805f2058
Capabilities:
Decompress data using aplib

Disassembly:
call 0x1805f21df
push r10
mov r10, rsp
push r10
mov rsi, qword [r10 + 0x10]
mov rdi, qword [r10 + 0x20]
cld
mov dl, 0x80
mov al, byte [rsi]
inc rsi
mov byte [rdi], al
inc rdi
mov ebx, 2
add dl, dl
jne 0x1805f2089
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x1805f206f
add dl, dl
jne 0x1805f2096
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x1805f20f6
xor eax, eax
add dl, dl
jne 0x1805f20a5
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x1805f21ad
add dl, dl
jne 0x1805f20b6
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x1805f20c3
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x1805f20d0
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x1805f20dd
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
je 0x1805f20ea
push rdi
mov eax, eax
sub rdi, rax
mov al, byte [rdi]
pop rdi
mov byte [rdi], al
inc rdi
mov ebx, 2
jmp 0x1805f207e
mov eax, 1
add dl, dl
jne 0x1805f2106
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x1805f2113
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x1805f20fb
sub eax, ebx
mov ebx, 1
jne 0x1805f214c
mov ecx, 1
add dl, dl
jne 0x1805f212e
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x1805f213b
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x1805f2123
push rsi
mov rsi, rdi
sub rsi, rbp
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x1805f207e
dec eax
shl eax, 8
mov al, byte [rsi]
inc rsi
mov ebp, eax
mov ecx, 1
add dl, dl
jne 0x1805f2168
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x1805f2175
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x1805f215d
cmp eax, 0x7d00
jae 0x1805f219b
cmp eax, 0x500
jb 0x1805f2196
inc ecx
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x1805f207e
cmp eax, 0x7f
ja 0x1805f219e
add ecx, 2
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x1805f207e
mov al, byte [rsi]
inc rsi
xor ecx, ecx
shr al, 1
je 0x1805f21d2
adc ecx, 2
mov ebp, eax
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
mov ebx, 1
jmp 0x1805f207e
pop r10
sub rdi, qword [r10 + 0x20]
mov eax, edi
pop r10
ret 0x20
Function at 0x180017128
Capabilities:
Access peb ldr_data

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x20
mov rax, qword gs:[0x30]
mov rcx, qword [rax + 0x60]
mov rdi, qword [rcx + 0x18]
add rdi, 0x20
mov rbx, qword [rdi]
cmp rbx, rdi
je 0x18001719a
lea rsi, str.tier0_s64.dll
cmp rsi, 1
jbe 0x180017176
mov rdx, qword [rbx + 0x50]
mov rcx, rsi
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll__wcsicmp]
test eax, eax
je 0x1800171ac
cmp rsi, 1
jne 0x180017192
cmp word [rbx + 0x48], 0x12
jne 0x180017192
mov rax, qword [rbx + 0x50]
movabs rcx, 0x6c00640074006e
cmp qword [rax], rcx
je 0x1800171ac
mov rbx, qword [rbx]
cmp rbx, rdi
jne 0x18001715b
xor eax, eax
mov rbx, qword [rsp + 0x30]
mov rsi, qword [rsp + 0x38]
add rsp, 0x20
pop rdi
ret
mov rax, qword [rbx + 0x20]
jmp 0x18001719c

Function at 0x180018a88
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
not r8d
mov r9d, 4
movzx eax, byte [rcx]
inc rcx
movzx edx, r8b
xor rdx, rax
shr r8d, 8
lea rax, [0x180050d50]
xor r8d, dword [rax + rdx*4]
sub r9, 1
jne 0x180018a91
not r8d
mov eax, r8d
ret

Function at 0x180018abc
Capabilities:
Hash data with crc32

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rdi
not r8d
mov r10, rcx
mov r9d, r8d
test rdx, rdx
je 0x180018b16
mov r11b, 0x23
lea rdi, [0x180050d50]
movzx ebx, byte [r10]
dec rdx
inc r10
cmp bl, r11b
jne 0x180018b00
cmp rdx, 2
jb 0x180018b00
cmp byte [r10], r11b
jne 0x180018b00
cmp byte [r10 + 1], r11b
cmove r9d, r8d
movzx ecx, r9b
xor rcx, rbx
shr r9d, 8
xor r9d, dword [rdi + rcx*4]
test rdx, rdx
jne 0x180018ade
jmp 0x180018b57
mov dl, byte [rcx]
inc r10
test dl, dl
je 0x180018b57
mov r11b, 0x23
lea rdi, [0x180050d50]
cmp dl, r11b
jne 0x180018b3b
cmp byte [r10], r11b
jne 0x180018b3b
cmp byte [r10 + 1], r11b
cmove r9d, r8d
movzx ecx, r9b
movzx eax, dl
mov dl, byte [r10]
xor rcx, rax
shr r9d, 8
inc r10
xor r9d, dword [rdi + rcx*4]
test dl, dl
jne 0x180018b29
mov rbx, qword [rsp + 8]
not r9d
mov rdi, qword [rsp + 0x10]
mov eax, r9d
ret