	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ntlm_server_init               ## -- Begin function ntlm_server_init
	.p2align	4, 0x90
_ntlm_server_init:                      ## @ntlm_server_init
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	subq	$112, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %rbx
	leaq	-112(%rbp), %rdi
	xorl	%esi, %esi
	movl	$32, %edx
	callq	_memset
	movq	_context@GOTPCREL(%rip), %r14
	movl	(%r14), %edi
	leaq	-20(%rbp), %rsi
	callq	_krb5_ntlm_alloc
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	movl	(%r14), %edi
	leaq	L_.str(%rip), %rcx
	movl	$1, %esi
	movq	%rax, %rdx
	callq	_krb5_err
LBB0_2:
	movl	(%r14), %edi
	movl	-20(%rbp), %esi
	movl	(%rbx), %edx
	movq	_id@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	_NTLM_NEG_UNICODE@GOTPCREL(%rip), %rax
	movq	_NTLM_NEG_NTLM@GOTPCREL(%rip), %rbx
	movl	(%rbx), %r8d
	orl	(%rax), %r8d
	leaq	L_.str.2(%rip), %rax
	movq	%rax, (%rsp)
	leaq	L_.str.1(%rip), %r9
	callq	_krb5_ntlm_init_request
	testq	%rax, %rax
	je	LBB0_4
## %bb.3:
	movl	(%r14), %edi
	leaq	L_.str.3(%rip), %rcx
	movl	$1, %esi
	movq	%rax, %rdx
	callq	_krb5_err
LBB0_4:
	movl	(%r14), %edi
	movl	-20(%rbp), %esi
	leaq	-80(%rbp), %rdx
	callq	_krb5_ntlm_init_get_challange
	testq	%rax, %rax
	je	LBB0_6
## %bb.5:
	movl	(%r14), %edi
	leaq	L_.str.4(%rip), %rcx
	movl	$1, %esi
	movq	%rax, %rdx
	callq	_krb5_err
LBB0_6:
	cmpl	$4, -80(%rbp)
	je	LBB0_8
## %bb.7:
	movl	(%r14), %edi
	leaq	L_.str.5(%rip), %rdx
	movl	$1, %esi
	callq	_krb5_errx
LBB0_8:
	movl	-84(%rbp), %edi
	movq	-72(%rbp), %rsi
	movl	$4, %edx
	callq	_memcpy
	leaq	-80(%rbp), %rdi
	callq	_krb5_data_free
	movl	(%r14), %edi
	movl	-20(%rbp), %esi
	leaq	-88(%rbp), %rdx
	callq	_krb5_ntlm_init_get_flags
	testq	%rax, %rax
	je	LBB0_10
## %bb.9:
	movl	(%r14), %edi
	leaq	L_.str.6(%rip), %rcx
	movl	$1, %esi
	movq	%rax, %rdx
	callq	_krb5_err
LBB0_10:
	movl	(%r14), %edi
	movl	-20(%rbp), %esi
	leaq	-112(%rbp), %rbx
	movq	%rbx, %rdx
	callq	_krb5_ntlm_init_get_targetname
	leaq	_ntlm_server_init.zero2(%rip), %rax
	movq	%rax, -104(%rbp)
	movl	$2, -96(%rbp)
	leaq	-48(%rbp), %rsi
	movq	%rbx, %rdi
	callq	_heim_ntlm_encode_type2
	testq	%rax, %rax
	je	LBB0_12
## %bb.11:
	movl	(%r14), %edi
	leaq	L_.str.7(%rip), %rdx
	movl	$1, %esi
	callq	_krb5_errx
LBB0_12:
	movq	-112(%rbp), %rdi
	callq	_free
	movq	-48(%rbp), %rdi
	movl	-40(%rbp), %esi
	leaq	-32(%rbp), %rdx
	callq	_base64_encode
	movq	-48(%rbp), %rdi
	callq	_free
	movq	-32(%rbp), %rsi
	leaq	L_.str.8(%rip), %rdi
	callq	_printf
	movq	-32(%rbp), %rdi
	callq	_free
	movl	(%r14), %edi
	movl	-20(%rbp), %esi
	leaq	-64(%rbp), %rdx
	callq	_krb5_ntlm_init_get_opaque
	testq	%rax, %rax
	je	LBB0_14
## %bb.13:
	movl	(%r14), %edi
	leaq	L_.str.9(%rip), %rcx
	movl	$1, %esi
	movq	%rax, %rdx
	callq	_krb5_err
LBB0_14:
	movq	-56(%rbp), %rdi
	movl	-64(%rbp), %esi
	leaq	-32(%rbp), %rdx
	callq	_base64_encode
	leaq	-64(%rbp), %rdi
	callq	_krb5_data_free
	movq	-32(%rbp), %rsi
	leaq	L_.str.10(%rip), %rdi
	callq	_printf
	movq	-32(%rbp), %rdi
	callq	_free
	movl	(%r14), %edi
	movl	-20(%rbp), %esi
	callq	_krb5_ntlm_free
	xorl	%eax, %eax
	addq	$112, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
