	.file	"394077.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	"DES initialization failed"
	.align 8
.LC1:
	.string	"Enter in hexadecimal:\nk <key>\np <plaintext>\nc <ciphertext>"
.LC2:
	.string	"s - standard DES mode"
.LC3:
	.string	"f - fast mode (no IP)"
.LC4:
	.string	"Enter key"
.LC5:
	.string	"Plaintext: "
.LC6:
	.string	"Ciphertext: "
.LC7:
	.string	"eh?"
	.text
	.globl	main
	.type	main, @function
main:
.LFB0:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	add	rsp, -128
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	DWORD PTR -116[rbp], 0
	mov	edi, 0
	mov	eax, 0
	call	desinit@PLT
	cmp	eax, -1
	jne	.L2
	lea	rdi, .LC0[rip]
	call	puts@PLT
	mov	edi, 1
	call	exit@PLT
.L2:
	lea	rdi, .LC1[rip]
	call	puts@PLT
	lea	rdi, .LC2[rip]
	call	puts@PLT
	lea	rdi, .LC3[rip]
	call	puts@PLT
.L18:
	lea	rax, -96[rbp]
	mov	rdi, rax
	mov	eax, 0
	call	gets@PLT
	mov	rax, QWORD PTR stdin[rip]
	mov	rdi, rax
	call	feof@PLT
	test	eax, eax
	jne	.L22
	call	__ctype_b_loc@PLT
	mov	rdx, QWORD PTR [rax]
	movzx	eax, BYTE PTR -96[rbp]
	movsx	rax, al
	add	rax, rax
	add	rax, rdx
	movzx	eax, WORD PTR [rax]
	movzx	eax, ax
	and	eax, 256
	test	eax, eax
	je	.L5
	movzx	eax, BYTE PTR -96[rbp]
	movsx	eax, al
	mov	edi, eax
	call	tolower@PLT
	mov	BYTE PTR -96[rbp], al
.L5:
	movzx	eax, BYTE PTR -96[rbp]
	movsx	eax, al
	sub	eax, 99
	cmp	eax, 16
	ja	.L6
	mov	eax, eax
	lea	rdx, 0[0+rax*4]
	lea	rax, .L8[rip]
	mov	eax, DWORD PTR [rdx+rax]
	cdqe
	lea	rdx, .L8[rip]
	add	rax, rdx
	notrack jmp	rax
	.section	.rodata
	.align 4
	.align 4
.L8:
	.long	.L12-.L8
	.long	.L6-.L8
	.long	.L6-.L8
	.long	.L11-.L8
	.long	.L6-.L8
	.long	.L6-.L8
	.long	.L6-.L8
	.long	.L6-.L8
	.long	.L10-.L8
	.long	.L6-.L8
	.long	.L6-.L8
	.long	.L6-.L8
	.long	.L6-.L8
	.long	.L9-.L8
	.long	.L6-.L8
	.long	.L6-.L8
	.long	.L7-.L8
	.text
.L7:
	mov	eax, 0
	call	desdone@PLT
	mov	edi, 0
	mov	eax, 0
	call	desinit@PLT
	cmp	DWORD PTR -116[rbp], 0
	je	.L23
	lea	rax, -112[rbp]
	mov	rdi, rax
	mov	eax, 0
	call	setkey@PLT
	jmp	.L23
.L11:
	mov	eax, 0
	call	desdone@PLT
	mov	edi, 1
	mov	eax, 0
	call	desinit@PLT
	cmp	DWORD PTR -116[rbp], 0
	je	.L24
	lea	rax, -112[rbp]
	mov	rdi, rax
	mov	eax, 0
	call	setkey@PLT
	jmp	.L24
.L10:
	lea	rax, -112[rbp]
	lea	rdx, -96[rbp]
	add	rdx, 1
	mov	rsi, rax
	mov	rdi, rdx
	mov	eax, 0
	call	get8
	lea	rax, -112[rbp]
	mov	rdi, rax
	mov	eax, 0
	call	setkey@PLT
	mov	DWORD PTR -116[rbp], 1
	jmp	.L14
.L12:
	cmp	DWORD PTR -116[rbp], 0
	jne	.L16
	lea	rdi, .LC4[rip]
	call	puts@PLT
	jmp	.L14
