	.file	"876770.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
	.align 8
.LC0:
	.string	"use: ./client [hostname] [username] [password]"
.LC1:
	.string	"username:%s\n"
.LC2:
	.string	"password:%s\n"
.LC3:
	.string	"fail to get host by name."
	.align 8
.LC4:
	.string	"Success to get host by name ..."
.LC5:
	.string	"fail to establish a socket"
	.align 8
.LC6:
	.string	"Success to establish a socket..."
.LC7:
	.string	"fail to connect the socket"
	.align 8
.LC8:
	.string	"Success to connect the socket..."
.LC9:
	.string	"fail to send datas."
.LC10:
	.string	"fail to receive datas."
.LC11:
	.string	"no"
.LC12:
	.string	"wrong passwd"
.LC13:
	.string	"fork error\n"
.LC14:
	.string	"Me:%s\n"
.LC15:
	.string	"Server maybe shutdown!"
	.text
	.globl	main
	.type	main, @function
main:
.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, 4096
	or	QWORD PTR [rsp], 0
	sub	rsp, 4096
	or	QWORD PTR [rsp], 0
	sub	rsp, 144
	mov	DWORD PTR -8324[rbp], edi
	mov	QWORD PTR -8336[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	cmp	DWORD PTR -8324[rbp], 4
	je	.L2
	lea	rdi, .LC0[rip]
	call	perror@PLT
	mov	edi, -1
	call	exit@PLT
.L2:
	mov	rax, QWORD PTR -8336[rbp]
	add	rax, 16
	mov	rdx, QWORD PTR [rax]
	lea	rax, -8272[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	strcpy@PLT
	mov	rax, QWORD PTR -8336[rbp]
	add	rax, 24
	mov	rax, QWORD PTR [rax]
	lea	rdx, -8272[rbp]
	add	rdx, 32
	mov	rsi, rax
	mov	rdi, rdx
	call	strcpy@PLT
	lea	rax, -8272[rbp]
	mov	rsi, rax
	lea	rdi, .LC1[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rax, -8272[rbp]
	add	rax, 32
	mov	rsi, rax
	lea	rdi, .LC2[rip]
	mov	eax, 0
	call	printf@PLT
	mov	rax, QWORD PTR -8336[rbp]
	add	rax, 8
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	gethostbyname@PLT
	mov	QWORD PTR -8296[rbp], rax
	cmp	QWORD PTR -8296[rbp], 0
	jne	.L3
	lea	rdi, .LC3[rip]
	call	perror@PLT
	mov	edi, -1
	call	exit@PLT
.L3:
	lea	rdi, .LC4[rip]
	call	puts@PLT
	mov	edx, 0
	mov	esi, 1
	mov	edi, 2
	call	socket@PLT
	mov	DWORD PTR -8308[rbp], eax
	cmp	DWORD PTR -8308[rbp], -1
	jne	.L4
	lea	rdi, .LC5[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L4:
	lea	rdi, .LC6[rip]
	call	puts@PLT
	mov	WORD PTR -8288[rbp], 2
	mov	edi, 12138
	call	htons@PLT
	mov	WORD PTR -8286[rbp], ax
	mov	rax, QWORD PTR -8296[rbp]
	mov	rax, QWORD PTR 24[rax]
	mov	rax, QWORD PTR [rax]
	mov	eax, DWORD PTR [rax]
	mov	DWORD PTR -8284[rbp], eax
	lea	rax, -8288[rbp]
	add	rax, 8
	mov	QWORD PTR [rax], 0
	lea	rcx, -8288[rbp]
	mov	eax, DWORD PTR -8308[rbp]
	mov	edx, 16
	mov	rsi, rcx
	mov	edi, eax
	call	connect@PLT
	cmp	eax, -1
	jne	.L5
	lea	rdi, .LC7[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L5:
	lea	rdi, .LC8[rip]
	call	puts@PLT
	lea	rsi, -8272[rbp]
	mov	eax, DWORD PTR -8308[rbp]
	mov	ecx, 0
	mov	edx, 64
	mov	edi, eax
	call	send@PLT
	cmp	rax, -1
	jne	.L6
	lea	rdi, .LC9[rip]
	call	perror@PLT
	mov	edi, -1
	call	exit@PLT
.L6:
	lea	rsi, -4112[rbp]
	mov	eax, DWORD PTR -8308[rbp]
	mov	ecx, 0
	mov	edx, 4096
	mov	edi, eax
	call	recv@PLT
	cmp	rax, -1
	sete	al
	movzx	eax, al
	mov	DWORD PTR -8304[rbp], eax
	cmp	DWORD PTR -8304[rbp], 0
	je	.L7
	lea	rdi, .LC10[rip]
	call	perror@PLT
	mov	edi, -1
	call	exit@PLT
.L7:
	lea	rax, -4112[rbp]
	lea	rsi, .LC11[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L8
	lea	rdi, .LC12[rip]
	call	perror@PLT
	mov	edi, -1
	call	exit@PLT
.L8:
	call	fork@PLT
	mov	DWORD PTR -8300[rbp], eax
	cmp	DWORD PTR -8300[rbp], 0
	jns	.L9
	lea	rdi, .LC13[rip]
	call	perror@PLT
	jmp	.L10
.L9:
	cmp	DWORD PTR -8300[rbp], 0
	jne	.L11
.L13:
	mov	rdx, QWORD PTR stdin[rip]
	lea	rax, -8208[rbp]
	mov	esi, 4096
	mov	rdi, rax
	call	fgets@PLT
	lea	rax, -8208[rbp]
	mov	rsi, rax
	lea	rdi, .LC14[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rax, -8208[rbp]
	mov	rdi, rax
	call	strlen@PLT
	mov	rdx, rax
	lea	rsi, -8208[rbp]
	mov	eax, DWORD PTR -8308[rbp]
	mov	ecx, 0
	mov	edi, eax
	call	send@PLT
	cmp	rax, -1
	jne	.L12
	lea	rdi, .LC10[rip]
	call	perror@PLT
.L12:
	lea	rax, -8208[rbp]
	mov	edx, 4096
	mov	esi, 0
	mov	rdi, rax
	call	memset@PLT
	jmp	.L13
.L11:
	lea	rsi, -4112[rbp]
	mov	eax, DWORD PTR -8308[rbp]
	mov	ecx, 0
	mov	edx, 4096
	mov	edi, eax
	call	recv@PLT
	cmp	rax, -1
	sete	al
	movzx	eax, al
	mov	DWORD PTR -8304[rbp], eax
	cmp	DWORD PTR -8304[rbp], 0
	je	.L14
	lea	rdi, .LC15[rip]
	mov	eax, 0
	call	printf@PLT
	nop
	mov	eax, DWORD PTR -8300[rbp]
	mov	esi, 9
	mov	edi, eax
	call	kill@PLT
	jmp	.L10
.L14:
	lea	rax, -4112[rbp]
	mov	rdi, rax
	call	puts@PLT
	lea	rax, -4112[rbp]
	mov	edx, 4096
	mov	esi, 0
	mov	rdi, rax
	call	memset@PLT
	jmp	.L11
.L10:
	mov	eax, DWORD PTR -8308[rbp]
	mov	edi, eax
	call	close@PLT
	mov	eax, 0
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L17
	call	__stack_chk_fail@PLT
.L17:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	main, .-main
	.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	"876770.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"use: ./client [hostname] [username] [password]\000"
	.align	2
.LC1:
	.ascii	"username:%s\012\000"
	.align	2
.LC2:
	.ascii	"password:%s\012\000"
	.align	2
.LC3:
	.ascii	"fail to get host by name.\000"
	.align	2
.LC4:
	.ascii	"Success to get host by name ...\000"
	.align	2
.LC5:
	.ascii	"fail to establish a socket\000"
	.align	2
.LC6:
	.ascii	"Success to establish a socket...\000"
	.align	2
.LC7:
	.ascii	"fail to connect the socket\000"
	.align	2
.LC8:
	.ascii	"Success to connect the socket...\000"
	.align	2
.LC9:
	.ascii	"fail to send datas.\000"
	.align	2
.LC10:
	.ascii	"fail to receive datas.\000"
	.align	2
.LC11:
	.ascii	"no\000"
	.align	2
.LC12:
	.ascii	"wrong passwd\000"
	.align	2
.LC13:
	.ascii	"fork error\012\000"
	.align	2
.LC14:
	.ascii	"Me:%s\012\000"
	.align	2
.LC15:
	.ascii	"Server maybe shutdown!\000"
	.align	2
.LC16:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 8304
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #8256
	sub	sp, sp, #52
	sub	r3, fp, #8192
	sub	r3, r3, #12
	str	r0, [r3, #-108]
	sub	r3, fp, #8192
	sub	r3, r3, #12
	str	r1, [r3, #-112]
	ldr	r3, .L18
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-108]
	cmp	r3, #4
	beq	.L2
	ldr	r0, .L18+4
	bl	perror
	mvn	r0, #0
	bl	exit
.L2:
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-112]
	add	r3, r3, #8
	ldr	r2, [r3]
	sub	r3, fp, #8256
	sub	r3, r3, #12
	sub	r3, r3, #4
	mov	r1, r2
	mov	r0, r3
	bl	strcpy
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-112]
	add	r3, r3, #12
	ldr	r2, [r3]
	sub	r3, fp, #8256
	sub	r3, r3, #12
	sub	r3, r3, #4
	add	r3, r3, #32
	mov	r1, r2
	mov	r0, r3
	bl	strcpy
	sub	r3, fp, #8256
	sub	r3, r3, #12
	sub	r3, r3, #4
	mov	r1, r3
	ldr	r0, .L18+8
	bl	printf
	sub	r3, fp, #8256
	sub	r3, r3, #12
	sub	r3, r3, #4
	add	r3, r3, #32
	mov	r1, r3
	ldr	r0, .L18+12
	bl	printf
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-112]
	add	r3, r3, #4
	ldr	r3, [r3]
	sub	r2, fp, #8192
	sub	r2, r2, #12
	mov	r4, r2
	mov	r0, r3
	bl	gethostbyname
	str	r0, [r4, #-100]
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-100]
	cmp	r3, #0
	bne	.L3
	ldr	r0, .L18+16
	bl	perror
	mvn	r0, #0
	bl	exit
.L3:
	ldr	r0, .L18+20
	bl	puts
	sub	r3, fp, #8192
	sub	r3, r3, #12
	mov	r4, r3
	mov	r2, #0
	mov	r1, #1
	mov	r0, #2
	bl	socket
	str	r0, [r4, #-96]
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-96]
	cmn	r3, #1
	bne	.L4
	ldr	r0, .L18+24
	bl	perror
	mov	r0, #1
	bl	exit
.L4:
	ldr	r0, .L18+28
	bl	puts
	sub	r3, fp, #8192
	sub	r3, r3, #12
	mov	r2, #2
	strh	r2, [r3, #-84]	@ movhi
	ldr	r0, .L18+32
	bl	htons
	mov	r3, r0
	mov	r2, r3
	sub	r3, fp, #8192
	sub	r3, r3, #12
	strh	r2, [r3, #-82]	@ movhi
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-100]
	ldr	r3, [r3, #16]
	ldr	r3, [r3]
	sub	r2, fp, #8192
	sub	r2, r2, #12
	ldr	r3, [r3]
	str	r3, [r2, #-80]
	sub	r3, fp, #8256
	sub	r3, r3, #12
	sub	r3, r3, #20
	add	r3, r3, #8
	mov	r2, r3
	mov	r3, #0
	str	r3, [r2]
	str	r3, [r2, #4]
	sub	r3, fp, #8256
	sub	r3, r3, #12
	sub	r3, r3, #20
	sub	r2, fp, #8192
	sub	r2, r2, #12
	mov	r0, r2
	mov	r2, #16
	mov	r1, r3
	ldr	r0, [r0, #-96]
	bl	connect
	mov	r3, r0
	cmn	r3, #1
	bne	.L5
	ldr	r0, .L18+36
	bl	perror
	mov	r0, #1
	bl	exit
.L5:
	ldr	r0, .L18+40
	bl	puts
	sub	r1, fp, #8256
	sub	r1, r1, #12
	sub	r1, r1, #4
	sub	r3, fp, #8192
	sub	r3, r3, #12
	mov	r0, r3
	mov	r3, #0
	mov	r2, #64
	ldr	r0, [r0, #-96]
	bl	send
	mov	r3, r0
	cmn	r3, #1
	bne	.L6
	ldr	r0, .L18+44
	bl	perror
	mvn	r0, #0
	bl	exit
.L6:
	sub	r1, fp, #4096
	sub	r1, r1, #12
	sub	r1, r1, #4
	sub	r3, fp, #8192
	sub	r3, r3, #12
	mov	r0, r3
	mov	r3, #0
	mov	r2, #4096
	ldr	r0, [r0, #-96]
	bl	recv
	mov	r3, r0
	cmn	r3, #1
	moveq	r3, #1
	movne	r3, #0
	and	r3, r3, #255
	sub	r2, fp, #8192
	sub	r2, r2, #12
	str	r3, [r2, #-92]
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-92]
	cmp	r3, #0
	beq	.L7
	ldr	r0, .L18+48
	bl	perror
	mvn	r0, #0
	bl	exit
.L7:
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #4
	ldr	r1, .L18+52
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L8
	ldr	r0, .L18+56
	bl	perror
	mvn	r0, #0
	bl	exit
.L8:
	sub	r3, fp, #8192
	sub	r3, r3, #12
	mov	r4, r3
	bl	fork
	mov	r3, r0
	str	r3, [r4, #-88]
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-88]
	cmp	r3, #0
	bge	.L9
	ldr	r0, .L18+60
	bl	perror
	b	.L10
.L9:
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-88]
	cmp	r3, #0
	bne	.L11
.L13:
	ldr	r3, .L18+64
	ldr	r2, [r3]
	sub	r3, fp, #8192
	sub	r3, r3, #12
	sub	r3, r3, #4
	mov	r1, #4096
	mov	r0, r3
	bl	fgets
	sub	r3, fp, #8192
	sub	r3, r3, #12
	sub	r3, r3, #4
	mov	r1, r3
	ldr	r0, .L18+68
	bl	printf
	sub	r3, fp, #8192
	sub	r3, r3, #12
	sub	r3, r3, #4
	mov	r0, r3
	bl	strlen
	mov	r2, r0
	sub	r1, fp, #8192
	sub	r1, r1, #12
	sub	r1, r1, #4
	sub	r3, fp, #8192
	sub	r3, r3, #12
	mov	r0, r3
	mov	r3, #0
	ldr	r0, [r0, #-96]
	bl	send
	mov	r3, r0
	cmn	r3, #1
	bne	.L12
	ldr	r0, .L18+48
	bl	perror
.L12:
	sub	r3, fp, #8192
	sub	r3, r3, #12
	sub	r3, r3, #4
	mov	r2, #4096
	mov	r1, #0
	mov	r0, r3
	bl	memset
	b	.L13
.L11:
	sub	r1, fp, #4096
	sub	r1, r1, #12
	sub	r1, r1, #4
	sub	r3, fp, #8192
	sub	r3, r3, #12
	mov	r0, r3
	mov	r3, #0
	mov	r2, #4096
	ldr	r0, [r0, #-96]
	bl	recv
	mov	r3, r0
	cmn	r3, #1
	moveq	r3, #1
	movne	r3, #0
	and	r3, r3, #255
	sub	r2, fp, #8192
	sub	r2, r2, #12
	str	r3, [r2, #-92]
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-92]
	cmp	r3, #0
	beq	.L14
	ldr	r0, .L18+72
	bl	printf
	nop
	sub	r3, fp, #8192
	sub	r3, r3, #12
	mov	r1, #9
	ldr	r0, [r3, #-88]
	bl	kill
	b	.L10
.L14:
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #4
	mov	r0, r3
	bl	puts
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #4
	mov	r2, #4096
	mov	r1, #0
	mov	r0, r3
	bl	memset
	b	.L11
.L10:
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r0, [r3, #-96]
	bl	close
	mov	r3, #0
	ldr	r2, .L18
	ldr	r1, [r2]
	ldr	r2, [fp, #-16]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L17
	bl	__stack_chk_fail
.L17:
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L19:
	.align	2
.L18:
	.word	.LC16
	.word	.LC0
	.word	.LC1
	.word	.LC2
	.word	.LC3
	.word	.LC4
	.word	.LC5
	.word	.LC6
	.word	12138
	.word	.LC7
	.word	.LC8
	.word	.LC9
	.word	.LC10
	.word	.LC11
	.word	.LC12
	.word	.LC13
	.word	stdin
	.word	.LC14
	.word	.LC15
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
