	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_tlsv1_record_set_cipher_suite  ## -- Begin function tlsv1_record_set_cipher_suite
	.p2align	4, 0x90
_tlsv1_record_set_cipher_suite:         ## @tlsv1_record_set_cipher_suite
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %ebx
	movq	%rdi, %r15
	movq	_MSG_DEBUG@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	movl	%ebx, %edx
	callq	_wpa_printf
	movl	%ebx, 20(%r15)
	movl	%ebx, %edi
	callq	_tls_get_cipher_suite
	movl	$-1, %r14d
	testq	%rax, %rax
	je	LBB0_10
## %bb.1:
	movq	(%rax), %rcx
	movq	_TLS_HASH_MD5@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	jne	LBB0_3
## %bb.2:
	movq	_MD5_MAC_LEN@GOTPCREL(%rip), %rcx
	movq	_CRYPTO_HASH_ALG_HMAC_MD5@GOTPCREL(%rip), %rdx
	jmp	LBB0_7
LBB0_3:
	movq	_TLS_HASH_SHA@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	jne	LBB0_5
## %bb.4:
	movq	_SHA1_MAC_LEN@GOTPCREL(%rip), %rcx
	movq	_CRYPTO_HASH_ALG_HMAC_SHA1@GOTPCREL(%rip), %rdx
	jmp	LBB0_7
LBB0_5:
	movq	_TLS_HASH_SHA256@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	jne	LBB0_8
## %bb.6:
	movq	_SHA256_MAC_LEN@GOTPCREL(%rip), %rcx
	movq	_CRYPTO_HASH_ALG_HMAC_SHA256@GOTPCREL(%rip), %rdx
LBB0_7:
	movl	(%rdx), %edx
	movl	%edx, 16(%r15)
	movl	(%rcx), %ecx
	movl	%ecx, 12(%r15)
LBB0_8:
	movl	8(%rax), %edi
	callq	_tls_get_cipher_data
	testq	%rax, %rax
	je	LBB0_10
## %bb.9:
	movl	8(%rax), %ecx
	movl	%ecx, 8(%r15)
	movl	4(%rax), %ecx
	movl	%ecx, 4(%r15)
	movl	(%rax), %eax
	movl	%eax, (%r15)
	xorl	%r14d, %r14d
LBB0_10:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MSG_DEBUG,4,2                  ## @MSG_DEBUG
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"TLSv1: Selected cipher suite: 0x%04x"

	.comm	_TLS_HASH_MD5,8,3               ## @TLS_HASH_MD5
	.comm	_CRYPTO_HASH_ALG_HMAC_MD5,4,2   ## @CRYPTO_HASH_ALG_HMAC_MD5
	.comm	_MD5_MAC_LEN,4,2                ## @MD5_MAC_LEN
	.comm	_TLS_HASH_SHA,8,3               ## @TLS_HASH_SHA
	.comm	_CRYPTO_HASH_ALG_HMAC_SHA1,4,2  ## @CRYPTO_HASH_ALG_HMAC_SHA1
	.comm	_SHA1_MAC_LEN,4,2               ## @SHA1_MAC_LEN
	.comm	_TLS_HASH_SHA256,8,3            ## @TLS_HASH_SHA256
	.comm	_CRYPTO_HASH_ALG_HMAC_SHA256,4,2 ## @CRYPTO_HASH_ALG_HMAC_SHA256
	.comm	_SHA256_MAC_LEN,4,2             ## @SHA256_MAC_LEN
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_tlsv1_record_set_cipher_suite  ; -- Begin function tlsv1_record_set_cipher_suite
	.p2align	2
_tlsv1_record_set_cipher_suite:         ; @tlsv1_record_set_cipher_suite
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x20, x1
	mov	x19, x0
