	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function eap_aka_ext_sim_result
_eap_aka_ext_sim_result:                ## @eap_aka_ext_sim_result
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %rbx
	movq	%rsi, %r14
	movq	_MSG_DEBUG@GOTPCREL(%rip), %r13
	movl	(%r13), %edi
	leaq	L_.str(%rip), %rsi
	callq	_wpa_printf
	movq	(%rbx), %r12
	movq	$0, (%rbx)
	leaq	L_.str.1(%rip), %rsi
	movq	%r12, %rdi
	movl	$10, %edx
	callq	_os_strncmp
	testq	%rax, %rax
	je	LBB0_1
## %bb.3:
	leaq	L_.str.3(%rip), %rsi
	movq	%r12, %rdi
	movl	$10, %edx
	callq	_os_strncmp
	testq	%rax, %rax
	je	LBB0_5
## %bb.4:
	movl	(%r13), %edi
	leaq	L_.str.4(%rip), %rsi
	jmp	LBB0_12
LBB0_1:
	leaq	10(%r12), %rdi
	movl	20(%r14), %esi
	movq	_EAP_AKA_AUTS_LEN@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edx
	callq	_hexstr2bin
	testq	%rax, %rax
	js	LBB0_11
## %bb.2:
	movl	(%r13), %edi
	movl	20(%r14), %edx
	movl	(%rbx), %ecx
	leaq	L_.str.2(%rip), %rsi
	callq	_wpa_hexdump_key
	movq	%r12, %rdi
	callq	_os_free
	movl	$-2, %eax
	jmp	LBB0_15
LBB0_5:
	leaq	10(%r12), %r15
	movl	(%r13), %edi
	movl	16(%r14), %edx
	movq	_EAP_AKA_RAND_LEN@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	leaq	L_.str.5(%rip), %rsi
	callq	_wpa_hexdump
	movl	12(%r14), %esi
	movq	_EAP_AKA_IK_LEN@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edx
	movq	%r15, %rdi
	callq	_hexstr2bin
	testq	%rax, %rax
	js	LBB0_11
## %bb.6:
	movl	(%r13), %edi
	movl	12(%r14), %edx
	movl	(%rbx), %ecx
	leaq	L_.str.6(%rip), %rsi
	callq	_wpa_hexdump_key
	movslq	(%rbx), %rax
	cmpb	$58, (%r15,%rax,2)
	jne	LBB0_11
## %bb.7:
	leaq	(%r15,%rax,2), %r15
	incq	%r15
	movl	8(%r14), %esi
	movq	_EAP_AKA_CK_LEN@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edx
	movq	%r15, %rdi
	callq	_hexstr2bin
	testq	%rax, %rax
	js	LBB0_11
## %bb.8:
	movl	(%r13), %edi
	movl	8(%r14), %edx
	movl	(%rbx), %ecx
	leaq	L_.str.7(%rip), %rsi
	callq	_wpa_hexdump_key
	movslq	(%rbx), %rax
	cmpb	$58, (%r15,%rax,2)
	jne	LBB0_11
## %bb.9:
	leaq	(%r15,%rax,2), %r15
	incq	%r15
	movq	%r15, %rdi
	callq	_os_strlen
	movl	%eax, %edx
	shrl	$31, %edx
	addl	%eax, %edx
	sarl	%edx
	movl	%edx, (%r14)
	movq	_EAP_AKA_RES_MAX_LEN@GOTPCREL(%rip), %rax
	cmpl	(%rax), %edx
	jle	LBB0_13
## %bb.10:
	movl	$0, (%r14)
	jmp	LBB0_11
LBB0_13:
	movl	4(%r14), %esi
	movq	%r15, %rdi
	callq	_hexstr2bin
	testq	%rax, %rax
	js	LBB0_11
## %bb.14:
	movl	(%r13), %edi
	movl	(%r14), %ecx
	movl	4(%r14), %edx
	leaq	L_.str.8(%rip), %rsi
	callq	_wpa_hexdump_key
	movq	%r12, %rdi
	callq	_os_free
	xorl	%eax, %eax
	jmp	LBB0_15
LBB0_11:
	movl	(%r13), %edi
	leaq	L_.str.9(%rip), %rsi
LBB0_12:
	callq	_wpa_printf
	movq	%r12, %rdi
	callq	_os_free
	movl	$-1, %eax
LBB0_15:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	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	"EAP-AKA: Use result from external USIM processing"

L_.str.1:                               ## @.str.1
	.asciz	"UMTS-AUTS:"

	.comm	_EAP_AKA_AUTS_LEN,4,2           ## @EAP_AKA_AUTS_LEN
