	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_NET_OpenSocks                  ## -- Begin function NET_OpenSocks
	.p2align	4, 0x90
_NET_OpenSocks:                         ## @NET_OpenSocks
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	subq	$104, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edi, %r13d
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	_qfalse@GOTPCREL(%rip), %r14
	movq	(%r14), %rax
	movq	_usingSocks@GOTPCREL(%rip), %rcx
	movq	%rax, (%rcx)
	leaq	L_.str(%rip), %rdi
	xorl	%eax, %eax
	callq	_Com_Printf
	movq	_AF_INET@GOTPCREL(%rip), %r12
	movq	(%r12), %rdi
	movq	_SOCK_STREAM@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_IPPROTO_TCP@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_socket
	movq	_socks_socket@GOTPCREL(%rip), %r15
	movl	%eax, (%r15)
	movq	_INVALID_SOCKET@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_4
## %bb.1:
	xorl	%eax, %eax
	callq	_WSAGetLastError
	xorl	%eax, %eax
	callq	_NET_ErrorString
	movq	___stack_chk_guard@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	cmpq	-48(%rbp), %rcx
	jne	LBB0_48
## %bb.2:
	movzbl	%al, %esi
	leaq	L_.str.1(%rip), %rdi
	jmp	LBB0_3
LBB0_4:
	movq	_net_socksServer@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movl	(%rax), %edi
	callq	_gethostbyname
	testq	%rax, %rax
	je	LBB0_5
## %bb.7:
	movq	(%rax), %rcx
	cmpq	(%r12), %rcx
	jne	LBB0_8
## %bb.10:
	movq	%rcx, -128(%rbp)
	movq	8(%rax), %rax
	movq	(%rax), %rax
	movl	(%rax), %eax
	movl	%eax, -136(%rbp)
	movq	_net_socksPort@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movswl	(%rax), %edi
	callq	_htons
	movw	%ax, -144(%rbp)
	movl	(%r15), %edi
	leaq	-144(%rbp), %rsi
	movl	$24, %edx
	callq	_connect
	movq	_SOCKET_ERROR@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_12
## %bb.11:
	xorl	%eax, %eax
	callq	_WSAGetLastError
	xorl	%eax, %eax
	callq	_NET_ErrorString
	movzbl	%al, %esi
	leaq	L_.str.4(%rip), %rdi
	jmp	LBB0_42
LBB0_5:
	xorl	%eax, %eax
	callq	_WSAGetLastError
	xorl	%eax, %eax
	callq	_NET_ErrorString
	movq	___stack_chk_guard@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	cmpq	-48(%rbp), %rcx
	jne	LBB0_48
## %bb.6:
	movzbl	%al, %esi
	leaq	L_.str.2(%rip), %rdi
LBB0_3:
	xorl	%eax, %eax
	addq	$104, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_Com_Printf                     ## TAILCALL
LBB0_8:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_48
## %bb.9:
	leaq	L_.str.3(%rip), %rdi
	xorl	%eax, %eax
	addq	$104, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_Com_Printf                     ## TAILCALL
LBB0_12:
	movq	_net_socksUsername@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	(%rax), %rax
	cmpq	$0, (%rax)
	jne	LBB0_14
## %bb.13:
	movq	_net_socksPassword@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	(%rax), %rax
	cmpq	$0, (%rax)
	je	LBB0_15
LBB0_14:
	movq	_qtrue@GOTPCREL(%rip), %r14
LBB0_15:
	xorl	%eax, %eax
	cmpq	$0, (%r14)
	setne	%cl
	movb	$5, -112(%rbp)
	sete	%al
	movb	$2, %bl
	subb	%al, %bl
	addb	%cl, %cl
	movl	$4, %edx
	subl	%eax, %edx
	movb	%bl, -111(%rbp)
	movb	%cl, -110(%rbp)
	movl	(%r15), %edi
	leaq	-112(%rbp), %rsi
	xorl	%ecx, %ecx
	callq	_send
	movq	_SOCKET_ERROR@GOTPCREL(%rip), %rbx
	cmpl	(%rbx), %eax
	jne	LBB0_17
LBB0_16:
	xorl	%eax, %eax
	callq	_WSAGetLastError
	xorl	%eax, %eax
	callq	_NET_ErrorString
	movzbl	%al, %esi
	leaq	L_.str.5(%rip), %rdi
	jmp	LBB0_42