.zerofill __DATA,__bss,_ntlm_server_init.zero2,3,0 ## @ntlm_server_init.zero2
	.comm	_context,4,2                    ## @context
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"krb5_ntlm_alloc"

	.comm	_id,4,2                         ## @id
	.comm	_NTLM_NEG_UNICODE,4,2           ## @NTLM_NEG_UNICODE
	.comm	_NTLM_NEG_NTLM,4,2              ## @NTLM_NEG_NTLM
L_.str.1:                               ## @.str.1
	.asciz	"NUTCRACKER"

L_.str.2:                               ## @.str.2
	.asciz	"L"

L_.str.3:                               ## @.str.3
	.asciz	"krb5_ntlm_init_request"

L_.str.4:                               ## @.str.4
	.asciz	"krb5_ntlm_init_get_challange"

L_.str.5:                               ## @.str.5
	.asciz	"ntlm challenge have wrong length"

L_.str.6:                               ## @.str.6
	.asciz	"krb5_ntlm_init_get_flags"

L_.str.7:                               ## @.str.7
	.asciz	"heim_ntlm_encode_type2"

L_.str.8:                               ## @.str.8
	.asciz	"type2=%s\n"

L_.str.9:                               ## @.str.9
	.asciz	"krb5_ntlm_init_get_opaque"

L_.str.10:                              ## @.str.10
	.asciz	"opaque=%s\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ntlm_server_init               ; -- Begin function ntlm_server_init
	.p2align	2
_ntlm_server_init:                      ; @ntlm_server_init
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	add	x0, sp, #56
	mov	w1, #0
	mov	w2, #32
	bl	_memset
Lloh0:
	adrp	x20, _context@GOTPAGE
Lloh1:
	ldr	x20, [x20, _context@GOTPAGEOFF]
	ldr	w0, [x20]
	sub	x1, x29, #20
	bl	_krb5_ntlm_alloc
	cbz	x0, LBB0_2
; %bb.1:
	mov	x2, x0
	ldr	w0, [x20]
Lloh2:
	adrp	x3, l_.str@PAGE
Lloh3:
	add	x3, x3, l_.str@PAGEOFF
	mov	w1, #1
	bl	_krb5_err
