	.file	"507157.c"
	.intel_syntax noprefix
	.text
	.globl	debug
	.bss
	.type	debug, @object
	.size	debug, 1
debug:
	.zero	1
	.globl	verbose
	.type	verbose, @object
	.size	verbose, 1
verbose:
	.zero	1
	.globl	time_buffer
	.align 32
	.type	time_buffer, @object
	.size	time_buffer, 50
time_buffer:
	.zero	50
	.section	.rodata
.LC0:
	.string	"%Y-%m-%d %H:%M:%S       "
	.text
	.globl	time_str
	.type	time_str, @function
time_str:
.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	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	edi, 0
	call	time@PLT
	mov	QWORD PTR -16[rbp], rax
	lea	rax, -16[rbp]
	mov	rdi, rax
	call	localtime@PLT
	mov	rcx, rax
	lea	rdx, .LC0[rip]
	mov	esi, 50
	lea	rdi, time_buffer[rip]
	call	strftime@PLT
	lea	rax, time_buffer[rip]
	mov	rdx, QWORD PTR -8[rbp]
	sub	rdx, QWORD PTR fs:40
	je	.L3
	call	__stack_chk_fail@PLT
.L3:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	time_str, .-time_str
	.section	.rodata
	.align 8
.LC1:
	.string	"%5d    shim     [%s]        : "
	.text
	.globl	print_prefix
	.type	print_prefix, @function
print_prefix:
.LFB7:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	push	rbx
	sub	rsp, 8
	.cfi_offset 3, -24
	movzx	eax, BYTE PTR verbose[rip]
	test	al, al
	je	.L6
	call	time_str
	mov	rbx, rax
	call	getpid@PLT
	mov	rdx, rbx
	mov	esi, eax
	lea	rdi, .LC1[rip]
	mov	eax, 0
	call	printf@PLT
