	.file	"927397.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	"$6$"
	.text
	.type	pwhash, @function
pwhash:
.LFB6:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 16
	mov	QWORD PTR -8[rbp], rdi
	mov	rax, QWORD PTR -8[rbp]
	lea	rsi, .LC0[rip]
	mov	rdi, rax
	call	crypt@PLT
	mov	rdi, rax
	call	strdup@PLT
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	pwhash, .-pwhash
	.local	real_getpwnam
	.comm	real_getpwnam,8,8
	.local	real_getpwnam_r
	.comm	real_getpwnam_r,8,8
	.local	real_getspnam
	.comm	real_getspnam,8,8
	.local	real_getspnam_r
	.comm	real_getspnam_r,8,8
	.local	test_user
	.comm	test_user,8,8
	.local	test_passwd_hash
	.comm	test_passwd_hash,8,8
	.section	.rodata
.LC1:
	.string	"getpwnam"
.LC2:
	.string	"getpwnam_r"
.LC3:
	.string	"getspnam"
.LC4:
	.string	"getspnam_r"
.LC5:
	.string	"TEST_USER"
.LC6:
	.string	"TEST_PASSWD"
	.align 8
.LC7:
	.string	"env variables TEST_USER and TEST_PASSWD are missing\n"
	.text
	.type	init, @function
init:
.LFB7:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	lea	rsi, .LC1[rip]
	mov	rdi, -1
	call	dlsym@PLT
	mov	QWORD PTR real_getpwnam[rip], rax
	lea	rsi, .LC2[rip]
	mov	rdi, -1
	call	dlsym@PLT
	mov	QWORD PTR real_getpwnam_r[rip], rax
	lea	rsi, .LC3[rip]
	mov	rdi, -1
	call	dlsym@PLT
	mov	QWORD PTR real_getspnam[rip], rax
	lea	rsi, .LC4[rip]
	mov	rdi, -1
	call	dlsym@PLT
	mov	QWORD PTR real_getspnam_r[rip], rax
	lea	rdi, .LC5[rip]
	call	getenv@PLT
	test	rax, rax
	je	.L4
	lea	rdi, .LC6[rip]
	call	getenv@PLT
	test	rax, rax
	jne	.L5
.L4:
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 52
	mov	esi, 1
	lea	rdi, .LC7[rip]
	call	fwrite@PLT
	call	abort@PLT
.L5:
	lea	rdi, .LC5[rip]
	call	getenv@PLT
	mov	rdi, rax
	call	strdup@PLT
	mov	QWORD PTR test_user[rip], rax
	lea	rdi, .LC6[rip]
	call	getenv@PLT
	mov	rdi, rax
	call	pwhash
	mov	QWORD PTR test_passwd_hash[rip], rax
	nop
	nop
	nop
	nop
	nop
	nop
	nop
	nop
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	init, .-init
	.type	is_test_user, @function
is_test_user:
.LFB8:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 16
	mov	QWORD PTR -8[rbp], rdi
	mov	rax, QWORD PTR test_user[rip]
	test	rax, rax
	je	.L7
	mov	rax, QWORD PTR test_user[rip]
	mov	rdx, QWORD PTR -8[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L7
	mov	eax, 1
	jmp	.L8
.L7:
	mov	eax, 0
.L8:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	is_test_user, .-is_test_user
	.globl	getpwnam
	.type	getpwnam, @function
getpwnam:
.LFB9:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 32
	mov	QWORD PTR -24[rbp], rdi
	nop
	mov	rax, QWORD PTR real_getpwnam[rip]
	test	rax, rax
	jne	.L10
	call	init
.L10:
	mov	rdx, QWORD PTR real_getpwnam[rip]
	mov	rax, QWORD PTR -24[rbp]
	mov	rdi, rax
	call	rdx
	mov	QWORD PTR -8[rbp], rax
	cmp	QWORD PTR -8[rbp], 0
	jne	.L11
	mov	eax, 0
	jmp	.L12
.L11:
	mov	rax, QWORD PTR -24[rbp]
	mov	rdi, rax
	call	is_test_user
	test	eax, eax
	je	.L13
	mov	rax, QWORD PTR test_passwd_hash[rip]
	mov	rdi, rax
	call	strdup@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR -8[rbp]
	mov	QWORD PTR 8[rax], rdx
.L13:
	mov	rax, QWORD PTR -8[rbp]
.L12:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.size	getpwnam, .-getpwnam
	.globl	getpwnam_r
	.type	getpwnam_r, @function
getpwnam_r:
.LFB10:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 64
	mov	QWORD PTR -24[rbp], rdi
	mov	QWORD PTR -32[rbp], rsi
	mov	QWORD PTR -40[rbp], rdx
	mov	QWORD PTR -48[rbp], rcx
	mov	QWORD PTR -56[rbp], r8
	nop
	mov	rax, QWORD PTR real_getpwnam_r[rip]
	test	rax, rax
	jne	.L15
	call	init
.L15:
	mov	r9, QWORD PTR real_getpwnam_r[rip]
	mov	rdi, QWORD PTR -56[rbp]
	mov	rcx, QWORD PTR -48[rbp]
	mov	rdx, QWORD PTR -40[rbp]
	mov	rsi, QWORD PTR -32[rbp]
	mov	rax, QWORD PTR -24[rbp]
	mov	r8, rdi
	mov	rdi, rax
	call	r9
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], 0
	jne	.L16
	mov	rax, QWORD PTR -56[rbp]
	mov	rax, QWORD PTR [rax]
	test	rax, rax
	jne	.L17
