Function at 0x1400114c0
Capabilities:
Get common file path
Query or enumerate registry value

Disassembly:
mov qword [rsp + 8], rcx
push rdi
sub rsp, 0x640
mov rax, qword [0x140021220]
xor rax, rsp
mov qword [rsp + 0x630], rax
mov qword [rsp + 0x380], 0
cmp qword [0x140025290], 0
jne 0x140011502
mov rcx, qword [rsp + 0x650]
call fcn.140010a30
cmp qword [0x140025288], 0
jne 0x140011519
mov rcx, qword [rsp + 0x650]
call fcn.140010ec0
mov dword [0x140020940], 0
mov dword [0x140023654], 2
mov dword [0x140023650], 0
mov dword [0x140023658], 4
lea rcx, [0x140024e50]
call qword [sym.imp.KERNEL32.dll_QueryPerformanceFrequency]
test eax, eax
jne 0x14001155d
mov qword [0x140024e50], 1
mov dword [rsp + 0x50], 0
jmp 0x140011572
mov eax, dword [rsp + 0x50]
add eax, 1
mov dword [rsp + 0x50], eax
cmp dword [rsp + 0x50], 0x64
jge 0x1400115cb
movsxd rcx, dword [rsp + 0x50]
lea rax, [0x140023660]
mov qword [rax + rcx*8], 0
movsxd rcx, dword [rsp + 0x50]
lea rax, [0x140023980]
mov qword [rax + rcx*8], 0
movsxd rcx, dword [rsp + 0x50]
lea rax, [0x140023ca0]
mov qword [rax + rcx*8], 0
movsxd rcx, dword [rsp + 0x50]
lea rax, [0x140023fc0]
mov qword [rax + rcx*8], 0
jmp 0x140011567
mov dword [rsp + 0x50], 0
jmp 0x1400115e0
mov eax, dword [rsp + 0x50]
add eax, 1
mov dword [rsp + 0x50], eax
cmp dword [rsp + 0x50], 0x104
jge 0x140011606
movsxd rax, dword [rsp + 0x50]
mov byte [rsp + rax + 0x4a0], 0
movsxd rax, dword [rsp + 0x50]
mov byte [rsp + rax + 0x390], 0
jmp 0x1400115d5
lea rcx, str.TrcParams
call fcn.140011320
test eax, eax
je 0x140011c19
mov r8d, 0x104
lea rdx, [rsp + 0x60]
lea rcx, str.Consult
call fcn.1400113d0
test eax, eax
je 0x140011646
lea rcx, [rsp + 0x60]
call qword [sym.imp.MSVCR90.dll_atoi]
mov dword [0x140023650], eax
mov r8d, 0x104
lea rdx, [rsp + 0x60]
lea rcx, str.FctName
call fcn.1400113d0
test eax, eax
je 0x140011679
lea r8, [0x140024770]
lea rdx, [0x140023ca0]
lea rcx, [rsp + 0x60]
call fcn.140013ce0
mov r8d, 0x104
lea rdx, [rsp + 0x60]
lea rcx, str.Format
call fcn.1400113d0
test eax, eax
je 0x140011704
lea rdx, str.SHORT
lea rcx, [rsp + 0x60]
call qword [sym.imp.MSVCR90.dll__stricmp]
test eax, eax
jne 0x1400116b6
mov dword [0x140023654], 1
jmp 0x140011704
lea rdx, str.TIME
lea rcx, [rsp + 0x60]
call qword [sym.imp.MSVCR90.dll__stricmp]
test eax, eax
jne 0x1400116d8
mov dword [0x140023654], 3
jmp 0x140011704
lea rdx, str.TEXT
lea rcx, [rsp + 0x60]
call qword [sym.imp.MSVCR90.dll__stricmp]
test eax, eax
jne 0x1400116fa
mov dword [0x140023654], 4
jmp 0x140011704
mov dword [0x140023654], 2
mov r8d, 0x104
lea rdx, [rsp + 0x60]
lea rcx, str.Level
call fcn.1400113d0
test eax, eax
je 0x140011776
xor r8d, r8d
lea rdx, [rsp + 0x40]
lea rcx, [rsp + 0x60]
call qword [sym.imp.MSVCR90.dll_strtoul]
mov dword [0x140020940], eax
cmp qword [0x140025268], 0
je 0x140011776
mov r8d, 0x104
lea rdx, [rsp + 0x60]
mov rcx, qword [0x140025268]
call fcn.1400113d0
test eax, eax
je 0x140011776
xor r8d, r8d
lea rdx, [rsp + 0x40]
lea rcx, [rsp + 0x60]
call qword [sym.imp.MSVCR90.dll_strtoul]
mov dword [0x140025260], eax
mov r8d, 0x104
lea rdx, [rsp + 0x60]
lea rcx, str.Module
call fcn.1400113d0
test eax, eax
je 0x1400117a9
lea r8, [0x140024670]
lea rdx, [0x140023980]
lea rcx, [rsp + 0x60]
call fcn.140013ce0
mov r8d, 0x104
lea rdx, [rsp + 0x60]
lea rcx, str.String
call fcn.1400113d0
test eax, eax
je 0x1400117dc
lea r8, [0x140024870]
lea rdx, [0x140023fc0]
lea rcx, [rsp + 0x60]
call fcn.140013ce0
mov r8d, 0x104
lea rdx, [rsp + 0x60]
lea rcx, str.TraceId
call fcn.1400113d0
test eax, eax
je 0x14001180f
lea r8, [0x140024570]
lea rdx, [0x140023660]
lea rcx, [rsp + 0x60]
call fcn.140013ce0
mov r8d, 0x104
lea rdx, [rsp + 0x60]
lea rcx, str.Output
call fcn.1400113d0
test eax, eax
je 0x140011c14
lea rdx, [0x140020b74]
lea rcx, [rsp + 0x60]
call qword [sym.imp.MSVCR90.dll__stricmp]
test eax, eax
jne 0x140011853
mov dword [0x140023658], 0
jmp 0x140011c14
lea rdx, str.COM1
lea rcx, [rsp + 0x60]
call qword [sym.imp.MSVCR90.dll__stricmp]
test eax, eax
jne 0x140011878
mov dword [0x140023658], 1
jmp 0x140011c14
lea rdx, str.COM2
lea rcx, [rsp + 0x60]
call qword [sym.imp.MSVCR90.dll__stricmp]
test eax, eax
jne 0x14001189d
mov dword [0x140023658], 2
jmp 0x140011c14
lea rdx, str.PIPE
lea rcx, [rsp + 0x60]
call qword [sym.imp.MSVCR90.dll__stricmp]
test eax, eax
jne 0x1400118c2
mov dword [0x140023658], 3
jmp 0x140011c14
lea rdx, [0x140020bfc]
lea rcx, [rsp + 0x60]
call qword [sym.imp.MSVCR90.dll__stricmp]
test eax, eax
jne 0x140011922
mov dword [0x140023658], 5
mov r8d, 0x104
lea rdx, [rsp + 0x60]
lea rcx, str.sm_size
call fcn.1400113d0
test eax, eax
je 0x14001191d
lea rcx, [rsp + 0x60]
call qword [sym.imp.MSVCR90.dll_atol]
test eax, eax
jle 0x14001191d
lea rcx, [rsp + 0x60]
call qword [sym.imp.MSVCR90.dll_atol]
mov dword [0x140020b64], eax
jmp 0x140011c14
lea rdx, str.FILE
lea rcx, [rsp + 0x60]
call qword [sym.imp.MSVCR90.dll__stricmp]
test eax, eax
jne 0x140011a64
mov dword [0x140023658], 4
mov r8d, 0x104
lea rdx, [rsp + 0x60]
lea rcx, str.Byte_File
call fcn.1400113d0
test eax, eax
je 0x140011981
lea rcx, [rsp + 0x60]
call qword [sym.imp.MSVCR90.dll_atol]
test eax, eax
jle 0x140011981
lea rcx, [rsp + 0x60]
call qword [sym.imp.MSVCR90.dll_atol]
mov dword [0x140020b58], eax
mov r8d, 0x104
lea rdx, [rsp + 0x60]
lea rcx, str.Path
call fcn.1400113d0
test eax, eax
je 0x1400119b4
lea r8, [rsp + 0x60]
mov edx, 0x104
lea rcx, [rsp + 0x4a0]
call qword [sym.imp.MSVCR90.dll_strcpy_s]
mov r8d, 0x104
lea rdx, [rsp + 0x60]
lea rcx, str.FileName
call fcn.1400113d0
test eax, eax
je 0x1400119e7
lea r8, [rsp + 0x60]
mov edx, 0x104
lea rcx, [rsp + 0x390]
call qword [sym.imp.MSVCR90.dll_strcpy_s]
movsx eax, byte [rsp + 0x4a0]
test eax, eax
je 0x140011a00
mov dword [rsp + 0x620], 1
jmp 0x140011a0b
mov dword [rsp + 0x620], 0
movsx eax, byte [rsp + 0x390]
test eax, eax
je 0x140011a24
mov dword [rsp + 0x624], 1
jmp 0x140011a2f
mov dword [rsp + 0x624], 0
mov ecx, dword [rsp + 0x624]
mov eax, dword [rsp + 0x620]
or eax, ecx
test eax, eax
je 0x140011a5f
lea r8, str.C:TMPS7FILE
lea rdx, [rsp + 0x390]
lea rcx, [rsp + 0x4a0]
call fcn.140013db0
jmp 0x140011c14
lea rdx, [0x140020d8c]
lea rcx, [rsp + 0x60]
call qword [sym.imp.MSVCR90.dll__stricmp]
test eax, eax
jne 0x140011a89
mov dword [0x140023658], 6
jmp 0x140011c14
lea rdx, str.S7TRACEENGINE
lea rcx, [rsp + 0x60]
call qword [sym.imp.MSVCR90.dll__stricmp]
test eax, eax
jne 0x140011c14
mov dword [0x140023658], 7
lea rax, [rsp + 0x380]
mov qword [rsp + 0x20], rax
mov r9d, 0x20019
xor r8d, r8d
lea rdx, str.SoftwareSIEMENSAUTSWGlobal
mov rcx, 0xffffffff80000002
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x140011b61
lea rax, [rsp + 0x4c]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], 0
lea r9, [rsp + 0x48]
xor r8d, r8d
lea rdx, [0x140020dc0]
mov rcx, qword [rsp + 0x380]
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov dword [rsp + 0x54], eax
cmp dword [rsp + 0x54], 0
jne 0x140011b51
lea rax, [rsp + 0x4c]
mov qword [rsp + 0x28], rax
lea rax, [0x1400258b0]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x48]
xor r8d, r8d
lea rdx, str.SharedPath
mov rcx, qword [rsp + 0x380]
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov dword [rsp + 0x54], eax
mov rcx, qword [rsp + 0x380]
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
jmp 0x140011b98
xor r9d, r9d
mov r8d, 0x2b
lea rdx, [0x1400258b0]
xor ecx, ecx
call qword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathA]
mov r9d, 0x200
lea r8, str.Siemens
mov edx, 0x200
lea rcx, [0x1400258b0]
call qword [sym.imp.MSVCR90.dll_strncat_s]
mov r9d, 0x200
lea r8, str._s7dosmeta_traceSettings_
mov edx, 0x200
lea rcx, [0x1400258b0]
call qword [sym.imp.MSVCR90.dll_strncat_s]
mov r9d, 0x200
lea r8, str.S7sdd_TraceSettings.xml
mov edx, 0x200
lea rcx, [0x1400254b0]
call qword [sym.imp.MSVCR90.dll_strncpy_s]
mov r9d, 0x200
lea r8, str.S7sdd_TraceMetaInfo.xml
mov edx, 0x200
lea rcx, [0x1400252b0]
call qword [sym.imp.MSVCR90.dll_strncpy_s]
mov r9d, 0x200
lea r8, str.1.0.0.0
mov edx, 0x200
lea rcx, [0x1400256b0]
call qword [sym.imp.MSVCR90.dll_strncpy_s]
call fcn.140011470
mov eax, dword [0x140023658]
mov dword [rsp + 0x628], eax
cmp dword [rsp + 0x628], 7
ja case.0x140011c4d.3
movsxd rax, dword [rsp + 0x628]
lea rcx, [0x140000000]
mov eax, dword [rcx + rax*4 + 0x12110]
add rax, rcx
jmp rax
mov qword [rsp + 0x30], 0
mov dword [rsp + 0x28], 0x4000000
mov dword [rsp + 0x20], 1
xor r9d, r9d
xor r8d, r8d
xor edx, edx
lea rcx, str..S7ONLINX.VXD
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov qword [0x140025270], rax
cmp qword [0x140025270], 0xffffffffffffffff
jne 0x140011cbf
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [rsp + 0x388], eax
cmp dword [rsp + 0x388], 0x32
jne 0x140011cb3
lea rcx, str.Unable_to_open_VxD__device_does_not_support_DeviceIOCTL
call fcn.140013450
jmp 0x140011cbf
lea rcx, str.Unable_to_open_VxD__got_error_code__
call fcn.140013450
jmp 0x1400120d1
call fcn.140010ff0
mov rdx, qword [rsp + 0x650]
mov ecx, dword [0x140020b64]
call fcn.140010b00
call fcn.1400110a0
jmp 0x1400120d1
jmp 0x1400120d1
call fcn.140010ff0
mov dword [rsp + 0x5f0], 0
lea rdi, [rsp + 0x5f4]
xor eax, eax
mov ecx, 0x2c
rep stosb byte [rdi], al
mov dword [rsp + 0x5b8], 0
lea rdi, [rsp + 0x5bc]
xor eax, eax
mov ecx, 0x2c
rep stosb byte [rdi], al
mov dword [rsp + 0x5e8], 0xffffffff
mov dword [rsp + 0x5ec], 0xffffffff
mov dword [rsp + 0x5b4], 0xffffffff
mov dword [rsp + 0x5b0], 0xffffffff
mov dword [rsp + 0x20], 1
lea r9, str.C:TMPS7FILE
lea r8, [0x140020ec0]
mov edx, 0x100
lea rcx, [0x140024300]
call qword [sym.imp.MSVCR90.dll_sprintf_s]
mov dword [rsp + 0x20], 0x100
mov r9d, 0x20
xor r8d, r8d
lea rdx, [0x140024300]
lea rcx, [rsp + 0x5e8]
call qword [sym.imp.MSVCR90.dll__sopen_s]
cmp dword [rsp + 0x5e8], 0
jl 0x140011dd5
lea rdx, [rsp + 0x5f0]
mov ecx, dword [rsp + 0x5e8]
call qword [sym.imp.MSVCR90.dll__fstat64i32]
mov dword [rsp + 0x5ec], eax
mov ecx, dword [rsp + 0x5e8]
call qword [sym.imp.MSVCR90.dll__close]
mov dword [rsp + 0x20], 2
lea r9, str.C:TMPS7FILE
lea r8, [0x140020ed0]
mov edx, 0x100
lea rcx, [0x140024d50]
call qword [sym.imp.MSVCR90.dll_sprintf_s]
mov dword [rsp + 0x20], 0x100
mov r9d, 0x20
xor r8d, r8d
lea rdx, [0x140024d50]
lea rcx, [rsp + 0x5b4]
call qword [sym.imp.MSVCR90.dll__sopen_s]
cmp dword [rsp + 0x5b4], 0
jl 0x140011e56
lea rdx, [rsp + 0x5b8]
mov ecx, dword [rsp + 0x5b4]
call qword [sym.imp.MSVCR90.dll__fstat64i32]
mov dword [rsp + 0x5b0], eax
mov ecx, dword [rsp + 0x5b4]
call qword [sym.imp.MSVCR90.dll__close]
cmp dword [rsp + 0x5ec], 0
jne 0x140011e94
cmp dword [rsp + 0x5b0], 0
jne 0x140011e94
mov rax, qword [rsp + 0x5d8]
cmp qword [rsp + 0x610], rax
jge 0x140011e88
mov dword [0x140020b5c], 2
jmp 0x140011e92
mov dword [0x140020b5c], 1
jmp 0x140011eb4
cmp dword [rsp + 0x5b0], 0
jne 0x140011eaa
mov dword [0x140020b5c], 2
jmp 0x140011eb4
mov dword [0x140020b5c], 1
call fcn.1400110a0
jmp 0x1400120d1
jmp 0x1400120d1
xor r9d, r9d
mov r8d, 0x2b
lea rdx, [rsp + 0x180]
xor ecx, ecx
call qword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathA]
lea r8, str.SiemensAutomationTraceEngine_binS7TraceEngineX.dll
mov edx, 0x200
lea rcx, [rsp + 0x180]
call qword [sym.imp.MSVCR90.dll_strcat_s]
lea rcx, [rsp + 0x180]
call qword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov qword [rsp + 0x170], rax
cmp qword [rsp + 0x170], 0
jne 0x140011f53
mov dword [0x140020b6c], 0
mov qword [rsp + 0x28], 0
mov qword [rsp + 0x20], 0
lea r9, [rsp + 0x180]
mov r8w, 1
mov edx, 0xc0001400
mov cx, 1
call fcn.1400110d0
jmp 0x1400120c3
lea rdx, [0x140020f18]
mov rcx, qword [rsp + 0x170]
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [0x140026170], rax
cmp qword [0x140026170], 0
jne 0x140011faf
mov dword [0x140020b6c], 0
mov qword [rsp + 0x28], 0
mov qword [rsp + 0x20], 0
lea r9, [0x140020f28]
mov r8w, 1
mov edx, 0xc0001401
mov cx, 1
call fcn.1400110d0
lea rdx, [0x140020f38]
mov rcx, qword [rsp + 0x170]
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [0x140026160], rax
cmp qword [0x140026160], 0
jne 0x14001200b
mov dword [0x140020b6c], 0
mov qword [rsp + 0x28], 0
mov qword [rsp + 0x20], 0
lea r9, [0x140020f48]
mov r8w, 1
mov edx, 0xc0001401
mov cx, 1
call fcn.1400110d0
lea rdx, [0x140020f58]
mov rcx, qword [rsp + 0x170]
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [0x140026158], rax
cmp qword [0x140026158], 0
jne 0x140012067
mov dword [0x140020b6c], 0
mov qword [rsp + 0x28], 0
mov qword [rsp + 0x20], 0
lea r9, str.TraceCommand
mov r8w, 1
mov edx, 0xc0001401
mov cx, 1
call fcn.1400110d0
lea rdx, [0x140020f78]
mov rcx, qword [rsp + 0x170]
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [0x140026150], rax
cmp qword [0x140026150], 0
jne 0x1400120c3
mov dword [0x140020b6c], 0
mov qword [rsp + 0x28], 0
mov qword [rsp + 0x20], 0
lea r9, str.TraceClose
mov r8w, 1
mov edx, 0xc0001401
mov cx, 1
call fcn.1400110d0
jmp 0x1400120d1
lea rcx, str.Fehler_im_STEP7_Tracesystem__bitte_wenden_Sie_sich_an_den_Hersteller__
call fcn.140013450
mov rax, qword [0x140020948]
mov eax, dword [rax]
mov dword [0x140025264], eax
cmp dword [0x140023650], 0
je 0x1400120f5
lea rcx, [0x1400242f0]
call fcn.140012140
mov rcx, qword [rsp + 0x630]
xor rcx, rsp
call fcn.140015270
add rsp, 0x640
pop rdi
ret