[MASTER] passwords lost from 3.0.1 to 3.0.2

Bug #270429 reported by Fritz Heinrichmeyer on 2008-09-15
56
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mozilla Firefox
Invalid
High
XULRunner
Fix Released
High
firefox-3.0 (Ubuntu)
Critical
Unassigned
Hardy
Critical
Unassigned
Intrepid
Critical
Unassigned
xulrunner-1.9 (Ubuntu)
Critical
Unassigned
Hardy
Critical
Unassigned
Intrepid
Critical
Unassigned

Bug Description

Binary package hint: firefox-3.0

firefox 3.0.2 does not use password database from 3.0.1 and moreover storing of new passwords does not work, password list is empty.

signons3.txt is left alone.

Build identifier : Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.0.2) Gecko/2008090514 Firefox/3.0.2

I'm also having this issue since upgrading to the newest version. signons3.txt is still there, but it seems no passwords are actually read from this file.
The passwords manager display stays blank, although the file it's supposed to read from...isn't blank.

(In reply to comment #1)
> Build identifier : Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.0.2)
> Gecko/2008090514 Firefox/3.0.2
>
> I'm also having this issue since upgrading to the newest version. signons3.txt
> is still there, but it seems no passwords are actually read from this file.
> The passwords manager display stays blank, although the file it's supposed to
> read from...isn't blank.
In that case I'd say: make a screenshot of your passwords while it's still possible.

User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.9.0.2) Gecko/2008090514 Firefox/3.0.2
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.9.0.2) Gecko/2008090514 Firefox/3.0.2

After Update from Mozilla 3.0.1 to 3.0.2 all Safed Passwords are lost.

Reproducible: Didn't try

Steps to Reproduce:
1.
2.
3.

Please visit http://support.mozilla.org for technical support. This is not a support center, but a technical bug reporting database for the developers.

same here, old "signons3.txt" is still there but no more used. Also the saved password list stays empty when passwords (like for this account, luckily i could remember) are typed in again. This seems to be remarkable bug. I use the firefox from ubuntu intrepid (3.0.2).

Binary package hint: firefox-3.0

firefox 3.0.2 (intrepid) does not use password database from 3.0.1 (hardy) and moreover storing of new passwords does not work, password list is empty.

signons3.txt is left alone.

additional information from javascript console:

Fehler: uncaught exception: [Exception... "'[JavaScript Error: "this._storage is null" {file: "file:///usr/lib/xulrunner-1.9.0.2/components/nsLoginManager.js" line: 425}]' when calling method: [nsILoginManager::getAllLogins]" nsresult: "0x80570021 (NS_ERROR_XPC_JAVASCRIPT_ERROR_WITH_DETAILS)" location: "JS frame :: chrome://passwordmgr/content/passwordManager.js :: LoadSignons :: line 59" data: yes]

error javascript console:

Fehler: uncaught exception: [Exception... "'[JavaScript Error: "this._storage is null" {file: "file:///usr/lib/xulrunner-1.9.0.2/components/nsLoginManager.js" line: 425}]' when calling method: [nsILoginManager::getAllLogins]" nsresult: "0x80570021 (NS_ERROR_XPC_JAVASCRIPT_ERROR_WITH_DETAILS)" location: "JS frame :: chrome://passwordmgr/content/passwordManager.js :: LoadSignons :: line 59" data: yes]

Debugging shows the following :

Login Manager: Initialization of storage component failed: [Exception... "Component returned failure code: 0x8000ffff (NS_ERROR_UNEXPECTED) [nsIScriptableUnicodeConverter.ConvertToUnicode]" nsresult: "0x8000ffff (NS_ERROR_UNEXPECTED)" location: "JS frame :: file:///C:/Program%20Files/Mozilla%20Firefox%203/components/storage-Legacy.js :: anonymous :: line 853" data: no]

That line 853 reads :
line.value = this._utfConverter.ConvertToUnicode(line.value);

Bah. This is probably a regression from bug 451155... The bug fixed buy 451155 could result in invalid UTF8 being written to the file, so now that we try to convert it from UTF8, the bogus data will cause it to fail. :(

We can't recover the login (due to lossy UTF16->ascii conversion), but we should at least try/catch the UTF8 conversion and delete the login.

I'd be curious to see which line in your profile's signon3.txt is causing the problem. Could you email me this file? (The passwords are encrypted, but you can edit out encrypted-looking lines if you'd like.)

Created attachment 339174
a sample of corrupted signons3.txt

(In reply to comment #5)
> I'd be curious to see which line in your profile's signon3.txt is causing the
> problem.

The sample is here.
I made it on https://うっかり.jp/members/

Created attachment 339175
key3.db for the sample signons3.txt

key3.db is here.
Not to worry because real password is not included.

i tried to repro this and could only confirm this issue with my working profile, but not in a clean profile.
what i did:
1. create a new profile using 3.0.1
2. save a password for google.com
3. run 3.0.2 (build5) on the same profile
-> password was still available

so i tought it may be caused by an extension, but as an further test i repeated above steps with installing those extension one-by-one to 3.0.1 prior to testing the profile with 3.0.2

arrg, as addition to comment 4:
even after getting my test profile to my "working" profile concerning the base of installed extensions i still failed to repro :-/

It seems like an extension has modified something in your working profile. You can try in safe Mode, then if it does not occur then (with new passwords in the working profile) then it is 99% certain it is an extension. Disable them one by one, then if you find the one that causes it, contact the developer of the extension. i am closing as INVALID for now, since it does not seem to be a bug in Firefox, but you can reopen if you fail to find the issue. Also, you can post the name of the extension while leaving as INVALID.

(In reply to comment #4)
> so i tought it may be caused by an extension, but as an further test i repeated
> above steps with installing those extension one-by-one to 3.0.1 prior to
> testing the profile with 3.0.2
It was seemingly a freak thing that happened, with a messup modification.

@Tyler: please do *not* invalidate bugreports based on feedback by just one commenter (here: me), with other commenters not having a chance to contribute (a lot of ppl do not seach for INVALID marked bugs). e.g. maybe my testing hasn't been appropriate.
thank you.

If this is an issue with an extension (as it certainly seems) there is no need to wait for INVALID. It is not a problem with Firefox. The reported has been given opportunity to confirm. If you can find the issue with Firefox, feel free to reopen.

it happened with existings accounts on ubuntu on different boxes (i386, amd64) even in -safe-mode. With a clean profile passwords are saved.

Now i don't have time to investigate further but i have read going back to 3.0.1 helped another user. Maybe it is an ubuntu thing as there were 3.0.1 language extensions active in the updated 3.0.2 firefox.

Maybe this is an ubuntu bug.

What OS are you guys that have experienced this issue using. fritz said ubuntu, reporter was on XP, what about the rest?

Created attachment 339502
Patch v.1

The core fix here is to wrap the charset conversion in a try/catch. The tricky bit is deciding what to do with a corrupted entry...

One option is to do nothing, and keep it around. It won't get used anywhere, but it's a safe and minimal change.

The other option is to flag corrupted entries, and drop them when loading the file. This makes for tidy housekeeping, but adds complexity, risk, and more to test. The particular risk here is a "drop this entry" code path adds the possibility of having a bug that results in more dataloss (eg, forgetting to reset the "drop this entry" flag, and dropping all following entries).

I've implemented the second option here (untested!), but I'm sort of leaning towards just doing the first option instead.

Gavin, thoughts?

option 1 sounds best - cost of ignoring them is pretty low I think.

If we keep it around (option 1), will that effect importing with the switch to mozStorage? Or will we just import a corrupted entry?

Created attachment 340035
Patch v.2

Updated to implement option 1, with tests.

(In reply to comment #10)
> If we keep it around (option 1), will that effect importing with the switch to
> mozStorage? Or will we just import a corrupted entry?

No. It's a valid string once it's in memory, the problem only happens when we try converting the on-disk value from UTF8. The mozStorage code is unaffected by this.

Updating summary.

Gavin noted on IRC that this bug can't be the same problem that the original reporter (Ed) was having. The patch that caused this regression didn't land until Firefox 3.0.2. This bug was filed against FF3.0.1. So, although the symptoms are the same, they must be separate problems. *sigh*

Since this bug has already mutated, I've filed bug 456661 to track the original problem from comment 0.

When i delete "signons3.txt" in the profile directory the password database and an new useable "signons3.txt" is built up successive again when logging in my websites.

It seems to me that data records are separated by "---". I don't want to post this database files :-) btw.

The first record in the old database makes no sense to me but until now i found no way to repair the old database by deleting or changing lines.

Maybe encryption has changed?

The same happened when I updated my firefox from 3.0.1+build1+nobinonly-0ubuntu0.8.04.3 to 3.0.2+build6+nobinonly-0ubuntu0.8.04.1 today (no distro-upgrade just hardy to hardy). Although I don't get that output mentioned by Fritz on the command line (on the second run after the update, if that's supposed to appear on the command line).

description: updated

Error output is not from command line, but from javascript error console in firefox (ctrl+shift+j).

When i delete "signons3.txt" in the profile directory the password database and
an new usable "signons3.txt" is built up successive again when logging in my
websites.

It seems to me that data records are separated by "---". I don't want to post
this database files :-) btw.

The first record in the old database makes no sense to me. But until now i found
no way to repair the old database by deleting or changing lines.

Maybe encryption has changed?

Michael Tänzer (neoatnhng) wrote :

P.S.: Logging off and on again doesn't help either. I'm using the option "When Firefox is started: restore windows and tabs from the last session" (on-the-fly translation from German) maybe that's got something to do with it. Apart from BugMeNot, ProfileSwitcher and maybe NoScript, I have no password related add-ons installed.

Michael Tänzer (neoatnhng) wrote :

Yes, I also got some "this._storage is null" error in the error console, although I don't know how to get the verbose output.

Michael Tänzer (neoatnhng) wrote :

I backed up the old signons3.txt and firefox created a new one. The structure indeed seems to be the same but the encrypted values aren't (same masterpassword). The top entry (which Fritz said makes no sense) apparently has to be there as the new file has exactly the same. The encrypted values all have the same prefix (that also didn't change from old -> new).

Dukai Gábor (gdukai) wrote :

I can confirm this bug on hardy. After the 3.0.2 upgrade the password list went empty, reverting back to 3.0.1 got the passwords back.
My plugins probably aren't password-related: Adblock Plus, Colorunreadtabs, Fastdial, Flashblock, Flashgot, Hupper, Torbutton

doday i (automatically) updated firefox under windows.

Passwords are also lost there so maybe this is an "upstream" bug.

i klicked at firefox upgrade button under windows and now had the same effect (lost passwords, but i saved everything before ;-) ) also under windows XP.

*** Bug 456723 has been marked as a duplicate of this bug. ***

*** Bug 456691 has been marked as a duplicate of this bug. ***

reopening since after the 3.0.2 rel there are now some more reports of lost passwords after migration. moreover the error console output of comment 3 does not point to extension relevance.

*** Bug 456701 has been marked as a duplicate of this bug. ***

*** Bug 456182 has been marked as a duplicate of this bug. ***

Alexander Sack (asac) on 2008-09-24
Changed in firefox-3.0:
importance: Undecided → Critical
status: New → Triaged
Changed in xulrunner-1.9:
importance: Undecided → Critical
status: New → Triaged
Alexander Sack (asac) on 2008-09-24
Changed in firefox-3.0:
importance: Undecided → Critical
status: New → Triaged
Changed in xulrunner-1.9:
importance: Undecided → Critical
status: New → Triaged
milestone: none → ubuntu-8.10-beta
Changed in firefox-3.0:
milestone: none → ubuntu-8.10-beta
Changed in firefox:
status: Unknown → Confirmed
Changed in xulrunner:
status: Unknown → Confirmed
Alexander Sack (asac) on 2008-09-24
Changed in xulrunner-1.9:
status: Triaged → Fix Committed
Changed in xulrunner-1.9:
status: Fix Committed → Fix Released
Changed in firefox-3.0:
status: Triaged → Fix Released
Changed in firefox:
status: Confirmed → Invalid
Changed in xulrunner:
status: Confirmed → Fix Released
Changed in firefox-3.0:
status: Triaged → Fix Released
Changed in xulrunner-1.9:
status: Triaged → Fix Released
72 comments hidden view all 152 comments
Petr Halas (petr-halas) wrote :

not fixed for me, only manual conversion signons3.txt from iso-8859-1 to utf8 help me

Ubuntu Hardy, FF 3.0.3+build1, xulrunner 1.9.0.3+build1

Eduardo (eduardoj) wrote :

> I closed Firefox, and re opened it. It didn't worked.
> After rebooting the computer, it works perfectly.

Installing new packages, launching Firefox, and restarting Firefox has been enough for me.

Philippe Piquer (philippep62) wrote :

Upgraded, re-started firefox , re-booted computer , re started firefox ... still no logins/passwords
Closed firefox , backed-up signons3.txt then
>recode latin1..utf8 signons3.txt
re-started firefox, logins/passwords are back.

I did "downgrade" xulrunner to have passwords back.
Now there is new versions of firefox and xulrunner and I upgraded too : after restarting ff and also rebooting my computer, I don't have passwords anymore... I'll try the signons3.txt workaround...

Indeed my problem went away (now it remembers passwords again and they are all there) after rebooting my laptop.

aldebx (aldebx) wrote :

Thank you Alexander Sack,
Thank you all Ubuntu & Mozilla devs for being so efficient and patching that promptly this nasty bug!

You can also mark Bug 457178 as a duplicate of this bug...

Alexey Androsov (doochik) wrote :

i've performed this (https://bugs.launchpad.net/ubuntu/+source/firefox-3.0/+bug/270429/comments/16) commands yesterday .
today i updated ff and xulrunner to 3.0.3:
firefox-3.0: 3.0.3+build1+nobinonly-0ubuntu0.8.04.1
xulrunner-1.9: 1.9.0.3+build1+nobinonly-0ubuntu0.8.04.1

i make restart, reboot, restart and still have no saved passwods. then i transform signons3.txt to utf-8 (recode latin1..utf8 signons3.txt). login and passwords are back, but i still haven't promt message to save new passwords

*** Bug 457190 has been marked as a duplicate of this bug. ***

*** Bug 457178 has been marked as a duplicate of this bug. ***

v.

*** Bug 457212 has been marked as a duplicate of this bug. ***

*** Bug 457259 has been marked as a duplicate of this bug. ***

Tomcat (carstenbook) wrote :

Alexey and others who see this problem: i think it would be helpful to have the debug output as described at https://wiki.mozilla.org/Firefox:Password_Manager_Debugging

Autoupdated to 3.0.3, passwords still not saved and the list is empty, just like 3.0.2!

Alexey Androsov (doochik) wrote :

i've notice that settings "signon.rememberSignons" was set to false, i set it to "true" and get a promt message to save passwords.
Thank you!

Made a downgrade from 3.0.2 to 3.0.1
Then patched to 3.0.2 again and applied 3.0.3

Passwords still won't work.

OS: WinVista x64

(In reply to comment #38)
> Passwords still won't work.
..and for anyone else visiting this bug to add comments, there are reports on irc that in 3.0.3 just adding a new password (by going to any new site with a form for logging in and entering a bogus one and choosing to save it when prompted) then restarting firefox fixes any carry-over problems.

Could you please try that and mention whether doing that works?

Comment #39: It does indeed work and fixes the issue. However, the regular user does not appreciate the non-automatic solution and may not be able to fix it, frustrates and leaves Mozilla for good.

Didn't try.
I fixed it with downgrading to 3.0.1 again and applying 3.0.3 directly without the mentioned UTF-8 fixes above. Thx anyways :)

It worked for me.

Fixed only after applying method from comment #39. Thanks to Mardeg and shame to developers. Nobody should know tricks in order to fix the problem.

#43 +1

Fire Fox 3.0.3 is not remembering passwords too ... No accessing to password...

The Patch didn't work for me, too. I fixed it with re-installing FireFox.

the patch works on my computer, old password are back and it propose to save new ones.
thanks

The problem people are seeing in 3.0.3 is most likely bug 457358. Comment 39 is a known workaround for that bug. We're going to be landing the fix for that bug in Firefox 3.0.4. Please refrain from adding comments here or there unless there is new information available.

The workaround in comment 39 did not work for me. I am running FF 3.0.3 on Kubuntu Linux 8.04. After following the instructions in comment 39, I also tried deleting passwords from the password manager and re-establishing them. This did not work either.

I'm not sure what relevant information I can provide. Please ask and I'll do my best.

If you're still seeing problems after adding or removing a login, please file a new bug and attach debugging output per https://wiki.mozilla.org/Firefox:Password_Manager_Debugging

Hi, the Passwort Manager still does not work for me (XPSP2), since the Update to 3.0.3 I am asked for my master password when I go to a password protected Website, but the Passwort is not filled in. Here is the debug output:

PwMgr Storage: Failed to decrypt string: MDoEEPgAAAAAAAAAAAAAAAAAAAEwFAYIKoZIhvcNAwcECCeWezDqxdTnBBCh+2tmsj2ZH4jatEAMdNpH (NS_ERROR_UNEXPECTED)
.. (repeated) ..
PwMgr Storage: Failed to decrypt string: MEIEEPgAAAAAAAAAAAAAAAAAAAEwFAYIKoZIhvcNAwcECB1OY9s/BVzXBBjEOs6YRhvakDV4WeaPXSfl/DHSPnl1BJ8= (NS_ERROR_UNEXPECTED)
.. (repeated) ..
Login Manager: form[0]: found 0 matching logins.
Login Manager: (form ignored -- no password fields.)

Any Idea? When I reinstall 3.0.1 it works fine.

OK, Comment #39 also works for me.

Same as Comment #51 for me.
For a short while my passwords worked fine and now...
PwMgr Storage: Failed to decrypt string: VeryLongStringWhichI'veTruncated (NS_ERROR_UNEXPECTED)

Theres ~10 passwords that work but apart from them... all errors like above

Have tried all solutions listed here. My firefox 3.0.3 installation simply stopped letting me use passwords. Rebooting, reinstalling firefox, saving as UTF8. None of these things worked.

This just happened today, but I recently upgraded to 3.0.3 so maybe it's been going on for a couple days

Dan

I have downgraded to 3.0.1, but passwords still inaccessible. It is now allowing me to add passwords, but the old ones aren't showing up. It appears they may be lost forever, even though they are in the signons3.txt in encrypted form.

-Dan

Dan: Please file a new bug, and attach debugging as described in https://wiki.mozilla.org/Firefox:Password_Manager_Debugging.

(removing fixed1904 keyword, I think it was accidentally added when things were shuffled around for 3.0.3/3.0.4. This bug is already correctly marked verified1.9.0.3).

fixed1.9.0.4 was added because this patch was fixed in two places: the relbranch for the firedrilled Firefox 3.0.3 and the main cvs trunk for Firefox 3.0.4. This needs to be reverified for the next release.

Verified for 1.9.0.4 with Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.5; en-US; rv:1.9.0.4pre) Gecko/2008102304 GranParadiso/3.0.4pre.

Verified fixed Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.0.4pre) Gecko/2008102304 GranParadiso/3.0.4pre

latin-1 passwords (Realm) are being listed in the password manager now without any other "user-fixes".

One strange thing though. When I save a new password, it convert the text in the file to UTF-8. However the file is still being opened as latin-1 by gedit making the UTF-8 chars in the file being displayed as latin-1 by gedit. Line should read "begrænset", but reads it "begrænset".
It is being reed as the correct "begrænset" however.
See the testcase.

Can be ignored?

Happened me on update to 3.5.5 (windows 7)- first the update couldn't be applied, retried to update and update finished but passwords were gone - had to change encoding of signon3.txt to utf-8 -> passwords are back

Changed in firefox:
importance: Unknown → High
status: Invalid → Unknown
Changed in xulrunner:
importance: Unknown → High
Changed in firefox:
status: Unknown → Invalid
Displaying first 40 and last 40 comments. View all 152 comments or add a comment.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.