I forgot my linux password. I have access to the shadow file (Fedora 33), and I believe it should be possible to retrieve it with John the Ripper as I remember the first 4 characters, I remember the last 5 characters, I just can't connect them anymore (must be 3 or 4 char in the middle).

Can I use John for that? What would be the command? Thanks!

  • maybe you should use any script language to generate all password matching your description and use it with john --wordlist=password.lst
    – furas
    Commented May 13, 2021 at 21:50
  • 2
    Take a look at MASK mode. Relevant: security.stackexchange.com/a/114773/235964
    – nobody
    Commented May 13, 2021 at 22:08
  • 1
    Yea I get it to work with MASK, thanks. I think the version of John I was trying to use didn't seem to support MASK, not fully sure. Anyway, couldn't crack my own password, turns out I got the end wrong. I ended up installing a key logger because I noticed that once or twice a day, I would type mechanically my past (lost) password instead of the new one I started to use. This worked well, problem solved :) Commented Jun 13, 2021 at 4:55


You must log in to answer this question.

Browse other questions tagged .