GNOME Bugzilla – Bug 729246
During login username is not replaced by password field
Last modified: 2015-05-22 07:06:07 UTC
(https://bugzilla.novell.com/show_bug.cgi?id=871865) Steps to recreate: 1] Disable the user list. (My production machines get user information from an LDAP server, no users exist on the machines themselves.) This can be done by creating a file /etc/dconf/db/gdm.d/99-mine which contains [org/gnome/login-screen] disable-user-list=true then reboot. 2] Leave machine at login screen screen until you see the lock screen. 3] Hit Escape or wiggle the mouse or whatever to get the login screen showing again. 4] Enter something in the username field and hit Enter. Expected result: The username field is replaced by the password field. Observed result: The username field is replaced by another, empty, username field.
Created attachment 275471 [details] [review] prevent nextSignalId from being connected multiply times The problem is caused by '_askForUsernameAndBeginVerification' being called multiply times. So when we click 'next', the old connected function will also be executed.
Review of attachment 275471 [details] [review]: 473 this._disableUserList = undefined; 473 this._disableUserList = undefined; 474 this._userListLoaded = false; 474 this._userListLoaded = false; 475 this._nextSignalId = 0; 476 477 this._realmManager = new Realmd.Manager(); 478 this._realmSignalId = this._realmManager.connect('login-format-changed', 479 Lang.bind(this, this._showRealmLoginHint)); 475 480 476 LoginManager.getLoginManager().getCurrentSessionProxy(Lang.bind(this, this._gotGreeterSessionProxy)); 481 LoginManager.getLoginManager().getCurrentSessionProxy(Lang.bind(this, this._gotGreeterSessionProxy)); 477 482 const LoginDialog = new Lang.Class({ 620 this._authPrompt.setPasswordChar(''); 625 this._authPrompt.setPasswordChar(''); 621 this._authPrompt.setQuestion(_("Username: ")); 626 this._authPrompt.setQuestion(_("Username: ")); 622 627 623 let realmManager = new Realmd.Manager(); 628 this._showRealmLoginHint(this._realmManager.loginFormat); 624 let realmSignalId = realmManager.connect('login-format-changed', 625 Lang.bind(this, this._showRealmLoginHint)); 626 this._showRealmLoginHint(realmManager.loginFormat); 627 629 628 let nextSignalId = this._authPrompt.connect('next', 630 if (this._nextSignalId) 631 this._authPrompt.disconnect(this._nextSignalId); 632 this._nextSignalId = this._authPrompt.connect('next', 629 Lang.bind(this, function() { 633 Lang.bind(this, function() { 630 this._authPrompt.disconnect(nextSignalId); 634 this._authPrompt.disconnect(this._nextSignalId); 635 this._nextSignalId = 0; 631 this._authPrompt.updateSensitivity(false); 636 this._authPrompt.updateSensitivity(false); 632 let answer = this._authPrompt.getAnswer(); 637 let answer = this._authPrompt.getAnswer(); 633 this._user = this._userManager.get_user(answer); 638 this._user = this._userManager.get_user(answer); const LoginDialog = new Lang.Class({ 635 this._authPrompt.startSpinning(); 640 this._authPrompt.startSpinning(); 636 this._authPrompt.begin({ userName: answer }); 641 this._authPrompt.begin({ userName: answer }); 637 this._updateCancelButton(); 642 this._updateCancelButton(); 638 639 realmManager.disconnect(realmSignalId) 640 realmManager.release(); 641 })); 643 })); 642 this._updateCancelButton(); 644 this._updateCancelButton(); 643 this._showPrompt(); 645 this._showPrompt(); const LoginDialog = new Lang.Class({ 892 this._userManager.disconnect(this._userManagerLoadedId); 894 this._userManager.disconnect(this._userManagerLoadedId); 893 this._userManagerLoadedId = 0; 895 this._userManagerLoadedId = 0; 894 } 896 } 897 if (this._realmManager) { 898 this._realmManager.disconnect(this._realmSignalId);
Review of attachment 275471 [details] [review]: Hehehdh <hectormendez321@yahoo.com>4:41:00 AM CDT 473 this._disableUserList = undefined; 473 this._disableUserList = undefined; 474 this._userListLoaded = false; 474 this._userListLoaded = false; 475 this._nextSignalId = 0; 476 477 this._realmManager = new Realmd.Manager(); 478 this._realmSignalId = this._realmManager.connect('login-format-changed', 479 Lang.bind(this, this._showRealmLoginHint)); 475 480 476 LoginManager.getLoginManager().getCurrentSessionProxy(Lang.bind(this, this._gotGreeterSessionProxy)); 481 LoginManager.getLoginManager().getCurrentSessionProxy(Lang.bind(this, this._gotGreeterSessionProxy)); 477 482 const LoginDialog = new Lang.Class({ 620 this._authPrompt.setPasswordChar(''); 625 this._authPrompt.setPasswordChar(''); 621 this._authPrompt.setQuestion(_("Username: ")); 626 this._authPrompt.setQuestion(_("Username: ")); 622 627 623 let realmManager = new Realmd.Manager(); 628 this._showRealmLoginHint(this._realmManager.loginFormat); 624 let realmSignalId = realmManager.connect('login-format-changed', 625 Lang.bind(this, this._showRealmLoginHint)); 626 this._showRealmLoginHint(realmManager.loginFormat); 627 629 628 let nextSignalId = this._authPrompt.connect('next', 630 if (this._nextSignalId) 631 this._authPrompt.disconnect(this._nextSignalId); 632 this._nextSignalId = this._authPrompt.connect('next', 629 Lang.bind(this, function() { 633 Lang.bind(this, function() { 630 this._authPrompt.disconnect(nextSignalId); 634 this._authPrompt.disconnect(this._nextSignalId); 635 this._nextSignalId = 0; 631 this._authPrompt.updateSensitivity(false); 636 this._authPrompt.updateSensitivity(false); 632 let answer = this._authPrompt.getAnswer(); 637 let answer = this._authPrompt.getAnswer(); 633 this._user = this._userManager.get_user(answer); 638 this._user = this._userManager.get_user(answer); const LoginDialog = new Lang.Class({ 635 this._authPrompt.startSpinning(); 640 this._authPrompt.startSpinning(); 636 this._authPrompt.begin({ userName: answer }); 641 this._authPrompt.begin({ userName: answer }); 637 this._updateCancelButton(); 642 this._updateCancelButton(); 638 639 realmManager.disconnect(realmSignalId) 640 realmManager.release(); 641 })); 643 })); 642 this._updateCancelButton(); 644 this._updateCancelButton(); 643 this._showPrompt(); 645 this._showPrompt(); const LoginDialog = new Lang.Class({ 892 this._userManager.disconnect(this._userManagerLoadedId); 894 this._userManager.disconnect(this._userManagerLoadedId); 893 this._userManagerLoadedId = 0; 895 this._userManagerLoadedId = 0; 894 } 896 } 897 if (this._realmManager) { 898 this._realmManager.disconnect(this._realmSignalId);
Review of attachment 275471 [details] [review]: 473 this._disableUserList = undefined; 473 this._disableUserList = undefined; 474 this._userListLoaded = false; 474 this._userListLoaded = false; 475 this._nextSignalId = 0; 476 477 this._realmManager = new Realmd.Manager(); 478 this._realmSignalId = this._realmManager.connect('login-format-changed', 479 Lang.bind(this, this._showRealmLoginHint)); 475 480 476 LoginManager.getLoginManager().getCurrentSessionProxy(Lang.bind(this, this._gotGreeterSessionProxy)); 481 LoginManager.getLoginManager().getCurrentSessionProxy(Lang.bind(this, this._gotGreeterSessionProxy)); 477 482 const LoginDialog = new Lang.Class({ 620 this._authPrompt.setPasswordChar(''); 625 this._authPrompt.setPasswordChar(''); 621 this._authPrompt.setQuestion(_("Username: ")); 626 this._authPrompt.setQuestion(_("Username: ")); 622 627 623 let realmManager = new Realmd.Manager(); 628 this._showRealmLoginHint(this._realmManager.loginFormat); 624 let realmSignalId = realmManager.connect('login-format-changed', 625 Lang.bind(this, this._showRealmLoginHint)); 626 this._showRealmLoginHint(realmManager.loginFormat); 627 629 628 let nextSignalId = this._authPrompt.connect('next', 630 if (this._nextSignalId) 631 this._authPrompt.disconnect(this._nextSignalId); 632 this._nextSignalId = this._authPrompt.connect('next', 629 Lang.bind(this, function() { 633 Lang.bind(this, function() { 630 this._authPrompt.disconnect(nextSignalId); 634 this._authPrompt.disconnect(this._nextSignalId); 635 this._nextSignalId = 0; 631 this._authPrompt.updateSensitivity(false); 636 this._authPrompt.updateSensitivity(false); 632 let answer = this._authPrompt.getAnswer(); 637 let answer = this._authPrompt.getAnswer();
Review of attachment 275471 [details] [review]: 474 this._userListLoaded = false; 474 this._userListLoaded = false; 475 this._nextSignalId = 0; 476 477 this._realmManager = new Realmd.Manager(); 478 this._realmSignalId = this._realmManager.connect('login-format-changed', 479 Lang.bind(this, this._showRealmLoginHint)); 475 480 476 LoginManager.getLoginManager().getCurrentSessionProxy(Lang.bind(this, this._gotGreeterSessionProxy)); 481 LoginManager.getLoginManager().getCurrentSessionProxy(Lang.bind(this, this._gotGreeterSessionProxy)); 477 482 const LoginDialog = new Lang.Class({ 620 this._authPrompt.setPasswordChar(''); 625 this._authPrompt.setPasswordChar(''); 621 this._authPrompt.setQuestion(_("Username: ")); 626 this._authPrompt.setQuestion(_("Username: ")); 622 627 623 let realmManager = new Realmd.Manager(); 628 this._showRealmLoginHint(this._realmManager.loginFormat); 624 let realmSignalId = realmManager.connect('login-format-changed', 625 Lang.bind(this, this._showRealmLoginHint)); 626 this._showRealmLoginHint(realmManager.loginFormat); 627 629 628 let nextSignalId = this._authPrompt.connect('next', 630 if (this._nextSignalId) 631 this._authPrompt.disconnect(this._nextSignalId); 632 this._nextSignalId = this._authPrompt.connect('next', 629 Lang.bind(this, function() { 633 Lang.bind(this, function() { 630 this._authPrompt.disconnect(nextSignalId); 634 this._authPrompt.disconnect(this._nextSignalId); 635 this._nextSignalId = 0; 631 this._authPrompt.updateSensitivity(false); 636 this._authPrompt.updateSensitivity(false); 632 let answer = this._authPrompt.getAnswer(); 637 let answer = this._authPrompt.getAnswer(); 633 this._user = this._userManager.get_user(answer); 638 this._user = this._userManager.get_user(answer); const LoginDialog = new Lang.Class({ 635 this._authPrompt.startSpinning(); 640 this._authPrompt.startSpinning(); 636 this._authPrompt.begin({ userName: answer }); 641 this._authPrompt.begin({ userName: answer }); 637 this._updateCancelButton(); 642 this._updateCancelButton(); 638 639 realmManager.disconnect(realmSignalId) 640 realmManager.release(); 641 })); 643 })); 642 this._updateCancelButton(); 644 this._updateCancelButton(); 643 this._showPrompt(); 645 this._showPrompt(); const LoginDialog = new Lang.Class({ 892 this._userManager.disconnect(this._userManagerLoadedId); 894 this._userManager.disconnect(this._userManagerLoadedId);
Comment on attachment 275471 [details] [review] prevent nextSignalId from being connected multiply times Please stop messing with the patch status (and spamming comments). Seriously.
This bug is killing us on our Fedora 20 lab machines. Students are expecting the password prompt and end up typing their passwords in cleartext! This could really be considered somewhat of a security problem! The patch that was supplied appears to fix the problem. This bug has been around since F20 was released (gnome-shell 3.10.2.1). Any chance we can get an official fix merged so we can backport the fix to gnome-shell in Fedora? RHBZ: https://bugzilla.redhat.com/show_bug.cgi?id=1073713
Dear @David sadly your patch does not longer apply against 3.10. Have you prepared an updated version, already?
Created attachment 278429 [details] [review] Blindly updated version of Davids patch works-for-me on current f20, NO warranties, please try. only the first of four hunks of davids patch failed to apply, and i just 'fixed'(?) it by putting the hunk's additions more or less at the same place as before.
Maybe i should also have noted, as it might eventually help getting this bug out of 'unconfirmed' state: To quickly and reliably reproduce the duplicate Username: prompt (even on non-LDAP, simply vanilla F20 boxes): - Just hit escape twice while the Username: prompt has focus or - Hit escape once at the password prompt to return to the Username: prompt. Then hit escape once again. Using the updated patch, only a cosmetic issue remains: While at the Username: prompt after escaping the Password: prompt, the button is labeled 'Sign in' while it should read 'Next' -- I am saying cosmetic, as without the patch this secondary issue is just worse (i.e. you'll get an additional 'cancel' button at the Username: prompt _and_ the 'Next' button being labeled 'Sign in').
We had the chance to test the patch and it works perfectly. Thanks Jan for your help.
For me the patch doesn't work (https://bugzilla.gnome.org/attachment.cgi?id=278429) There is another bug report here https://bugzilla.redhat.com/show_bug.cgi?id=1002464 my configuration : Fedora 20 x86_64 with gdm-3.10.0.1-1.fc20.x86_64 and [org/gnome/login-screen] disable-user-list=true with dconf_update
The good bug report on redhat bugzilla : https://bugzilla.redhat.com/show_bug.cgi?id=1092274
I've been encountering this issue with SSSD authenticating against AD and user list being hidden (as per our IS policies). Applying the patch Jan Hacker provided appears to have resolved our issue. This is on Fedora 20 64bit with the following versions: gdm-3.10.0.1-1.fc20.x86_64 gnome-shell-3.10.4-5.fc20.x86_64
Comment on attachment 275471 [details] [review] prevent nextSignalId from being connected multiply times thanks pushed
(In reply to Jan Hacker from comment #11) > Created attachment 278429 [details] [review] [review] > Blindly updated version of Davids patch > > works-for-me on current f20, NO warranties, please try. > only the first of four hunks of davids patch failed to apply, > and i just 'fixed'(?) it by putting the hunk's additions more > or less at the same place as before. thanks for updating it.
Seems to fix it for me on Debian 8/jessie too. Submitting to bugs.debian.org as well.