LBB0_2:
	ldr	w0, [x20]
	ldur	w1, [x29, #-20]
	ldr	w2, [x19]
Lloh4:
	adrp	x8, _id@GOTPAGE
Lloh5:
	ldr	x8, [x8, _id@GOTPAGEOFF]
Lloh6:
	adrp	x9, _NTLM_NEG_UNICODE@GOTPAGE
Lloh7:
	ldr	x9, [x9, _NTLM_NEG_UNICODE@GOTPAGEOFF]
Lloh8:
	ldr	w3, [x8]
Lloh9:
	ldr	w8, [x9]
Lloh10:
	adrp	x9, _NTLM_NEG_NTLM@GOTPAGE
Lloh11:
	ldr	x9, [x9, _NTLM_NEG_NTLM@GOTPAGEOFF]
Lloh12:
	ldr	w9, [x9]
	orr	w4, w9, w8
Lloh13:
	adrp	x5, l_.str.1@PAGE
Lloh14:
	add	x5, x5, l_.str.1@PAGEOFF
Lloh15:
	adrp	x6, l_.str.2@PAGE
Lloh16:
	add	x6, x6, l_.str.2@PAGEOFF
	bl	_krb5_ntlm_init_request
	cbz	x0, LBB0_4
; %bb.3:
	mov	x2, x0
	ldr	w0, [x20]
Lloh17:
	adrp	x3, l_.str.3@PAGE
Lloh18:
	add	x3, x3, l_.str.3@PAGEOFF
	mov	w1, #1
	bl	_krb5_err
LBB0_4:
	ldr	w0, [x20]
	ldur	w1, [x29, #-20]
	add	x2, sp, #40
	bl	_krb5_ntlm_init_get_challange
	cbz	x0, LBB0_6
; %bb.5:
	mov	x2, x0
	ldr	w0, [x20]
Lloh19:
	adrp	x3, l_.str.4@PAGE
Lloh20:
	add	x3, x3, l_.str.4@PAGEOFF
	mov	w1, #1
	bl	_krb5_err
LBB0_6:
	ldr	w8, [sp, #40]
	cmp	w8, #4
	b.eq	LBB0_8
; %bb.7:
	ldr	w0, [x20]
Lloh21:
	adrp	x2, l_.str.5@PAGE
Lloh22:
	add	x2, x2, l_.str.5@PAGEOFF
	mov	w1, #1
	bl	_krb5_errx
LBB0_8:
	ldr	w0, [sp, #84]
	ldr	x1, [sp, #48]
	mov	w2, #4
	bl	_memcpy
	add	x0, sp, #40
	bl	_krb5_data_free
	ldr	w0, [x20]
	ldur	w1, [x29, #-20]
	add	x8, sp, #56
	add	x2, x8, #24
	bl	_krb5_ntlm_init_get_flags
	cbz	x0, LBB0_10
; %bb.9:
	mov	x2, x0
	ldr	w0, [x20]
Lloh23:
	adrp	x3, l_.str.6@PAGE
Lloh24:
	add	x3, x3, l_.str.6@PAGEOFF
	mov	w1, #1
	bl	_krb5_err
LBB0_10:
	ldr	w0, [x20]
	ldur	w1, [x29, #-20]
	add	x2, sp, #56
	bl	_krb5_ntlm_init_get_targetname
Lloh25:
	adrp	x8, _ntlm_server_init.zero2@PAGE
Lloh26:
	add	x8, x8, _ntlm_server_init.zero2@PAGEOFF
	str	x8, [sp, #64]
	mov	w8, #2
	str	w8, [sp, #72]
	add	x0, sp, #56
	add	x1, sp, #8
	bl	_heim_ntlm_encode_type2
	cbz	x0, LBB0_12
; %bb.11:
	ldr	w0, [x20]
Lloh27:
	adrp	x2, l_.str.7@PAGE
Lloh28:
	add	x2, x2, l_.str.7@PAGEOFF
	mov	w1, #1
	bl	_krb5_errx
LBB0_12:
	ldr	x0, [sp, #56]
	bl	_free
	ldr	x0, [sp, #8]
	ldr	w1, [sp, #16]
	mov	x2, sp
	bl	_base64_encode
	ldr	x0, [sp, #8]
	bl	_free
	ldr	x1, [sp]
Lloh29:
	adrp	x0, l_.str.8@PAGE
Lloh30:
	add	x0, x0, l_.str.8@PAGEOFF
	bl	_printf
	ldr	x0, [sp]
	bl	_free
	ldr	w0, [x20]
	ldur	w1, [x29, #-20]
	add	x2, sp, #24
	bl	_krb5_ntlm_init_get_opaque
	cbz	x0, LBB0_14
; %bb.13:
	mov	x2, x0
	ldr	w0, [x20]
Lloh31:
	adrp	x3, l_.str.9@PAGE
Lloh32:
	add	x3, x3, l_.str.9@PAGEOFF
	mov	w1, #1
	bl	_krb5_err
LBB0_14:
	ldr	x0, [sp, #32]
	ldr	w1, [sp, #24]
	mov	x2, sp
	bl	_base64_encode
	add	x0, sp, #24
	bl	_krb5_data_free
	ldr	x1, [sp]
Lloh33:
	adrp	x0, l_.str.10@PAGE
Lloh34:
	add	x0, x0, l_.str.10@PAGEOFF
	bl	_printf
	ldr	x0, [sp]
	bl	_free
	ldr	w0, [x20]
	ldur	w1, [x29, #-20]
	bl	_krb5_ntlm_free
	mov	w0, #0
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh9
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh8
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpAdd	Lloh29, Lloh30
	.loh AdrpAdd	Lloh31, Lloh32
	.loh AdrpAdd	Lloh33, Lloh34
	.cfi_endproc
                                        ; -- End function
.zerofill __DATA,__bss,_ntlm_server_init.zero2,3,0 ; @ntlm_server_init.zero2
	.comm	_context,4,2                    ; @context
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"krb5_ntlm_alloc"

	.comm	_id,4,2                         ; @id
	.comm	_NTLM_NEG_UNICODE,4,2           ; @NTLM_NEG_UNICODE
	.comm	_NTLM_NEG_NTLM,4,2              ; @NTLM_NEG_NTLM
l_.str.1:                               ; @.str.1
	.asciz	"NUTCRACKER"

l_.str.2:                               ; @.str.2
	.asciz	"L"

l_.str.3:                               ; @.str.3
	.asciz	"krb5_ntlm_init_request"

l_.str.4:                               ; @.str.4
	.asciz	"krb5_ntlm_init_get_challange"

l_.str.5:                               ; @.str.5
	.asciz	"ntlm challenge have wrong length"

l_.str.6:                               ; @.str.6
	.asciz	"krb5_ntlm_init_get_flags"

l_.str.7:                               ; @.str.7
	.asciz	"heim_ntlm_encode_type2"

l_.str.8:                               ; @.str.8
	.asciz	"type2=%s\n"

l_.str.9:                               ; @.str.9
	.asciz	"krb5_ntlm_init_get_opaque"

l_.str.10:                              ; @.str.10
	.asciz	"opaque=%s\n"

.subsections_via_symbols
