0

I forgot my Ubuntu password. I entered recovery mode and changed the password for my user with passwd as root. I haven't used that machine for a long long time, so I also forgot that my home folder was actually encrypted using ecryptfs. My bad, but I don't have that 32-char long MOUNT passphrase...

What are the options in this case? Have I lost all or is there still a chance to recover?

  • is there a point to try with ecryptfs-recover-private and try to recall this forgotten LOGIN password which I changed with passwd? Will it return a success code if I eventually manage to find the password at the back of my head?
  • if the point above doesn't happen, should I try the solution described here? can't log in after password change (ecryptfs) and run the shadow crack?

Or is there anything else I can do? I wouldn't like to break it more.

Many thanks

UPDATE: I think I found the old password. I am able to unwrap the passphrase. What's the way to go now? Go again root and passwd the user to the old password again or do a rewrap? Which is recommended? I just don't want to screw up things again :)

  • Yes, I just read that. Is there still any way for me to try "the old password" to recover? – Adam Soliński Dec 18 '19 at 16:34
  • @user68186 would trying to provide the old password to the recover script work in case I guess that password? or even trying to again do a root passwd to that password for the user and try to reboot? or is all lost already? – Adam Soliński Dec 18 '19 at 16:47
  • I believe that ecryptfs-recover-private is you best bet here. But you will still need the old password or the passphrase. – g_bor Dec 18 '19 at 17:21
  • @g_bor Please see my update on the original question. Can you please advise? – Adam Soliński Dec 18 '19 at 17:23
  • 1
    Now it is safe to rewrap using ecryptfs-rewrap-passphrase. – g_bor Dec 18 '19 at 17:26
  • 1
    Also I would recommend to use some other methods for encrypting home, like using LUKS. – g_bor Dec 18 '19 at 17:36

0 Answers0