	.file	"646867.c"
	.intel_syntax noprefix
	.text
	.globl	flag
	.section	.rodata
.LC0:
	.string	"REDACTED"
	.section	.data.rel.local,"aw"
	.align 8
	.type	flag, @object
	.size	flag, 8
flag:
	.quad	.LC0
	.globl	buf
	.bss
	.align 32
	.type	buf, @object
	.size	buf, 50
buf:
	.zero	50
	.section	.rodata
	.align 8
.LC1:
	.string	"Welcome to the number guessing game!"
	.align 8
.LC2:
	.string	"Before we begin, please enter your name (40 chars max): "
	.align 8
.LC3:
	.string	"I'm thinking of two random numbers (0 to 1000000), can you tell me their sum?"
.LC4:
	.string	"%d"
.LC5:
	.string	"Congrats, here's a flag: %s\n"
	.align 8
.LC6:
	.string	"Sorry, the answer was %d. Try again :(\n"
	.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, 48
	mov	DWORD PTR -36[rbp], edi
	mov	QWORD PTR -48[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	lea	rdi, .LC1[rip]
	call	puts@PLT
	lea	rdi, .LC2[rip]
	call	puts@PLT
	mov	rax, QWORD PTR stdout[rip]
	mov	rdi, rax
	call	fflush@PLT
	mov	rax, QWORD PTR stdin[rip]
	mov	rdx, rax
	mov	esi, 40
	lea	rdi, buf[rip]
	call	fgets@PLT
	lea	rdi, buf[rip]
	call	strlen@PLT
	lea	rdx, -1[rax]
	lea	rax, buf[rip]
	mov	BYTE PTR [rdx+rax], 0
	lea	rdi, buf[rip]
	call	strlen@PLT
	mov	rdx, rax
	lea	rax, buf[rip]
	add	rax, rdx
	movabs	rsi, 8319104491599196967
	mov	QWORD PTR [rax], rsi
	mov	WORD PTR 8[rax], 8250
	mov	BYTE PTR 10[rax], 0
	lea	rdi, .LC3[rip]
	call	puts@PLT
	mov	edi, 0
	call	time@PLT
	mov	edi, eax
	call	srand@PLT
	call	rand@PLT
	movsx	rdx, eax
	imul	rdx, rdx, 1125899907
	shr	rdx, 32
	sar	edx, 18
	mov	ecx, eax
	sar	ecx, 31
	sub	edx, ecx
	mov	DWORD PTR -24[rbp], edx
	mov	edx, DWORD PTR -24[rbp]
	imul	edx, edx, 1000000
	sub	eax, edx
	mov	DWORD PTR -24[rbp], eax
	call	rand@PLT
	movsx	rdx, eax
	imul	rdx, rdx, 1125899907
	shr	rdx, 32
	sar	edx, 18
	mov	ecx, eax
	sar	ecx, 31
	sub	edx, ecx
	mov	DWORD PTR -20[rbp], edx
	mov	edx, DWORD PTR -20[rbp]
	imul	edx, edx, 1000000
	sub	eax, edx
	mov	DWORD PTR -20[rbp], eax
	lea	rdi, buf[rip]
	mov	eax, 0
	call	printf@PLT
	mov	rax, QWORD PTR stdout[rip]
	mov	rdi, rax
	call	fflush@PLT
	mov	rdx, QWORD PTR stdin[rip]
	lea	rax, -16[rbp]
	mov	esi, 8
	mov	rdi, rax
	call	fgets@PLT
	lea	rdx, -28[rbp]
	lea	rax, -16[rbp]
	lea	rsi, .LC4[rip]
	mov	rdi, rax
	mov	eax, 0
	call	__isoc99_sscanf@PLT
	mov	edx, DWORD PTR -24[rbp]
	mov	eax, DWORD PTR -20[rbp]
	add	edx, eax
	mov	eax, DWORD PTR -28[rbp]
	cmp	edx, eax
	jne	.L2
	mov	rax, QWORD PTR flag[rip]
	mov	rsi, rax
	lea	rdi, .LC5[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L3
.L2:
	mov	edx, DWORD PTR -24[rbp]
	mov	eax, DWORD PTR -20[rbp]
	add	eax, edx
	mov	esi, eax
	lea	rdi, .LC6[rip]
	mov	eax, 0
	call	printf@PLT
.L3:
	mov	rax, QWORD PTR stdout[rip]
	mov	rdi, rax
	call	fflush@PLT
	mov	eax, 0
	mov	rsi, QWORD PTR -8[rbp]
	sub	rsi, QWORD PTR fs:40
	je	.L5
	call	__stack_chk_fail@PLT
.L5:
	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	"646867.c"
	.text
	.global	flag
	.section	.rodata
	.align	2
.LC0:
	.ascii	"REDACTED\000"
	.data
	.align	2
	.type	flag, %object
	.size	flag, 4
flag:
	.word	.LC0
	.comm	buf,50,4
	.section	.rodata
	.align	2
.LC1:
	.ascii	"Welcome to the number guessing game!\000"
	.align	2
.LC2:
	.ascii	"Before we begin, please enter your name (40 chars m"
	.ascii	"ax): \000"
	.align	2
.LC3:
	.ascii	"'s guess: \000"
	.align	2
.LC4:
	.ascii	"I'm thinking of two random numbers (0 to 1000000), "
	.ascii	"can you tell me their sum?\000"
	.align	2
.LC5:
	.ascii	"%d\000"
	.align	2
.LC6:
	.ascii	"Congrats, here's a flag: %s\012\000"
	.align	2
.LC7:
	.ascii	"Sorry, the answer was %d. Try again :(\012\000"
	.align	2
.LC8:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ 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, .L6
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r0, .L6+4
	bl	puts
	ldr	r0, .L6+8
	bl	puts
	ldr	r3, .L6+12
	ldr	r3, [r3]
	mov	r0, r3
	bl	fflush
	ldr	r3, .L6+16
	ldr	r3, [r3]
	mov	r2, r3
	mov	r1, #40
	ldr	r0, .L6+20
	bl	fgets
	ldr	r0, .L6+20
	bl	strlen
	mov	r3, r0
	sub	r3, r3, #1
	ldr	r2, .L6+20
	mov	r1, #0
	strb	r1, [r2, r3]
	ldr	r0, .L6+20
	bl	strlen
	mov	r3, r0
	mov	r2, r3
	ldr	r3, .L6+20
	add	r3, r2, r3
	ldr	r2, .L6+24
	mov	r0, r3
	mov	r1, r2
	mov	r3, #11
	mov	r2, r3
	bl	memcpy
	ldr	r0, .L6+28
	bl	puts
	mov	r0, #0
	bl	time
	mov	r3, r0
	mov	r0, r3
	bl	srand
	bl	rand
	mov	r1, r0
	ldr	r3, .L6+32
	smull	r2, r3, r1, r3
	asr	r2, r3, #18
	asr	r3, r1, #31
	sub	r0, r2, r3
	mov	r2, r0
	lsl	r2, r2, #5
	sub	r2, r2, r0
	lsl	r3, r2, #6
	sub	r3, r3, r2
	lsl	r3, r3, #3
	add	r3, r3, r0
	lsl	r3, r3, #6
	sub	r3, r1, r3
	str	r3, [fp, #-24]
	bl	rand
	mov	r1, r0
	ldr	r3, .L6+32
	smull	r2, r3, r1, r3
	asr	r2, r3, #18
	asr	r3, r1, #31
	sub	r0, r2, r3
	mov	r2, r0
	lsl	r2, r2, #5
	sub	r2, r2, r0
	lsl	r3, r2, #6
	sub	r3, r3, r2
	lsl	r3, r3, #3
	add	r3, r3, r0
	lsl	r3, r3, #6
	sub	r3, r1, r3
	str	r3, [fp, #-20]
	ldr	r0, .L6+20
	bl	printf
	ldr	r3, .L6+12
	ldr	r3, [r3]
	mov	r0, r3
	bl	fflush
	ldr	r3, .L6+16
	ldr	r2, [r3]
	sub	r3, fp, #16
	mov	r1, #8
	mov	r0, r3
	bl	fgets
	sub	r2, fp, #28
	sub	r3, fp, #16
	ldr	r1, .L6+36
	mov	r0, r3
	bl	__isoc99_sscanf
	ldr	r2, [fp, #-24]
	ldr	r3, [fp, #-20]
	add	r2, r2, r3
	ldr	r3, [fp, #-28]
	cmp	r2, r3
	bne	.L2
	ldr	r3, .L6+40
	ldr	r3, [r3]
	mov	r1, r3
	ldr	r0, .L6+44
	bl	printf
	b	.L3
.L2:
	ldr	r2, [fp, #-24]
	ldr	r3, [fp, #-20]
	add	r3, r2, r3
	mov	r1, r3
	ldr	r0, .L6+48
	bl	printf
.L3:
	ldr	r3, .L6+12
	ldr	r3, [r3]
	mov	r0, r3
	bl	fflush
	mov	r3, #0
	ldr	r2, .L6
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L5
	bl	__stack_chk_fail
.L5:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L7:
	.align	2
.L6:
	.word	.LC8
	.word	.LC1
	.word	.LC2
	.word	stdout
	.word	stdin
	.word	buf
	.word	.LC3
	.word	.LC4
	.word	1125899907
	.word	.LC5
	.word	flag
	.word	.LC6
	.word	.LC7
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
