Function at 0x18005bf90
Capabilities:
Check if file exists

Disassembly:
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x230]
sub rsp, 0x330
mov qword [rsp + 0x58], 0xfffffffffffffffe
mov qword [rsp + 0x388], rbx
mov rax, qword [0x180168908]
xor rax, rsp
mov qword [rbp + 0x220], rax
mov qword [rsp + 0x50], r8
mov r15, rdx
mov qword [rsp + 0x48], rdx
mov rsi, rcx
xor r12d, r12d
mov r14d, r12d
mov rdi, qword [rdx + 8]
mov rbx, qword [rdx]
lea r13, [r12 - 1]
cmp rbx, rdi
je 0x18005c029
nop dword [rax]
nop dword [rax + rax]
mov rdx, qword [rbx]
sub rdx, 0x18
mov eax, r13d
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x18005c01d
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + 8]
add rbx, 8
cmp rbx, rdi
jne 0x18005c000
mov rbx, qword [r15]
mov qword [r15 + 8], rbx
lea rdx, [rsp + 0x40]
mov rcx, rsi
call fcn.18005be40
nop
call fcn.180009090
mov rcx, rax
test rax, rax
je 0x18005ca6a
mov rax, qword [rax]
call qword [rax + 0x18]
lea rbx, [rax + 0x18]
mov qword [rsp + 0x38], rbx
mov rdi, qword [rsi + 0x68]
mov rsi, qword [rsp + 0x40]
mov ecx, 1
sub ecx, dword [rbx - 8]
mov eax, dword [rbx - 0xc]
sub eax, 0x104
or eax, ecx
jge 0x18005c08c
mov edx, 0x104
lea rcx, [rsp + 0x38]
call fcn.180009160
mov rbx, qword [rsp + 0x38]
cmp dword [rbx - 0xc], 0x104
jl 0x18005ca75
mov dword [rbx - 0x10], 0x104
mov word [rbx + 0x208], r12w
mov r8, rdi
mov rdx, rsi
mov rcx, rbx
call qword [sym.imp.SHLWAPI.dll_PathCombineW]
movsxd rdx, dword [rbx - 0xc]
mov rcx, rbx
call fcn.1800d7f80
test eax, eax
js 0x18005ca5f
cmp eax, dword [rbx - 0xc]
jg 0x18005ca5f
mov dword [rbx - 0x10], eax
cdqe
mov word [rbx + rax*2], r12w
cmp dword [rbx - 0x10], 0
je 0x18005c9f2
mov rcx, rbx
call qword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x18005c9f2
mov rcx, rbx
call qword [sym.imp.SHLWAPI.dll_PathIsDirectoryW]
test eax, eax
jne 0x18005c9f2
mov dword [rsp + 0x20], 1
lea r9d, [rax + 0x40]
lea r8d, [rax + 1]
mov rdx, rbx
lea rcx, [rsp + 0x60]
call fcn.18005af90
nop
mov qword [rbp + 0xb8], r12
mov qword [rbp + 0xc0], reloc.WS2_32.dll_ntohs
mov byte [rbp + 0xa8], 0
mov rax, qword [rsp + 0x60]
movsxd rcx, dword [rax + 4]
test byte [rsp + rcx + 0x70], 6
jne 0x18005c889
nop word [rax + rax]
lea rax, [rsp + 0x60]
add rcx, rax
mov dl, 0xa
call fcn.18005dd40
movzx r8d, al
lea rdx, [rbp + 0xa8]
lea rcx, [rsp + 0x60]
call fcn.18005aba0
lea rbx, [rbp + 0xa8]
mov r15, qword [rbp + 0xc0]
cmp r15, 0x10
mov r12, qword [rbp + 0xa8]
cmovae rbx, r12
mov r14, qword [rbp + 0xb8]
cmp r14, 0xb
jb 0x18005c20c
lea rsi, [rbx + r14]
lea r8, [rsi - 0xa]
sub r8, rbx
mov edx, 0x68
mov rcx, rbx
call fcn.1800d4ce0
mov rdi, rax
test rax, rax
je 0x18005c20c
nop
mov r8d, ntohs
lea rdx, str.homepages_
mov rcx, rdi
call fcn.1800d4b70
test eax, eax
je 0x18005c28d
inc rdi
lea r8, [rsi - 0xa]
sub r8, rdi
mov edx, 0x68
mov rcx, rdi
call fcn.1800d4ce0
mov rdi, rax
test rax, rax
jne 0x18005c1d0
lea rbx, [rbp + 0xa8]
cmp r15, 0x10
cmovae rbx, r12
cmp r14, 0xa
jb 0x18005c2a5
lea rsi, [rbx + r14]
lea r8, [rsi - 9]
sub r8, rbx
mov edx, 0x68
mov rcx, rbx
call fcn.1800d4ce0
mov rdi, rax
test rax, rax
je 0x18005c288
nop word [rax + rax]
mov r8d, 0xa
lea rdx, str.homepage_
mov rcx, rdi
call fcn.1800d4b70
test eax, eax
je 0x18005c2a0
inc rdi
lea r8, [rsi - 9]
sub r8, rdi
mov edx, 0x68
mov rcx, rdi
call fcn.1800d4ce0
mov rdi, rax
test rax, rax
jne 0x18005c250
mov rdi, r13
jmp 0x18005c2b6
sub rdi, rbx
cmp rdi, 0xffffffffffffffff
je 0x18005c20c
add rdi, 0xb
jmp 0x18005c2b6
sub rdi, rbx
jmp 0x18005c2a8
mov rdi, r13
cmp rdi, 0xffffffffffffffff
je 0x18005c686
add rdi, 0xa
cmp rdi, 0xffffffffffffffff
je 0x18005c686
lea r15, [rbp + 0xa8]
cmp qword [rbp + 0xc0], 0x10
cmovae r15, r12
cmp r14, 1
jb 0x18005c346
lea rax, [r14 - 1]
cmp rdi, rax
ja 0x18005c346
lea r12, [r15 + r14]
lea rcx, [r15 + rdi]
mov r8, r12
sub r8, rcx
mov edx, 0x22
call fcn.1800d4ce0
mov rsi, rax
test rax, rax
je 0x18005c33f
movzx ebx, word [0x18011a07c]
nop dword [rax]
cmp byte [rsi], bl
jne 0x18005c318
xor eax, eax
jmp 0x18005c31d
sbb eax, eax
or eax, 1
test eax, eax
je 0x18005c39a
inc rsi
mov r8, r12
sub r8, rsi
mov edx, 0x22
mov rcx, rsi
call fcn.1800d4ce0
mov rsi, rax
test rax, rax
jne 0x18005c310
mov r12, qword [rbp + 0xa8]
mov rsi, r13
lea r15, [rbp + 0xa8]
cmp qword [rbp + 0xc0], 0x10
cmovae r15, r12
cmp r14, 1
jb 0x18005c3d5
lea rax, [r14 - 1]
cmp rdi, rax
ja 0x18005c3d5
lea r12, [r15 + r14]
lea rcx, [r15 + rdi]
mov r8, r12
sub r8, rcx
mov edx, 9
call fcn.1800d4ce0
mov rcx, rax
test rax, rax
je 0x18005c3ce
movzx ebx, word [0x18011a080]
cmp byte [rcx], bl
jne 0x18005c3a6
xor eax, eax
jmp 0x18005c3ab
sub rsi, r15
mov r12, qword [rbp + 0xa8]
jmp 0x18005c349
sbb eax, eax
or eax, 1
test eax, eax
je 0x18005c478
inc rcx
mov r8, r12
sub r8, rcx
mov edx, 9
call fcn.1800d4ce0
mov rcx, rax
test rax, rax
jne 0x18005c392
mov r12, qword [rbp + 0xa8]
mov rcx, r13
cmp rcx, rsi
cmovae rcx, rsi
cmp rcx, 0xffffffffffffffff
cmove rcx, r14
xor r15d, r15d
mov qword [rbp + 0xd8], r15
mov qword [rbp + 0xe0], reloc.WS2_32.dll_ntohs
mov byte [rbp + 0xc8], r15b
cmp r14, rdi
jb 0x18005cab0
sub rcx, rdi
sub r14, rdi
cmp r14, rcx
cmovb rcx, r14
lea rdx, [rbp + 0xa8]
cmp qword [rbp + 0xc0], 0x10
cmovae rdx, r12
add rdx, rdi
mov r8, rcx
lea rcx, [rbp + 0xc8]
call fcn.18000a3d0
nop
lea rsi, [rbp + 0xc8]
cmp qword [rbp + 0xe0], 0x10
cmovae rsi, qword [rbp + 0xc8]
lea rax, [rbp + 0x118]
mov qword [rbp + 0x110], rax
test rsi, rsi
jne 0x18005c487
mov ebx, r15d
mov qword [rbp + 0x110], rbx
jmp 0x18005c564
sub rcx, r15
mov r12, qword [rbp + 0xa8]
jmp 0x18005c3d8
mov rdi, r13
nop word [rax + rax]
inc rdi
cmp byte [rsi + rdi], 0
jne 0x18005c490
inc edi
mov r9d, 0x80
lea r8, [rbp + 0x118]
mov edx, edi
lea rcx, [rbp + 0x110]
call fcn.180009580
mov dword [rsp + 0x28], edi
mov rax, qword [rbp + 0x110]
mov qword [rsp + 0x20], rax
mov r9d, edi
mov r8, rsi
xor edx, edx
mov ecx, 0xfde9
call qword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
mov ebx, r15d
test eax, eax
sete bl
test eax, eax
jne 0x18005c555
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x18005c555
mov dword [rsp + 0x28], r15d
mov qword [rsp + 0x20], r15
mov r9d, edi
mov r8, rsi
xor edx, edx
mov ecx, 0xfde9
call qword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
mov ebx, eax
mov r9d, 0x80
lea r8, [rbp + 0x118]
mov edx, eax
lea rcx, [rbp + 0x110]
call fcn.180009580
mov dword [rsp + 0x28], ebx
mov rax, qword [rbp + 0x110]
mov qword [rsp + 0x20], rax
mov r9d, edi
mov r8, rsi
xor edx, edx
mov ecx, 0xfde9
call qword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
mov ebx, r15d
test eax, eax
sete bl
test ebx, ebx
jne 0x18005ca91
mov rbx, qword [rbp + 0x110]
call fcn.180009090
test rax, rax
je 0x18005ca86
mov rdx, qword [rax]
mov rcx, rax
call qword [rdx + 0x18]
add rax, 0x18
mov qword [rsp + 0x30], rax
test rbx, rbx
je 0x18005c5b0
cmp rbx, 0x10000
jae 0x18005c5a1
movzx edx, bx
lea rcx, [rsp + 0x30]
call fcn.180012580
jmp 0x18005c5c4
mov rax, r13
inc rax
cmp word [rbx + rax*2], 0
jne 0x18005c5a4
jmp 0x18005c5b3
mov eax, r15d
mov r8d, eax
mov rdx, rbx
lea rcx, [rsp + 0x30]
call fcn.180009210
nop
lea rax, [rbp + 0x118]
mov rcx, qword [rbp + 0x110]
cmp rcx, rax
je 0x18005c5dc
call fcn.1800d7598
mov rsi, qword [rsp + 0x48]
mov rdi, qword [rsi + 8]
cmp qword [rsi + 0x10], rdi
je 0x18005c607
mov rbx, qword [rsp + 0x30]
lea rcx, [rbx - 0x18]
call fcn.180008df0
add rax, 0x18
mov qword [rdi], rax
add qword [rsi + 8], 8
jmp 0x18005c61c
lea r8, [rsp + 0x30]
mov rdx, rdi
mov rcx, rsi
call fcn.18004c400
mov rbx, qword [rsp + 0x30]
lea rdx, [rbx - 0x18]
mov eax, r13d
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x18005c637
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + 8]
nop
mov rdx, qword [rbp + 0xe0]
cmp rdx, 0x10
jb 0x18005c678
inc rdx
mov rcx, qword [rbp + 0xc8]
mov rax, rcx
cmp rdx, 0x1000
jb 0x18005c673
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x18005ca80
call fcn.1800a4c5c
mov r12, qword [rbp + 0xa8]
mov r14, qword [rbp + 0xb8]
lea rdi, [rbp + 0xa8]
cmp qword [rbp + 0xc0], 0x10
cmovae rdi, r12
cmp r14, 0x10
jb 0x18005c86d
lea rsi, [rdi + r14]
lea r8, [rsi - 0xf]
sub r8, rdi
mov edx, 0x68
mov rcx, rdi
call fcn.1800d4ce0
mov rbx, rax
test rax, rax
je 0x18005c86d
nop word [rax + rax]
mov r8d, 0x10
lea rdx, str.homepagetype50_
mov rcx, rbx
call fcn.1800d4b70
test eax, eax
je 0x18005c70d
inc rbx
lea r8, [rsi - 0xf]
sub r8, rbx
mov edx, 0x68
mov rcx, rbx
call fcn.1800d4ce0
mov rbx, rax
test rax, rax
jne 0x18005c6d0
jmp 0x18005c86d
sub rbx, rdi
cmp rbx, 0xffffffffffffffff
je 0x18005c86d
lea r15, [rbx + 0x10]
lea rdi, [rbp + 0xa8]
mov rdx, qword [rbp + 0xc0]
cmp rdx, 0x10
cmovae rdi, r12
cmp r14, 1
jb 0x18005c7a7
lea rax, [r14 - 1]
cmp r15, rax
ja 0x18005c7a7
lea rsi, [rdi + r14]
lea rcx, [rdi + r15]
mov r8, rsi
sub r8, rcx
mov edx, 0x22
call fcn.1800d4ce0
mov rcx, rax
test rax, rax
je 0x18005c7a0
movzx ebx, word [0x18011a07c]
nop word [rax + rax]
cmp byte [rcx], bl
jne 0x18005c778
xor eax, eax
jmp 0x18005c77d
sbb eax, eax
or eax, 1
test eax, eax
je 0x18005c8dc
inc rcx
mov r8, rsi
sub r8, rcx
mov edx, 0x22
call fcn.1800d4ce0
mov rcx, rax
test rax, rax
jne 0x18005c770
mov rdx, qword [rbp + 0xc0]
mov rcx, r13
cmp rcx, 0xffffffffffffffff
je 0x18005c86d
mov qword [rbp + 0xf8], 0
mov qword [rbp + 0x100], reloc.WS2_32.dll_ntohs
mov byte [rbp + 0xe8], 0
cmp r14, r15
jb 0x18005cabc
sub rcx, r15
sub r14, r15
cmp r14, rcx
cmovb rcx, r14
lea rax, [rbp + 0xa8]
cmp rdx, 0x10
cmovae rax, r12
lea rdx, [rax + r15]
mov r8, rcx
lea rcx, [rbp + 0xe8]
call fcn.18000a3d0
lea rcx, [rbp + 0xe8]
cmp qword [rbp + 0x100], 0x10
cmovae rcx, qword [rbp + 0xe8]
call fcn.1800dcd20
mov rcx, qword [rsp + 0x50]
mov dword [rcx], eax
mov rdx, qword [rbp + 0x100]
cmp rdx, 0x10
jb 0x18005c86d
inc rdx
mov rcx, qword [rbp + 0xe8]
mov rax, rcx
cmp rdx, 0x1000
jb 0x18005c868
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x18005cab6
call fcn.1800a4c5c
mov rax, qword [rsp + 0x60]
movsxd rcx, dword [rax + 4]
test byte [rsp + rcx + 0x70], 6
je 0x18005c160
mov rbx, qword [rsp + 0x38]
xor r12d, r12d
lea rcx, [rsp + 0x70]
call fcn.18005d1f0
test rax, rax
jne 0x18005c8eb
mov rax, qword [rsp + 0x60]
movsxd rcx, dword [rax + 4]
mov eax, 6
mov edx, 2
cmp qword [rbp + rcx - 0x58], 0
cmovne eax, edx
or eax, dword [rsp + rcx + 0x70]
and eax, 0x17
mov dword [rsp + rcx + 0x70], eax
mov edx, dword [rsp + rcx + 0x74]
and edx, eax
je 0x18005c8eb
test dl, 4
je 0x18005cac2
lea rbx, str.ios_base::badbit_set
jmp 0x18005cad7
sub rcx, rdi
mov rdx, qword [rbp + 0xc0]
jmp 0x18005c7aa
mov r14d, 1
mov rdx, qword [rbp + 0xc0]
cmp rdx, 0x10
jb 0x18005c932
inc rdx
mov rcx, qword [rbp + 0xa8]
mov rax, rcx
cmp rdx, 0x1000
jb 0x18005c92d
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x18005ca59
call fcn.1800a4c5c
mov qword [rbp + 0xb8], r12
mov qword [rbp + 0xc0], reloc.WS2_32.dll_ntohs
mov byte [rbp + 0xa8], 0
mov rax, qword [rsp + 0x60]
movsxd rcx, dword [rax + 4]
lea rax, vtable.std::basic_ifstream_char__struct_std::char_traits_char__.0
mov qword [rsp + rcx + 0x60], rax
mov rax, qword [rsp + 0x60]
movsxd rcx, dword [rax + 4]
lea edx, [rcx - 0xb0]
mov dword [rsp + rcx + 0x5c], edx
lea rcx, [rsp + 0x70]
call fcn.18005b3e0
mov rax, qword [rsp + 0x60]
movsxd rcx, dword [rax + 4]
lea rax, vtable.std::basic_istream_char__struct_std::char_traits_char__.0
mov qword [rsp + rcx + 0x60], rax
mov rax, qword [rsp + 0x60]
movsxd rcx, dword [rax + 4]
lea edx, [rcx - 0x18]
mov dword [rsp + rcx + 0x5c], edx
lea rax, vtable.std::ios_base.0
mov qword [rbp + 0x10], rax
lea rcx, [rbp + 0x10]
call fcn.18007738c
nop
lea rdx, [rbx - 0x18]
mov eax, r13d
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x18005c9d2
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + 8]
nop
mov rdx, qword [rsp + 0x40]
add rdx, 0xffffffffffffffe8
lock xadd dword [rdx + 0x10], r13d
sub r13d, 1
jg 0x18005ca2c
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + 8]
jmp 0x18005ca2c
lea rdx, [rbx - 0x18]
mov eax, r13d
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x18005ca0d
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + 8]
nop
mov rdx, qword [rsp + 0x40]
add rdx, 0xffffffffffffffe8
lock xadd dword [rdx + 0x10], r13d
sub r13d, 1
jg 0x18005ca2c
mov rcx, qword [rdx]
mov r8, qword [rcx]
call qword [r8 + 8]
mov eax, r14d
mov rcx, qword [rbp + 0x220]
xor rcx, rsp
call fcn.1800a5130
mov rbx, qword [rsp + 0x388]
add rsp, 0x330
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
call fcn.1800d79f8
nop
mov ecx, 0x80070057
call fcn.180008c20
nop
mov ecx, 0x80004005
call fcn.180008c20
nop
mov ecx, 0x80070057
call fcn.180008c20
nop
call fcn.1800d79f8
nop
mov ecx, 0x80004005
call fcn.180008c20
nop
mov r8d, 0x80
lea rdx, [rbp + 0x118]
mov rcx, qword [rbp + 0x110]
call fcn.180009610
call fcn.1800098d0
nop
call fcn.180019980
int3
call fcn.1800d79f8
int3
call fcn.180019980
int3
test dl, 2
lea rbx, str.ios_base::failbit_set
lea rax, str.ios_base::eofbit_set
cmove rbx, rax
mov edx, 1
lea rcx, [rbp + 0x70]
call fcn.18001b480
mov r8, rax
mov rdx, rbx
lea rcx, [rbp + 0x80]
call fcn.18000e2c0
lea rdx, [0x1801623a8]
lea rcx, [rbp + 0x80]
call fcn.1800d4790
int3