Closed Bug 524623 Opened 15 years ago Closed 14 years ago

2.0 -> 3b4, no password saved, "error getting mail password" on POP

Categories

(Thunderbird :: Account Manager, defect)

defect
Not set
normal

Tracking

(blocking-thunderbird3.1 rc1+, thunderbird3.1 rc1-fixed, blocking-thunderbird3.0 .6+, thunderbird3.0 .6-fixed)

RESOLVED FIXED
Thunderbird 3.3a1
Tracking Status
blocking-thunderbird3.1 --- rc1+
thunderbird3.1 --- rc1-fixed
blocking-thunderbird3.0 --- .6+
thunderbird3.0 --- .6-fixed

People

(Reporter: bugzilla, Assigned: standard8)

References

()

Details

(Whiteboard: [223 Migration][gs][fixed by bug 530079])

Attachments

(2 files)

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.9.1.4) Gecko/20091007 Firefox/3.5.4
Build Identifier: Thunderbird 3 b4

When I click 'get mail' on my pop account the status bar changes to 'host contacted, sending login information...' at which point I'd expect the 'enter password' dialog to appear.
It doesn't, I get a dialog saying 'Error getting mail password'

I am using my old TB2 profile.
I've never saved passwords, or set a master password.
The account configuration all looks fine as it did in TB2
I've had a search around - tried deleting popstate.dat, checked the password list in config (its empty), tried creating a master password, all to no effect.

Reproducible: Always

Steps to Reproduce:
1. Open Thunderbird 3b4 using profile from TB2 (which still works)
2. Click 'get mail'

Actual Results:  
POP connection is initiated but instead of asking for password a dialog pops up which says "error getting mail password"

Expected Results:  
'Please enter password' dialog box pops up with a password entry field.

Originally posted here:
http://forums.mozillazine.org/viewtopic.php?f=29&t=1547505&p=7830825#p7830825

Looks like a migration bug - block bug #521381
Blocks: Migration223
Version: unspecified → 3.0
Neil your account is pop3 or imap?
Whiteboard: [223 Migration]
(In reply to comment #1)
> Neil your account is pop3 or imap?

POP.  Anything in Tools-> Error console ?
Yes it is POP3.

Error console shows this:

Error: [Exception... "'Initialization failed' when calling method: [nsILoginManagerStorage::init]"  nsresult: "0x8057001e (NS_ERROR_XPC_JS_THREW_STRING)"  location: "JS frame :: file:///usr/lib64/thunderbird-3.0b4/components/nsLoginManager.js :: anonymous :: line 129"  data: no]
Source File: file:///usr/lib64/thunderbird-3.0b4/components/nsLoginManager.js
Line: 129

Error: this._storage is null
Source File: file:///usr/lib64/thunderbird-3.0b4/components/nsLoginManager.js
Line: 527
Can you try to reinstall thunderbird 3.0b4 and see if that fixes the issue ?
To me this looks like the login manager didn't like upgrading your password files for some reason. If you're getting it every time, you could try setting the pref "signon.debug" to true and see if there's any more useful information comes up on the error console.
OK reinstalled, I've been switching between TB2 and TB3b4.

I have never saved the password, nor set a master password in Thunderbird.

OK set signon.debug and grabbed the info, in attachment tb3b4_pop_password_debug.txt.
Hmm, that's interesting.

PwMgr mozStorage: Creating Tables
PwMgr mozStorage: Initialization failed: [Exception... "Component returned failure code: 0x80630001 [mozIStorageConnection.createTable]"

That's an unexpected place to fail.

1) What are the permissions set to on that profile directory? I wonder if it's not able to create the DB.

2) Is there already a signons.sqlite there? Filesize / permissions?

3) If the file is there, I'd be curious to know the contents. Assuming you have the sqlite tools installed on your system (odds are you do), running "sqlite3 signons.sqlite" and then issuing the ".dump" command will dump the results as text. I'd like to see that dump (feel free to delete any delete sensitive info, including any seemingly-encrypted values beginning with "~"). I'd also want to know what issuing the "PRAGMA user_version" command says.