.L16:
	lea	rax, -104[rbp]
	lea	rdx, -96[rbp]
	add	rdx, 1
	mov	rsi, rax
	mov	rdi, rdx
	mov	eax, 0
	call	get8
	lea	rax, -104[rbp]
	mov	rdi, rax
	mov	eax, 0
	call	dedes@PLT
	lea	rdi, .LC5[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rax, -104[rbp]
	mov	rdi, rax
	mov	eax, 0
	call	put8
	mov	edi, 10
	call	putchar@PLT
	jmp	.L14
.L9:
	cmp	DWORD PTR -116[rbp], 0
	jne	.L17
	lea	rdi, .LC4[rip]
	call	puts@PLT
	jmp	.L14
.L17:
	lea	rax, -104[rbp]
	lea	rdx, -96[rbp]
	add	rdx, 1
	mov	rsi, rax
	mov	rdi, rdx
	mov	eax, 0
	call	get8
	lea	rax, -104[rbp]
	mov	rdi, rax
	mov	eax, 0
	call	endes@PLT
	lea	rdi, .LC6[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rax, -104[rbp]
	mov	rdi, rax
	mov	eax, 0
	call	put8
	mov	edi, 10
	call	putchar@PLT
	jmp	.L14
.L6:
	lea	rdi, .LC7[rip]
	call	puts@PLT
	jmp	.L14
.L23:
	nop
	jmp	.L18
.L24:
	nop
.L14:
	jmp	.L18
.L22:
	nop
	mov	eax, 0
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L20
	call	__stack_chk_fail@PLT
.L20:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	main, .-main
	.section	.rodata
.LC8:
	.string	"%2x%2x%2x%2x%2x%2x%2x%2x"
	.text
	.globl	get8
	.type	get8, @function
get8:
.LFB1:
	.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, 88
	.cfi_offset 3, -24
	mov	QWORD PTR -88[rbp], rdi
	mov	rbx, rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -24[rbp], rax
	xor	eax, eax
	lea	rax, -64[rbp]
	lea	r8, 12[rax]
	lea	rax, -64[rbp]
	lea	rdi, 8[rax]
	lea	rax, -64[rbp]
	lea	rcx, 4[rax]
	lea	rdx, -64[rbp]
	mov	rax, QWORD PTR -88[rbp]
	lea	rsi, -64[rbp]
	add	rsi, 28
	push	rsi
	lea	rsi, -64[rbp]
	add	rsi, 24
	push	rsi
	lea	rsi, -64[rbp]
	add	rsi, 20
	push	rsi
	lea	rsi, -64[rbp]
	add	rsi, 16
	push	rsi
	mov	r9, r8
	mov	r8, rdi
	lea	rsi, .LC8[rip]
	mov	rdi, rax
	mov	eax, 0
	call	__isoc99_sscanf@PLT
	add	rsp, 32
	mov	DWORD PTR -68[rbp], 0
	jmp	.L26
.L27:
	mov	eax, DWORD PTR -68[rbp]
	cdqe
	mov	edx, DWORD PTR -64[rbp+rax*4]
	mov	rax, rbx
	lea	rbx, 1[rax]
	mov	BYTE PTR [rax], dl
	add	DWORD PTR -68[rbp], 1
.L26:
	cmp	DWORD PTR -68[rbp], 7
	jle	.L27
	nop
	mov	rcx, QWORD PTR -24[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L28
	call	__stack_chk_fail@PLT
.L28:
	mov	rbx, QWORD PTR -8[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.size	get8, .-get8
	.section	.rodata
.LC9:
	.string	"%02x "
	.text
	.globl	put8
	.type	put8, @function
put8:
.LFB2:
	.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, 24
	.cfi_offset 3, -24
	mov	rbx, rdi
	mov	DWORD PTR -20[rbp], 0
	jmp	.L30
.L31:
	mov	rax, rbx
	lea	rbx, 1[rax]
	movzx	eax, BYTE PTR [rax]
	movsx	eax, al
	movzx	eax, al
	mov	esi, eax
	lea	rdi, .LC9[rip]
	mov	eax, 0
	call	printf@PLT
	add	DWORD PTR -20[rbp], 1
.L30:
	cmp	DWORD PTR -20[rbp], 7
	jle	.L31
	nop
	mov	rbx, QWORD PTR -8[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE2:
	.size	put8, .-put8
	.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	"394077.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"DES initialization failed\000"
	.align	2
.LC1:
	.ascii	"Enter in hexadecimal:\012k <key>\012p <plaintext>\012"
	.ascii	"c <ciphertext>\000"
	.align	2
.LC2:
	.ascii	"s - standard DES mode\000"
	.align	2
.LC3:
	.ascii	"f - fast mode (no IP)\000"
	.align	2
.LC4:
	.ascii	"Enter key\000"
	.align	2
.LC5:
	.ascii	"Plaintext: \000"
	.align	2
.LC6:
	.ascii	"Ciphertext: \000"
	.align	2
.LC7:
	.ascii	"eh?\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 = 104
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #104
	ldr	r3, .L25
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	mov	r3, #0
	str	r3, [fp, #-108]
	mov	r0, #0
	bl	desinit
	mov	r3, r0
	cmn	r3, #1
	bne	.L2
	ldr	r0, .L25+4
	bl	puts
	mov	r0, #1
	bl	exit
.L2:
	ldr	r0, .L25+8
	bl	puts
	ldr	r0, .L25+12
	bl	puts
	ldr	r0, .L25+16
	bl	puts
.L18:
	sub	r3, fp, #88
	mov	r0, r3
	bl	gets
	ldr	r3, .L25+20
	ldr	r3, [r3]
	mov	r0, r3
	bl	feof
	mov	r3, r0
	cmp	r3, #0
	bne	.L22
	bl	__ctype_b_loc
	mov	r3, r0
	ldr	r2, [r3]
	ldrb	r3, [fp, #-88]	@ zero_extendqisi2
	lsl	r3, r3, #1
	add	r3, r2, r3
	ldrh	r3, [r3]
	and	r3, r3, #256
	cmp	r3, #0
	beq	.L5
	ldrb	r3, [fp, #-88]	@ zero_extendqisi2
	mov	r0, r3
	bl	tolower
	mov	r3, r0
	and	r3, r3, #255
	strb	r3, [fp, #-88]
.L5:
	ldrb	r3, [fp, #-88]	@ zero_extendqisi2
	sub	r3, r3, #99
	cmp	r3, #16
	ldrls	pc, [pc, r3, asl #2]
	b	.L6
.L8:
	.word	.L12
	.word	.L6
	.word	.L6
	.word	.L11
	.word	.L6
	.word	.L6
	.word	.L6
	.word	.L6
	.word	.L10
	.word	.L6
	.word	.L6
	.word	.L6
	.word	.L6
	.word	.L9
	.word	.L6
	.word	.L6
	.word	.L7
.L7:
	bl	desdone
	mov	r0, #0
	bl	desinit
	ldr	r3, [fp, #-108]
	cmp	r3, #0
	beq	.L23
	sub	r3, fp, #104
	mov	r0, r3
	bl	setkey
	b	.L23
.L11:
	bl	desdone
	mov	r0, #1
	bl	desinit
	ldr	r3, [fp, #-108]
	cmp	r3, #0
	beq	.L24
	sub	r3, fp, #104
	mov	r0, r3
	bl	setkey
	b	.L24
.L10:
	sub	r2, fp, #104
	sub	r3, fp, #88
	add	r3, r3, #1
	mov	r1, r2
	mov	r0, r3
	bl	get8
	sub	r3, fp, #104
	mov	r0, r3
	bl	setkey
	mov	r3, #1
	str	r3, [fp, #-108]
	b	.L14
.L12:
	ldr	r3, [fp, #-108]
	cmp	r3, #0
	bne	.L16
	ldr	r0, .L25+24
	bl	puts
	b	.L14
.L16:
	sub	r2, fp, #96
	sub	r3, fp, #88
	add	r3, r3, #1
	mov	r1, r2
	mov	r0, r3
	bl	get8
	sub	r3, fp, #96
	mov	r0, r3
	bl	dedes
	ldr	r0, .L25+28
	bl	printf
	sub	r3, fp, #96
	mov	r0, r3
	bl	put8
	mov	r0, #10
	bl	putchar
	b	.L14
.L9:
	ldr	r3, [fp, #-108]
	cmp	r3, #0
	bne	.L17
	ldr	r0, .L25+24
	bl	puts
	b	.L14
.L17:
	sub	r2, fp, #96
	sub	r3, fp, #88
	add	r3, r3, #1
	mov	r1, r2
	mov	r0, r3
	bl	get8
	sub	r3, fp, #96
	mov	r0, r3
	bl	endes
	ldr	r0, .L25+32
	bl	printf
	sub	r3, fp, #96
	mov	r0, r3
	bl	put8
	mov	r0, #10
	bl	putchar
	b	.L14
.L6:
	ldr	r0, .L25+36
	bl	puts
	b	.L14
.L23:
	nop
	b	.L18
.L24:
	nop
.L14:
	b	.L18
.L22:
	nop
	mov	r3, #0
	ldr	r2, .L25
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L20
	bl	__stack_chk_fail
.L20:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L26:
	.align	2
.L25:
	.word	.LC8
	.word	.LC0
	.word	.LC1
	.word	.LC2
	.word	.LC3
	.word	stdin
	.word	.LC4
	.word	.LC5
	.word	.LC6
	.word	.LC7
	.size	main, .-main
	.section	.rodata
	.align	2
.LC9:
	.ascii	"%2x%2x%2x%2x%2x%2x%2x%2x\000"
	.align	2
.LC10:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	get8
	.syntax unified
	.arm
	.fpu softvfp
	.type	get8, %function
get8:
	@ args = 0, pretend = 0, frame = 48
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #76
	str	r0, [fp, #-56]
	mov	r4, r1
	ldr	r3, .L31
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	sub	r3, fp, #48
	add	r1, r3, #4
	sub	r2, fp, #48
	sub	r3, fp, #48
	add	r3, r3, #28
	str	r3, [sp, #20]
	sub	r3, fp, #48
	add	r3, r3, #24
	str	r3, [sp, #16]
	sub	r3, fp, #48
	add	r3, r3, #20
	str	r3, [sp, #12]
	sub	r3, fp, #48
	add	r3, r3, #16
	str	r3, [sp, #8]
	sub	r3, fp, #48
	add	r3, r3, #12
	str	r3, [sp, #4]
	sub	r3, fp, #48
	add	r3, r3, #8
	str	r3, [sp]
	mov	r3, r1
	ldr	r1, .L31+4
	ldr	r0, [fp, #-56]
	bl	__isoc99_sscanf
	mov	r3, #0
	str	r3, [fp, #-52]
	b	.L28
.L29:
	ldr	r3, [fp, #-52]
	lsl	r3, r3, #2
	sub	r2, fp, #12
	add	r3, r2, r3
	ldr	r2, [r3, #-36]
	mov	r3, r4
	add	r4, r3, #1
	and	r2, r2, #255
	strb	r2, [r3]
	ldr	r3, [fp, #-52]
	add	r3, r3, #1
	str	r3, [fp, #-52]
.L28:
	ldr	r3, [fp, #-52]
	cmp	r3, #7
	ble	.L29
	nop
	ldr	r2, .L31
	ldr	r1, [r2]
	ldr	r2, [fp, #-16]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L30
	bl	__stack_chk_fail
.L30:
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L32:
	.align	2
.L31:
	.word	.LC10
	.word	.LC9
	.size	get8, .-get8
	.section	.rodata
	.align	2
.LC11:
	.ascii	"%02x \000"
	.text
	.align	2
	.global	put8
	.syntax unified
	.arm
	.fpu softvfp
	.type	put8, %function
put8:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #12
	mov	r4, r0
	mov	r3, #0
	str	r3, [fp, #-16]
	b	.L34
.L35:
	mov	r3, r4
	add	r4, r3, #1
	ldrb	r3, [r3]	@ zero_extendqisi2
	mov	r1, r3
	ldr	r0, .L36
	bl	printf
	ldr	r3, [fp, #-16]
	add	r3, r3, #1
	str	r3, [fp, #-16]
.L34:
	ldr	r3, [fp, #-16]
	cmp	r3, #7
	ble	.L35
	nop
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L37:
	.align	2
.L36:
	.word	.LC11
	.size	put8, .-put8
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