.L6:
	nop
	mov	rbx, QWORD PTR -8[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	print_prefix, .-print_prefix
	.globl	log1
	.type	log1, @function
log1:
.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
	movzx	eax, BYTE PTR debug[rip]
	test	al, al
	je	.L10
	call	print_prefix
	mov	rax, QWORD PTR -8[rbp]
	mov	rdi, rax
	call	puts@PLT
	jmp	.L7
.L10:
	nop
.L7:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	log1, .-log1
	.globl	shim_log
	.type	shim_log, @function
shim_log:
.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, 224
	mov	QWORD PTR -216[rbp], rdi
	mov	QWORD PTR -168[rbp], rsi
	mov	QWORD PTR -160[rbp], rdx
	mov	QWORD PTR -152[rbp], rcx
	mov	QWORD PTR -144[rbp], r8
	mov	QWORD PTR -136[rbp], r9
	test	al, al
	je	.L12
	movaps	XMMWORD PTR -128[rbp], xmm0
	movaps	XMMWORD PTR -112[rbp], xmm1
	movaps	XMMWORD PTR -96[rbp], xmm2
	movaps	XMMWORD PTR -80[rbp], xmm3
	movaps	XMMWORD PTR -64[rbp], xmm4
	movaps	XMMWORD PTR -48[rbp], xmm5
	movaps	XMMWORD PTR -32[rbp], xmm6
	movaps	XMMWORD PTR -16[rbp], xmm7
.L12:
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -184[rbp], rax
	xor	eax, eax
	movzx	eax, BYTE PTR debug[rip]
	test	al, al
	je	.L16
	call	print_prefix
	mov	DWORD PTR -208[rbp], 8
	mov	DWORD PTR -204[rbp], 48
	lea	rax, 16[rbp]
	mov	QWORD PTR -200[rbp], rax
	lea	rax, -176[rbp]
	mov	QWORD PTR -192[rbp], rax
	lea	rdx, -208[rbp]
	mov	rax, QWORD PTR -216[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	vprintf@PLT
	mov	edi, 10
	call	putchar@PLT
	jmp	.L11
.L16:
	nop
.L11:
	mov	rax, QWORD PTR -184[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L15
	call	__stack_chk_fail@PLT
.L15:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.size	shim_log, .-shim_log
	.globl	send_string
	.type	send_string, @function
send_string:
.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, 16
	mov	DWORD PTR -4[rbp], edi
	mov	QWORD PTR -16[rbp], rsi
	mov	rax, QWORD PTR -16[rbp]
	mov	rdi, rax
	call	strlen@PLT
	lea	rdx, 1[rax]
	mov	rsi, QWORD PTR -16[rbp]
	mov	eax, DWORD PTR -4[rbp]
	mov	ecx, 0
	mov	edi, eax
	call	send@PLT
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE10:
	.size	send_string, .-send_string
	.section	.rodata
.LC2:
	.string	"%d"
.LC3:
	.string	"%d (%s) has size %d"
	.text
	.globl	send_int
	.type	send_int, @function
send_int:
.LFB11:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	push	r15
	push	r14
	push	r13
	push	r12
	push	rbx
	sub	rsp, 56
	.cfi_offset 15, -24
	.cfi_offset 14, -32
	.cfi_offset 13, -40
	.cfi_offset 12, -48
	.cfi_offset 3, -56
	mov	DWORD PTR -84[rbp], edi
	mov	DWORD PTR -88[rbp], esi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -56[rbp], rax
	xor	eax, eax
	mov	rax, rsp
	mov	rbx, rax
	mov	eax, DWORD PTR -88[rbp]
	mov	ecx, eax
	lea	rdx, .LC2[rip]
	mov	esi, 0
	mov	edi, 0
	mov	eax, 0
	call	snprintf@PLT
	mov	DWORD PTR -76[rbp], eax
	mov	eax, DWORD PTR -76[rbp]
	add	eax, 1
	movsx	rdx, eax
	sub	rdx, 1
	mov	QWORD PTR -72[rbp], rdx
	movsx	rdx, eax
	mov	r14, rdx
	mov	r15d, 0
	movsx	rdx, eax
	mov	r12, rdx
	mov	r13d, 0
	cdqe
	mov	edx, 16
	sub	rdx, 1
	add	rax, rdx
	mov	edi, 16
	mov	edx, 0
	div	rdi
	imul	rax, rax, 16
	mov	rcx, rax
	and	rcx, -4096
	mov	rdx, rsp
	sub	rdx, rcx
.L20:
	cmp	rsp, rdx
	je	.L21
	sub	rsp, 4096
	or	QWORD PTR 4088[rsp], 0
	jmp	.L20
.L21:
	mov	rdx, rax
	and	edx, 4095
	sub	rsp, rdx
	mov	rdx, rax
	and	edx, 4095
	test	rdx, rdx
	je	.L22
	and	eax, 4095
	sub	rax, 8
	add	rax, rsp
	or	QWORD PTR [rax], 0
.L22:
	mov	rax, rsp
	add	rax, 0
	mov	QWORD PTR -64[rbp], rax
	mov	eax, DWORD PTR -76[rbp]
	add	eax, 1
	movsx	rsi, eax
	mov	edx, DWORD PTR -88[rbp]
	mov	rax, QWORD PTR -64[rbp]
	mov	ecx, edx
	lea	rdx, .LC2[rip]
	mov	rdi, rax
	mov	eax, 0
	call	snprintf@PLT
	mov	rdx, QWORD PTR -64[rbp]
	mov	eax, DWORD PTR -76[rbp]
	cdqe
	mov	BYTE PTR [rdx+rax], 0
	mov	ecx, DWORD PTR -76[rbp]
	mov	rdx, QWORD PTR -64[rbp]
	mov	eax, DWORD PTR -88[rbp]
	mov	esi, eax
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	shim_log
	mov	rdx, QWORD PTR -64[rbp]
	mov	eax, DWORD PTR -84[rbp]
	mov	rsi, rdx
	mov	edi, eax
	call	send_string
	mov	rsp, rbx
	mov	rbx, QWORD PTR -56[rbp]
	sub	rbx, QWORD PTR fs:40
	je	.L24
	call	__stack_chk_fail@PLT
.L24:
	lea	rsp, -40[rbp]
	pop	rbx
	pop	r12
	pop	r13
	pop	r14
	pop	r15
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE11:
	.size	send_int, .-send_int
	.section	.rodata
.LC4:
	.string	"the_stack_data/507157.c"
.LC5:
	.string	"path != 0"
.LC6:
	.string	"socket_fd != 0"
.LC7:
	.string	"socket"
.LC8:
	.string	"Shim: Path %s is too long!"
.LC9:
	.string	"unlink"
.LC10:
	.string	"bind"
.LC11:
	.string	"listen"
	.text
	.globl	start_server
	.type	start_server, @function
start_server:
.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, 160
	mov	QWORD PTR -152[rbp], rdi
	mov	QWORD PTR -160[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	cmp	QWORD PTR -152[rbp], 0
	jne	.L26
	lea	rcx, __PRETTY_FUNCTION__.2[rip]
	mov	edx, 76
	lea	rsi, .LC4[rip]
	lea	rdi, .LC5[rip]
	call	__assert_fail@PLT
.L26:
	cmp	QWORD PTR -160[rbp], 0
	jne	.L27
	lea	rcx, __PRETTY_FUNCTION__.2[rip]
	mov	edx, 77
	lea	rsi, .LC4[rip]
	lea	rdi, .LC6[rip]
	call	__assert_fail@PLT
.L27:
	mov	edx, 0
	mov	esi, 1
	mov	edi, 1
	call	socket@PLT
	mov	rdx, QWORD PTR -160[rbp]
	mov	DWORD PTR [rdx], eax
	mov	rax, QWORD PTR -160[rbp]
	mov	eax, DWORD PTR [rax]
	cmp	eax, -1
	jne	.L28
	lea	rdi, .LC7[rip]
	call	perror@PLT
	mov	eax, 0
	jmp	.L34
.L28:
	mov	WORD PTR -128[rbp], 1
	mov	rax, QWORD PTR -152[rbp]
	mov	rdi, rax
	call	strlen@PLT
	cmp	rax, 107
	jbe	.L30
	mov	rax, QWORD PTR stderr[rip]
	mov	rdx, QWORD PTR -152[rbp]
	lea	rsi, .LC8[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	eax, 0
	jmp	.L34
.L30:
	mov	rax, QWORD PTR -152[rbp]
	lea	rdx, -128[rbp]
	lea	rcx, 2[rdx]
	mov	edx, 107
	mov	rsi, rax
	mov	rdi, rcx
	call	strncpy@PLT
	mov	BYTE PTR -19[rbp], 0
	mov	rax, QWORD PTR -152[rbp]
	mov	rdi, rax
	call	unlink@PLT
	cmp	eax, -1
	jne	.L31
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	cmp	eax, 2
	je	.L31
	lea	rdi, .LC9[rip]
	call	perror@PLT
	mov	eax, 0
	jmp	.L34
.L31:
	mov	rax, QWORD PTR -152[rbp]
	mov	rdi, rax
	call	strlen@PLT
	add	eax, 2
	mov	DWORD PTR -136[rbp], eax
	mov	rax, QWORD PTR -160[rbp]
	mov	eax, DWORD PTR [rax]
	mov	edx, DWORD PTR -136[rbp]
	lea	rcx, -128[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	bind@PLT
	cmp	eax, -1
	jne	.L32
	lea	rdi, .LC10[rip]
	call	perror@PLT
	mov	eax, 0
	jmp	.L34
.L32:
	mov	DWORD PTR -132[rbp], 5
	mov	rax, QWORD PTR -160[rbp]
	mov	eax, DWORD PTR [rax]
	mov	edx, DWORD PTR -132[rbp]
	mov	esi, edx
	mov	edi, eax
	call	listen@PLT
	cmp	eax, -1
	jne	.L33
	lea	rdi, .LC11[rip]
	call	perror@PLT
	mov	eax, 0
	jmp	.L34
.L33:
	mov	rax, QWORD PTR -152[rbp]
	mov	esi, 432
	mov	rdi, rax
	call	chmod@PLT
	mov	eax, 1
.L34:
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L35
	call	__stack_chk_fail@PLT
.L35:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE12:
	.size	start_server, .-start_server
	.section	.rodata
.LC12:
	.string	"params != 0"
.LC13:
	.string	"*params != 0"
.LC14:
	.string	"Spawning!"
.LC15:
	.string	"Forked!"
.LC16:
	.string	"setsid"
.LC17:
	.string	"Sent pid %d"
.LC18:
	.string	"Reforked!"
.LC19:
	.string	"Running %s"
.LC20:
	.string	"execv"
	.text
	.globl	spawn
	.type	spawn, @function
spawn:
.LFB13:
	.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	DWORD PTR -20[rbp], edi
	mov	QWORD PTR -32[rbp], rsi
	cmp	QWORD PTR -32[rbp], 0
	jne	.L37
	lea	rcx, __PRETTY_FUNCTION__.1[rip]
	mov	edx, 117
	lea	rsi, .LC4[rip]
	lea	rdi, .LC12[rip]
	call	__assert_fail@PLT
.L37:
	mov	rax, QWORD PTR -32[rbp]
	mov	rax, QWORD PTR [rax]
	test	rax, rax
	jne	.L38
	lea	rcx, __PRETTY_FUNCTION__.1[rip]
	mov	edx, 118
	lea	rsi, .LC4[rip]
	lea	rdi, .LC13[rip]
	call	__assert_fail@PLT
.L38:
	lea	rdi, .LC14[rip]
	call	log1
	call	fork@PLT
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], 0
	je	.L39
	mov	eax, 0
	jmp	.L40
.L39:
	lea	rdi, .LC15[rip]
	call	log1
	call	setsid@PLT
	cmp	eax, -1
	jne	.L41
	lea	rdi, .LC16[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L41:
	call	fork@PLT
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], 0
	je	.L42
	mov	edx, DWORD PTR -4[rbp]
	mov	eax, DWORD PTR -20[rbp]
	mov	esi, edx
	mov	edi, eax
	call	send_int
	mov	eax, DWORD PTR -4[rbp]
	mov	esi, eax
	lea	rdi, .LC17[rip]
	mov	eax, 0
	call	shim_log
	mov	edi, 0
	call	exit@PLT
.L42:
	lea	rdi, .LC18[rip]
	call	log1
	mov	rax, QWORD PTR -32[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rsi, rax
	lea	rdi, .LC19[rip]
	mov	eax, 0
	call	shim_log
	mov	rax, QWORD PTR -32[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rdx, QWORD PTR -32[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	execv@PLT
	cmp	eax, -1
	jne	.L43
	lea	rdi, .LC20[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L43:
	mov	eax, -1
.L40:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE13:
	.size	spawn, .-spawn
	.section	.rodata
.LC21:
	.string	"fd != 0"
.LC22:
	.string	"recv"
.LC23:
	.string	"SPAWN\n"
.LC24:
	.string	"Sending NOK"
.LC25:
	.string	"NOK\n"
.LC26:
	.string	"send"
.LC27:
	.string	"Sending NACK!"
.LC28:
	.string	"NACK!\n"
	.text
	.globl	run_connection
	.type	run_connection, @function
run_connection:
.LFB14:
	.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	DWORD PTR -52[rbp], edi
	mov	QWORD PTR -64[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	cmp	DWORD PTR -52[rbp], 0
	jne	.L45
	lea	rcx, __PRETTY_FUNCTION__.0[rip]
	mov	edx, 153
	lea	rsi, .LC4[rip]
	lea	rdi, .LC21[rip]
	call	__assert_fail@PLT
.L45:
	cmp	QWORD PTR -64[rbp], 0
	jne	.L46
	lea	rcx, __PRETTY_FUNCTION__.0[rip]
	mov	edx, 154
	lea	rsi, .LC4[rip]
	lea	rdi, .LC12[rip]
	call	__assert_fail@PLT
.L46:
	mov	rax, QWORD PTR -64[rbp]
	mov	rax, QWORD PTR [rax]
	test	rax, rax
	jne	.L47
	lea	rcx, __PRETTY_FUNCTION__.0[rip]
	mov	edx, 155
	lea	rsi, .LC4[rip]
	lea	rdi, .LC13[rip]
	call	__assert_fail@PLT
.L47:
	lea	rsi, -18[rbp]
	mov	eax, DWORD PTR -52[rbp]
	mov	ecx, 0
	mov	edx, 10
	mov	edi, eax
	call	recv@PLT
	mov	QWORD PTR -32[rbp], rax
	cmp	QWORD PTR -32[rbp], 0
	jns	.L48
	lea	rdi, .LC22[rip]
	call	perror@PLT
	mov	eax, 0
	jmp	.L53
.L48:
	cmp	QWORD PTR -32[rbp], 0
	jne	.L50
	mov	eax, 1
	jmp	.L53
.L50:
	lea	rax, -18[rbp]
	mov	edx, 6
	lea	rsi, .LC23[rip]
	mov	rdi, rax
	call	strncmp@PLT
	test	eax, eax
	jne	.L51
	mov	rdx, QWORD PTR -64[rbp]
	mov	eax, DWORD PTR -52[rbp]
	mov	rsi, rdx
	mov	edi, eax
	call	spawn
	mov	DWORD PTR -36[rbp], eax
	cmp	DWORD PTR -36[rbp], 0
	je	.L47
	lea	rdi, .LC24[rip]
	call	log1
	mov	eax, DWORD PTR -52[rbp]
	lea	rsi, .LC25[rip]
	mov	edi, eax
	call	send_string
	test	rax, rax
	jns	.L47
	lea	rdi, .LC26[rip]
	call	perror@PLT
	mov	eax, 0
	jmp	.L53
.L51:
	lea	rdi, .LC27[rip]
	call	log1
	mov	eax, DWORD PTR -52[rbp]
	lea	rsi, .LC28[rip]
	mov	edi, eax
	call	send_string
	test	rax, rax
	jns	.L47
	lea	rdi, .LC26[rip]
	call	perror@PLT
	mov	eax, 0
.L53:
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L54
	call	__stack_chk_fail@PLT
.L54:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE14:
	.size	run_connection, .-run_connection
	.section	.rodata
.LC29:
	.string	"VERBOSE"
.LC30:
	.string	"DEBUG"
.LC31:
	.string	"Started."
	.align 8
.LC32:
	.string	"I'm uid %d euid %d gid %d egid %d"
.LC33:
	.string	"Usage: %s <socket> <command>\n"
.LC34:
	.string	"Will run %s"
.LC35:
	.string	"Waiting for a connection..."
.LC36:
	.string	"accept"
.LC37:
	.string	"Connected."
	.align 8
.LC38:
	.string	"Something went wrong while processing input"
	.text
	.globl	main
	.type	main, @function
main:
.LFB15:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	push	r13
	push	r12
	push	rbx
	sub	rsp, 232
	.cfi_offset 13, -24
	.cfi_offset 12, -32
	.cfi_offset 3, -40
	mov	DWORD PTR -228[rbp], edi
	mov	QWORD PTR -240[rbp], rsi
	mov	QWORD PTR -248[rbp], rdx
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -40[rbp], rax
	xor	eax, eax
	call	geteuid@PLT
	mov	DWORD PTR -204[rbp], eax
	mov	edx, DWORD PTR -204[rbp]
	mov	eax, DWORD PTR -204[rbp]
	mov	esi, edx
	mov	edi, eax
	call	setreuid@PLT
	call	getegid@PLT
	mov	DWORD PTR -200[rbp], eax
	mov	edx, DWORD PTR -200[rbp]
	mov	eax, DWORD PTR -200[rbp]
	mov	esi, edx
	mov	edi, eax
	call	setregid@PLT
	lea	rdi, .LC29[rip]
	call	getenv@PLT
	mov	QWORD PTR -192[rbp], rax
	lea	rdi, .LC30[rip]
	call	getenv@PLT
	mov	QWORD PTR -184[rbp], rax
	cmp	QWORD PTR -192[rbp], 0
	je	.L56
	mov	rax, QWORD PTR -192[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 121
	je	.L57
	mov	rax, QWORD PTR -192[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 89
	jne	.L56
.L57:
	mov	eax, 1
	jmp	.L58
.L56:
	mov	eax, 0
.L58:
	mov	BYTE PTR verbose[rip], al
	cmp	QWORD PTR -184[rbp], 0
	je	.L59
	mov	rax, QWORD PTR -184[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 121
	je	.L60
	mov	rax, QWORD PTR -184[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 89
	jne	.L59
.L60:
	mov	eax, 1
	jmp	.L61
.L59:
	mov	eax, 0
.L61:
	mov	BYTE PTR debug[rip], al
	lea	rdi, .LC31[rip]
	call	log1
	call	getegid@PLT
	mov	r13d, eax
	call	getgid@PLT
	mov	r12d, eax
	call	geteuid@PLT
	mov	ebx, eax
	call	getuid@PLT
	mov	r8d, r13d
	mov	ecx, r12d
	mov	edx, ebx
	mov	esi, eax
	lea	rdi, .LC32[rip]
	mov	eax, 0
	call	shim_log
	cmp	DWORD PTR -228[rbp], 2
	jg	.L62
	mov	rax, QWORD PTR -240[rbp]
	mov	rdx, QWORD PTR [rax]
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC33[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	eax, 1
	jmp	.L67
.L62:
	mov	rax, QWORD PTR -240[rbp]
	mov	rax, QWORD PTR 8[rax]
	mov	QWORD PTR -176[rbp], rax
	mov	rax, QWORD PTR -240[rbp]
	add	rax, 16
	mov	QWORD PTR -168[rbp], rax
	mov	rax, QWORD PTR -168[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rsi, rax
	lea	rdi, .LC34[rip]
	mov	eax, 0
	call	shim_log
	lea	rdx, -212[rbp]
	mov	rax, QWORD PTR -176[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	start_server
	test	al, al
	jne	.L64
	mov	eax, 1
	jmp	.L67
.L64:
	lea	rdi, .LC35[rip]
	call	log1
	mov	DWORD PTR -208[rbp], 110
	mov	eax, DWORD PTR -212[rbp]
	lea	rdx, -208[rbp]
	lea	rcx, -160[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	accept@PLT
	mov	DWORD PTR -196[rbp], eax
	cmp	DWORD PTR -196[rbp], -1
	jne	.L65
	lea	rdi, .LC36[rip]
	call	perror@PLT
	mov	eax, 1
	jmp	.L67
.L65:
	lea	rdi, .LC37[rip]
	call	log1
	mov	rdx, QWORD PTR -168[rbp]
	mov	eax, DWORD PTR -196[rbp]
	mov	rsi, rdx
	mov	edi, eax
	call	run_connection
	test	al, al
	jne	.L66
	lea	rdi, .LC38[rip]
	call	log1
.L66:
	mov	eax, DWORD PTR -196[rbp]
	mov	edi, eax
	call	close@PLT
	jmp	.L64
.L67:
	mov	rbx, QWORD PTR -40[rbp]
	sub	rbx, QWORD PTR fs:40
	je	.L68
	call	__stack_chk_fail@PLT
.L68:
	add	rsp, 232
	pop	rbx
	pop	r12
	pop	r13
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE15:
	.size	main, .-main
	.section	.rodata
	.align 8
	.type	__PRETTY_FUNCTION__.2, @object
	.size	__PRETTY_FUNCTION__.2, 13
__PRETTY_FUNCTION__.2:
	.string	"start_server"
	.type	__PRETTY_FUNCTION__.1, @object
	.size	__PRETTY_FUNCTION__.1, 6
__PRETTY_FUNCTION__.1:
	.string	"spawn"
	.align 8
	.type	__PRETTY_FUNCTION__.0, @object
	.size	__PRETTY_FUNCTION__.0, 15
__PRETTY_FUNCTION__.0:
	.string	"run_connection"
	.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	"507157.c"
	.text
	.global	debug
	.bss
	.type	debug, %object
	.size	debug, 1
debug:
	.space	1
	.global	verbose
	.type	verbose, %object
	.size	verbose, 1
verbose:
	.space	1
	.comm	time_buffer,50,4
	.section	.rodata
	.align	2
.LC0:
	.ascii	"%Y-%m-%d %H:%M:%S       \000"
	.align	2
.LC1:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	time_str
	.syntax unified
	.arm
	.fpu softvfp
	.type	time_str, %function
time_str:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	ldr	r3, .L4
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	mov	r0, #0
	bl	time
	mov	r3, r0
	str	r3, [fp, #-12]
	sub	r3, fp, #12
	mov	r0, r3
	bl	localtime
	mov	r3, r0
	ldr	r2, .L4+4
	mov	r1, #50
	ldr	r0, .L4+8
	bl	strftime
	ldr	r3, .L4+8
	ldr	r2, .L4
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L3
	bl	__stack_chk_fail
.L3:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L5:
	.align	2
.L4:
	.word	.LC1
	.word	.LC0
	.word	time_buffer
	.size	time_str, .-time_str
	.section	.rodata
	.align	2
.LC2:
	.ascii	"%5d    shim     [%s]        : \000"
	.text
	.align	2
	.global	print_prefix
	.syntax unified
	.arm
	.fpu softvfp
	.type	print_prefix, %function
print_prefix:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, r5, fp, lr}
	add	fp, sp, #12
	ldr	r3, .L9
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L8
	bl	getpid
	mov	r4, r0
	bl	time_str
	mov	r3, r0
	mov	r2, r3
	mov	r1, r4
	ldr	r0, .L9+4
	bl	printf
.L8:
	nop
	pop	{r4, r5, fp, pc}
.L10:
	.align	2
.L9:
	.word	verbose
	.word	.LC2
	.size	print_prefix, .-print_prefix
	.align	2
	.global	log1
	.syntax unified
	.arm
	.fpu softvfp
	.type	log1, %function
log1:
	@ 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, .L15
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L14
	bl	print_prefix
	ldr	r0, [fp, #-8]
	bl	puts
	b	.L11
.L14:
	nop
.L11:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L16:
	.align	2
.L15:
	.word	debug
	.size	log1, .-log1
	.section	.rodata
	.align	2
.LC3:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	shim_log
	.syntax unified
	.arm
	.fpu softvfp
	.type	shim_log, %function
shim_log:
	@ args = 4, pretend = 16, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 1
	push	{r0, r1, r2, r3}
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	ldr	r3, [fp, #4]
	str	r3, [fp, #-16]
	ldr	r3, .L22
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r3, .L22+4
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L21
	bl	print_prefix
	add	r3, fp, #8
	str	r3, [fp, #-12]
	ldr	r1, [fp, #-12]
	ldr	r0, [fp, #-16]
	bl	vprintf
	mov	r0, #10
	bl	putchar
	b	.L17
.L21:
	nop
.L17:
	ldr	r3, .L22
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L20
	bl	__stack_chk_fail
.L20:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, lr}
	add	sp, sp, #16
	bx	lr
.L23:
	.align	2
.L22:
	.word	.LC3
	.word	debug
	.size	shim_log, .-shim_log
	.align	2
	.global	send_string
	.syntax unified
	.arm
	.fpu softvfp
	.type	send_string, %function
send_string:
	@ 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]
	str	r1, [fp, #-12]
	ldr	r0, [fp, #-12]
	bl	strlen
	mov	r3, r0
	add	r2, r3, #1
	mov	r3, #0
	ldr	r1, [fp, #-12]
	ldr	r0, [fp, #-8]
	bl	send
	mov	r3, r0
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	send_string, .-send_string
	.section	.rodata
	.align	2
.LC4:
	.ascii	"%d\000"
	.align	2
.LC5:
	.ascii	"%d (%s) has size %d\000"
	.align	2
.LC6:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	send_int
	.syntax unified
	.arm
	.fpu softvfp
	.type	send_int, %function
send_int:
	@ args = 0, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #28
	str	r0, [fp, #-32]
	str	r1, [fp, #-36]
	ldr	r3, .L29
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	mov	r3, sp
	mov	r4, r3
	ldr	r3, [fp, #-36]
	ldr	r2, .L29+4
	mov	r1, #0
	mov	r0, #0
	bl	snprintf
	str	r0, [fp, #-28]
	ldr	r3, [fp, #-28]
	add	ip, r3, #1
	sub	r3, ip, #1
	str	r3, [fp, #-24]
	mov	r3, ip
	mov	r0, r3
	mov	r1, #0
	mov	r2, #0
	mov	r3, #0
	lsl	r3, r1, #3
	orr	r3, r3, r0, lsr #29
	lsl	r2, r0, #3
	mov	r3, ip
	mov	r0, r3
	mov	r1, #0
	mov	r2, #0
	mov	r3, #0
	lsl	r3, r1, #3
	orr	r3, r3, r0, lsr #29
	lsl	r2, r0, #3
	mov	r3, ip
	add	r3, r3, #7
	lsr	r3, r3, #3
	lsl	r3, r3, #3
	sub	sp, sp, r3
	mov	r3, sp
	add	r3, r3, #0
	str	r3, [fp, #-20]
	ldr	r3, [fp, #-28]
	add	r3, r3, #1
	mov	r1, r3
	ldr	r3, [fp, #-36]
	ldr	r2, .L29+4
	ldr	r0, [fp, #-20]
	bl	snprintf
	ldr	r2, [fp, #-20]
	ldr	r3, [fp, #-28]
	add	r3, r2, r3
	mov	r2, #0
	strb	r2, [r3]
	ldr	r3, [fp, #-28]
	ldr	r2, [fp, #-20]
	ldr	r1, [fp, #-36]
	ldr	r0, .L29+8
	bl	shim_log
	ldr	r1, [fp, #-20]
	ldr	r0, [fp, #-32]
	bl	send_string
	mov	r3, r0
	mov	sp, r4
	ldr	r2, .L29
	ldr	r1, [r2]
	ldr	r2, [fp, #-16]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L28
	bl	__stack_chk_fail
.L28:
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L30:
	.align	2
.L29:
	.word	.LC6
	.word	.LC4
	.word	.LC5
	.size	send_int, .-send_int
	.section	.rodata
	.align	2
.LC7:
	.ascii	"the_stack_data/507157.c\000"
	.align	2
.LC8:
	.ascii	"path != 0\000"
	.align	2
.LC9:
	.ascii	"socket_fd != 0\000"
	.align	2
.LC10:
	.ascii	"socket\000"
	.align	2
.LC11:
	.ascii	"Shim: Path %s is too long!\000"
	.align	2
.LC12:
	.ascii	"unlink\000"
	.align	2
.LC13:
	.ascii	"bind\000"
	.align	2
.LC14:
	.ascii	"listen\000"
	.align	2
.LC15:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	start_server
	.syntax unified
	.arm
	.fpu softvfp
	.type	start_server, %function
start_server:
	@ args = 0, pretend = 0, frame = 136
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #136
	str	r0, [fp, #-136]
	str	r1, [fp, #-140]
	ldr	r3, .L42
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r3, [fp, #-136]
	cmp	r3, #0
	bne	.L32
	ldr	r3, .L42+4
	mov	r2, #76
	ldr	r1, .L42+8
	ldr	r0, .L42+12
	bl	__assert_fail
.L32:
	ldr	r3, [fp, #-140]
	cmp	r3, #0
	bne	.L33
	ldr	r3, .L42+4
	mov	r2, #77
	ldr	r1, .L42+8
	ldr	r0, .L42+16
	bl	__assert_fail
.L33:
	mov	r2, #0
	mov	r1, #1
	mov	r0, #1
	bl	socket
	mov	r2, r0
	ldr	r3, [fp, #-140]
	str	r2, [r3]
	ldr	r3, [fp, #-140]
	ldr	r3, [r3]
	cmn	r3, #1
	bne	.L34
	ldr	r0, .L42+20
	bl	perror
	mov	r3, #0
	b	.L40
.L34:
	mov	r3, #1
	strh	r3, [fp, #-120]	@ movhi
	ldr	r0, [fp, #-136]
	bl	strlen
	mov	r3, r0
	cmp	r3, #107
	bls	.L36
	ldr	r3, .L42+24
	ldr	r3, [r3]
	ldr	r2, [fp, #-136]
	ldr	r1, .L42+28
	mov	r0, r3
	bl	fprintf
	mov	r3, #0
	b	.L40
.L36:
	sub	r3, fp, #120
	add	r3, r3, #2
	mov	r2, #107
	ldr	r1, [fp, #-136]
	mov	r0, r3
	bl	strncpy
	mov	r3, #0
	strb	r3, [fp, #-11]
	ldr	r0, [fp, #-136]
	bl	unlink
	mov	r3, r0
	cmn	r3, #1
	bne	.L37
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	cmp	r3, #2
	beq	.L37
	ldr	r0, .L42+32
	bl	perror
	mov	r3, #0
	b	.L40
.L37:
	ldr	r0, [fp, #-136]
	bl	strlen
	mov	r3, r0
	add	r3, r3, #2
	str	r3, [fp, #-128]
	ldr	r3, [fp, #-140]
	ldr	r3, [r3]
	sub	r1, fp, #120
	ldr	r2, [fp, #-128]
	mov	r0, r3
	bl	bind
	mov	r3, r0
	cmn	r3, #1
	bne	.L38
	ldr	r0, .L42+36
	bl	perror
	mov	r3, #0
	b	.L40
.L38:
	mov	r3, #5
	str	r3, [fp, #-124]
	ldr	r3, [fp, #-140]
	ldr	r3, [r3]
	ldr	r1, [fp, #-124]
	mov	r0, r3
	bl	listen
	mov	r3, r0
	cmn	r3, #1
	bne	.L39
	ldr	r0, .L42+40
	bl	perror
	mov	r3, #0
	b	.L40
.L39:
	mov	r1, #432
	ldr	r0, [fp, #-136]
	bl	chmod
	mov	r3, #1
.L40:
	ldr	r2, .L42
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L41
	bl	__stack_chk_fail
.L41:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L43:
	.align	2
.L42:
	.word	.LC15
	.word	__PRETTY_FUNCTION__.6361
	.word	.LC7
	.word	.LC8
	.word	.LC9
	.word	.LC10
	.word	stderr
	.word	.LC11
	.word	.LC12
	.word	.LC13
	.word	.LC14
	.size	start_server, .-start_server
	.section	.rodata
	.align	2
.LC16:
	.ascii	"params != 0\000"
	.align	2
.LC17:
	.ascii	"*params != 0\000"
	.align	2
.LC18:
	.ascii	"Spawning!\000"
	.align	2
.LC19:
	.ascii	"Forked!\000"
	.align	2
.LC20:
	.ascii	"setsid\000"
	.align	2
.LC21:
	.ascii	"Sent pid %d\000"
	.align	2
.LC22:
	.ascii	"Reforked!\000"
	.align	2
.LC23:
	.ascii	"Running %s\000"
	.align	2
.LC24:
	.ascii	"execv\000"
	.text
	.align	2
	.global	spawn
	.syntax unified
	.arm
	.fpu softvfp
	.type	spawn, %function
spawn:
	@ 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]
	str	r1, [fp, #-20]
	ldr	r3, [fp, #-20]
	cmp	r3, #0
	bne	.L45
	ldr	r3, .L52
	mov	r2, #117
	ldr	r1, .L52+4
	ldr	r0, .L52+8
	bl	__assert_fail
.L45:
	ldr	r3, [fp, #-20]
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L46
	ldr	r3, .L52
	mov	r2, #118
	ldr	r1, .L52+4
	ldr	r0, .L52+12
	bl	__assert_fail
.L46:
	ldr	r0, .L52+16
	bl	log1
	bl	fork
	mov	r3, r0
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	beq	.L47
	mov	r3, #0
	b	.L48
.L47:
	ldr	r0, .L52+20
	bl	log1
	bl	setsid
	mov	r3, r0
	cmn	r3, #1
	bne	.L49
	ldr	r0, .L52+24
	bl	perror
	mov	r0, #1
	bl	exit
.L49:
	bl	fork
	mov	r3, r0
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	beq	.L50
	ldr	r1, [fp, #-8]
	ldr	r0, [fp, #-16]
	bl	send_int
	ldr	r1, [fp, #-8]
	ldr	r0, .L52+28
	bl	shim_log
	mov	r0, #0
	bl	exit
.L50:
	ldr	r0, .L52+32
	bl	log1
	ldr	r3, [fp, #-20]
	ldr	r3, [r3]
	mov	r1, r3
	ldr	r0, .L52+36
	bl	shim_log
	ldr	r3, [fp, #-20]
	ldr	r3, [r3]
	ldr	r1, [fp, #-20]
	mov	r0, r3
	bl	execv
	mov	r3, r0
	cmn	r3, #1
	bne	.L51
	ldr	r0, .L52+40
	bl	perror
	mov	r0, #1
	bl	exit
.L51:
	mvn	r3, #0
.L48:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L53:
	.align	2
.L52:
	.word	__PRETTY_FUNCTION__.6369
	.word	.LC7
	.word	.LC16
	.word	.LC17
	.word	.LC18
	.word	.LC19
	.word	.LC20
	.word	.LC21
	.word	.LC22
	.word	.LC23
	.word	.LC24
	.size	spawn, .-spawn
	.section	.rodata
	.align	2
.LC25:
	.ascii	"fd != 0\000"
	.align	2
.LC26:
	.ascii	"recv\000"
	.align	2
.LC27:
	.ascii	"SPAWN\012\000"
	.align	2
.LC28:
	.ascii	"Sending NOK\000"
	.align	2
.LC29:
	.ascii	"NOK\012\000"
	.align	2
.LC30:
	.ascii	"send\000"
	.align	2
.LC31:
	.ascii	"Sending NACK!\000"
	.align	2
.LC32:
	.ascii	"NACK!\012\000"
	.align	2
.LC33:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	run_connection
	.syntax unified
	.arm
	.fpu softvfp
	.type	run_connection, %function
run_connection:
	@ args = 0, pretend = 0, frame = 32
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #32
	str	r0, [fp, #-32]
	str	r1, [fp, #-36]
	ldr	r3, .L65
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r3, [fp, #-32]
	cmp	r3, #0
	bne	.L55
	ldr	r3, .L65+4
	mov	r2, #153
	ldr	r1, .L65+8
	ldr	r0, .L65+12
	bl	__assert_fail
.L55:
	ldr	r3, [fp, #-36]
	cmp	r3, #0
	bne	.L56
	ldr	r3, .L65+4
	mov	r2, #154
	ldr	r1, .L65+8
	ldr	r0, .L65+16
	bl	__assert_fail
.L56:
	ldr	r3, [fp, #-36]
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L57
	ldr	r3, .L65+4
	mov	r2, #155
	ldr	r1, .L65+8
	ldr	r0, .L65+20
	bl	__assert_fail
.L57:
	sub	r1, fp, #20
	mov	r3, #0
	mov	r2, #10
	ldr	r0, [fp, #-32]
	bl	recv
	str	r0, [fp, #-28]
	ldr	r3, [fp, #-28]
	cmp	r3, #0
	bge	.L58
	ldr	r0, .L65+24
	bl	perror
	mov	r3, #0
	b	.L63
.L58:
	ldr	r3, [fp, #-28]
	cmp	r3, #0
	bne	.L60
	mov	r3, #1
	b	.L63
.L60:
	sub	r3, fp, #20
	mov	r2, #6
	ldr	r1, .L65+28
	mov	r0, r3
	bl	strncmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L61
	ldr	r1, [fp, #-36]
	ldr	r0, [fp, #-32]
	bl	spawn
	str	r0, [fp, #-24]
	ldr	r3, [fp, #-24]
	cmp	r3, #0
	beq	.L57
	ldr	r0, .L65+32
	bl	log1
	ldr	r1, .L65+36
	ldr	r0, [fp, #-32]
	bl	send_string
	mov	r3, r0
	cmp	r3, #0
	bge	.L57
	ldr	r0, .L65+40
	bl	perror
	mov	r3, #0
	b	.L63
.L61:
	ldr	r0, .L65+44
	bl	log1
	ldr	r1, .L65+48
	ldr	r0, [fp, #-32]
	bl	send_string
	mov	r3, r0
	cmp	r3, #0
	bge	.L57
	ldr	r0, .L65+40
	bl	perror
	mov	r3, #0
.L63:
	ldr	r2, .L65
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L64
	bl	__stack_chk_fail
.L64:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L66:
	.align	2
.L65:
	.word	.LC33
	.word	__PRETTY_FUNCTION__.6375
	.word	.LC7
	.word	.LC25
	.word	.LC16
	.word	.LC17
	.word	.LC26
	.word	.LC27
	.word	.LC28
	.word	.LC29
	.word	.LC30
	.word	.LC31
	.word	.LC32
	.size	run_connection, .-run_connection
	.section	.rodata
	.align	2
.LC34:
	.ascii	"VERBOSE\000"
	.align	2
.LC35:
	.ascii	"DEBUG\000"
	.align	2
.LC36:
	.ascii	"Started.\000"
	.align	2
.LC37:
	.ascii	"I'm uid %d euid %d gid %d egid %d\000"
	.align	2
.LC38:
	.ascii	"Usage: %s <socket> <command>\012\000"
	.align	2
.LC39:
	.ascii	"Will run %s\000"
	.align	2
.LC40:
	.ascii	"Waiting for a connection...\000"
	.align	2
.LC41:
	.ascii	"accept\000"
	.align	2
.LC42:
	.ascii	"Connected.\000"
	.align	2
.LC43:
	.ascii	"Something went wrong while processing input\000"
	.align	2
.LC44:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 168
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, r5, r6, fp, lr}
	add	fp, sp, #16
	sub	sp, sp, #180
	str	r0, [fp, #-176]
	str	r1, [fp, #-180]
	str	r2, [fp, #-184]
	ldr	r3, .L81
	ldr	r3, [r3]
	str	r3, [fp, #-24]
	mov	r3,#0
	bl	geteuid
	str	r0, [fp, #-164]
	ldr	r1, [fp, #-164]
	ldr	r0, [fp, #-164]
	bl	setreuid
	bl	getegid
	str	r0, [fp, #-160]
	ldr	r1, [fp, #-160]
	ldr	r0, [fp, #-160]
	bl	setregid
	ldr	r0, .L81+4
	bl	getenv
	str	r0, [fp, #-156]
	ldr	r0, .L81+8
	bl	getenv
	str	r0, [fp, #-152]
	ldr	r3, [fp, #-156]
	cmp	r3, #0
	beq	.L68
	ldr	r3, [fp, #-156]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #121
	beq	.L69
	ldr	r3, [fp, #-156]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #89
	bne	.L68
.L69:
	mov	r3, #1
	b	.L70
.L68:
	mov	r3, #0
.L70:
	and	r2, r3, #255
	ldr	r3, .L81+12
	strb	r2, [r3]
	ldr	r3, [fp, #-152]
	cmp	r3, #0
	beq	.L71
	ldr	r3, [fp, #-152]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #121
	beq	.L72
	ldr	r3, [fp, #-152]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #89
	bne	.L71
.L72:
	mov	r3, #1
	b	.L73
.L71:
	mov	r3, #0
.L73:
	and	r2, r3, #255
	ldr	r3, .L81+16
	strb	r2, [r3]
	ldr	r0, .L81+20
	bl	log1
	bl	getuid
	mov	r4, r0
	bl	geteuid
	mov	r5, r0
	bl	getgid
	mov	r6, r0
	bl	getegid
	mov	r3, r0
	str	r3, [sp]
	mov	r3, r6
	mov	r2, r5
	mov	r1, r4
	ldr	r0, .L81+24
	bl	shim_log
	ldr	r3, [fp, #-176]
	cmp	r3, #2
	bgt	.L74
	ldr	r3, .L81+28
	ldr	r0, [r3]
	ldr	r3, [fp, #-180]
	ldr	r3, [r3]
	mov	r2, r3
	ldr	r1, .L81+32
	bl	fprintf
	mov	r3, #1
	b	.L79
.L74:
	ldr	r3, [fp, #-180]
	ldr	r3, [r3, #4]
	str	r3, [fp, #-148]
	ldr	r3, [fp, #-180]
	add	r3, r3, #8
	str	r3, [fp, #-144]
	ldr	r3, [fp, #-144]
	ldr	r3, [r3]
	mov	r1, r3
	ldr	r0, .L81+36
	bl	shim_log
	sub	r3, fp, #172
	mov	r1, r3
	ldr	r0, [fp, #-148]
	bl	start_server
	mov	r3, r0
	cmp	r3, #0
	bne	.L76
	mov	r3, #1
	b	.L79
.L76:
	ldr	r0, .L81+40
	bl	log1
	mov	r3, #110
	str	r3, [fp, #-168]
	ldr	r3, [fp, #-172]
	sub	r2, fp, #168
	sub	r1, fp, #136
	mov	r0, r3
	bl	accept
	str	r0, [fp, #-140]
	ldr	r3, [fp, #-140]
	cmn	r3, #1
	bne	.L77
	ldr	r0, .L81+44
	bl	perror
	mov	r3, #1
	b	.L79
.L77:
	ldr	r0, .L81+48
	bl	log1
	ldr	r1, [fp, #-144]
	ldr	r0, [fp, #-140]
	bl	run_connection
	mov	r3, r0
	cmp	r3, #0
	bne	.L78
	ldr	r0, .L81+52
	bl	log1
.L78:
	ldr	r0, [fp, #-140]
	bl	close
	b	.L76
.L79:
	ldr	r2, .L81
	ldr	r1, [r2]
	ldr	r2, [fp, #-24]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L80
	bl	__stack_chk_fail
.L80:
	mov	r0, r3
	sub	sp, fp, #16
	@ sp needed
	pop	{r4, r5, r6, fp, pc}
.L82:
	.align	2
.L81:
	.word	.LC44
	.word	.LC34
	.word	.LC35
	.word	verbose
	.word	debug
	.word	.LC36
	.word	.LC37
	.word	stderr
	.word	.LC38
	.word	.LC39
	.word	.LC40
	.word	.LC41
	.word	.LC42
	.word	.LC43
	.size	main, .-main
	.section	.rodata
	.align	2
	.type	__PRETTY_FUNCTION__.6361, %object
	.size	__PRETTY_FUNCTION__.6361, 13
__PRETTY_FUNCTION__.6361:
	.ascii	"start_server\000"
	.align	2
	.type	__PRETTY_FUNCTION__.6369, %object
	.size	__PRETTY_FUNCTION__.6369, 6
__PRETTY_FUNCTION__.6369:
	.ascii	"spawn\000"
	.align	2
	.type	__PRETTY_FUNCTION__.6375, %object
	.size	__PRETTY_FUNCTION__.6375, 15
__PRETTY_FUNCTION__.6375:
	.ascii	"run_connection\000"
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