4) Try deleting signons.sqlite (keep a backup elsewhere), and start again. Paste debug info here.
Same issue here when upgrading from TB2.0.0.23 to TB3 RC1 (English GB locale, running on English Windows Vista. I would add that the issue affects also IMAP accounts (when trying to get mail for an IMAP account in the status bar the "Connetcing... Connected... Checking mail server capabilities" messages are shown but then nothing happens. When trying to send mail the same message is shown for both IMAP and POP accounts: "Sending of message failed. An error occurred sending mail: Could not get password for [server IP].The message was not sent.".

The profile directory is read-only and there is no signons.sqlite file in it.
(In reply to comment #9)

> The profile directory is read-only and there is no signons.sqlite file in it.

Why is your profile read-only? That's likely causing your problem -- make it writable and see if that fixes things. (I'd be curious to know if you get the same signons.debug output as above.)
Actually the profile folder itself is not read-only, just some of the stuff in it (the read-only box does not show a tick mark but is shown with a blue fill color...). Files right within the profile folder are not read-only. I have never fiddled with this folder manually and I have full admin rights.

I have attached the signosn.debug information (signons.debug.png).
Some additional information: In TB2 all passwords were saved. Now the "Saved Passwords" list is empty. All in all it seems that TB3 RC1 "knows" that the passwords for the accounts were saved, and is trying to retrieve them, but fails, yet it does not prompt for the password to be entered manually. How would it be possible to "force" TB to prompt for the passwords again? This would solve my current issue, although there might be something wrong with how saved passwords are handled during the upgrade process.
I have tried what happens if I create a new profile: the singons.sqlite file is created in the profile folder. The access right to this new profile folderare the same as for my "real" profile where the signons.sqlite file was not created during the upgrade to TB3 RC1.
OK I've solved the immediate problem (except for one of the POP accounts) by creating a new profile and copying the signons.sqlite file from this new profile to the old one. When starting TB again with the original profile I was prompted to enter the passwords.
I just upgraded from en-US Thunderbird 2.0.0.23 on Windows XP to Thunderbird 3 RC1 Build1 and as I suspected after the upgrade everything was fine with POP:
i.e. I could send and receive emails and see my old email (I am tracking this problem for support purposes at: http://gsfn.us/t/lfie  ) So it sounds like a bug specific to gyurrika's config (gyurrika is the original poster on Get Satisfaction)
(In reply to comment #12)
> Created an attachment (id=412452) [details]
> Error console with signons.debug on

This looks like a different problem, file a new bug please?

Specifically, the "malformed URI sequence" implies the reading of the legacy wallet format is out of sync (see bug 474846). Either the import code needs to wrap some newURI calls with try/catch, or the impl. for those URIs needs to not throw.
OK created new bug report <a href="https://bugzilla.mozilla.org/show_bug.cgi?id=530079">530079</a>.
Blocks: 530079
I have the same problem from TB 2 to TB 3rc1.

My solution is to comment the line which error console report "malformed URI sequence".

On windows, it is at "C:\Program Files\Mozilla Thunderbird\components\nsLoginManagerPrompter.js".

Comment the line 357 which is "username = decodeURIComponent(username);"

Then your old account will work fine. But if you create a new one, it will fail.

I try to dump the "username" to error console and the difference between old account (TB 2) and new account (TB 3rc1) is:

My account plain text is "powen.tan".

Old account dump "username" at line 357 is "powen%2Etan%28ZZ%87%29"
New account dump "username" at line 357 is "powen%2Etan"

I find that the "%87" can't be decoded by uriDecodeComponent. So when you try to decode old account, something bed will happen.

I think it may be inconsistence between TB 2 and TB 3.
(In reply to comment #7)
> Created an attachment (id=410674) [details]
> Error console content with signon.debug set

I got exactly the same error message as Neil.
Installing 3.0(final) in a new folder, having before 2.0.0.23 (20090812) in another.
POP accounts.
From the 2 messages Neil got in the Error console, I got exactly the first one, and the second one with the same message just pointing to another line number.
I was not using a master password in TB2 but I was using the "Use password manager to remember this password" tick when prompted the first time for the password.
Still TB2 was working normally. In TB3 Tools/Options/Security/Passwords/ Saved passwords was just empty.
I solved it by (in TB _2_) deleting the passwords (Tools/options/security => Edit saved password => Delete all). 
When reopening TB3 and clicking on "Get mail" I got normally prompted for the password like if they were never stored. After that TB3 works normally. TB2 doesnt see the passwords.
Apologies in wrong spot, please move or advise what to do.

I'm coming from Installing Eudora 8.0b7, with the same problem
see
http://eudorabb.qualcomm.com/showthread.php?p=43155&posted=1#post43155

I have installed thunderbird 3.0 and the problem seems to be solved in it.

But we still have it in Eudora, where do I go from here please

thanks 
scsijon
ps adding a copy of this in the other thread.
sorry, forgot to say that alberto's workaround (comment 20) doesn't work for us. there is no clearbox available, they are both greyed out
thanks
scsijon
I have had this problem upgrading a couple of workstations, and don't think it has anything to do with the profile.  Here is what I did as a workaround:

Uninstall all versions of Thunderbird.  Leave the profile directory as is.  Delete the "c:\Program Files\Mozilla Thunderbird" directory.  Remove the Registry key "HKLM\Software\Mozilla\Thunderbird".  Directory or key names may vary depending on which version you are running.

Re-install Thunderbird and it should run ok.   I will try and dig a bit deeper if I come across this again.
I too have this problem.  I am running Ubuntu 9.10 and am on the 3.1 nightly builds (http://ppa.launchpad.net/ubuntu-mozilla-daily/ppa/ubuntu).  Just updated to Shredder 3.1a1pre and now cannot receive any email complaining "error getting mail password" on all pop accounts.
Flags: blocking-thunderbird3.1?
blocking-thunderbird3.0: --- → ?
I have the same problem - Ubuntu karmic x64, 3.1 nightly builds. As a workaround I keep a 3.0 installation. Open the same profile in Thunderbird 3.0 - goto Edit > Preferences > Security > Passwords. Click on 'Saved passwords' and then click on 'Remove All'. Warning - this will remove all stored passwords!

Next time you open Thunderbird 3.1 you will be prompted for a password. Do not click 'Use password manager' - just manually enter the password once per session.
Problems with Thunderbird 3.1 are not part of this bug.

For people seeing this in Thunderbird 3, what I really need to know is what is the site url as displayed in Thunderbird 2.

So if anyone still has an example of the passwords failing upgrade, and can re-load Thunderbird 2, what I'd really like to know is what is the site URL(s), as displayed when you go into Preferences/Options and the Privacy -> Passwords -> Edit Saved Passwords.

If you don't want to post them here, feel free to email me direct.

I'm hoping a few of the site urls can help me figure out what is happening here (if not, I'll at least see if we can get some kind of work around in place).
Assignee: nobody → bugzilla
blocking-thunderbird3.0: ? → needed
Flags: blocking-thunderbird3.1? → blocking-thunderbird3.1+
(In reply to comment #27)
> For people seeing this in Thunderbird 3, what I really need to know is what is
> the site url as displayed in Thunderbird 2.

In Thunderbird 2, one of the accounts is (did the same for all my 4 pop accounts):
mailbox://myusername@pop.gmail.com

"myusername" contains only lower case ascii letters

Note: i have a different language version of TB2 than 3, in case that would matter(?)
It would also be interesting to see debug output per https://wiki.mozilla.org/Firefox:Password_Manager_Debugging... Set the pref, quit TB, delete signons.sqlite (keep a backup!), and then start TB. This will force a reimport of passwords from the TB2 database, and any failures will be logged in the error console. You can restore signons.sqlite when you're done if you've already fixed your logins.
(In reply to comment #29)
I tried deleting the signons.sqlite from the profile, but after that TB3 is just asking for the passwords like if it doesnt remember them. It doesnt try to import, neither gives any error. TB2 still has them
What i did exactly: 
Change in Firefox the config like described in your link.
Close TB.
In the Thunderbird profile folder delete signons.sqlite
Start TB2 and reenter there the passwords without master password, close it.
Start TB3. TB3 just asks for the passwords like if I normally deleted them. Doesnt try to import anything. Does throw any error.
17 people have this problem on Get Satisfaction:
http://gsfn.us/t/nsid

I'd like to nominate this for 3.1. Any easy workarounds or ways the users on Get Satisfaction can help other than getting the URL as Mark Banner suggested in comment 27?
Whiteboard: [223 Migration] → [223 Migration] [gs]
Same bug for me during migration from V2 to V 3.0.1 (french).
Thank you for your help.

Could provide you some additionnal informations if requested.
After going through with Password Manager Debugging.... following error shows up in console.

Error: Cc['@mozilla.org/login-manager/crypto/SDR;1'] is undefined
Source File: file:///usr/lib/thunderbird-3.1a1pre/components/storage-mozStorage.js
Line: 72
(In reply to comment #33)
> After going through with Password Manager Debugging.... following error shows
> up in console.

Navi, that sounds like a different issue. If you're using Linux then you're most likely using a build that is provided by your distribution and they haven't updated it to include the latest code.
So true, I'll try pulling the source code tonight and trying it on a fresh build.

My bad!
Mark, is UNCONFIRMED really the right state for this bug?  I'm assuming not and carrying over the blocking+ to the new 3.1 multi-state flag.  I've targetted it at rc1 based on the assumption that this isn't likely to require string changes, but I don't know whether that's actually true.  Feel free to retarget.
blocking-thunderbird3.1: --- → rc1+
Flags: blocking-thunderbird3.1+ → blocking-thunderbird3.1-
I've seen this bug after migrating from thunderbird-3.0.3 to thunderbird-3.1a1.

There is a workaround that worked with me: move or delete the files:
signons.sqlite, key3.db and signons3.txt
Pedro,

Thank you for the suggestions.  I have entered a similar bug where pass word manager will not show a hceck box to save the mail account pass word, htere by requiring me to enter hte pass words for 4 different accounts to down load any new messages.

Now when I launch TB 3.0.3 it downloads all new messages without requiring the account's password.

What should happen is TB should ask for each mail account password and have a check box to save the password.  Once the check box is checked TB should save the account password and not ask for it again.

Michael
(In reply to comment #38)
> Pedro,
> 
> Thank you for the suggestions.  I have entered a similar bug where pass word
> manager will not show a hceck box to save the mail account pass word, htere by
> requiring me to enter hte pass words for 4 different accounts to down load any
> new messages.
> 
> Now when I launch TB 3.0.3 it downloads all new messages without requiring the
> account's password.
> 
> What should happen is TB should ask for each mail account password and have a
> check box to save the password.  Once the check box is checked TB should save
> the account password and not ask for it again.
> 
> Michael

Latest Update on this bug.

After performing Pedro's suggestion none of my mail accounts asks for the password, TB simply downloads all new messages.

There is one exception, when TB is closed and launched the sending of a mail message requires the password for the SMTP outgoing server and again there is no check box to remember the password.

Michael
(In reply to comment #27)
> Problems with Thunderbird 3.1 are not part of this bug.
> 
> For people seeing this in Thunderbird 3, what I really need to know is what is
> the site url as displayed in Thunderbird 2.
> 
> So if anyone still has an example of the passwords failing upgrade, and can
> re-load Thunderbird 2, what I'd really like to know is what is the site URL(s),
> as displayed when you go into Preferences/Options and the Privacy -> Passwords
> -> Edit Saved Passwords.
> 
> If you don't want to post them here, feel free to email me direct.
> 
> I'm hoping a few of the site urls can help me figure out what is happening here
> (if not, I'll at least see if we can get some kind of work around in place).

Standard8 from http://getsatisfaction.com/mozilla_messaging/topics/_error_getting_mail_password#reply_1806347:
QUOTE
Roland, I see Mark invited us to send him URLs directly, but not being a member of that bugzilla site, I'll just add it here (no email for him).
Example of one:
mailbox://name%40hotpop.com@pop.hotpop.com
So I have %40 and one %25 and lots of @. Mark should note that most people with this problem have multiple email addresses at multiple servers, and may have many unused addresses left over from old, old TB installations or migrations from Netscape. (Sorry!) I also have some http: entries and smtp: entries. Some entries are no longer used, no longer show in account list, but are here in password list.
Roland, you might check for other threads here in Get Satisfaction, there are others with this problem, so your user count in Bugzilla may be off. 
END QUOTE
So far, Mark hasn't been able to reproduce.  However, he believes that he should be able to generate a band-aid fix that will at least keep Tb usable for people who encounter this problem.
Status: UNCONFIRMED → NEW
Ever confirmed: true
I have exactly the same problems (error getting the email password) and I solve it by changing the owner of .thunderbird directory, which was set on root:root.

The following command solved it chown originalowner:originalowner -R .thunderbird

Restarting thunderbird now did not result in any problems and mail are downloaded as usual.

Cheers
Whiteboard: [223 Migration] [gs] → [223 Migration] [gs] [patch eta Thurs][will be core patch]
Whiteboard: [223 Migration] [gs] [patch eta Thurs][will be core patch] → [223 Migration] [gs] [patch eta Thurs 6th][will be core patch]
Whiteboard: [223 Migration] [gs] [patch eta Thurs 6th][will be core patch] → [223 Migration] [gs] [patch eta Fri 7th][will be core patch]
I'm in a similar boat. Let me know if it belongs here or in a new bug report.

I am transferring my thunderbird from Fedora 12 - 32 bit to a new machine running Fedora 12 - 64 bit. Both were fully updated before the transfer. Both have TB 3.0.4. So I tar.gz'd .thunderbird and copied and unpacked it to the new machine. The userid on both machines is the same. All the mail is present, everything looks the same but...

o Fetching mail from any account (pop3 and imap) gets the "Error getting mail password."
o The list of passwords is empty. 
o The sqllite3 .dump is the same between the two machines.
o Renaming key3.db, signons.sqlite and signons3.txt to *.bak did not help.
o Permissions are the same for the files on the two machines.

After turning on debug and trying to fetch mail I see:
(Note: ----- use to separate entries)
Login Manager: Searching for logins matching host: mailbox://mail.wfinet.com, formSubmitURL: , httpRealm: mailbox://mail.wfinet.com
-----
Login Manager: No alternate nsILoginManagerStorage registered
-----
Error: Cc['@mozilla.org/security/pk11tokendb;1'] is undefined
Source File: file:///usr/lib64/thunderbird-3.0/components/storage-mozStorage.js
Line: 224
-----
Login Manager: Initialization of storage component failed: [Exception... "'[JavaScript Error: "Cc['@mozilla.org/security/pk11tokendb;1'] is undefined" {file: "file:///usr/lib64/thunderbird-3.0/components/storage-mozStorage.js" line: 224}]' when calling method: [nsILoginManagerStorage::init]"  nsresult: "0x80570021 (NS_ERROR_XPC_JAVASCRIPT_ERROR_WITH_DETAILS)"  location: "JS frame :: file:///usr/lib64/thunderbird-3.0/components/nsLoginManager.js :: anonymous :: line 129"  data: yes]
-----
Error: this._storage is null
Source File: file:///usr/lib64/thunderbird-3.0/components/nsLoginManager.js
Line: 534
-----
Pwmgr Prompter: ===== initialized =====
-----
Pwmgr Prompter: ===== promptPassword called() =====
-----
Login Manager: Checking if logins to mailbox://mail.wfinet.com can be saved.
-----
Login Manager: No alternate nsILoginManagerStorage registered
-----
Error: Cc['@mozilla.org/security/pk11tokendb;1'] is undefined
Source File: file:///usr/lib64/thunderbird-3.0/components/storage-mozStorage.js
Line: 224
-----
Login Manager: Initialization of storage component failed: [Exception... "'[JavaScript Error: "Cc['@mozilla.org/security/pk11tokendb;1'] is undefined" {file: "file:///usr/lib64/thunderbird-3.0/components/storage-mozStorage.js" line: 224}]' when calling method: [nsILoginManagerStorage::init]"  nsresult: "0x80570021 (NS_ERROR_XPC_JAVASCRIPT_ERROR_WITH_DETAILS)"  location: "JS frame :: file:///usr/lib64/thunderbird-3.0/components/nsLoginManager.js :: anonymous :: line 129"  data: yes]
-----
Error: this._storage is null
Source File: file:///usr/lib64/thunderbird-3.0/components/nsLoginManager.js
Line: 578
-----
Error: this._storage is null
Source File: file:///usr/lib64/thunderbird-3.0/components/nsLoginManager.js
Line: 578

So I tried to create a temp profile to get a valid signons.sqlite for this profile. Creating the temp profile worked just fine, but I was not able to use it's signons.sqlite for this profile. (I then deleted that temp profile.)

I then deleted an imap account and tried to re-create it. I got the error dialog saying: TypeError: this._init is not a function. The error console had:
Warning: Expected color but found 'dialog'.  Error in parsing value for 'background-color'.  Declaration dropped.
Source File: chrome://messenger/skin/accountCreation.css
Line: 229

Not sure what else to try...
I tried the copy again. And it worked. I'm going to guess that I had a bad copy. So ignore the details in my last post.

That said, I think it would be good to be able to fully manage the passwords in this situation.
(In reply to comment #43)

> Error: Cc['@mozilla.org/security/pk11tokendb;1'] is undefined

Please file a separate bug for your issue, you seem to have a broken Thunderbird install. The component referenced in that error should always exist. That's a different issue than this bug is about.
No longer blocks: 530079
Depends on: 530079
I've put a patch into bug 530079 that will work around the broken password entries, and at least allow the password manager to continue working.

From looking back at the comments on this bug and elsewhere, I think that the original reporter's problem was a read-only profile directory (or unable to create new files). Unfortunately we never heard back about that.

The other issues on this bug I think fall into the categories of:

- The same as the original reporter's (probably a read-only directory)
- The same as bug 530079 where a particular entry can't be upgraded
- Other issues with broken installs or not part of this bug.

Therefore I think fixing bug 530079 is the best we can do to resolve this bug.
Whiteboard: [223 Migration] [gs] [patch eta Fri 7th][will be core patch] → [223 Migration][gs][core patch review in 530079][see comment 46]
Whiteboard: [223 Migration][gs][core patch review in 530079][see comment 46] → [223 Migration][gs][core patch landed on m-c, need to get onto 1.9.2]
Whiteboard: [223 Migration][gs][core patch landed on m-c, need to get onto 1.9.2] → [223 Migration][gs][core patch landed on m-c, waiting on Tinderboxes to pick up relbranch]
This is now fixed (via a workaround) for Thunderbird 3.1 rc1, and on trunk builds, by bug 530079.

I'd still like to know what's actually the root cause of this, but if we find any of those we can handle them in a new bug.
Status: NEW → RESOLVED
Closed: 14 years ago
OS: Linux → All
Hardware: x86 → All
Resolution: --- → FIXED
Whiteboard: [223 Migration][gs][core patch landed on m-c, waiting on Tinderboxes to pick up relbranch] → [223 Migration][gs][fixed by bug 530079]
Target Milestone: --- → Thunderbird 3.2a1
I upgraded from TB2 to TB3 on a Ubuntu 9.04 desktop. Same issue as most of the previous posters - "error getting mail password".

I managed to get TB3 to start promting for a password by running the following in both TB2 and TB3:
Open the Error Console, paste the expression: openDialog("chrome://pippki/content/resetpassword.xul")  and press the Evaluate button. That will open a dialog asking you if you want to reset your password.

When prompted you can enter your password and your mail does work, but when you tick the dialog to "save password in password manager", the same error re-appears. I installed an addon called "Saved Passwords" and tried to manually add an entry, which fails saying a duplicate entry already exists - yet there are no saved passwords in the GUI under Preferences -> Security -> Saved passwords. I have also deleted the files mentioned above with no luck.

Could it be that the entry exists but for some reason you cannot see it in the GUI?
blocking-thunderbird3.0: needed → .6+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: