Function at 0x1401bb680
Capabilities:
Acquire debug privileges
Read file via mapping

Disassembly:
push rbp
push rbx
lea rbp, [rsp - 0x278]
sub rsp, 0x378
mov rax, qword [0x1403ad830]
xor rax, rsp
mov qword [rbp + 0x250], rax
cmp byte [rcx + 0x24], 0
mov rbx, rcx
jne 0x1401bb6b6
mov eax, 0xffffff9c
jmp 0x1401bb9bc
mov rax, qword [rcx]
lea rdx, str.DevicePhysicalMemory
mov qword [rcx + 8], rax
lea rcx, [rbp - 0x58]
mov qword [rsp + 0x370], r13
xor r13d, r13d
mov qword [rsp + 0x58], r13
mov dword [rsp + 0x40], r13d
call qword [0x140452420]
lea rax, [rbp - 0x58]
mov dword [rbp + 0x20], 0x30
xorps xmm0, xmm0
mov qword [rbp + 0x30], rax
lea r8, [rbp + 0x20]
mov qword [rbp + 0x28], r13
lea edx, [r13 + 4]
mov dword [rbp + 0x38], r13d
lea rcx, [rsp + 0x58]
movdqu xmmword [rbp + 0x40], xmm0
call qword [0x140452428]
test eax, eax
jne 0x1401bc008
mov qword [rsp + 0x3a0], rdi
mov qword [rsp + 0x3a8], r12
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov rcx, qword [rsp + 0x58]
lea edx, [r13 + 4]
mov r9d, 0x30000
mov qword [rbp - 0x80], rax
xor r8d, r8d
mov qword [rsp + 0x20], 0x1000
mov rdi, rax
call qword [sym.imp.KERNEL32.dll_MapViewOfFile]
lea r8, [rbp + 0x54]
mov qword [rbp + 0x50], 1
lea rdx, str.SeDebugPrivilege
mov qword [rsp + 0x48], rax
xor ecx, ecx
mov dword [rbp + 0x5c], 2
mov r12, rax
mov dword [rbp + 0x58], r13d
call qword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueW]
lea r8, [rbp - 0x70]
mov rcx, rdi
lea edx, [r13 + 0x20]
call qword [sym.imp.ADVAPI32.dll_OpenProcessToken]
mov rcx, qword [rbp - 0x70]
lea r9d, [r13 + 0x10]
lea r8, [rbp + 0x50]
mov qword [rsp + 0x28], r13
xor edx, edx
mov qword [rsp + 0x20], r13
call qword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
mov rcx, qword [rbp - 0x70]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
lea rdx, str.DeviceTcp
lea rcx, [rbp - 0x58]
call qword [0x140452420]
lea rax, [rbp - 0x58]
mov dword [rsp + 0x28], r13d
lea r9, [rbp - 0x28]
mov qword [rbp], rax
lea r8, [rbp - 0x10]
mov qword [rbp + 0x10], r13
mov edx, 0x100000
mov dword [rbp - 0x10], reloc.ODBC32.dll_SQLAllocHandle
lea rcx, [rbp - 0x68]
mov qword [rbp - 8], r13
mov dword [rbp + 8], 0x40
mov qword [rbp + 0x18], r13
mov dword [rsp + 0x20], 3
call qword [0x140452430]
lea rdx, str.DeviceUdp
lea rcx, [rbp - 0x58]
call qword [0x140452420]
lea rax, [rbp - 0x58]
mov dword [rsp + 0x28], r13d
lea r9, [rbp - 0x28]
mov qword [rbp], rax
lea r8, [rbp - 0x10]
mov dword [rsp + 0x20], 3
mov edx, 0x100000
lea rcx, [rbp - 0x60]
call qword [0x140452430]
mov ecx, 0x200000
call fcn.140299e90
mov ecx, 0x800
mov qword [rbp - 0x18], rax
mov rdi, rax
call fcn.140299e90
lea r9, [rsp + 0x70]
mov qword [rbp - 0x78], rax
mov r8d, 0x200000
mov dword [rsp + 0x70], reloc.ODBC32.dll_SQLFreeStmt
mov rdx, rdi
lea ecx, [r13 + 0x10]
call qword [0x140452418]
test eax, eax
jne 0x1401bbff2
mov qword [rsp + 0x398], rsi
mov ecx, r13d
mov qword [rsp + 0x368], r14
lea rsi, [rdi + 4]
mov qword [rsp + 0x360], r15
mov r14, rsi
mov r15d, dword [rdi]
mov dword [rsp + 0x74], r15d
mov qword [rbp - 0x20], rsi
test r15d, r15d
je 0x1401bb8f4
mov edx, dword [rbx + 0x20]
mov r8, qword [rbp - 0x68]
movzx eax, word [r14]
cmp eax, edx
jne 0x1401bb8e9
movzx eax, word [r14 + 6]
cmp eax, r8d
je 0x1401bb8f8
add r14, 0x10
inc ecx
cmp ecx, r15d
jb 0x1401bb8d7
mov r14, qword [rbp - 0x78]
xor edi, edi
mov qword [rsp + 0x78], rsi
mov r13, rsi
mov ecx, edi
test r15d, r15d
je 0x1401bb933
mov edx, dword [rbx + 0x20]
mov r8, qword [rbp - 0x60]
movzx eax, word [r13]
cmp eax, edx
jne 0x1401bb923
movzx eax, word [r13 + 6]
cmp eax, r8d
je 0x1401bb93c
add r13, 0x10
inc ecx
mov qword [rsp + 0x78], r13
cmp ecx, r15d
jb 0x1401bb910
mov r13, qword [rbp - 0x78]
mov qword [rsp + 0x78], r13
xor edx, edx
lea rcx, [rbp + 0x170]
lea r8d, [rdx + 0x70]
call fcn.140285450
xor edx, edx
lea rcx, [rbp + 0x1e0]
lea r8d, [rdx + 0x70]
call fcn.140285450
mov r8, qword [rsp + 0x58]
lea r9, [rbp + 0x170]
mov rdx, r12
mov rcx, r14
call fcn.1401bb250
test eax, eax
jne 0x1401bb9d5
lea rcx, str.map_tcp_fail_n
call fcn.14002d4e0
mov eax, 0xfffffffe
mov r14, qword [rsp + 0x368]
mov rsi, qword [rsp + 0x398]
mov r15, qword [rsp + 0x360]
mov rdi, qword [rsp + 0x3a0]
mov r12, qword [rsp + 0x3a8]
mov r13, qword [rsp + 0x370]
mov rcx, qword [rbp + 0x250]
xor rcx, rsp
call fcn.140283120
add rsp, 0x378
pop rbx
pop rbp
ret
mov r8, qword [rsp + 0x58]
lea r9, [rbp + 0x1e0]
mov rdx, r12
mov rcx, r13
call fcn.1401bb250
test eax, eax
jne 0x1401bba03
lea rcx, str.map_udp_fail_n
call fcn.14002d4e0
mov eax, 0xfffffffd
jmp 0x1401bb98c
xor r9d, r9d
xor r8d, r8d
xor ecx, ecx
lea edx, [r9 + 1]
call qword [sym.imp.KERNEL32.dll_CreateEventW]
mov qword [rbp - 0x48], rdi
mov qword [rbp - 0x40], rdi
mov qword [rbp - 0x38], rdi
mov rdi, rsi
mov qword [rbp - 0x30], rax
test r15d, r15d
je 0x1401bbf9b
mov r13, qword [rbp + 0x177]
mov rsi, r15
nop dword [rax + rax]
xor edx, edx
lea rcx, [rbp + 0x100]
lea r8d, [rdx + 0x70]
call fcn.140285450
movzx eax, byte [r14 + 4]
cmp byte [rdi + 4], al
jne 0x1401bbcd1
mov r8, qword [rsp + 0x58]
lea r9, [rbp + 0x100]
mov rdx, r12
mov rcx, rdi
call fcn.1401bb250
test eax, eax
je 0x1401bbcd1
mov rax, qword [rbp + 0x174]
cmp byte [rbp + 0x104], al
jne 0x1401bbcd1
mov rax, qword [rbp + 0x175]
cmp byte [rbp + 0x105], al
jne 0x1401bbcd1
mov rax, qword [rbp + 0x176]
cmp byte [rbp + 0x106], al
jne 0x1401bbcd1
cmp byte [rbp + 0x107], r13b
jne 0x1401bbcd1
movzx r12d, byte [rbp + 0x110]
lea eax, [r12 - 1]
cmp al, 1
ja 0x1401bbccc
cmp byte [rbp + 0x111], 0
jne 0x1401bbccc
cmp byte [rbp + 0x112], 0
jne 0x1401bbccc
cmp byte [rbp + 0x113], 0
jne 0x1401bbccc
movzx r8d, word [rdi]
xor edx, edx
lea ecx, [rdx + 0x40]
call qword [sym.imp.KERNEL32.dll_OpenProcess]
mov r15, rax
test rax, rax
je 0x1401bbccc
movzx edx, word [rdi + 6]
lea r9, [rsp + 0x50]
mov r8, qword [rbp - 0x80]
xor eax, eax
mov dword [rsp + 0x30], 2
mov rcx, r15
mov dword [rsp + 0x28], eax
mov dword [rsp + 0x20], eax
call qword [sym.imp.KERNEL32.dll_DuplicateHandle]
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rsp + 0x50]
test rcx, rcx
je 0x1401bbccc
xor eax, eax
mov qword [rbp + 0x70], rax
mov qword [rbp + 0x88], rax
mov byte [rbp + 0x70], 4
mov byte [rbp + 0x88], 3
mov qword [rbp + 0x90], rax
mov qword [rbp + 0x98], rax
mov qword [rbp + 0xa0], rax
mov qword [rbp + 0xa8], rax
mov qword [rbp + 0xb0], rax
mov qword [rbp + 0xb8], rax
mov qword [rbp + 0xc0], rax
mov qword [rbp + 0xc8], rax
mov qword [rbp + 0xd0], rax
mov qword [rbp + 0xd8], rax
mov qword [rbp + 0xe0], rax
mov qword [rbp + 0xe8], rax
mov qword [rbp + 0xf0], rax
mov qword [rbp + 0x60], rax
mov qword [rbp + 0x68], rax
mov qword [rbp + 0x78], rax
mov qword [rbp + 0x80], rax
cmp r12b, 2
jne 0x1401bbc34
mov dword [rsp + 0x40], eax
lea r8, [rbp + 0x60]
lea rax, [rbp - 0x48]
mov r9d, reloc.ODBC32.dll_SQLAllocHandle
mov qword [rsp + 0x38], rax
mov edx, 0x210012
lea rax, [rsp + 0x40]
mov qword [rsp + 0x30], rax
lea rax, [rbp + 0xc0]
mov dword [rsp + 0x28], SQLMoreResults
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_DeviceIoControl]
mov rcx, qword [rsp + 0x50]
test eax, eax
je 0x1401bbcc6
lea rax, [rbp - 0x48]
mov r9d, reloc.ODBC32.dll_SQLAllocHandle
mov qword [rsp + 0x38], rax
lea r8, [rbp + 0x78]
lea rax, [rsp + 0x40]
mov edx, 0x210012
mov qword [rsp + 0x30], rax
lea rax, [rbp + 0x90]
mov dword [rsp + 0x28], 0x30
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
je 0x1401bbcc1
movzx ecx, word [rbp + 0x9c]
mov dword [rsp + 0x60], 1
call sub.WS2_32.dll_ntohs
mov rdx, qword [rbx + 8]
movzx eax, ax
mov dword [rsp + 0x64], eax
movzx eax, word [rdi]
mov dword [rsp + 0x68], eax
cmp qword [rbx + 0x10], rdx
je 0x1401bbcb4
movsd xmm0, qword [rsp + 0x60]
movsd qword [rdx], xmm0
mov dword [rdx + 8], eax
add qword [rbx + 8], 0xc
jmp 0x1401bbcc1
lea r8, [rsp + 0x60]
mov rcx, rbx
call fcn.1401baf00
mov rcx, qword [rsp + 0x50]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov r12, qword [rsp + 0x48]
add rdi, 0x10
sub rsi, 1
jne 0x1401bba40
mov r15d, dword [rsp + 0x74]
mov rsi, qword [rbp - 0x20]
mov r13, qword [rsp + 0x78]
test r15d, r15d
je 0x1401bbf9b
mov r12, qword [rbp + 0x1e7]
nop dword [rax]
xor edx, edx
lea rcx, [rbp + 0x100]
lea r8d, [rdx + 0x70]
call fcn.140285450
movzx eax, byte [r13 + 4]
cmp byte [rsi + 4], al
jne 0x1401bbf8d
mov r8, qword [rsp + 0x58]
lea r9, [rbp + 0x100]
mov rdx, qword [rsp + 0x48]
mov rcx, rsi
call fcn.1401bb250
test eax, eax
je 0x1401bbf8d
mov rax, qword [rbp + 0x1e4]
cmp byte [rbp + 0x104], al
jne 0x1401bbf8d
mov rax, qword [rbp + 0x1e5]
cmp byte [rbp + 0x105], al
jne 0x1401bbf8d
mov rax, qword [rbp + 0x1e6]
cmp byte [rbp + 0x106], al
jne 0x1401bbf8d
cmp byte [rbp + 0x107], r12b
jne 0x1401bbf8d
movzx r14d, byte [rbp + 0x110]
lea eax, [r14 - 1]
cmp al, 1
ja 0x1401bbf8d
cmp byte [rbp + 0x111], 0
jne 0x1401bbf8d
cmp byte [rbp + 0x112], 0
jne 0x1401bbf8d
cmp byte [rbp + 0x113], 0
jne 0x1401bbf8d
movzx r8d, word [rsi]
xor edx, edx
lea ecx, [rdx + 0x40]
call qword [sym.imp.KERNEL32.dll_OpenProcess]
mov rdi, rax
test rax, rax
je 0x1401bbf8d
movzx edx, word [rsi + 6]
lea r9, [rsp + 0x50]
mov r8, qword [rbp - 0x80]
xor eax, eax
mov dword [rsp + 0x30], 2
mov rcx, rdi
mov dword [rsp + 0x28], eax
mov dword [rsp + 0x20], eax
call qword [sym.imp.KERNEL32.dll_DuplicateHandle]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rsp + 0x50]
test rcx, rcx
je 0x1401bbf8d
xor eax, eax
mov qword [rbp + 0x70], rax
mov qword [rbp + 0x88], rax
mov byte [rbp + 0x70], 4
mov byte [rbp + 0x88], 3
mov qword [rbp + 0x90], rax
mov qword [rbp + 0x98], rax
mov qword [rbp + 0xa0], rax
mov qword [rbp + 0xa8], rax
mov qword [rbp + 0xb0], rax
mov qword [rbp + 0xb8], rax
mov qword [rbp + 0xc0], rax
mov qword [rbp + 0xc8], rax
mov qword [rbp + 0xd0], rax
mov qword [rbp + 0xd8], rax
mov qword [rbp + 0xe0], rax
mov qword [rbp + 0xe8], rax
mov qword [rbp + 0xf0], rax
mov qword [rbp + 0x60], rax
mov qword [rbp + 0x68], rax
mov qword [rbp + 0x78], rax
mov qword [rbp + 0x80], rax
cmp r14b, 2
jne 0x1401bbef5
mov dword [rsp + 0x40], eax
lea r8, [rbp + 0x60]
lea rax, [rbp - 0x48]
mov r9d, reloc.ODBC32.dll_SQLAllocHandle
mov qword [rsp + 0x38], rax
mov edx, 0x210012
lea rax, [rsp + 0x40]
mov qword [rsp + 0x30], rax
lea rax, [rbp + 0xc0]
mov dword [rsp + 0x28], SQLMoreResults
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_DeviceIoControl]
mov rcx, qword [rsp + 0x50]
test eax, eax
je 0x1401bbf87
lea rax, [rbp - 0x48]
mov r9d, reloc.ODBC32.dll_SQLAllocHandle
mov qword [rsp + 0x38], rax
lea r8, [rbp + 0x78]
lea rax, [rsp + 0x40]
mov edx, 0x210012
mov qword [rsp + 0x30], rax
lea rax, [rbp + 0x90]
mov dword [rsp + 0x28], 0x30
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
je 0x1401bbf82
movzx ecx, word [rbp + 0x9c]
mov dword [rsp + 0x60], 2
call sub.WS2_32.dll_ntohs
mov rdx, qword [rbx + 8]
movzx eax, ax
mov dword [rsp + 0x64], eax
movzx eax, word [rsi]
mov dword [rsp + 0x68], eax
cmp qword [rbx + 0x10], rdx
je 0x1401bbf75
movsd xmm0, qword [rsp + 0x60]
movsd qword [rdx], xmm0
mov dword [rdx + 8], eax
add qword [rbx + 8], 0xc
jmp 0x1401bbf82
lea r8, [rsp + 0x60]
mov rcx, rbx
call fcn.1401baf00
mov rcx, qword [rsp + 0x50]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
add rsi, 0x10
sub r15, 1
jne 0x1401bbd00
mov rcx, qword [rbp - 0x30]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rbp - 0x18]
call fcn.140299e88
mov rcx, qword [rbp - 0x78]
call fcn.140299e88
mov rcx, qword [rsp + 0x58]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rbp - 0x80]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rbp - 0x68]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rbp - 0x60]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rsp + 0x48]
call qword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
xor eax, eax
jmp 0x1401bb98c
lea rcx, str.error_open_handlelist_n
call fcn.14002d4e0
mov eax, 0xfffffffb
jmp 0x1401bb9a4
lea rcx, str.error_open_physcalmemorynn_n
call fcn.14002d4e0
mov eax, 0xfffffffa
jmp 0x1401bb9b4