L_.str.2:                               ## @.str.2
	.asciz	"EAP-AKA: AUTS"

L_.str.3:                               ## @.str.3
	.asciz	"UMTS-AUTH:"

L_.str.4:                               ## @.str.4
	.asciz	"EAP-AKA: Unrecognized external USIM processing response"

L_.str.5:                               ## @.str.5
	.asciz	"EAP-AKA: RAND"

	.comm	_EAP_AKA_RAND_LEN,4,2           ## @EAP_AKA_RAND_LEN
	.comm	_EAP_AKA_IK_LEN,4,2             ## @EAP_AKA_IK_LEN
L_.str.6:                               ## @.str.6
	.asciz	"EAP-AKA: IK"

	.comm	_EAP_AKA_CK_LEN,4,2             ## @EAP_AKA_CK_LEN
L_.str.7:                               ## @.str.7
	.asciz	"EAP-AKA: CK"

	.comm	_EAP_AKA_RES_MAX_LEN,4,2        ## @EAP_AKA_RES_MAX_LEN
L_.str.8:                               ## @.str.8
	.asciz	"EAP-AKA: RES"

L_.str.9:                               ## @.str.9
	.asciz	"EAP-AKA: Invalid external USIM processing UMTS-AUTH response"

	.no_dead_strip	_eap_aka_ext_sim_result
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function eap_aka_ext_sim_result
_eap_aka_ext_sim_result:                ; @eap_aka_ext_sim_result
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x21, x2
	mov	x20, x1
Lloh0:
	adrp	x22, _MSG_DEBUG@GOTPAGE
Lloh1:
	ldr	x22, [x22, _MSG_DEBUG@GOTPAGEOFF]
	ldr	w0, [x22]
Lloh2:
	adrp	x1, l_.str@PAGE
Lloh3:
	add	x1, x1, l_.str@PAGEOFF
	bl	_wpa_printf
	ldr	x19, [x21]
	str	xzr, [x21]
Lloh4:
	adrp	x1, l_.str.1@PAGE
Lloh5:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	mov	w2, #10
	bl	_os_strncmp
	cbz	x0, LBB0_3
; %bb.1:
Lloh6:
	adrp	x1, l_.str.3@PAGE
Lloh7:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x0, x19
	mov	w2, #10
	bl	_os_strncmp
	cbz	x0, LBB0_5
; %bb.2:
	ldr	w0, [x22]
Lloh8:
	adrp	x1, l_.str.4@PAGE
Lloh9:
	add	x1, x1, l_.str.4@PAGEOFF
	b	LBB0_14
LBB0_3:
	add	x0, x19, #10
	ldr	w1, [x20, #20]
Lloh10:
	adrp	x21, _EAP_AKA_AUTS_LEN@GOTPAGE
Lloh11:
	ldr	x21, [x21, _EAP_AKA_AUTS_LEN@GOTPAGEOFF]
	ldr	w2, [x21]
	bl	_hexstr2bin
	tbnz	x0, #63, LBB0_13
; %bb.4:
	ldr	w0, [x22]
	ldr	w2, [x20, #20]
	ldr	w3, [x21]
Lloh12:
	adrp	x1, l_.str.2@PAGE
Lloh13:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_wpa_hexdump_key
	mov	x0, x19
	bl	_os_free
	mov	w0, #-2
	b	LBB0_15
LBB0_5:
	add	x21, x19, #10
	ldr	w0, [x22]
	ldr	w2, [x20, #16]
Lloh14:
	adrp	x8, _EAP_AKA_RAND_LEN@GOTPAGE
Lloh15:
	ldr	x8, [x8, _EAP_AKA_RAND_LEN@GOTPAGEOFF]
Lloh16:
	ldr	w3, [x8]
Lloh17:
	adrp	x1, l_.str.5@PAGE
Lloh18:
	add	x1, x1, l_.str.5@PAGEOFF
	bl	_wpa_hexdump
	ldr	w1, [x20, #12]
Lloh19:
	adrp	x23, _EAP_AKA_IK_LEN@GOTPAGE
Lloh20:
	ldr	x23, [x23, _EAP_AKA_IK_LEN@GOTPAGEOFF]
	ldr	w2, [x23]
	mov	x0, x21
	bl	_hexstr2bin
	tbnz	x0, #63, LBB0_13
; %bb.6:
	ldr	w0, [x22]
	ldr	w2, [x20, #12]
	ldr	w3, [x23]
Lloh21:
	adrp	x1, l_.str.6@PAGE
Lloh22:
	add	x1, x1, l_.str.6@PAGEOFF
	bl	_wpa_hexdump_key
	ldrsw	x8, [x23]
	add	x8, x21, x8, lsl #1
	ldrb	w9, [x8]
	cmp	w9, #58
	b.ne	LBB0_13
; %bb.7:
	add	x21, x8, #1
	ldr	w1, [x20, #8]
Lloh23:
	adrp	x23, _EAP_AKA_CK_LEN@GOTPAGE
Lloh24:
	ldr	x23, [x23, _EAP_AKA_CK_LEN@GOTPAGEOFF]
	ldr	w2, [x23]
	mov	x0, x21
	bl	_hexstr2bin
	tbnz	x0, #63, LBB0_13
; %bb.8:
	ldr	w0, [x22]
	ldr	w2, [x20, #8]
	ldr	w3, [x23]
Lloh25:
	adrp	x1, l_.str.7@PAGE
Lloh26:
	add	x1, x1, l_.str.7@PAGEOFF
	bl	_wpa_hexdump_key
	ldrsw	x8, [x23]
	add	x8, x21, x8, lsl #1
	ldrb	w9, [x8]
	cmp	w9, #58
	b.ne	LBB0_13
; %bb.9:
	add	x21, x8, #1
	mov	x0, x21
	bl	_os_strlen
	cmp	w0, #0
	cinc	w8, w0, lt
	asr	w2, w8, #1
	str	w2, [x20]
Lloh27:
	adrp	x8, _EAP_AKA_RES_MAX_LEN@GOTPAGE
Lloh28:
	ldr	x8, [x8, _EAP_AKA_RES_MAX_LEN@GOTPAGEOFF]
Lloh29:
	ldr	w8, [x8]
	cmp	w2, w8
	b.le	LBB0_11
; %bb.10:
	str	wzr, [x20]
	b	LBB0_13
LBB0_11:
	ldr	w1, [x20, #4]
	mov	x0, x21
	bl	_hexstr2bin
	tbnz	x0, #63, LBB0_13
; %bb.12:
	ldr	w0, [x22]
	ldp	w3, w2, [x20]
Lloh30:
	adrp	x1, l_.str.8@PAGE
Lloh31:
	add	x1, x1, l_.str.8@PAGEOFF
	bl	_wpa_hexdump_key
	mov	x0, x19
	bl	_os_free
	mov	w0, #0
	b	LBB0_15
LBB0_13:
	ldr	w0, [x22]
Lloh32:
	adrp	x1, l_.str.9@PAGE
Lloh33:
	add	x1, x1, l_.str.9@PAGEOFF
LBB0_14:
	bl	_wpa_printf
	mov	x0, x19
	bl	_os_free
	mov	w0, #-1
LBB0_15:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpLdrGot	Lloh23, Lloh24
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpAdd	Lloh30, Lloh31
	.loh AdrpAdd	Lloh32, Lloh33
	.cfi_endproc
                                        ; -- End function
	.comm	_MSG_DEBUG,4,2                  ; @MSG_DEBUG
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"EAP-AKA: Use result from external USIM processing"

l_.str.1:                               ; @.str.1
	.asciz	"UMTS-AUTS:"

	.comm	_EAP_AKA_AUTS_LEN,4,2           ; @EAP_AKA_AUTS_LEN
l_.str.2:                               ; @.str.2
	.asciz	"EAP-AKA: AUTS"

l_.str.3:                               ; @.str.3
	.asciz	"UMTS-AUTH:"

l_.str.4:                               ; @.str.4
	.asciz	"EAP-AKA: Unrecognized external USIM processing response"

l_.str.5:                               ; @.str.5
	.asciz	"EAP-AKA: RAND"

	.comm	_EAP_AKA_RAND_LEN,4,2           ; @EAP_AKA_RAND_LEN
	.comm	_EAP_AKA_IK_LEN,4,2             ; @EAP_AKA_IK_LEN
l_.str.6:                               ; @.str.6
	.asciz	"EAP-AKA: IK"

	.comm	_EAP_AKA_CK_LEN,4,2             ; @EAP_AKA_CK_LEN
l_.str.7:                               ; @.str.7
	.asciz	"EAP-AKA: CK"

	.comm	_EAP_AKA_RES_MAX_LEN,4,2        ; @EAP_AKA_RES_MAX_LEN
l_.str.8:                               ; @.str.8
	.asciz	"EAP-AKA: RES"

l_.str.9:                               ; @.str.9
	.asciz	"EAP-AKA: Invalid external USIM processing UMTS-AUTH response"

	.no_dead_strip	_eap_aka_ext_sim_result
.subsections_via_symbols