LBB0_17:
	movl	(%r15), %edi
	leaq	-112(%rbp), %rsi
	movl	$64, %edx
	xorl	%ecx, %ecx
	callq	_recv
	cmpl	(%rbx), %eax
	jne	LBB0_19
LBB0_18:
	xorl	%eax, %eax
	callq	_WSAGetLastError
	xorl	%eax, %eax
	callq	_NET_ErrorString
	movzbl	%al, %esi
	leaq	L_.str.6(%rip), %rdi
LBB0_42:
	xorl	%eax, %eax
	callq	_Com_Printf
LBB0_46:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_48
## %bb.47:
	addq	$104, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_19:
	cmpl	$2, %eax
	jne	LBB0_21
## %bb.20:
	cmpb	$5, -112(%rbp)
	jne	LBB0_21
## %bb.23:
	movb	-111(%rbp), %al
	testb	%al, %al
	je	LBB0_36
## %bb.24:
	cmpb	$2, %al
	jne	LBB0_25
## %bb.26:
	movq	_net_socksUsername@GOTPCREL(%rip), %r14
	movq	(%r14), %rax
	movq	(%rax), %rdi
	callq	_strlen
	movl	%eax, %r14d
	movq	_net_socksPassword@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	(%rax), %rdi
	callq	_strlen
	movb	$1, -112(%rbp)
	movb	%r14b, -111(%rbp)
	movl	%r14d, -116(%rbp)               ## 4-byte Spill
	testl	%r14d, %r14d
	je	LBB0_28
## %bb.27:
	leaq	-110(%rbp), %rdi
	movq	_net_socksUsername@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	(%rcx), %rsi
	movl	%eax, %r14d
	movl	-116(%rbp), %edx                ## 4-byte Reload
	callq	_memcpy
	movl	%r14d, %eax
LBB0_28:
	movl	-116(%rbp), %r14d               ## 4-byte Reload
	movslq	%r14d, %rdx
	leaq	-112(%rbp), %rcx
	movb	%al, 2(%rdx,%rcx)
	addl	$3, %r14d
	testl	%eax, %eax
	je	LBB0_30
## %bb.29:
	movslq	%r14d, %rcx
	leaq	(%rcx,%rbp), %rdi
	addq	$-112, %rdi
	movq	_net_socksPassword@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	(%rcx), %rsi
	movl	%eax, -116(%rbp)                ## 4-byte Spill
	movl	-116(%rbp), %edx                ## 4-byte Reload
	callq	_memcpy
	movl	-116(%rbp), %eax                ## 4-byte Reload
LBB0_30:
	movl	(%r15), %edi
	addl	%eax, %r14d
	leaq	-112(%rbp), %rsi
	movl	%r14d, %edx
	xorl	%ecx, %ecx
	callq	_send
	cmpl	(%rbx), %eax
	je	LBB0_16
## %bb.31:
	movl	(%r15), %edi
	leaq	-112(%rbp), %rsi
	movl	$64, %edx
	xorl	%ecx, %ecx
	callq	_recv
	cmpl	(%rbx), %eax
	je	LBB0_18
## %bb.32:
	cmpl	$2, %eax
	jne	LBB0_21
## %bb.33:
	cmpb	$1, -112(%rbp)
	jne	LBB0_21
## %bb.34:
	cmpb	$0, -111(%rbp)
	je	LBB0_36
## %bb.35:
	leaq	L_.str.9(%rip), %rdi
	jmp	LBB0_22
LBB0_36:
	movl	$16777989, -112(%rbp)           ## imm = 0x1000305
	movq	_INADDR_ANY@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -108(%rbp)
	movswl	%r13w, %edi
	callq	_htons
	movw	%ax, -104(%rbp)
	movl	(%r15), %edi
	leaq	-112(%rbp), %rsi
	movl	$10, %edx
	xorl	%ecx, %ecx
	callq	_send
	cmpl	(%rbx), %eax
	je	LBB0_16
## %bb.37:
	movl	(%r15), %edi
	leaq	-112(%rbp), %rsi
	movl	$64, %edx
	xorl	%ecx, %ecx
	callq	_recv
	cmpl	(%rbx), %eax
	je	LBB0_18
## %bb.38:
	cmpl	$2, %eax
	jl	LBB0_21
## %bb.39:
	cmpb	$5, -112(%rbp)
	jne	LBB0_21
## %bb.40:
	movzbl	-111(%rbp), %esi
	testl	%esi, %esi
	je	LBB0_43
## %bb.41:
	leaq	L_.str.10(%rip), %rdi
	jmp	LBB0_42
LBB0_21:
	leaq	L_.str.7(%rip), %rdi
	jmp	LBB0_22
LBB0_25:
	leaq	L_.str.8(%rip), %rdi
LBB0_22:
	xorl	%eax, %eax
	callq	_Com_Printf
	jmp	LBB0_46
LBB0_43:
	movzbl	-109(%rbp), %esi
	cmpl	$1, %esi
	jne	LBB0_44
## %bb.45:
	movq	(%r12), %rax
	movq	_socksRelayAddr@GOTPCREL(%rip), %rcx
	movq	%rax, 16(%rcx)
	movl	-108(%rbp), %eax
	movl	%eax, 8(%rcx)
	movzwl	-104(%rbp), %eax
	movw	%ax, (%rcx)
	movl	4(%rcx), %edi
	xorl	%esi, %esi
	movl	$8, %edx
	callq	_memset
	movq	_qtrue@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	_usingSocks@GOTPCREL(%rip), %rcx
	movq	%rax, (%rcx)
	jmp	LBB0_46
LBB0_44:
	leaq	L_.str.11(%rip), %rdi
	jmp	LBB0_42
LBB0_48:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_qfalse,8,3                     ## @qfalse
	.comm	_usingSocks,8,3                 ## @usingSocks
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Opening connection to SOCKS server.\n"

	.comm	_AF_INET,8,3                    ## @AF_INET
	.comm	_SOCK_STREAM,4,2                ## @SOCK_STREAM
	.comm	_IPPROTO_TCP,4,2                ## @IPPROTO_TCP
	.comm	_socks_socket,4,2               ## @socks_socket
	.comm	_INVALID_SOCKET,4,2             ## @INVALID_SOCKET
L_.str.1:                               ## @.str.1
	.asciz	"WARNING: NET_OpenSocks: socket: %s\n"

	.comm	_net_socksServer,8,3            ## @net_socksServer
L_.str.2:                               ## @.str.2
	.asciz	"WARNING: NET_OpenSocks: gethostbyname: %s\n"

L_.str.3:                               ## @.str.3
	.asciz	"WARNING: NET_OpenSocks: gethostbyname: address type was not AF_INET\n"

	.comm	_net_socksPort,8,3              ## @net_socksPort
	.comm	_SOCKET_ERROR,4,2               ## @SOCKET_ERROR
L_.str.4:                               ## @.str.4
	.asciz	"NET_OpenSocks: connect: %s\n"

	.comm	_net_socksUsername,8,3          ## @net_socksUsername
	.comm	_net_socksPassword,8,3          ## @net_socksPassword
	.comm	_qtrue,8,3                      ## @qtrue
L_.str.5:                               ## @.str.5
	.asciz	"NET_OpenSocks: send: %s\n"

L_.str.6:                               ## @.str.6
	.asciz	"NET_OpenSocks: recv: %s\n"

L_.str.7:                               ## @.str.7
	.asciz	"NET_OpenSocks: bad response\n"

L_.str.8:                               ## @.str.8
	.asciz	"NET_OpenSocks: request denied\n"

L_.str.9:                               ## @.str.9
	.asciz	"NET_OpenSocks: authentication failed\n"

	.comm	_INADDR_ANY,4,2                 ## @INADDR_ANY
L_.str.10:                              ## @.str.10
	.asciz	"NET_OpenSocks: request denied: %i\n"

L_.str.11:                              ## @.str.11
	.asciz	"NET_OpenSocks: relay address is not IPV4: %i\n"

	.comm	_socksRelayAddr,4,2             ## @socksRelayAddr
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_NET_OpenSocks                  ; -- Begin function NET_OpenSocks
	.p2align	2
