	.file	"844103.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	"XOAUTH"
.LC1:
	.string	"SMTPUTF8"
	.align 8
.LC2:
	.string	"Usage: %s output-filename port\n"
.LC3:
	.string	"w"
	.align 8
.LC4:
	.string	"Unable to open output file \"%s\": %s\n"
.LC5:
	.string	"/tmp/fakesmtp.pid"
	.align 8
.LC6:
	.string	"220 Not really an ESMTP server"
.LC7:
	.string	"."
.LC8:
	.string	"250 Thanks for the info!"
.LC9:
	.string	"535 Not no way, not no how!"
.LC10:
	.string	"QUIT"
.LC11:
	.string	"221 Later alligator!"
.LC12:
	.string	"DATA"
.LC13:
	.string	"354 Go ahead"
.LC14:
	.string	"EHLO"
.LC15:
	.string	"250-ready"
.LC16:
	.string	"250-8BITMIME"
.LC17:
	.string	"250-SMTPUTF8"
.LC18:
	.string	"250-AUTH XOAUTH2"
	.align 8
.LC19:
	.string	"250 I'll buy that for a dollar!"
.LC20:
	.string	"AUTH"
.LC21:
	.string	"AUTH XOAUTH2"
.LC22:
	.string	"235 OK come in"
.LC23:
	.string	"334 base64-json-err"
	.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, 1104
	mov	DWORD PTR -1092[rbp], edi
	mov	QWORD PTR -1104[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	lea	rdi, .LC0[rip]
	call	getenv@PLT
	mov	QWORD PTR -1056[rbp], rax
	lea	rdi, .LC1[rip]
	call	getenv@PLT
	mov	QWORD PTR -1048[rbp], rax
	cmp	DWORD PTR -1092[rbp], 3
	je	.L2
	mov	rax, QWORD PTR -1104[rbp]
	mov	rdx, QWORD PTR [rax]
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC2[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
.L2:
	mov	rax, QWORD PTR -1104[rbp]
	add	rax, 8
	mov	rax, QWORD PTR [rax]
	lea	rsi, .LC3[rip]
	mov	rdi, rax
	call	fopen@PLT
	mov	QWORD PTR -1064[rbp], rax
	cmp	QWORD PTR -1064[rbp], 0
	jne	.L3
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rcx, rax
	mov	rax, QWORD PTR -1104[rbp]
	add	rax, 8
	mov	rdx, QWORD PTR [rax]
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC4[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
.L3:
	mov	rax, QWORD PTR -1104[rbp]
	add	rax, 16
	mov	rax, QWORD PTR [rax]
	mov	rsi, rax
	lea	rdi, .LC5[rip]
	call	serve@PLT
	mov	DWORD PTR -1072[rbp], eax
	mov	eax, DWORD PTR -1072[rbp]
	lea	rsi, .LC6[rip]
	mov	edi, eax
	call	putcrlf@PLT
	mov	DWORD PTR -1076[rbp], 0
.L21:
	lea	rdx, -1040[rbp]
	mov	eax, DWORD PTR -1072[rbp]
	mov	rsi, rdx
	mov	edi, eax
	call	getsmtp
	mov	DWORD PTR -1068[rbp], eax
	cmp	DWORD PTR -1068[rbp], -1
	je	.L24
	mov	rdx, QWORD PTR -1064[rbp]
	lea	rax, -1040[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	fputs@PLT
	mov	rax, QWORD PTR -1064[rbp]
	mov	rsi, rax
	mov	edi, 10
	call	putc@PLT
	cmp	DWORD PTR -1076[rbp], 1
	je	.L6
	cmp	DWORD PTR -1076[rbp], 2
	je	.L7
	jmp	.L23
.L6:
	lea	rax, -1040[rbp]
	lea	rsi, .LC7[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L25
	mov	DWORD PTR -1076[rbp], 0
	mov	eax, DWORD PTR -1072[rbp]
	lea	rsi, .LC8[rip]
	mov	edi, eax
	call	putcrlf@PLT
	jmp	.L25
.L7:
	mov	DWORD PTR -1076[rbp], 0
	mov	eax, DWORD PTR -1072[rbp]
	lea	rsi, .LC9[rip]
	mov	edi, eax
	call	putcrlf@PLT
	jmp	.L18
.L23:
	lea	rax, -1040[rbp]
	lea	rsi, .LC10[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L11
	mov	rax, QWORD PTR -1064[rbp]
	mov	rdi, rax
	call	fclose@PLT
	mov	QWORD PTR -1064[rbp], 0
	mov	eax, DWORD PTR -1072[rbp]
	lea	rsi, .LC11[rip]
	mov	edi, eax
	call	putcrlf@PLT
	mov	eax, DWORD PTR -1072[rbp]
	mov	edi, eax
	call	close@PLT
	jmp	.L5
.L11:
	lea	rax, -1040[rbp]
	lea	rsi, .LC12[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L12
	mov	eax, DWORD PTR -1072[rbp]
	lea	rsi, .LC13[rip]
	mov	edi, eax
	call	putcrlf@PLT
	mov	DWORD PTR -1076[rbp], 1
	jmp	.L18
.L12:
	lea	rax, -1040[rbp]
	mov	edx, 4
	lea	rsi, .LC14[rip]
	mov	rdi, rax
	call	strncmp@PLT
	test	eax, eax
	jne	.L13
	mov	eax, DWORD PTR -1072[rbp]
	lea	rsi, .LC15[rip]
	mov	edi, eax
	call	putcrlf@PLT
	cmp	QWORD PTR -1048[rbp], 0
	je	.L14
	mov	eax, DWORD PTR -1072[rbp]
	lea	rsi, .LC16[rip]
	mov	edi, eax
	call	putcrlf@PLT
	mov	eax, DWORD PTR -1072[rbp]
	lea	rsi, .LC17[rip]
	mov	edi, eax
	call	putcrlf@PLT
.L14:
	cmp	QWORD PTR -1056[rbp], 0
	je	.L15
	mov	eax, DWORD PTR -1072[rbp]
	lea	rsi, .LC18[rip]
	mov	edi, eax
	call	putcrlf@PLT
.L15:
	mov	eax, DWORD PTR -1072[rbp]
	lea	rsi, .LC19[rip]
	mov	edi, eax
	call	putcrlf@PLT
	jmp	.L18
.L13:
	cmp	QWORD PTR -1056[rbp], 0
	je	.L16
	lea	rax, -1040[rbp]
	mov	edx, 4
	lea	rsi, .LC20[rip]
	mov	rdi, rax
	call	strncmp@PLT
	test	eax, eax
	jne	.L16
	lea	rax, -1040[rbp]
	mov	edx, 12
	lea	rsi, .LC21[rip]
	mov	rdi, rax
	call	strncmp@PLT
	test	eax, eax
	jne	.L17
	mov	rdx, QWORD PTR -1056[rbp]
	lea	rax, -1040[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	strstr@PLT
	test	rax, rax
	je	.L17
	mov	eax, DWORD PTR -1072[rbp]
	lea	rsi, .LC22[rip]
	mov	edi, eax
	call	putcrlf@PLT
	jmp	.L18
.L17:
	mov	eax, DWORD PTR -1072[rbp]
	lea	rsi, .LC23[rip]
	mov	edi, eax
	call	putcrlf@PLT
	mov	DWORD PTR -1076[rbp], 2
	jmp	.L18
.L16:
	mov	eax, DWORD PTR -1072[rbp]
	lea	rsi, .LC19[rip]
	mov	edi, eax
	call	putcrlf@PLT
	jmp	.L21
.L24:
	nop
.L5:
	cmp	QWORD PTR -1064[rbp], 0
	jne	.L19
	jmp	.L20
.L25:
	nop
.L18:
	jmp	.L21
.L19:
	mov	rax, QWORD PTR -1064[rbp]
	mov	rdi, rax
	call	fclose@PLT
.L20:
	mov	edi, 0
	call	exit@PLT
	.cfi_endproc
.LFE6:
	.size	main, .-main
	.section	.rodata
	.align 8
.LC24:
	.string	"Buffer overflow in getsmtp()!\n"
.LC25:
	.string	"Read failed: %s\n"
	.text
	.type	getsmtp, @function
getsmtp:
.LFB7:
	.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
.L33:
	mov	eax, DWORD PTR bytesinbuf.2[rip]
	test	eax, eax
	je	.L27
	mov	esi, 13
	lea	rdi, buffer.1[rip]
	call	strchr@PLT
	mov	QWORD PTR p.0[rip], rax
	mov	rax, QWORD PTR p.0[rip]
	test	rax, rax
	je	.L27
	mov	rax, QWORD PTR p.0[rip]
	add	rax, 1
	movzx	eax, BYTE PTR [rax]
	cmp	al, 10
	jne	.L27
	mov	rax, QWORD PTR p.0[rip]
	mov	BYTE PTR [rax], 0
	mov	rax, QWORD PTR -32[rbp]
	mov	edx, 1024
	lea	rsi, buffer.1[rip]
	mov	rdi, rax
	call	strncpy@PLT
	mov	rax, QWORD PTR -32[rbp]
	add	rax, 1023
	mov	BYTE PTR [rax], 0
	lea	rdi, buffer.1[rip]
	call	strlen@PLT
	mov	DWORD PTR -4[rbp], eax
	mov	eax, DWORD PTR bytesinbuf.2[rip]
	mov	edx, DWORD PTR -4[rbp]
	sub	eax, edx
	sub	eax, 2
	mov	DWORD PTR bytesinbuf.2[rip], eax
	mov	eax, DWORD PTR bytesinbuf.2[rip]
	test	eax, eax
	je	.L28
	mov	eax, DWORD PTR bytesinbuf.2[rip]
	mov	edx, eax
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rcx, 2[rax]
	lea	rax, buffer.1[rip]
	add	rax, rcx
	mov	rsi, rax
	lea	rdi, buffer.1[rip]
	call	memmove@PLT
.L28:
	mov	eax, DWORD PTR -4[rbp]
	jmp	.L29
.L27:
	mov	eax, DWORD PTR bytesinbuf.2[rip]
	cmp	eax, 2047
	jbe	.L30
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 30
	mov	esi, 1
	lea	rdi, .LC24[rip]
	call	fwrite@PLT
	mov	edi, 1
	call	exit@PLT
.L30:
	mov	eax, DWORD PTR bytesinbuf.2[rip]
	mov	ecx, eax
	mov	eax, 2048
	sub	rax, rcx
	mov	rdx, rax
	mov	eax, DWORD PTR bytesinbuf.2[rip]
	mov	ecx, eax
	lea	rax, buffer.1[rip]
	add	rax, rcx
	mov	esi, 0
	mov	rdi, rax
	call	memset@PLT
	mov	eax, DWORD PTR bytesinbuf.2[rip]
	mov	ecx, eax
	mov	eax, 2048
	sub	rax, rcx
	mov	rdx, rax
	mov	eax, DWORD PTR bytesinbuf.2[rip]
	mov	ecx, eax
	lea	rax, buffer.1[rip]
	add	rcx, rax
	mov	eax, DWORD PTR -20[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	read@PLT
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], 0
	jns	.L31
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC25[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
.L31:
	cmp	DWORD PTR -4[rbp], 0
	jne	.L32
	mov	eax, -1
	jmp	.L29
.L32:
	mov	edx, DWORD PTR bytesinbuf.2[rip]
	mov	eax, DWORD PTR -4[rbp]
	add	eax, edx
	mov	DWORD PTR bytesinbuf.2[rip], eax
	jmp	.L33
.L29:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	getsmtp, .-getsmtp
	.local	bytesinbuf.2
	.comm	bytesinbuf.2,4,4
	.local	buffer.1
	.comm	buffer.1,2048,32
	.local	p.0
	.comm	p.0,8,8
	.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	"844103.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"XOAUTH\000"
	.align	2
.LC1:
	.ascii	"SMTPUTF8\000"
	.align	2
.LC2:
	.ascii	"Usage: %s output-filename port\012\000"
	.align	2
.LC3:
	.ascii	"w\000"
	.align	2
.LC4:
	.ascii	"Unable to open output file \"%s\": %s\012\000"
	.align	2
.LC5:
	.ascii	"/tmp/fakesmtp.pid\000"
	.align	2
.LC6:
	.ascii	"220 Not really an ESMTP server\000"
	.align	2
.LC7:
	.ascii	".\000"
	.align	2
.LC8:
	.ascii	"250 Thanks for the info!\000"
	.align	2
.LC9:
	.ascii	"535 Not no way, not no how!\000"
	.align	2
.LC10:
	.ascii	"QUIT\000"
	.align	2
.LC11:
	.ascii	"221 Later alligator!\000"
	.align	2
.LC12:
	.ascii	"DATA\000"
	.align	2
.LC13:
	.ascii	"354 Go ahead\000"
	.align	2
.LC14:
	.ascii	"EHLO\000"
	.align	2
.LC15:
	.ascii	"250-ready\000"
	.align	2
.LC16:
	.ascii	"250-8BITMIME\000"
	.align	2
.LC17:
	.ascii	"250-SMTPUTF8\000"
	.align	2
.LC18:
	.ascii	"250-AUTH XOAUTH2\000"
	.align	2
.LC19:
	.ascii	"250 I'll buy that for a dollar!\000"
	.align	2
.LC20:
	.ascii	"AUTH\000"
	.align	2
.LC21:
	.ascii	"AUTH XOAUTH2\000"
	.align	2
.LC22:
	.ascii	"235 OK come in\000"
	.align	2
.LC23:
	.ascii	"334 base64-json-err\000"
	.align	2
.LC24:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 1064
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, r5, fp, lr}
	add	fp, sp, #12
	sub	sp, sp, #1056
	sub	sp, sp, #8
	str	r0, [fp, #-1072]
	str	r1, [fp, #-1076]
	ldr	r3, .L26
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	ldr	r0, .L26+4
	bl	getenv
	str	r0, [fp, #-1056]
	ldr	r0, .L26+8
	bl	getenv
	str	r0, [fp, #-1052]
	ldr	r3, [fp, #-1072]
	cmp	r3, #3
	beq	.L2
	ldr	r3, .L26+12
	ldr	r0, [r3]
	ldr	r3, [fp, #-1076]
	ldr	r3, [r3]
	mov	r2, r3
	ldr	r1, .L26+16
	bl	fprintf
	mov	r0, #1
	bl	exit
.L2:
	ldr	r3, [fp, #-1076]
	add	r3, r3, #4
	ldr	r3, [r3]
	ldr	r1, .L26+20
	mov	r0, r3
	bl	fopen
	str	r0, [fp, #-1060]
	ldr	r3, [fp, #-1060]
	cmp	r3, #0
	bne	.L3
	ldr	r3, .L26+12
	ldr	r4, [r3]
	ldr	r3, [fp, #-1076]
	add	r3, r3, #4
	ldr	r5, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r5
	ldr	r1, .L26+24
	mov	r0, r4
	bl	fprintf
	mov	r0, #1
	bl	exit
.L3:
	ldr	r3, [fp, #-1076]
	add	r3, r3, #8
	ldr	r3, [r3]
	mov	r1, r3
	ldr	r0, .L26+28
	bl	serve
	str	r0, [fp, #-1048]
	ldr	r1, .L26+32
	ldr	r0, [fp, #-1048]
	bl	putcrlf
	mov	r3, #0
	str	r3, [fp, #-1064]
.L21:
	sub	r3, fp, #1024
	sub	r3, r3, #12
	sub	r3, r3, #4
	mov	r1, r3
	ldr	r0, [fp, #-1048]
	bl	getsmtp
	str	r0, [fp, #-1044]
	ldr	r3, [fp, #-1044]
	cmn	r3, #1
	beq	.L24
	sub	r3, fp, #1024
	sub	r3, r3, #12
	sub	r3, r3, #4
	ldr	r1, [fp, #-1060]
	mov	r0, r3
	bl	fputs
	ldr	r1, [fp, #-1060]
	mov	r0, #10
	bl	putc
	ldr	r3, [fp, #-1064]
	cmp	r3, #1
	beq	.L6
	ldr	r3, [fp, #-1064]
	cmp	r3, #2
	beq	.L7
	b	.L23
.L6:
	sub	r3, fp, #1024
	sub	r3, r3, #12
	sub	r3, r3, #4
	ldr	r1, .L26+36
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L25
	mov	r3, #0
	str	r3, [fp, #-1064]
	ldr	r1, .L26+40
	ldr	r0, [fp, #-1048]
	bl	putcrlf
	b	.L25
.L7:
	mov	r3, #0
	str	r3, [fp, #-1064]
	ldr	r1, .L26+44
	ldr	r0, [fp, #-1048]
	bl	putcrlf
	b	.L18
.L23:
	sub	r3, fp, #1024
	sub	r3, r3, #12
	sub	r3, r3, #4
	ldr	r1, .L26+48
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L11
	ldr	r0, [fp, #-1060]
	bl	fclose
	mov	r3, #0
	str	r3, [fp, #-1060]
	ldr	r1, .L26+52
	ldr	r0, [fp, #-1048]
	bl	putcrlf
	ldr	r0, [fp, #-1048]
	bl	close
	b	.L5
.L11:
	sub	r3, fp, #1024
	sub	r3, r3, #12
	sub	r3, r3, #4
	ldr	r1, .L26+56
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L12
	ldr	r1, .L26+60
	ldr	r0, [fp, #-1048]
	bl	putcrlf
	mov	r3, #1
	str	r3, [fp, #-1064]
	b	.L18
.L12:
	sub	r3, fp, #1024
	sub	r3, r3, #12
	sub	r3, r3, #4
	mov	r2, #4
	ldr	r1, .L26+64
	mov	r0, r3
	bl	strncmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L13
	ldr	r1, .L26+68
	ldr	r0, [fp, #-1048]
	bl	putcrlf
	ldr	r3, [fp, #-1052]
	cmp	r3, #0
	beq	.L14
	ldr	r1, .L26+72
	ldr	r0, [fp, #-1048]
	bl	putcrlf
	ldr	r1, .L26+76
	ldr	r0, [fp, #-1048]
	bl	putcrlf
.L14:
	ldr	r3, [fp, #-1056]
	cmp	r3, #0
	beq	.L15
	ldr	r1, .L26+80
	ldr	r0, [fp, #-1048]
	bl	putcrlf
.L15:
	ldr	r1, .L26+84
	ldr	r0, [fp, #-1048]
	bl	putcrlf
	b	.L18
.L13:
	ldr	r3, [fp, #-1056]
	cmp	r3, #0
	beq	.L16
	sub	r3, fp, #1024
	sub	r3, r3, #12
	sub	r3, r3, #4
	mov	r2, #4
	ldr	r1, .L26+88
	mov	r0, r3
	bl	strncmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L16
	sub	r3, fp, #1024
	sub	r3, r3, #12
	sub	r3, r3, #4
	mov	r2, #12
	ldr	r1, .L26+92
	mov	r0, r3
	bl	strncmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L17
	sub	r3, fp, #1024
	sub	r3, r3, #12
	sub	r3, r3, #4
	ldr	r1, [fp, #-1056]
	mov	r0, r3
	bl	strstr
	mov	r3, r0
	cmp	r3, #0
	beq	.L17
	ldr	r1, .L26+96
	ldr	r0, [fp, #-1048]
	bl	putcrlf
	b	.L18
.L17:
	ldr	r1, .L26+100
	ldr	r0, [fp, #-1048]
	bl	putcrlf
	mov	r3, #2
	str	r3, [fp, #-1064]
	b	.L18
.L16:
	ldr	r1, .L26+84
	ldr	r0, [fp, #-1048]
	bl	putcrlf
	b	.L21
.L24:
	nop
.L5:
	ldr	r3, [fp, #-1060]
	cmp	r3, #0
	bne	.L19
	b	.L20
.L25:
	nop
.L18:
	b	.L21
.L19:
	ldr	r0, [fp, #-1060]
	bl	fclose
.L20:
	mov	r0, #0
	bl	exit
.L27:
	.align	2
.L26:
	.word	.LC24
	.word	.LC0
	.word	.LC1
	.word	stderr
	.word	.LC2
	.word	.LC3
	.word	.LC4
	.word	.LC5
	.word	.LC6
	.word	.LC7
	.word	.LC8
	.word	.LC9
	.word	.LC10
	.word	.LC11
	.word	.LC12
	.word	.LC13
	.word	.LC14
	.word	.LC15
	.word	.LC16
	.word	.LC17
	.word	.LC18
	.word	.LC19
	.word	.LC20
	.word	.LC21
	.word	.LC22
	.word	.LC23
	.size	main, .-main
	.section	.rodata
	.align	2
.LC25:
	.ascii	"Buffer overflow in getsmtp()!\012\000"
	.align	2
.LC26:
	.ascii	"Read failed: %s\012\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	getsmtp, %function
getsmtp:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #20
	str	r0, [fp, #-24]
	str	r1, [fp, #-28]
.L35:
	ldr	r3, .L36
	ldr	r3, [r3]
	cmp	r3, #0
	beq	.L29
	mov	r1, #13
	ldr	r0, .L36+4
	bl	strchr
	mov	r3, r0
	ldr	r2, .L36+8
	str	r3, [r2]
	ldr	r3, .L36+8
	ldr	r3, [r3]
	cmp	r3, #0
	beq	.L29
	ldr	r3, .L36+8
	ldr	r3, [r3]
	add	r3, r3, #1
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #10
	bne	.L29
	ldr	r3, .L36+8
	ldr	r3, [r3]
	mov	r2, #0
	strb	r2, [r3]
	mov	r2, #1024
	ldr	r1, .L36+4
	ldr	r0, [fp, #-28]
	bl	strncpy
	ldr	r3, [fp, #-28]
	add	r3, r3, #1020
	add	r3, r3, #3
	mov	r2, #0
	strb	r2, [r3]
	ldr	r0, .L36+4
	bl	strlen
	mov	r3, r0
	str	r3, [fp, #-16]
	ldr	r3, .L36
	ldr	r2, [r3]
	ldr	r3, [fp, #-16]
	sub	r3, r2, r3
	sub	r3, r3, #2
	ldr	r2, .L36
	str	r3, [r2]
	ldr	r3, .L36
	ldr	r3, [r3]
	cmp	r3, #0
	beq	.L30
	ldr	r3, [fp, #-16]
	add	r3, r3, #2
	ldr	r2, .L36+4
	add	r3, r3, r2
	ldr	r2, .L36
	ldr	r2, [r2]
	mov	r1, r3
	ldr	r0, .L36+4
	bl	memmove
.L30:
	ldr	r3, [fp, #-16]
	b	.L31
.L29:
	ldr	r3, .L36
	ldr	r3, [r3]
	cmp	r3, #2048
	bcc	.L32
	ldr	r3, .L36+12
	ldr	r3, [r3]
	mov	r2, #30
	mov	r1, #1
	ldr	r0, .L36+16
	bl	fwrite
	mov	r0, #1
	bl	exit
.L32:
	ldr	r3, .L36
	ldr	r3, [r3]
	ldr	r2, .L36+4
	add	r0, r3, r2
	ldr	r3, .L36
	ldr	r3, [r3]
	rsb	r3, r3, #2048
	mov	r2, r3
	mov	r1, #0
	bl	memset
	ldr	r3, .L36
	ldr	r3, [r3]
	ldr	r2, .L36+4
	add	r1, r3, r2
	ldr	r3, .L36
	ldr	r3, [r3]
	rsb	r3, r3, #2048
	mov	r2, r3
	ldr	r0, [fp, #-24]
	bl	read
	str	r0, [fp, #-16]
	ldr	r3, [fp, #-16]
	cmp	r3, #0
	bge	.L33
	ldr	r3, .L36+12
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L36+20
	mov	r0, r4
	bl	fprintf
	mov	r0, #1
	bl	exit
.L33:
	ldr	r3, [fp, #-16]
	cmp	r3, #0
	bne	.L34
	mvn	r3, #0
	b	.L31
.L34:
	ldr	r3, .L36
	ldr	r2, [r3]
	ldr	r3, [fp, #-16]
	add	r3, r2, r3
	ldr	r2, .L36
	str	r3, [r2]
	b	.L35
.L31:
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L37:
	.align	2
.L36:
	.word	bytesinbuf.6238
	.word	buffer.6239
	.word	p.6240
	.word	stderr
	.word	.LC25
	.word	.LC26
	.size	getsmtp, .-getsmtp
	.local	bytesinbuf.6238
	.comm	bytesinbuf.6238,4,4
	.local	buffer.6239
	.comm	buffer.6239,2048,4
	.local	p.6240
	.comm	p.6240,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
