	.file	"565241.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	"Usage: %s <HOSTNAME> <PORT>\n"
.LC1:
	.string	"getaddrinfo: "
.LC2:
	.string	"socket: "
.LC3:
	.string	"connect: "
	.align 8
.LC4:
	.string	"client: failed to conect after parser reached NULL (end of linked list)\n"
.LC5:
	.string	"Client: connected to %s\n"
.LC6:
	.string	"Recieved %d bytes\n"
	.align 8
.LC7:
	.string	"\n-=-=-=-=-= Values Recieved (in Network Byte Order) =-=-=-=-=-\n"
.LC8:
	.string	"[-]Valuex%d : 0x%x\n"
	.align 8
.LC9:
	.string	"\n-=-=-=-=-= Values Converted (in Host Byte Order) =-=-=-=-=-\n"
.LC10:
	.string	"[+]Value%d : 0x%x\n"
.LC11:
	.string	"\nsum is : 0x%lx : %d\n"
.LC12:
	.string	"final payload : %s\n"
.LC13:
	.string	"\n0x%lx -----"
	.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, 736
	mov	DWORD PTR -724[rbp], edi
	mov	QWORD PTR -736[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	QWORD PTR -680[rbp], 0
	mov	QWORD PTR -664[rbp], 0
	mov	DWORD PTR -708[rbp], 0
	mov	DWORD PTR -696[rbp], 0
	cmp	DWORD PTR -724[rbp], 3
	je	.L2
	mov	rax, QWORD PTR -736[rbp]
	mov	rdx, QWORD PTR [rax]
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC0[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 16
	call	exit@PLT
.L2:
	lea	rax, -624[rbp]
	mov	edx, 48
	mov	esi, 0
	mov	rdi, rax
	call	memset@PLT
	mov	DWORD PTR -620[rbp], 0
	mov	DWORD PTR -616[rbp], 1
	mov	rax, QWORD PTR -736[rbp]
	add	rax, 16
	mov	rsi, QWORD PTR [rax]
	mov	rax, QWORD PTR -736[rbp]
	add	rax, 8
	mov	rax, QWORD PTR [rax]
	lea	rcx, -680[rbp]
	lea	rdx, -624[rbp]
	mov	rdi, rax
	call	getaddrinfo@PLT
	mov	DWORD PTR -696[rbp], eax
	cmp	DWORD PTR -696[rbp], 0
	je	.L3
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 13
	mov	esi, 1
	lea	rdi, .LC1[rip]
	call	fwrite@PLT
	mov	edi, 17
	call	exit@PLT
.L3:
	mov	rax, QWORD PTR -680[rbp]
	mov	QWORD PTR -664[rbp], rax
	jmp	.L4
.L9:
	mov	rax, QWORD PTR -664[rbp]
	mov	edx, DWORD PTR 12[rax]
	mov	rax, QWORD PTR -664[rbp]
	mov	ecx, DWORD PTR 8[rax]
	mov	rax, QWORD PTR -664[rbp]
	mov	eax, DWORD PTR 4[rax]
	mov	esi, ecx
	mov	edi, eax
	call	socket@PLT
	mov	DWORD PTR -708[rbp], eax
	cmp	DWORD PTR -708[rbp], -1
	jne	.L5
	lea	rdi, .LC2[rip]
	call	perror@PLT
	jmp	.L6
.L5:
	mov	rax, QWORD PTR -664[rbp]
	mov	edx, DWORD PTR 16[rax]
	mov	rax, QWORD PTR -664[rbp]
	mov	rcx, QWORD PTR 24[rax]
	mov	eax, DWORD PTR -708[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	connect@PLT
	mov	DWORD PTR -696[rbp], eax
	cmp	DWORD PTR -696[rbp], -1
	jne	.L19
	lea	rdi, .LC3[rip]
	call	perror@PLT
	nop
.L6:
	mov	rax, QWORD PTR -664[rbp]
	mov	rax, QWORD PTR 40[rax]
	mov	QWORD PTR -664[rbp], rax
.L4:
	cmp	QWORD PTR -664[rbp], 0
	jne	.L9
	jmp	.L8
.L19:
	nop
.L8:
	cmp	QWORD PTR -664[rbp], 0
	jne	.L10
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 72
	mov	esi, 1
	lea	rdi, .LC4[rip]
	call	fwrite@PLT
	mov	edi, 18
	call	exit@PLT
.L10:
	mov	rax, QWORD PTR -664[rbp]
	mov	rax, QWORD PTR 24[rax]
	movzx	eax, WORD PTR [rax]
	cmp	ax, 2
	jne	.L11
	mov	rax, QWORD PTR -664[rbp]
	mov	rax, QWORD PTR 24[rax]
	add	rax, 4
	mov	QWORD PTR -640[rbp], rax
	mov	rax, QWORD PTR -664[rbp]
	mov	eax, DWORD PTR 4[rax]
	lea	rdx, -560[rbp]
	mov	rsi, QWORD PTR -640[rbp]
	mov	ecx, 46
	mov	edi, eax
	call	inet_ntop@PLT
	lea	rax, -560[rbp]
	mov	rsi, rax
	lea	rdi, .LC5[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L12
.L11:
	mov	rax, QWORD PTR -664[rbp]
	mov	rax, QWORD PTR 24[rax]
	add	rax, 8
	mov	QWORD PTR -640[rbp], rax
	mov	rax, QWORD PTR -664[rbp]
	mov	eax, DWORD PTR 4[rax]
	lea	rdx, -560[rbp]
	mov	rsi, QWORD PTR -640[rbp]
	mov	ecx, 46
	mov	edi, eax
	call	inet_ntop@PLT
	lea	rax, -560[rbp]
	mov	rsi, rax
	lea	rdi, .LC5[rip]
	mov	eax, 0
	call	printf@PLT
.L12:
	mov	rax, QWORD PTR -680[rbp]
	mov	rdi, rax
	call	freeaddrinfo@PLT
	mov	QWORD PTR -656[rbp], 0
	mov	QWORD PTR -648[rbp], 0
	mov	DWORD PTR -692[rbp], 0
	mov	DWORD PTR -688[rbp], 0
	mov	DWORD PTR -704[rbp], 0
	mov	DWORD PTR -700[rbp], 0
	mov	DWORD PTR -684[rbp], 0
	mov	QWORD PTR -672[rbp], 0
	lea	rsi, -576[rbp]
	mov	eax, DWORD PTR -708[rbp]
	mov	ecx, 0
	mov	edx, 16
	mov	edi, eax
	call	recv@PLT
	mov	DWORD PTR -692[rbp], eax
	mov	eax, DWORD PTR -692[rbp]
	mov	esi, eax
	lea	rdi, .LC6[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rdi, .LC7[rip]
	call	puts@PLT
	lea	rax, -576[rbp]
	mov	QWORD PTR -648[rbp], rax
	jmp	.L13
.L14:
	mov	rax, QWORD PTR -648[rbp]
	mov	eax, DWORD PTR [rax]
	mov	edx, DWORD PTR -700[rbp]
	lea	ecx, 1[rdx]
	mov	edx, eax
	mov	esi, ecx
	lea	rdi, .LC8[rip]
	mov	eax, 0
	call	printf@PLT
	add	DWORD PTR -700[rbp], 1
	add	QWORD PTR -648[rbp], 4
.L13:
	cmp	DWORD PTR -700[rbp], 3
	jbe	.L14
	lea	rdi, .LC9[rip]
	call	puts@PLT
	lea	rax, -576[rbp]
	mov	QWORD PTR -656[rbp], rax
	jmp	.L15
.L16:
	mov	rax, QWORD PTR -656[rbp]
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	ntohl@PLT
	mov	DWORD PTR -684[rbp], eax
	mov	edx, DWORD PTR -684[rbp]
	mov	rax, QWORD PTR -672[rbp]
	add	rax, rdx
	mov	QWORD PTR -672[rbp], rax
	mov	eax, DWORD PTR -704[rbp]
	lea	ecx, 1[rax]
	mov	eax, DWORD PTR -684[rbp]
	mov	edx, eax
	mov	esi, ecx
	lea	rdi, .LC10[rip]
	mov	eax, 0
	call	printf@PLT
	add	DWORD PTR -704[rbp], 1
	add	QWORD PTR -656[rbp], 4
.L15:
	cmp	DWORD PTR -704[rbp], 3
	jbe	.L16
	mov	rax, QWORD PTR -672[rbp]
	mov	edx, 8
	mov	rsi, rax
	lea	rdi, .LC11[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rax, -672[rbp]
	mov	QWORD PTR -632[rbp], rax
	mov	rax, QWORD PTR -632[rbp]
	mov	rsi, rax
	lea	rdi, .LC12[rip]
	mov	eax, 0
	call	printf@PLT
	mov	rsi, QWORD PTR -632[rbp]
	mov	eax, DWORD PTR -708[rbp]
	mov	ecx, 0
	mov	edx, 8
	mov	edi, eax
	call	send@PLT
	mov	rax, QWORD PTR -632[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rsi, rax
	lea	rdi, .LC13[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rsi, -512[rbp]
	mov	eax, DWORD PTR -708[rbp]
	mov	ecx, 0
	mov	edx, 500
	mov	edi, eax
	call	recv@PLT
	mov	eax, 0
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L18
	call	__stack_chk_fail@PLT
.L18:
	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	"565241.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"Usage: %s <HOSTNAME> <PORT>\012\000"
	.align	2
.LC1:
	.ascii	"getaddrinfo: \000"
	.align	2
.LC2:
	.ascii	"socket: \000"
	.align	2
.LC3:
	.ascii	"connect: \000"
	.align	2
.LC4:
	.ascii	"client: failed to conect after parser reached NULL "
	.ascii	"(end of linked list)\012\000"
	.align	2
.LC5:
	.ascii	"Client: connected to %s\012\000"
	.align	2
.LC6:
	.ascii	"Recieved %d bytes\012\000"
	.align	2
.LC7:
	.ascii	"\012-=-=-=-=-= Values Recieved (in Network Byte Ord"
	.ascii	"er) =-=-=-=-=-\012\000"
	.align	2
.LC8:
	.ascii	"[-]Valuex%d : 0x%x\012\000"
	.align	2
.LC9:
	.ascii	"\012-=-=-=-=-= Values Converted (in Host Byte Order"
	.ascii	") =-=-=-=-=-\012\000"
	.align	2
.LC10:
	.ascii	"[+]Value%d : 0x%x\012\000"
	.align	2
.LC11:
	.ascii	"\012sum is : 0x%lx : %d\012\000"
	.align	2
.LC12:
	.ascii	"final payload : %s\012\000"
	.align	2
.LC13:
	.ascii	"\0120x%lx -----\000"
	.align	2
.LC14:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 672
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, r5, fp, lr}
	add	fp, sp, #12
	sub	sp, sp, #680
	str	r0, [fp, #-680]
	str	r1, [fp, #-684]
	ldr	r3, .L20
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	mov	r3, #0
	str	r3, [fp, #-672]
	mov	r3, #0
	str	r3, [fp, #-668]
	mov	r3, #0
	str	r3, [fp, #-664]
	mov	r3, #0
	str	r3, [fp, #-644]
	ldr	r3, [fp, #-680]
	cmp	r3, #3
	beq	.L2
	ldr	r3, .L20+4
	ldr	r0, [r3]
	ldr	r3, [fp, #-684]
	ldr	r3, [r3]
	mov	r2, r3
	ldr	r1, .L20+8
	bl	fprintf
	mov	r0, #16
	bl	exit
.L2:
	sub	r3, fp, #612
	mov	r2, #32
	mov	r1, #0
	mov	r0, r3
	bl	memset
	mov	r3, #0
	str	r3, [fp, #-608]
	mov	r3, #1
	str	r3, [fp, #-604]
	ldr	r3, [fp, #-684]
	add	r3, r3, #4
	ldr	r0, [r3]
	ldr	r3, [fp, #-684]
	add	r3, r3, #8
	ldr	r1, [r3]
	sub	r3, fp, #672
	sub	r2, fp, #612
	bl	getaddrinfo
	str	r0, [fp, #-644]
	ldr	r3, [fp, #-644]
	cmp	r3, #0
	beq	.L3
	ldr	r3, .L20+4
	ldr	r3, [r3]
	mov	r2, #13
	mov	r1, #1
	ldr	r0, .L20+12
	bl	fwrite
	mov	r0, #17
	bl	exit
.L3:
	ldr	r3, [fp, #-672]
	str	r3, [fp, #-668]
	b	.L4
.L9:
	ldr	r3, [fp, #-668]
	ldr	r0, [r3, #4]
	ldr	r3, [fp, #-668]
	ldr	r1, [r3, #8]
	ldr	r3, [fp, #-668]
	ldr	r3, [r3, #12]
	mov	r2, r3
	bl	socket
	str	r0, [fp, #-664]
	ldr	r3, [fp, #-664]
	cmn	r3, #1
	bne	.L5
	ldr	r0, .L20+16
	bl	perror
	b	.L6
.L5:
	ldr	r3, [fp, #-668]
	ldr	r1, [r3, #20]
	ldr	r3, [fp, #-668]
	ldr	r3, [r3, #16]
	mov	r2, r3
	ldr	r0, [fp, #-664]
	bl	connect
	str	r0, [fp, #-644]
	ldr	r3, [fp, #-644]
	cmn	r3, #1
	bne	.L19
	ldr	r0, .L20+20
	bl	perror
	nop
.L6:
	ldr	r3, [fp, #-668]
	ldr	r3, [r3, #28]
	str	r3, [fp, #-668]
.L4:
	ldr	r3, [fp, #-668]
	cmp	r3, #0
	bne	.L9
	b	.L8
.L19:
	nop
.L8:
	ldr	r3, [fp, #-668]
	cmp	r3, #0
	bne	.L10
	ldr	r3, .L20+4
	ldr	r3, [r3]
	mov	r2, #72
	mov	r1, #1
	ldr	r0, .L20+24
	bl	fwrite
	mov	r0, #18
	bl	exit
.L10:
	ldr	r3, [fp, #-668]
	ldr	r3, [r3, #20]
	ldrh	r3, [r3]
	cmp	r3, #2
	bne	.L11
	ldr	r3, [fp, #-668]
	ldr	r3, [r3, #20]
	add	r3, r3, #4
	str	r3, [fp, #-640]
	ldr	r3, [fp, #-668]
	ldr	r0, [r3, #4]
	sub	r2, fp, #564
	mov	r3, #46
	ldr	r1, [fp, #-640]
	bl	inet_ntop
	sub	r3, fp, #564
	mov	r1, r3
	ldr	r0, .L20+28
	bl	printf
	b	.L12
.L11:
	ldr	r3, [fp, #-668]
	ldr	r3, [r3, #20]
	add	r3, r3, #8
	str	r3, [fp, #-640]
	ldr	r3, [fp, #-668]
	ldr	r0, [r3, #4]
	sub	r2, fp, #564
	mov	r3, #46
	ldr	r1, [fp, #-640]
	bl	inet_ntop
	sub	r3, fp, #564
	mov	r1, r3
	ldr	r0, .L20+28
	bl	printf
.L12:
	ldr	r3, [fp, #-672]
	mov	r0, r3
	bl	freeaddrinfo
	mov	r3, #0
	str	r3, [fp, #-660]
	mov	r3, #0
	str	r3, [fp, #-656]
	mov	r3, #0
	str	r3, [fp, #-636]
	mov	r3, #0
	str	r3, [fp, #-632]
	mov	r3, #0
	str	r3, [fp, #-652]
	mov	r3, #0
	str	r3, [fp, #-648]
	mov	r3, #0
	str	r3, [fp, #-628]
	mov	r2, #0
	mov	r3, #0
	str	r2, [fp, #-620]
	str	r3, [fp, #-616]
	sub	r1, fp, #580
	mov	r3, #0
	mov	r2, #16
	ldr	r0, [fp, #-664]
	bl	recv
	mov	r3, r0
	str	r3, [fp, #-636]
	ldr	r1, [fp, #-636]
	ldr	r0, .L20+32
	bl	printf
	ldr	r0, .L20+36
	bl	puts
	sub	r3, fp, #580
	str	r3, [fp, #-656]
	b	.L13
.L14:
	ldr	r3, [fp, #-648]
	add	r1, r3, #1
	ldr	r3, [fp, #-656]
	ldr	r3, [r3]
	mov	r2, r3
	ldr	r0, .L20+40
	bl	printf
	ldr	r3, [fp, #-648]
	add	r3, r3, #1
	str	r3, [fp, #-648]
	ldr	r3, [fp, #-656]
	add	r3, r3, #4
	str	r3, [fp, #-656]
.L13:
	ldr	r3, [fp, #-648]
	cmp	r3, #3
	bls	.L14
	ldr	r0, .L20+44
	bl	puts
	sub	r3, fp, #580
	str	r3, [fp, #-660]
	b	.L15
.L16:
	ldr	r3, [fp, #-660]
	ldr	r3, [r3]
	mov	r0, r3
	bl	ntohl
	str	r0, [fp, #-628]
	ldr	r3, [fp, #-628]
	mov	r0, r3
	mov	r1, #0
	sub	r3, fp, #620
	ldmia	r3, {r2-r3}
	adds	r4, r0, r2
	adc	r5, r1, r3
	str	r4, [fp, #-620]
	str	r5, [fp, #-616]
	ldr	r3, [fp, #-652]
	add	r3, r3, #1
	ldr	r2, [fp, #-628]
	mov	r1, r3
	ldr	r0, .L20+48
	bl	printf
	ldr	r3, [fp, #-652]
	add	r3, r3, #1
	str	r3, [fp, #-652]
	ldr	r3, [fp, #-660]
	add	r3, r3, #4
	str	r3, [fp, #-660]
.L15:
	ldr	r3, [fp, #-652]
	cmp	r3, #3
	bls	.L16
	sub	r3, fp, #620
	ldmia	r3, {r2-r3}
	mov	r1, #8
	str	r1, [sp]
	ldr	r0, .L20+52
	bl	printf
	sub	r3, fp, #620
	str	r3, [fp, #-624]
	ldr	r1, [fp, #-624]
	ldr	r0, .L20+56
	bl	printf
	mov	r3, #0
	mov	r2, #4
	ldr	r1, [fp, #-624]
	ldr	r0, [fp, #-664]
	bl	send
	ldr	r3, [fp, #-624]
	ldmia	r3, {r2-r3}
	ldr	r0, .L20+60
	bl	printf
	sub	r1, fp, #516
	mov	r3, #0
	mov	r2, #500
	ldr	r0, [fp, #-664]
	bl	recv
	mov	r3, #0
	ldr	r2, .L20
	ldr	r1, [r2]
	ldr	r2, [fp, #-16]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L18
	bl	__stack_chk_fail
.L18:
	mov	r0, r3
	sub	sp, fp, #12
	@ sp needed
	pop	{r4, r5, fp, pc}
.L21:
	.align	2
.L20:
	.word	.LC14
	.word	stderr
	.word	.LC0
	.word	.LC1
	.word	.LC2
	.word	.LC3
	.word	.LC4
	.word	.LC5
	.word	.LC6
	.word	.LC7
	.word	.LC8
	.word	.LC9
	.word	.LC10
	.word	.LC11
	.word	.LC12
	.word	.LC13
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