.L16:
	mov	eax, DWORD PTR -4[rbp]
	jmp	.L18
.L17:
	mov	rax, QWORD PTR -24[rbp]
	mov	rdi, rax
	call	is_test_user
	test	eax, eax
	je	.L19
	mov	rax, QWORD PTR test_passwd_hash[rip]
	mov	rdi, rax
	call	strdup@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR -32[rbp]
	mov	QWORD PTR 8[rax], rdx
.L19:
	mov	eax, 0
.L18:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE10:
	.size	getpwnam_r, .-getpwnam_r
	.globl	getspnam
	.type	getspnam, @function
getspnam:
.LFB11:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 32
	mov	QWORD PTR -24[rbp], rdi
	nop
	mov	rax, QWORD PTR real_getspnam[rip]
	test	rax, rax
	jne	.L21
	call	init
.L21:
	mov	rdx, QWORD PTR real_getspnam[rip]
	mov	rax, QWORD PTR -24[rbp]
	mov	rdi, rax
	call	rdx
	mov	QWORD PTR -8[rbp], rax
	cmp	QWORD PTR -8[rbp], 0
	jne	.L22
	mov	eax, 0
	jmp	.L23
.L22:
	mov	rax, QWORD PTR -24[rbp]
	mov	rdi, rax
	call	is_test_user
	test	eax, eax
	je	.L24
	mov	rax, QWORD PTR test_passwd_hash[rip]
	mov	rdi, rax
	call	strdup@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR -8[rbp]
	mov	QWORD PTR 8[rax], rdx
.L24:
	mov	rax, QWORD PTR -8[rbp]
.L23:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE11:
	.size	getspnam, .-getspnam
	.globl	getspnam_r
	.type	getspnam_r, @function
getspnam_r:
.LFB12:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 64
	mov	QWORD PTR -24[rbp], rdi
	mov	QWORD PTR -32[rbp], rsi
	mov	QWORD PTR -40[rbp], rdx
	mov	QWORD PTR -48[rbp], rcx
	mov	QWORD PTR -56[rbp], r8
	nop
	mov	rax, QWORD PTR real_getspnam_r[rip]
	test	rax, rax
	jne	.L26
	call	init
.L26:
	mov	r9, QWORD PTR real_getspnam_r[rip]
	mov	rdi, QWORD PTR -56[rbp]
	mov	rcx, QWORD PTR -48[rbp]
	mov	rdx, QWORD PTR -40[rbp]
	mov	rsi, QWORD PTR -32[rbp]
	mov	rax, QWORD PTR -24[rbp]
	mov	r8, rdi
	mov	rdi, rax
	call	r9
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], 0
	je	.L27
	mov	eax, DWORD PTR -4[rbp]
	jmp	.L28
.L27:
	mov	rax, QWORD PTR -24[rbp]
	mov	rdi, rax
	call	is_test_user
	test	eax, eax
	je	.L29
	mov	rax, QWORD PTR test_passwd_hash[rip]
	mov	rdi, rax
	call	strdup@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR -32[rbp]
	mov	QWORD PTR 8[rax], rdx
.L29:
	mov	eax, DWORD PTR -4[rbp]
