IOS – Restore mail account password from iOS

iosiphone

I want to trick IOS to use my IMAP server so I can help my buddy retrieve his mail password (which he forgot, but is still stored on the iPhone).

So he has a Yahoo Mail account configured and working and I just want to edit the settings file so the Mail app will use the IMAP server that I just set up to intercept his password.

I tried modifying the file /private/var/mobile/Library/Mail/metadata.plist and "Envelop Index", changing imap.apple.yahoo.com with my server, but these two files seem to act more like a cache, they got rewritten when he did check mail.

Any ideas what file I should change or any other way to get the password? I know the password is kept encrypted in the keychain database, but it's too difficult to decrypt that.

Best Answer

It'd be a lot easier to just sniff packets from his iPhone on your wifi and get the password. (With this?)

Change the DNS servers on your wifi to point to your DNS server and tell the iPhone that mail.yahoo.com (or whatever) is your PC's IP address. Also, you might want to uncheck "Use SSL".