	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_smb_calcmackey                 ## -- Begin function smb_calcmackey
	.p2align	4, 0x90
_smb_calcmackey:                        ## @smb_calcmackey
	.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	$184, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	_SMB_FLAGS2_SECURITY_SIGNATURE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	andl	(%rbx), %edi
	leaq	L_.str(%rip), %rsi
	callq	_KASSERT
	movq	8(%rbx), %rdi
	testq	%rdi, %rdi
	je	LBB0_2
## %bb.1:
	movq	_M_SMBTEMP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_free
	movq	$0, 8(%rbx)
	movq	$0, 24(%rbx)
LBB0_2:
	movl	$40, 4(%rbx)
	movq	_M_SMBTEMP@GOTPCREL(%rip), %r13
	movl	(%r13), %esi
	movq	_M_WAITOK@GOTPCREL(%rip), %r14
	movl	(%r14), %edx
	movl	$40, %edi
	callq	_malloc
	movq	%rax, 8(%rbx)
	movq	%rbx, %rdi
	callq	_smb_vc_getpass
	movq	%rax, %r15
	movq	%rax, %rdi
	callq	_strlen
                                        ## kill: def $eax killed $eax def $rax
	leal	(,%rax,4), %r12d
	leal	4(,%rax,4), %edi
	movl	(%r13), %esi
	movl	(%r14), %edx
	callq	_malloc
	movq	%rax, %r14
	movq	%rax, %rdi
	movq	%r15, %rsi
	callq	_smb_strtouni
	leaq	-212(%rbp), %r15
	movq	%r15, %rdi
	callq	_MD4Init
	movq	%r15, %rdi
	movq	%r14, %rsi
	movl	%r12d, %edx
	callq	_MD4Update
	leaq	-112(%rbp), %r12
	movq	%r12, %rdi
	movq	%r15, %rsi
	callq	_MD4Final
	movq	%r15, %rdi
	callq	_MD4Init
	movq	%r15, %rdi
	movq	%r12, %rsi
	movl	$16, %edx
	callq	_MD4Update
	movq	8(%rbx), %rdi
	movq	%r15, %rsi
	callq	_MD4Final
	movl	(%r13), %esi
	movq	%r14, %rdi
	callq	_free
	leaq	-208(%rbp), %r14
	movq	%r14, %rdi
	movl	$21, %esi
	callq	_bzero
	movaps	-112(%rbp), %xmm0
	movaps	%xmm0, -208(%rbp)
	movl	16(%rbx), %esi
	movq	8(%rbx), %rdx
	addq	$64, %rdx
	movq	%r14, %rdi
	callq	_smb_E
	leaq	-180(%rbp), %rdi
	movl	16(%rbx), %esi
	movq	8(%rbx), %rdx
	addq	$96, %rdx
	callq	_smb_E
	leaq	-152(%rbp), %rdi
	movl	16(%rbx), %esi
	movq	8(%rbx), %rdx
	subq	$-128, %rdx
	callq	_smb_E
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_4
## %bb.3:
	xorl	%eax, %eax
	addq	$184, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_4:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_SMB_FLAGS2_SECURITY_SIGNATURE,4,2 ## @SMB_FLAGS2_SECURITY_SIGNATURE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"signatures not enabled"

	.comm	_M_SMBTEMP,4,2                  ## @M_SMBTEMP
	.comm	_M_WAITOK,4,2                   ## @M_WAITOK
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_smb_calcmackey                 ; -- Begin function smb_calcmackey
	.p2align	2
_smb_calcmackey:                        ; @smb_calcmackey
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #240
	.cfi_def_cfa_offset 240
	stp	x24, x23, [sp, #176]            ; 16-byte Folded Spill
	stp	x22, x21, [sp, #192]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #208]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #224]            ; 16-byte Folded Spill
	add	x29, sp, #224
	.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	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-56]
	ldr	w8, [x0]
Lloh3:
	adrp	x9, _SMB_FLAGS2_SECURITY_SIGNATURE@GOTPAGE
Lloh4:
	ldr	x9, [x9, _SMB_FLAGS2_SECURITY_SIGNATURE@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	and	w0, w9, w8
Lloh6:
	adrp	x1, l_.str@PAGE
Lloh7:
	add	x1, x1, l_.str@PAGEOFF
	bl	_KASSERT
	ldr	x0, [x19, #8]
Lloh8:
	adrp	x23, _M_SMBTEMP@GOTPAGE
Lloh9:
	ldr	x23, [x23, _M_SMBTEMP@GOTPAGEOFF]
	cbz	x0, LBB0_2
; %bb.1:
	ldr	w1, [x23]
	bl	_free
	str	xzr, [x19, #8]
	str	xzr, [x19, #24]
LBB0_2:
	mov	w8, #40
	str	w8, [x19, #4]
	ldr	w1, [x23]
Lloh10:
	adrp	x22, _M_WAITOK@GOTPAGE
Lloh11:
	ldr	x22, [x22, _M_WAITOK@GOTPAGEOFF]
	ldr	w2, [x22]
	mov	w0, #40
	bl	_malloc
	str	x0, [x19, #8]
	mov	x0, x19
	bl	_smb_vc_getpass
	mov	x20, x0
	bl	_strlen
	lsl	w21, w0, #2
	add	w0, w21, #4
	ldr	w1, [x23]
	ldr	w2, [x22]
	bl	_malloc
	mov	x22, x0
	mov	x1, x20
	bl	_smb_strtouni
	add	x0, sp, #12
	bl	_MD4Init
	add	x0, sp, #12
	mov	x1, x22
	mov	x2, x21
	bl	_MD4Update
	add	x0, sp, #104
	add	x1, sp, #12
	bl	_MD4Final
	add	x0, sp, #12
	bl	_MD4Init
	add	x0, sp, #12
	add	x1, sp, #104
	mov	w2, #16
	bl	_MD4Update
	ldr	x0, [x19, #8]
	add	x1, sp, #12
	bl	_MD4Final
	ldr	w1, [x23]
	mov	x0, x22
	bl	_free
	add	x20, sp, #16
	add	x0, sp, #16
	mov	w1, #21
	bl	_bzero
	ldur	q0, [sp, #104]
	str	q0, [sp, #16]
	ldr	w1, [x19, #16]
	ldr	x8, [x19, #8]
	add	x2, x8, #64
	add	x0, sp, #16
	bl	_smb_E
	add	x0, x20, #28
	ldr	w1, [x19, #16]
	ldr	x8, [x19, #8]
	add	x2, x8, #96
	bl	_smb_E
	add	x0, x20, #56
	ldr	w1, [x19, #16]
	ldr	x8, [x19, #8]
	add	x2, x8, #128
	bl	_smb_E
	ldur	x8, [x29, #-56]
Lloh12:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh13:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh14:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_4
; %bb.3:
	mov	w0, #0
	ldp	x29, x30, [sp, #224]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #208]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #192]            ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #176]            ; 16-byte Folded Reload
	add	sp, sp, #240
	ret
LBB0_4:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_SMB_FLAGS2_SECURITY_SIGNATURE,4,2 ; @SMB_FLAGS2_SECURITY_SIGNATURE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"signatures not enabled"

	.comm	_M_SMBTEMP,4,2                  ; @M_SMBTEMP
	.comm	_M_WAITOK,4,2                   ; @M_WAITOK
.subsections_via_symbols