.L28:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE12:
	.size	getspnam_r, .-getspnam_r
	.ident	"GCC: (Ubuntu 10.5.0-1ubuntu1~20.04) 10.5.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 6
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"927397.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"$6$\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	pwhash, %function
pwhash:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	str	r0, [fp, #-8]
	ldr	r1, .L3
	ldr	r0, [fp, #-8]
	bl	crypt
	mov	r3, r0
	mov	r0, r3
	bl	strdup
	mov	r3, r0
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L4:
	.align	2
.L3:
	.word	.LC0
	.size	pwhash, .-pwhash
	.local	real_getpwnam
	.comm	real_getpwnam,4,4
	.local	real_getpwnam_r
	.comm	real_getpwnam_r,4,4
	.local	real_getspnam
	.comm	real_getspnam,4,4
	.local	real_getspnam_r
	.comm	real_getspnam_r,4,4
	.local	test_user
	.comm	test_user,4,4
	.local	test_passwd_hash
	.comm	test_passwd_hash,4,4
	.section	.rodata
	.align	2
.LC1:
	.ascii	"getpwnam\000"
	.align	2
.LC2:
	.ascii	"getpwnam_r\000"
	.align	2
.LC3:
	.ascii	"getspnam\000"
	.align	2
.LC4:
	.ascii	"getspnam_r\000"
	.align	2
.LC5:
	.ascii	"TEST_USER\000"
	.align	2
.LC6:
	.ascii	"TEST_PASSWD\000"
	.align	2
.LC7:
	.ascii	"env variables TEST_USER and TEST_PASSWD are missing"
	.ascii	"\012\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	init, %function
init:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	ldr	r1, .L8
	mvn	r0, #0
	bl	dlsym
	mov	r3, r0
	mov	r2, r3
	ldr	r3, .L8+4
	str	r2, [r3]
	ldr	r1, .L8+8
	mvn	r0, #0
	bl	dlsym
	mov	r3, r0
	mov	r2, r3
	ldr	r3, .L8+12
	str	r2, [r3]
	ldr	r1, .L8+16
	mvn	r0, #0
	bl	dlsym
	mov	r3, r0
	mov	r2, r3
	ldr	r3, .L8+20
	str	r2, [r3]
	ldr	r1, .L8+24
	mvn	r0, #0
	bl	dlsym
	mov	r3, r0
	mov	r2, r3
	ldr	r3, .L8+28
	str	r2, [r3]
	ldr	r0, .L8+32
	bl	getenv
	mov	r3, r0
	cmp	r3, #0
	beq	.L6
	ldr	r0, .L8+36
	bl	getenv
	mov	r3, r0
	cmp	r3, #0
	bne	.L7
.L6:
	ldr	r3, .L8+40
	ldr	r3, [r3]
	mov	r2, #52
	mov	r1, #1
	ldr	r0, .L8+44
	bl	fwrite
	bl	abort
.L7:
	ldr	r0, .L8+32
	bl	getenv
	mov	r3, r0
	mov	r0, r3
	bl	strdup
	mov	r3, r0
	mov	r2, r3
	ldr	r3, .L8+48
	str	r2, [r3]
	ldr	r0, .L8+36
	bl	getenv
	mov	r3, r0
	mov	r0, r3
	bl	pwhash
	mov	r3, r0
	ldr	r2, .L8+52
	str	r3, [r2]
	nop
	nop
	nop
	nop
	nop
	nop
	nop
	nop
	nop
	pop	{fp, pc}
.L9:
	.align	2
.L8:
	.word	.LC1
	.word	real_getpwnam
	.word	.LC2
	.word	real_getpwnam_r
	.word	.LC3
	.word	real_getspnam
	.word	.LC4
	.word	real_getspnam_r
	.word	.LC5
	.word	.LC6
	.word	stderr
	.word	.LC7
	.word	test_user
	.word	test_passwd_hash
	.size	init, .-init
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	is_test_user, %function
is_test_user:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	str	r0, [fp, #-8]
	ldr	r3, .L13
	ldr	r3, [r3]
	cmp	r3, #0
	beq	.L11
	ldr	r3, .L13
	ldr	r3, [r3]
	ldr	r1, [fp, #-8]
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L11
	mov	r3, #1
	b	.L12
.L11:
	mov	r3, #0
.L12:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L14:
	.align	2
.L13:
	.word	test_user
	.size	is_test_user, .-is_test_user
	.align	2
	.global	getpwnam
	.syntax unified
	.arm
	.fpu softvfp
	.type	getpwnam, %function
getpwnam:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	str	r0, [fp, #-16]
	nop
	ldr	r3, .L20
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L16
	bl	init
.L16:
	ldr	r3, .L20
	ldr	r3, [r3]
	ldr	r0, [fp, #-16]
	blx	r3
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	bne	.L17
	mov	r3, #0
	b	.L18
.L17:
	ldr	r0, [fp, #-16]
	bl	is_test_user
	mov	r3, r0
	cmp	r3, #0
	beq	.L19
	ldr	r3, .L20+4
	ldr	r3, [r3]
	mov	r0, r3
	bl	strdup
	mov	r3, r0
	mov	r2, r3
	ldr	r3, [fp, #-8]
	str	r2, [r3, #4]
.L19:
	ldr	r3, [fp, #-8]
.L18:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L21:
	.align	2
.L20:
	.word	real_getpwnam
	.word	test_passwd_hash
	.size	getpwnam, .-getpwnam
	.align	2
	.global	getpwnam_r
	.syntax unified
	.arm
	.fpu softvfp
	.type	getpwnam_r, %function
getpwnam_r:
	@ args = 4, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #36
	str	r0, [fp, #-24]
	str	r1, [fp, #-28]
	str	r2, [fp, #-32]
	str	r3, [fp, #-36]
	nop
	ldr	r3, .L28
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L23
	bl	init
.L23:
	ldr	r3, .L28
	ldr	r4, [r3]
	ldr	r3, [fp, #4]
	str	r3, [sp]
	ldr	r3, [fp, #-36]
	ldr	r2, [fp, #-32]
	ldr	r1, [fp, #-28]
	ldr	r0, [fp, #-24]
	blx	r4
	str	r0, [fp, #-16]
	ldr	r3, [fp, #-16]
	cmp	r3, #0
	bne	.L24
	ldr	r3, [fp, #4]
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L25
.L24:
	ldr	r3, [fp, #-16]
	b	.L26
.L25:
	ldr	r0, [fp, #-24]
	bl	is_test_user
	mov	r3, r0
	cmp	r3, #0
	beq	.L27
	ldr	r3, .L28+4
	ldr	r3, [r3]
	mov	r0, r3
	bl	strdup
	mov	r3, r0
	mov	r2, r3
	ldr	r3, [fp, #-28]
	str	r2, [r3, #4]
.L27:
	mov	r3, #0
.L26:
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L29:
	.align	2
.L28:
	.word	real_getpwnam_r
	.word	test_passwd_hash
	.size	getpwnam_r, .-getpwnam_r
	.align	2
	.global	getspnam
	.syntax unified
	.arm
	.fpu softvfp
	.type	getspnam, %function
getspnam:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	str	r0, [fp, #-16]
	nop
	ldr	r3, .L35
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L31
	bl	init
.L31:
	ldr	r3, .L35
	ldr	r3, [r3]
	ldr	r0, [fp, #-16]
	blx	r3
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	bne	.L32
	mov	r3, #0
	b	.L33
.L32:
	ldr	r0, [fp, #-16]
	bl	is_test_user
	mov	r3, r0
	cmp	r3, #0
	beq	.L34
	ldr	r3, .L35+4
	ldr	r3, [r3]
	mov	r0, r3
	bl	strdup
	mov	r3, r0
	mov	r2, r3
	ldr	r3, [fp, #-8]
	str	r2, [r3, #4]
.L34:
	ldr	r3, [fp, #-8]
.L33:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L36:
	.align	2
.L35:
	.word	real_getspnam
	.word	test_passwd_hash
	.size	getspnam, .-getspnam
	.align	2
	.global	getspnam_r
	.syntax unified
	.arm
	.fpu softvfp
	.type	getspnam_r, %function
getspnam_r:
	@ args = 4, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #36
	str	r0, [fp, #-24]
	str	r1, [fp, #-28]
	str	r2, [fp, #-32]
	str	r3, [fp, #-36]
	nop
	ldr	r3, .L42
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L38
	bl	init
.L38:
	ldr	r3, .L42
	ldr	r4, [r3]
	ldr	r3, [fp, #4]
	str	r3, [sp]
	ldr	r3, [fp, #-36]
	ldr	r2, [fp, #-32]
	ldr	r1, [fp, #-28]
	ldr	r0, [fp, #-24]
	blx	r4
	str	r0, [fp, #-16]
	ldr	r3, [fp, #-16]
	cmp	r3, #0
	beq	.L39
	ldr	r3, [fp, #-16]
	b	.L40
.L39:
	ldr	r0, [fp, #-24]
	bl	is_test_user
	mov	r3, r0
	cmp	r3, #0
	beq	.L41
	ldr	r3, .L42+4
	ldr	r3, [r3]
	mov	r0, r3
	bl	strdup
	mov	r3, r0
	mov	r2, r3
	ldr	r3, [fp, #-28]
	str	r2, [r3, #4]
.L41:
	ldr	r3, [fp, #-16]
.L40:
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L43:
	.align	2
.L42:
	.word	real_getspnam_r
	.word	test_passwd_hash
	.size	getspnam_r, .-getspnam_r
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