Lloh0:
	adrp	x8, _MSG_DEBUG@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MSG_DEBUG@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x20
	bl	_wpa_printf
	str	w20, [x19, #20]
	mov	x0, x20
	bl	_tls_get_cipher_suite
	cbz	x0, LBB0_10
; %bb.1:
	ldr	x8, [x0]
Lloh5:
	adrp	x9, _TLS_HASH_MD5@GOTPAGE
Lloh6:
	ldr	x9, [x9, _TLS_HASH_MD5@GOTPAGEOFF]
Lloh7:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_3
; %bb.2:
Lloh8:
	adrp	x8, _MD5_MAC_LEN@GOTPAGE
Lloh9:
	ldr	x8, [x8, _MD5_MAC_LEN@GOTPAGEOFF]
Lloh10:
	adrp	x9, _CRYPTO_HASH_ALG_HMAC_MD5@GOTPAGE
Lloh11:
	ldr	x9, [x9, _CRYPTO_HASH_ALG_HMAC_MD5@GOTPAGEOFF]
	b	LBB0_7
LBB0_3:
Lloh12:
	adrp	x9, _TLS_HASH_SHA@GOTPAGE
Lloh13:
	ldr	x9, [x9, _TLS_HASH_SHA@GOTPAGEOFF]
Lloh14:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_5
; %bb.4:
Lloh15:
	adrp	x8, _SHA1_MAC_LEN@GOTPAGE
Lloh16:
	ldr	x8, [x8, _SHA1_MAC_LEN@GOTPAGEOFF]
Lloh17:
	adrp	x9, _CRYPTO_HASH_ALG_HMAC_SHA1@GOTPAGE
Lloh18:
	ldr	x9, [x9, _CRYPTO_HASH_ALG_HMAC_SHA1@GOTPAGEOFF]
	b	LBB0_7
LBB0_5:
Lloh19:
	adrp	x9, _TLS_HASH_SHA256@GOTPAGE
Lloh20:
	ldr	x9, [x9, _TLS_HASH_SHA256@GOTPAGEOFF]
Lloh21:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_8
; %bb.6:
Lloh22:
	adrp	x8, _SHA256_MAC_LEN@GOTPAGE
Lloh23:
	ldr	x8, [x8, _SHA256_MAC_LEN@GOTPAGEOFF]
Lloh24:
	adrp	x9, _CRYPTO_HASH_ALG_HMAC_SHA256@GOTPAGE
Lloh25:
	ldr	x9, [x9, _CRYPTO_HASH_ALG_HMAC_SHA256@GOTPAGEOFF]
LBB0_7:
	ldr	w9, [x9]
	ldr	w8, [x8]
	stp	w8, w9, [x19, #12]
LBB0_8:
	ldr	w0, [x0, #8]
	bl	_tls_get_cipher_data
	cbz	x0, LBB0_10
; %bb.9:
	mov	x8, x0
	mov	w0, #0
	ldr	w9, [x8, #8]
	str	w9, [x19, #8]
	ldr	d0, [x8]
	str	d0, [x19]
	b	LBB0_11
LBB0_10:
	mov	w0, #-1
LBB0_11:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh24, Lloh25
	.loh AdrpLdrGot	Lloh22, Lloh23
	.cfi_endproc
                                        ; -- End function
	.comm	_MSG_DEBUG,4,2                  ; @MSG_DEBUG
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"TLSv1: Selected cipher suite: 0x%04x"

	.comm	_TLS_HASH_MD5,8,3               ; @TLS_HASH_MD5
	.comm	_CRYPTO_HASH_ALG_HMAC_MD5,4,2   ; @CRYPTO_HASH_ALG_HMAC_MD5
	.comm	_MD5_MAC_LEN,4,2                ; @MD5_MAC_LEN
	.comm	_TLS_HASH_SHA,8,3               ; @TLS_HASH_SHA
	.comm	_CRYPTO_HASH_ALG_HMAC_SHA1,4,2  ; @CRYPTO_HASH_ALG_HMAC_SHA1
	.comm	_SHA1_MAC_LEN,4,2               ; @SHA1_MAC_LEN
	.comm	_TLS_HASH_SHA256,8,3            ; @TLS_HASH_SHA256
	.comm	_CRYPTO_HASH_ALG_HMAC_SHA256,4,2 ; @CRYPTO_HASH_ALG_HMAC_SHA256
	.comm	_SHA256_MAC_LEN,4,2             ; @SHA256_MAC_LEN
.subsections_via_symbols
