Function at 0x1400b7f10
Capabilities:
Clear file content
Resolve function by parsing pe exports

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
mov dword [rsp + 0x20], r9d
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x40
mov edi, dword [rsp + 0x98]
mov rsi, rdx
mov r13, rcx
mov ebx, 4
test edi, edi
je 0x1400b8aac
mov r12, qword [rsp + 0x90]
dec edi
mov r15, qword [r12]
mov edx, dword [r15 + 0x10]
test edx, edx
je 0x1400b7f92
sub edx, 1
je 0x1400b7f75
sub edx, 1
je 0x1400b7f75
sub edx, 2
je 0x1400b7f7e
cmp edx, 1
je 0x1400b7f92
lea r15, [0x140103574]
jmp 0x1400b7f95
mov rcx, qword [r15]
xor r8d, r8d
lea edx, [r8 + 1]
call fcn.1400017c0
mov r15, rax
jmp 0x1400b7f95
mov r15, qword [r15]
mov r8, rbx
lea rdx, str.Read
mov rcx, r15
call fcn.1400dc238
xor ebp, ebp
test eax, eax
jne 0x1400b7fe3
cmp word [r15 + 8], bp
lea rcx, [r15 + 8]
jne 0x1400b7fc1
lea r14d, [rbp + 1]
jmp 0x1400b8141
lea rdx, str.Line
call fcn.1400da910
test eax, eax
mov ecx, 3
mov r14d, 5
cmove r14d, ecx
jmp 0x1400b8141
mov r8d, 5
lea rdx, str.Write
mov rcx, r15
call fcn.1400dc238
test eax, eax
jne 0x1400b802c
cmp word [r15 + 0xa], bp
lea rcx, [r15 + 0xa]
jne 0x1400b8010
lea r14d, [rax + 2]
jmp 0x1400b8141
lea rdx, str.Line
call fcn.1400da910
mov ecx, ebp
test eax, eax
setne cl
lea r14d, [rcx + 4]
jmp 0x1400b8141
lea rdx, str.RawRead
mov rcx, r15
call fcn.1400da910
test eax, eax
jne 0x1400b8048
lea r14d, [rax + 6]
jmp 0x1400b8141
lea rdx, str.RawWrite
mov rcx, r15
call fcn.1400da910
test eax, eax
jne 0x1400b8064
lea r14d, [rax + 6]
jmp 0x1400b8141
lea rdx, [0x14011b758]
mov rcx, r15
call fcn.1400da910
test eax, eax
je 0x1400b813b
lea rdx, str.Length
mov rcx, r15
call fcn.1400da910
test eax, eax
jne 0x1400b8097
lea r14d, [rax + 9]
jmp 0x1400b8141
lea rdx, str.AtEOF
mov rcx, r15
call fcn.1400da910
test eax, eax
jne 0x1400b80b3
lea r14d, [rax + 0xa]
jmp 0x1400b8141
lea rdx, str.__Handle
mov rcx, r15
call fcn.1400da910
test eax, eax
jne 0x1400b80cc
lea r14d, [rax + 0xb]
jmp 0x1400b8141
lea rdx, str.Encoding
mov rcx, r15
call fcn.1400da910
test eax, eax
jne 0x1400b80e5
lea r14d, [rax + 0xc]
jmp 0x1400b8141
lea rdx, str.Close
mov rcx, r15
call fcn.1400da910
test eax, eax
jne 0x1400b80fe
lea r14d, [rax + 0xd]
jmp 0x1400b8141
lea rdx, str.Position
mov rcx, r15
call fcn.1400da910
test eax, eax
je 0x1400b813b
lea rdx, str.Seek
mov rcx, r15
call fcn.1400da910
test eax, eax
je 0x1400b813b
lea rdx, str.Tell
mov rcx, r15
call fcn.1400da910
test eax, eax
jne 0x1400b8aac
mov r14d, 8
mov eax, dword [rsp + 0x88]
test al, 2
jne 0x1400b8161
cmp r14d, 7
jb 0x1400b8495
and eax, 1
cmp edi, eax
jne 0x1400b8495
lea eax, [r14 - 1]
mov dword [rsi + 0x10], 1
cmp eax, 0xc
ja case.0x1400b820d.69
cdqe
lea rcx, [0x140000000]
mov eax, dword [rcx + rax*4 + 0xb8ad0]
add rax, rcx
jmp rax
movzx eax, word [r15]
mov ecx, 0xffdf
sub ax, 0x52
mov r14d, ebp
test cx, ax
sete al
mov byte [rsp + 0x98], al
movzx eax, al
xor rax, 1
lea r15, [r15 + rax*2]
add r15, 8
mov qword [rsp + 0x38], r15
movzx ecx, word [r15]
call fcn.1400163d0
cmp ax, 0x55
jne 0x1400b81d8
add r15, 2
mov qword [rsp + 0x38], r15
mov r15d, ebp
jmp 0x1400b81de
mov r15d, 1
mov rax, qword [rsp + 0x38]
movzx ecx, word [rax]
call fcn.1400163d0
movzx eax, ax
add eax, 0xffffffbd
cmp eax, 0x10
ja case.0x1400b820d.69
lea rcx, [0x140000000]
cdqe
mov edx, dword [rcx + rax*4 + 0xb8b04]
add rdx, rcx
jmp rdx
mov rcx, qword [rsp + 0x38]
mov dx, getservbyport
call fcn.1400d7a50
test rax, rax
mov eax, 8
cmovne ebx, eax
jmp 0x1400b824a
mov ebx, 2
jmp 0x1400b824a
mov ebx, 1
jmp 0x1400b824a
mov ebx, 8
jmp 0x1400b824a
mov ebx, 8
mov r14d, 1
cmp byte [rsp + 0x98], bpl
je 0x1400b8315
lea rcx, [r13 + 0x10]
mov qword [rsp + 0x30], rbp
mov r8d, ebx
lea rdx, [rsp + 0x30]
call fcn.1400b7820
test eax, eax
je case.0x1400b820d.69
test r14d, r14d
je 0x1400b82b9
cmp ebx, 4
jne 0x1400b829d
movss xmm0, dword [rsp + 0x30]
mov eax, 2
cvtps2pd xmm0, xmm0
mov dword [rsi + 0x10], eax
lea eax, [rbx - 3]
movsd qword [rsi], xmm0
jmp 0x1400b8aae
movsd xmm0, qword [rsp + 0x30]
mov eax, 2
mov dword [rsi + 0x10], eax
mov eax, 1
movsd qword [rsi], xmm0
jmp 0x1400b8aae
test r15d, r15d
je 0x1400b8303
sub ebx, 1
je 0x1400b82f0
sub ebx, 1
je 0x1400b82dd
cmp ebx, 2
jne 0x1400b8303
movsxd rax, dword [rsp + 0x30]
mov qword [rsi], rax
lea eax, [rbx - 1]
jmp 0x1400b8aae
movsx rax, word [rsp + 0x30]
mov qword [rsi], rax
mov eax, 1
jmp 0x1400b8aae
movsx rax, byte [rsp + 0x30]
mov qword [rsi], rax
mov eax, 1
jmp 0x1400b8aae
mov rax, qword [rsp + 0x30]
mov qword [rsi], rax
mov eax, 1
jmp 0x1400b8aae
cmp edi, 1
jne case.0x1400b820d.69
mov r9, qword [r12 + 8]
test r14d, r14d
je 0x1400b835a
xor r8d, r8d
mov edx, edi
mov rcx, r9
call fcn.1400834b0
movsd qword [rsp + 0x30], xmm0
lea rdi, [0x140103574]
cmp ebx, 4
jne 0x1400b83e6
cvtsd2ss xmm0, xmm0
movss dword [rsp + 0x30], xmm0
jmp 0x1400b83e6
cmp ebx, 8
jne 0x1400b83d0
test r15d, r15d
jne 0x1400b83d0
mov ecx, dword [r9 + 0x10]
lea eax, [rcx - 1]
cmp eax, 1
jbe 0x1400b83d0
test ecx, ecx
je 0x1400b83bc
sub ecx, 1
je 0x1400b8388
sub ecx, 1
je 0x1400b8388
sub ecx, 2
je 0x1400b839c
cmp ecx, 1
je 0x1400b83bc
lea rdi, [0x140103574]
mov rax, rdi
mov rcx, rax
call fcn.140058f20
jmp 0x1400b83e1
mov rcx, qword [r9]
xor r8d, r8d
lea edx, [r8 + 1]
call fcn.1400017c0
mov rcx, rax
lea rdi, [0x140103574]
call fcn.140058f20
jmp 0x1400b83e1
mov rax, qword [r9]
lea rdi, [0x140103574]
mov rcx, rax
call fcn.140058f20
jmp 0x1400b83e1
xor edx, edx
mov rcx, r9
call fcn.140083410
lea rdi, [0x140103574]
mov qword [rsp + 0x30], rax
lea rcx, [r13 + 0x10]
mov r8d, ebx
lea rdx, [rsp + 0x30]
call fcn.1400b7bd0
mov ecx, eax
test eax, eax
jne 0x1400b8411
mov rax, qword [0x14013dbf0]
test byte [rax + 0x140], 1
jne 0x1400b87cf
mov qword [rsi], rcx
mov eax, 1
jmp 0x1400b8aae
cmp edi, 1
jg case.0x1400b820d.69
test edi, edi
je 0x1400b843c
mov rcx, qword [r12 + 8]
xor edx, edx
call fcn.140083410
mov rbx, rax
jmp 0x1400b8455
lea rcx, [r13 + 0x10]
call fcn.1400b7220
lea rcx, [r13 + 0x10]
mov rdi, rax
call fcn.1400b7270
sub eax, edi
mov ebx, eax
cmp ebx, 0xffffffff
je case.0x1400b820d.69
mov r8d, ebx
xor edx, edx
mov rcx, rsi
call fcn.140083aa0
test eax, eax
je case.0x1400b820d.69
xor r9d, r9d
mov r8d, ebx
mov rdx, qword [rsi]
lea rcx, [r13 + 0x10]
call fcn.1400b7470
mov ecx, eax
mov rax, qword [rsi]
mov dword [rsi + 0x10], ebp
mov word [rax + rcx*2], bp
mov qword [rsi + 8], rcx
mov eax, 1
jmp 0x1400b8aae
test edi, edi
jne case.0x1400b820d.69
mov ecx, 0x20002
call fcn.1400dc214
mov qword [rsi + 0x18], rax
test rax, rax
je case.0x1400b820d.69
mov qword [rsi + 8], 0x10000
lea r9d, [rdi + 1]
mov qword [rsi], rax
mov r8d, 0xffff
mov word [rax + 0x20000], bp
jmp 0x1400b8479
cmp edi, 1
jg case.0x1400b820d.69
mov r15d, ebp
mov ebx, ebp
test edi, edi
je 0x1400b8590
mov rdx, qword [rsi + 8]
mov rcx, qword [r12 + 8]
call fcn.140083570
mov rbx, qword [r12 + 8]
mov rdi, rax
cmp dword [rbx + 0x10], 4
jne 0x1400b8563
mov rbx, qword [rbx]
movzx edx, byte [rbx + 0x23]
test dl, dl
jne 0x1400b8523
mov rax, qword [rbx + 0x10]
movzx ecx, byte [rax + 0x21]
jmp 0x1400b8527
movzx ecx, byte [rbx + 0x21]
test cl, 1
jne 0x1400b8563
test dl, dl
jne 0x1400b8534
mov rbx, qword [rbx + 0x10]
cmp byte [rbx + 0x23], 1
jne 0x1400b8554
test byte [rbx + 0x21], 8
je 0x1400b8548
mov rcx, rbx
call fcn.140001670
add rbx, 0x10
mov rbx, qword [rbx]
shr rbx, 1
jmp 0x1400b8579
lea rbx, [0x1401482e0]
mov rbx, qword [rbx]
shr rbx, 1
jmp 0x1400b8579
mov rbx, 0xffffffffffffffff
nop word [rax + rax]
inc rbx
cmp word [rdi + rbx*2], bp
jne 0x1400b8570
add r13, 0x10
mov r8d, ebx
mov rcx, r13
mov rdx, rdi
call fcn.1400b7970
mov r15d, eax
jmp 0x1400b8594
add r13, 0x10
cmp r14d, 4
jne 0x1400b85bd
test r15d, r15d
jne 0x1400b85a3
test ebx, ebx
jne 0x1400b85c6
mov r8d, 1
lea rdx, [0x1401239f4]
mov rcx, r13
inc ebx
call fcn.1400b7970
add r15d, eax
test r15d, r15d
jne 0x1400b85da
test ebx, ebx
je 0x1400b85da
mov rax, qword [0x14013dbf0]
test byte [rax + 0x140], 1
jne case.0x1400b820d.69
mov eax, r15d
mov qword [rsi], rax
mov eax, 1
jmp 0x1400b8aae
cmp edi, 2
jne case.0x1400b820d.69
movzx eax, word [r15 + 6]
mov ecx, 0xffdf
mov rdi, qword [r12 + 8]
sub ax, 0x52
test cx, ax
mov rcx, qword [r12 + 0x10]
sete r14b
xor edx, edx
call fcn.140083410
cmp dword [rdi + 0x10], 4
mov rbx, rax
jne 0x1400b86a1
mov rcx, qword [rdi]
cmp byte [rcx + 0x23], bpl
jne 0x1400b8631
mov rax, qword [rcx + 0x10]
jmp 0x1400b8634
mov rax, rcx
cmp byte [rax + 0x23], 2
mov edx, dword [0x140146980]
je 0x1400b8644
mov rdx, qword [rax + 0x18]
mov eax, ebx
cmp rax, rdx
jbe 0x1400b8690
test r14b, r14b
je 0x1400b866f
mov r8d, eax
mov byte [rsp + 0x20], bpl
shr r8, 1
and eax, 1
add r8, rax
xor r9d, r9d
xor edx, edx
call fcn.1400be640
test eax, eax
jne 0x1400b8690
mov rax, qword [0x14013dbf0]
test byte [rax + 0x140], 1
jne case.0x1400b820d.69
mov qword [rsi], rbp
mov eax, 1
jmp 0x1400b8aae
mov rcx, qword [rdi]
xor r8d, r8d
lea edx, [r8 + 1]
call fcn.1400017c0
jmp 0x1400b86ab
xor edx, edx
mov rcx, rdi
call fcn.140083410
cmp rax, 0x10000
jae 0x1400b86b7
mov ecx, ebp
jmp 0x1400b86d8
lea rcx, [r13 + 0x10]
mov r8d, ebx
mov rdx, rax
test r14b, r14b
je 0x1400b86cd
call fcn.1400b7820
jmp 0x1400b86d2
call fcn.1400b7bd0
mov ecx, eax
test eax, eax
jne 0x1400b86f0
test ebx, ebx
je 0x1400b86f0
mov rax, qword [0x14013dbf0]
test byte [rax + 0x140], 1
jne case.0x1400b820d.69
mov eax, ecx
mov qword [rsi], rax
mov eax, 1
jmp 0x1400b8aae
test edi, edi
jne 0x1400b8717
lea rcx, [r13 + 0x10]
call fcn.1400b7220
mov qword [rsi], rax
lea eax, [rdi + 1]
jmp 0x1400b8aae
cmp edi, 2
jg case.0x1400b820d.69
mov rcx, qword [r12 + 8]
xor edx, edx
call fcn.140083410
mov r14, rax
cmp edi, 2
jne 0x1400b8745
mov rcx, qword [r12 + 0x10]
xor edx, edx
call fcn.140083410
mov rdi, rax
jmp 0x1400b8752
test r14, r14
mov edi, ebp
mov ecx, 2
cmovs edi, ecx
mov rdx, qword [r13 + 0x40]
mov r8d, dword [r13 + 0x1c]
test rdx, rdx
je 0x1400b877e
sub rdx, qword [r13 + 0x48]
lea rcx, [r13 + 0x10]
mov r9, qword [r13 + 0x10]
sub rdx, r8
mov r8d, 1
call qword [r9 + 0x28]
mov qword [r13 + 0x40], rbp
jmp 0x1400b8792
test r8d, r8d
je 0x1400b8796
mov rax, qword [r13 + 0x10]
lea rcx, [r13 + 0x10]
mov rdx, qword [r13 + 0x48]
call qword [rax + 0x20]
mov dword [r13 + 0x1c], ebp
mov rax, qword [r13 + 0x10]
lea rcx, [r13 + 0x10]
mov r8d, edi
mov word [r13 + 0x3c], bp
mov rdx, r14
call qword [rax + 0x28]
test al, al
jne 0x1400b893c
mov rax, qword [0x14013dbf0]
test byte [rax + 0x140], 1
je 0x1400b8941
lea rdi, [0x140103574]
mov rax, qword [0x14013dbf0]
mov dword [rsi + 0x10], ebp
test byte [rax + 0x140], 1
je 0x1400b8495
mov rcx, qword [0x1401463a0]
lea r8, str.FileObject
mov r9, rdi
lea rdx, [0x140119fac]
call fcn.140056750
mov eax, 1
jmp 0x1400b8aae
test edi, edi
jne 0x1400b8825
lea rcx, [r13 + 0x10]
call fcn.1400b7270
mov qword [rsi], rax
lea eax, [rdi + 1]
jmp 0x1400b8aae
cmp edi, 1
jne case.0x1400b820d.69
mov rcx, qword [r12 + 8]
xor edx, edx
call fcn.140083410
mov rdx, qword [r13 + 0x40]
mov r14, rax
mov r8d, dword [r13 + 0x1c]
test rdx, rdx
je 0x1400b8862
sub rdx, qword [r13 + 0x48]
lea rcx, [r13 + 0x10]
mov r9, qword [r13 + 0x10]
sub rdx, r8
mov r8d, edi
call qword [r9 + 0x28]
mov qword [r13 + 0x40], rbp
jmp 0x1400b8876
test r8d, r8d
je 0x1400b887a
mov rax, qword [r13 + 0x10]
lea rcx, [r13 + 0x10]
mov rdx, qword [r13 + 0x48]
call qword [rax + 0x20]
mov dword [r13 + 0x1c], ebp
mov rax, qword [r13 + 0x10]
lea rcx, [r13 + 0x10]
mov word [r13 + 0x3c], bp
call qword [rax + 0x30]
xor r8d, r8d
lea rcx, [r13 + 0x10]
mov rdi, rax
mov rdx, r14
mov rax, qword [r13 + 0x10]
call qword [rax + 0x28]
test al, al
je 0x1400b88d8
mov rcx, qword [r13 + 0x50]
call qword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
je 0x1400b88d8
mov rax, qword [r13 + 0x10]
lea rcx, [r13 + 0x10]
cmp r14, rdi
cmovl rdi, r14
xor r8d, r8d
mov rdx, rdi
call qword [rax + 0x28]
mov rax, qword [r13 + 0x10]
lea rcx, [r13 + 0x10]
call qword [rax + reloc.WSOCK32.dll_getservbyport]
mov rbx, rax
jmp 0x1400b88df
mov rbx, 0xffffffffffffffff
mov qword [rsi], rbx
cmp rbx, 0xffffffffffffffff
jne 0x1400b8495
lea rdi, [0x140103574]
mov qword [rsi], rdi
jmp 0x1400b87cf
test edi, edi
jne 0x1400b8495
mov rcx, qword [r13 + 0x40]
test rcx, rcx
je 0x1400b8919
mov eax, dword [r13 + 0x1c]
add rax, qword [r13 + 0x48]
cmp rcx, rax
jb 0x1400b8941
mov rax, qword [r13 + 0x10]
lea rcx, [r13 + 0x10]
call qword [rax + 0x30]
mov rdi, rax
test rax, rax
js 0x1400b893c
mov rax, qword [r13 + 0x10]
lea rcx, [r13 + 0x10]
call qword [rax + reloc.WSOCK32.dll_getservbyport]
cmp rdi, rax
jl 0x1400b8941
mov ebp, 1
mov qword [rsi], rbp
mov eax, 1
jmp 0x1400b8aae
test edi, edi
jne 0x1400b8495
mov rdx, qword [r13 + 0x40]
mov r8d, dword [r13 + 0x1c]
test rdx, rdx
je 0x1400b8980
sub rdx, qword [r13 + 0x48]
lea rcx, [r13 + 0x10]
mov r9, qword [r13 + 0x10]
sub rdx, r8
lea r8d, [rdi + 1]
call qword [r9 + 0x28]
mov qword [r13 + 0x40], rbp
jmp 0x1400b8994
test r8d, r8d
je 0x1400b8998
mov rax, qword [r13 + 0x10]
lea rcx, [r13 + 0x10]
mov rdx, qword [r13 + 0x48]
call qword [rax + 0x20]
mov dword [r13 + 0x1c], ebp
mov rax, qword [r13 + 0x50]
mov word [r13 + 0x3c], bp
mov qword [rsi], rax
mov eax, 1
jmp 0x1400b8aae
test edi, edi
jle 0x1400b8a29
mov rcx, qword [r12 + 8]
call fcn.1400832e0
mov r9, qword [r12 + 8]
test eax, eax
je 0x1400b89d1
xor edx, edx
mov rcx, r9
call fcn.140083410
jmp 0x1400b8a15
mov ecx, dword [r9 + 0x10]
test ecx, ecx
je 0x1400b8a0a
sub ecx, 1
je 0x1400b89ed
sub ecx, 1
je 0x1400b89ed
sub ecx, 2
je 0x1400b89f6
cmp ecx, 1
je 0x1400b8a0a
lea rdi, [0x140103574]
jmp 0x1400b8a0d
mov rcx, qword [r9]
xor r8d, r8d
lea edx, [r8 + 1]
call fcn.1400017c0
mov rdi, rax
jmp 0x1400b8a0d
mov rdi, qword [r9]
mov rcx, rdi
call fcn.1400338d0
cmp eax, 0xffffffff
je 0x1400b8a29
btr eax, 0x1f
lea rcx, [r13 + 0x10]
mov edx, eax
call fcn.1400057c0
mov ecx, dword [r13 + 0x24]
cmp ecx, 0x4b0
je 0x1400b8a77
cmp ecx, 0xfde9
je 0x1400b8a63
mov rbx, qword [rsi + 8]
mov r8d, 0xa
lea rdx, [rbx + 4]
mov dword [rbx], 0x500043
call fcn.1400da7a0
mov eax, 1
mov dword [rsi + 0x10], ebp
mov qword [rsi], rbx
jmp 0x1400b8aae
lea rbx, str.UTF_8
mov dword [rsi + 0x10], ebp
mov qword [rsi], rbx
mov eax, 1
jmp 0x1400b8aae
lea rbx, str.UTF_16
mov dword [rsi + 0x10], ebp
mov qword [rsi], rbx
mov eax, 1
jmp 0x1400b8aae
test edi, edi
jne 0x1400b8a98
lea rcx, [r13 + 0x10]
call fcn.140005770
lea rdi, [0x140103574]
mov dword [rsi + 0x10], ebp
mov qword [rsi], rdi
mov eax, 1
jmp 0x1400b8aae
mov eax, ebx
mov rbx, qword [rsp + 0x70]
mov rbp, qword [rsp + 0x78]
mov rsi, qword [rsp + 0x80]
add rsp, 0x40
pop r15
pop r14
pop r13
pop r12
pop rdi
ret