_NET_OpenSocks:                         ; @NET_OpenSocks
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #208
	.cfi_def_cfa_offset 208
	stp	x28, x27, [sp, #112]            ; 16-byte Folded Spill
	stp	x26, x25, [sp, #128]            ; 16-byte Folded Spill
	stp	x24, x23, [sp, #144]            ; 16-byte Folded Spill
	stp	x22, x21, [sp, #160]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #176]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #192]            ; 16-byte Folded Spill
	add	x29, sp, #192
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-88]
Lloh3:
	adrp	x20, _qfalse@GOTPAGE
Lloh4:
	ldr	x20, [x20, _qfalse@GOTPAGEOFF]
	ldr	x8, [x20]
Lloh5:
	adrp	x22, _usingSocks@GOTPAGE
Lloh6:
	ldr	x22, [x22, _usingSocks@GOTPAGEOFF]
	str	x8, [x22]
Lloh7:
	adrp	x0, l_.str@PAGE
Lloh8:
	add	x0, x0, l_.str@PAGEOFF
	bl	_Com_Printf
Lloh9:
	adrp	x23, _AF_INET@GOTPAGE
Lloh10:
	ldr	x23, [x23, _AF_INET@GOTPAGEOFF]
	ldr	x0, [x23]
Lloh11:
	adrp	x8, _SOCK_STREAM@GOTPAGE
Lloh12:
	ldr	x8, [x8, _SOCK_STREAM@GOTPAGEOFF]
Lloh13:
	ldr	w1, [x8]
Lloh14:
	adrp	x8, _IPPROTO_TCP@GOTPAGE
Lloh15:
	ldr	x8, [x8, _IPPROTO_TCP@GOTPAGEOFF]
Lloh16:
	ldr	w2, [x8]
	bl	_socket
Lloh17:
	adrp	x24, _socks_socket@GOTPAGE
Lloh18:
	ldr	x24, [x24, _socks_socket@GOTPAGEOFF]
	str	w0, [x24]
Lloh19:
	adrp	x8, _INVALID_SOCKET@GOTPAGE
Lloh20:
	ldr	x8, [x8, _INVALID_SOCKET@GOTPAGEOFF]
Lloh21:
	ldr	w8, [x8]
	cmp	w0, w8
	b.ne	LBB0_2
; %bb.1:
	bl	_WSAGetLastError
	bl	_NET_ErrorString
	mov	w8, w0
	str	x8, [sp]
Lloh22:
	adrp	x0, l_.str.1@PAGE
Lloh23:
	add	x0, x0, l_.str.1@PAGEOFF
	b	LBB0_7
LBB0_2:
Lloh24:
	adrp	x8, _net_socksServer@GOTPAGE
Lloh25:
	ldr	x8, [x8, _net_socksServer@GOTPAGEOFF]
Lloh26:
	ldr	x8, [x8]
	ldr	w0, [x8]
	bl	_gethostbyname
	cbz	x0, LBB0_6
; %bb.3:
	ldr	x8, [x0]
	ldr	x9, [x23]
	cmp	x8, x9
	b.ne	LBB0_10
; %bb.4:
	str	x8, [sp, #32]
	ldr	x8, [x0, #8]
	ldr	x8, [x8]
	ldr	w8, [x8]
	str	w8, [sp, #24]
Lloh27:
	adrp	x8, _net_socksPort@GOTPAGE
Lloh28:
	ldr	x8, [x8, _net_socksPort@GOTPAGEOFF]
Lloh29:
	ldr	x8, [x8]
	ldrsh	w0, [x8]
	bl	_htons
	strh	w0, [sp, #16]
	ldr	w0, [x24]
	add	x1, sp, #16
	mov	w2, #24
	bl	_connect
Lloh30:
	adrp	x26, _SOCKET_ERROR@GOTPAGE
Lloh31:
	ldr	x26, [x26, _SOCKET_ERROR@GOTPAGEOFF]
	ldr	w8, [x26]
	cmp	w0, w8
	b.ne	LBB0_12
; %bb.5:
	bl	_WSAGetLastError
	bl	_NET_ErrorString
	mov	w8, w0
	str	x8, [sp]
Lloh32:
	adrp	x0, l_.str.4@PAGE
Lloh33:
	add	x0, x0, l_.str.4@PAGEOFF
	b	LBB0_7
LBB0_6:
	bl	_WSAGetLastError
	bl	_NET_ErrorString
	mov	w8, w0
	str	x8, [sp]
Lloh34:
	adrp	x0, l_.str.2@PAGE
Lloh35:
	add	x0, x0, l_.str.2@PAGEOFF
LBB0_7:
	bl	_Com_Printf
LBB0_8:
	ldur	x8, [x29, #-88]
Lloh36:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh37:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh38:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_43
; %bb.9:
	ldp	x29, x30, [sp, #192]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #176]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #160]            ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #144]            ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #128]            ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #112]            ; 16-byte Folded Reload
	add	sp, sp, #208
	ret
LBB0_10:
	ldur	x8, [x29, #-88]
Lloh39:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh40:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh41:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_43
; %bb.11:
Lloh42:
	adrp	x0, l_.str.3@PAGE
Lloh43:
	add	x0, x0, l_.str.3@PAGEOFF
	ldp	x29, x30, [sp, #192]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #176]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #160]            ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #144]            ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #128]            ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #112]            ; 16-byte Folded Reload
	add	sp, sp, #208
	b	_Com_Printf
LBB0_12:
Lloh44:
	adrp	x27, _net_socksUsername@GOTPAGE
Lloh45:
	ldr	x27, [x27, _net_socksUsername@GOTPAGEOFF]
	ldr	x8, [x27]
	ldr	x8, [x8]
	ldr	x9, [x8]
Lloh46:
	adrp	x25, _qtrue@GOTPAGE
Lloh47:
	ldr	x25, [x25, _qtrue@GOTPAGEOFF]
	mov	x8, x25
	cbnz	x9, LBB0_14
; %bb.13:
Lloh48:
	adrp	x8, _net_socksPassword@GOTPAGE
Lloh49:
	ldr	x8, [x8, _net_socksPassword@GOTPAGEOFF]
Lloh50:
	ldr	x8, [x8]
	ldr	x8, [x8]
	ldr	x8, [x8]
	cmp	x8, #0
	csel	x8, x20, x25, eq
LBB0_14:
	ldr	x8, [x8]
	cmp	x8, #0
	cset	w8, ne
	mov	w9, #5
	strb	w9, [sp, #40]
	mov	w9, #1
	cinc	w9, w9, ne
	lsl	w8, w8, #1
	mov	w10, #3
	cinc	w2, w10, ne
	strb	w9, [sp, #41]
	add	x28, sp, #40
	strb	w8, [sp, #42]
	ldr	w0, [x24]
	add	x1, sp, #40
	mov	w3, #0
	bl	_send
	ldr	w8, [x26]
	cmp	w0, w8
	b.ne	LBB0_16
LBB0_15:
	bl	_WSAGetLastError
	bl	_NET_ErrorString
	mov	w8, w0
	str	x8, [sp]
Lloh51:
	adrp	x0, l_.str.5@PAGE
Lloh52:
	add	x0, x0, l_.str.5@PAGEOFF
	b	LBB0_7
LBB0_16:
	ldr	w0, [x24]
	add	x1, sp, #40
	mov	w2, #64
	mov	w3, #0
	bl	_recv
	ldr	w8, [x26]
	cmp	w0, w8
	b.ne	LBB0_18
LBB0_17:
	bl	_WSAGetLastError
	bl	_NET_ErrorString
	mov	w8, w0
	str	x8, [sp]
Lloh53:
	adrp	x0, l_.str.6@PAGE
Lloh54:
	add	x0, x0, l_.str.6@PAGEOFF
	b	LBB0_7
LBB0_18:
	cmp	w0, #2
	b.ne	LBB0_38
; %bb.19:
	ldrb	w8, [sp, #40]
	cmp	w8, #5
	b.ne	LBB0_38
; %bb.20:
	ldrb	w8, [sp, #41]
	cbz	w8, LBB0_32
; %bb.21:
	cmp	w8, #2
	b.ne	LBB0_39
; %bb.22:
	ldr	x8, [x27]
	ldr	x0, [x8]
	bl	_strlen
	mov	x21, x0
Lloh55:
	adrp	x8, _net_socksPassword@GOTPAGE
Lloh56:
	ldr	x8, [x8, _net_socksPassword@GOTPAGEOFF]
Lloh57:
	ldr	x8, [x8]
	ldr	x0, [x8]
	bl	_strlen
	mov	x20, x0
	mov	w8, #1
	strb	w8, [sp, #40]
	strb	w21, [sp, #41]
	cbz	w21, LBB0_24
; %bb.23:
	add	x0, x28, #2
	ldr	x8, [x27]
	ldr	x1, [x8]
	mov	x2, x21
	bl	_memcpy
LBB0_24:
	sxtw	x9, w21
	add	x8, sp, #40
	add	x10, x9, x8
	strb	w20, [x10, #2]
	add	x21, x9, #3
	cbz	w20, LBB0_26
; %bb.25:
	add	x0, x8, x21
Lloh58:
	adrp	x8, _net_socksPassword@GOTPAGE
Lloh59:
	ldr	x8, [x8, _net_socksPassword@GOTPAGEOFF]
Lloh60:
	ldr	x8, [x8]
	ldr	x1, [x8]
	mov	x2, x20
	bl	_memcpy
LBB0_26:
	ldr	w0, [x24]
	add	w2, w21, w20
	add	x1, sp, #40
	mov	w3, #0
	bl	_send
	ldr	w8, [x26]
	cmp	w0, w8
	b.eq	LBB0_15
; %bb.27:
	ldr	w0, [x24]
	add	x1, sp, #40
	mov	w2, #64
	mov	w3, #0
	bl	_recv
	ldr	w8, [x26]
	cmp	w0, w8
	b.eq	LBB0_17
; %bb.28:
	cmp	w0, #2
	b.ne	LBB0_38
; %bb.29:
	ldrb	w8, [sp, #40]
	cmp	w8, #1
	b.ne	LBB0_38
; %bb.30:
	ldrb	w8, [sp, #41]
	cbz	w8, LBB0_32
; %bb.31:
Lloh61:
	adrp	x0, l_.str.9@PAGE
Lloh62:
	add	x0, x0, l_.str.9@PAGEOFF
	b	LBB0_7
LBB0_32:
	mov	w8, #773
	movk	w8, #256, lsl #16
Lloh63:
	adrp	x9, _INADDR_ANY@GOTPAGE
Lloh64:
	ldr	x9, [x9, _INADDR_ANY@GOTPAGEOFF]
Lloh65:
	ldr	w9, [x9]
	stp	w8, w9, [sp, #40]
	sxth	w0, w19
	bl	_htons
	strh	w0, [sp, #48]
	ldr	w0, [x24]
	add	x1, sp, #40
	mov	w2, #10
	mov	w3, #0
	bl	_send
	ldr	w8, [x26]
	cmp	w0, w8
	b.eq	LBB0_15
; %bb.33:
	ldr	w0, [x24]
	add	x1, sp, #40
	mov	w2, #64
	mov	w3, #0
	bl	_recv
	ldr	w8, [x26]
	cmp	w0, w8
	b.eq	LBB0_17
; %bb.34:
	cmp	w0, #2
	b.lt	LBB0_38
; %bb.35:
	ldrb	w8, [sp, #40]
	cmp	w8, #5
	b.ne	LBB0_38
; %bb.36:
	ldrb	w8, [sp, #41]
	cbz	w8, LBB0_40
; %bb.37:
	str	x8, [sp]
Lloh66:
	adrp	x0, l_.str.10@PAGE
Lloh67:
	add	x0, x0, l_.str.10@PAGEOFF
	b	LBB0_7
LBB0_38:
Lloh68:
	adrp	x0, l_.str.7@PAGE
Lloh69:
	add	x0, x0, l_.str.7@PAGEOFF
	b	LBB0_7
LBB0_39:
Lloh70:
	adrp	x0, l_.str.8@PAGE
Lloh71:
	add	x0, x0, l_.str.8@PAGEOFF
	b	LBB0_7
LBB0_40:
	ldrb	w8, [sp, #43]
	cmp	w8, #1
	b.ne	LBB0_42
; %bb.41:
	ldr	x8, [x23]
Lloh72:
	adrp	x9, _socksRelayAddr@GOTPAGE
Lloh73:
	ldr	x9, [x9, _socksRelayAddr@GOTPAGEOFF]
	str	x8, [x9, #16]
	ldr	w8, [sp, #44]
	str	w8, [x9, #8]
	ldrh	w8, [sp, #48]
	strh	w8, [x9]
	ldr	w0, [x9, #4]
	mov	w1, #0
	mov	w2, #8
	bl	_memset
	ldr	x8, [x25]
	str	x8, [x22]
	b	LBB0_8
LBB0_42:
	str	x8, [sp]
Lloh74:
	adrp	x0, l_.str.11@PAGE
Lloh75:
	add	x0, x0, l_.str.11@PAGEOFF
	b	LBB0_7
LBB0_43:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGot	Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpAdd	Lloh32, Lloh33
	.loh AdrpAdd	Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.loh AdrpLdrGotLdr	Lloh39, Lloh40, Lloh41
	.loh AdrpAdd	Lloh42, Lloh43
	.loh AdrpLdrGot	Lloh46, Lloh47
	.loh AdrpLdrGot	Lloh44, Lloh45
	.loh AdrpLdrGotLdr	Lloh48, Lloh49, Lloh50
	.loh AdrpAdd	Lloh51, Lloh52
	.loh AdrpAdd	Lloh53, Lloh54
	.loh AdrpLdrGotLdr	Lloh55, Lloh56, Lloh57
	.loh AdrpLdrGotLdr	Lloh58, Lloh59, Lloh60
	.loh AdrpAdd	Lloh61, Lloh62
	.loh AdrpLdrGotLdr	Lloh63, Lloh64, Lloh65
	.loh AdrpAdd	Lloh66, Lloh67
	.loh AdrpAdd	Lloh68, Lloh69
	.loh AdrpAdd	Lloh70, Lloh71
	.loh AdrpLdrGot	Lloh72, Lloh73
	.loh AdrpAdd	Lloh74, Lloh75
	.cfi_endproc
                                        ; -- End function
	.comm	_qfalse,8,3                     ; @qfalse
	.comm	_usingSocks,8,3                 ; @usingSocks
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Opening connection to SOCKS server.\n"

	.comm	_AF_INET,8,3                    ; @AF_INET
	.comm	_SOCK_STREAM,4,2                ; @SOCK_STREAM
	.comm	_IPPROTO_TCP,4,2                ; @IPPROTO_TCP
	.comm	_socks_socket,4,2               ; @socks_socket
	.comm	_INVALID_SOCKET,4,2             ; @INVALID_SOCKET
l_.str.1:                               ; @.str.1
	.asciz	"WARNING: NET_OpenSocks: socket: %s\n"

	.comm	_net_socksServer,8,3            ; @net_socksServer
l_.str.2:                               ; @.str.2
	.asciz	"WARNING: NET_OpenSocks: gethostbyname: %s\n"

l_.str.3:                               ; @.str.3
	.asciz	"WARNING: NET_OpenSocks: gethostbyname: address type was not AF_INET\n"

	.comm	_net_socksPort,8,3              ; @net_socksPort
	.comm	_SOCKET_ERROR,4,2               ; @SOCKET_ERROR
l_.str.4:                               ; @.str.4
	.asciz	"NET_OpenSocks: connect: %s\n"

	.comm	_net_socksUsername,8,3          ; @net_socksUsername
	.comm	_net_socksPassword,8,3          ; @net_socksPassword
	.comm	_qtrue,8,3                      ; @qtrue
l_.str.5:                               ; @.str.5
	.asciz	"NET_OpenSocks: send: %s\n"

l_.str.6:                               ; @.str.6
	.asciz	"NET_OpenSocks: recv: %s\n"

l_.str.7:                               ; @.str.7
	.asciz	"NET_OpenSocks: bad response\n"

l_.str.8:                               ; @.str.8
	.asciz	"NET_OpenSocks: request denied\n"

l_.str.9:                               ; @.str.9
	.asciz	"NET_OpenSocks: authentication failed\n"

	.comm	_INADDR_ANY,4,2                 ; @INADDR_ANY
l_.str.10:                              ; @.str.10
	.asciz	"NET_OpenSocks: request denied: %i\n"

l_.str.11:                              ; @.str.11
	.asciz	"NET_OpenSocks: relay address is not IPV4: %i\n"

	.comm	_socksRelayAddr,4,2             ; @socksRelayAddr
.subsections_via_symbols
