This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 183494

Summary: [69cat] Master Password dialog required 2 clicks to close.
Product: platform Reporter: esmithbss <esmithbss>
Component: Options&SettingsAssignee: Jesse Glick <jglick>
Status: RESOLVED INVALID    
Severity: normal CC: converginglight, jglick
Priority: P4    
Version: 6.x   
Hardware: PC   
OS: Linux   
Issue Type: DEFECT Exception Reporter:
Bug Depends on:    
Bug Blocks: 173413    

Description esmithbss 2010-04-05 15:55:18 UTC
[ BUILD # : 201004050201 ]
[ JDK VERSION : 1.6.* ]

Product Version = NetBeans IDE Dev (Build 201004050201)
Operating System = Linux version 2.6.32-19-generic running on i386
Java; VM; Vendor = 1.6.0_19
Runtime = Java HotSpot(TM) Client VM 16.2-b04

When first launching 201004050201, the Master Password dialog that is displayed
was redisplayed after the first "Cancel" click.  When a user cancels the
dialog, it needs to remain canceled.  This is equivalent to the user saying
"Don't use a Master Password."
Comment 1 Jesse Glick 2010-04-06 13:05:21 UTC
(In reply to comment #0)
> When a user cancels the
> dialog, it needs to remain canceled. This is equivalent to the user saying
> "Don't use a Master Password."

There is no option to not use a master password for disk storage; the dialog will be opened again whenever another request for a stored password arrives. Cancel could however be interpreted as "do not remember any passwords" (or "remember passwords only during the current IDE session but do not persist them").

Anyway you should not be seeing the Master Password dialog to begin with, at least assuming you are using either GNOME or KDE, since there is native keyring integration available for both these platforms. Please add -J-Dorg.netbeans.modules.keyring.level=0 to netbeans.conf and file a _separate bug_ in this component with a copy of your log file; that should help diagnose the reason the native keyring is not being loaded.
Comment 2 Jesse Glick 2010-04-06 15:04:27 UTC
*** Bug 183495 has been marked as a duplicate of this bug. ***
Comment 3 Jesse Glick 2010-04-06 15:05:20 UTC
*** Bug 183497 has been marked as a duplicate of this bug. ***
Comment 4 esmithbss 2010-04-06 15:13:13 UTC
Why is there no option to not use a master password?  

That seems like an individual developers choice, not something that should be forced or imposed on the user.

I agree that if the platform has a keyring it should be used, but even the platforms have the option of using a master password for their keyring
Comment 5 Jesse Glick 2010-04-06 15:19:45 UTC
(In reply to comment #4)
> Why is there no option to not use a master password?

Because then passwords would have to be stored unencrypted.

> even the platforms have the option of using a master password for their keyring

In the case of the GNOME Keyring, the default keyring (what NB uses) is unlocked by the login in a typical Linux setup. (On Solaris a separate keyring password seems to be prompted for.) AFAIK there is no option to leave the storage unprotected.
Comment 6 Jesse Glick 2010-05-06 13:45:18 UTC
After 63255a322a36, you will be prompted to reset the master password; if you decline it will not show up again in that session.
Comment 7 converginglight 2010-06-01 14:17:22 UTC
It does show up for me EVERYTIME (in all nighty builds since several months), and I need to hit [Esc] three times at EVERY startup :(

Suggestions?
Comment 8 converginglight 2010-06-01 19:41:55 UTC
Correction: Most times I need to hit [Esc] two times, but sometimes it's three times.

Algorithm:

- "Enter Master Password" dialog shows up;
- I hit [Esc];
- eventually the two steps above again;
- "Delete Stored Passwords" dialog shows up;
- I hit [Esc];
Comment 9 converginglight 2010-06-07 21:17:20 UTC
In case it's relevant:

Neither adding
    -J-Dorg.netbeans.modules.keyring.level=0
to netbeans.conf, not appending it as Netbeans' start parameter prevents the annoying dialogs from appearing.

I'm using 6.9-rc2, but it applies also to nighties before rc2.
Comment 10 Jesse Glick 2010-06-10 15:17:43 UTC
(In reply to comment #8)
> - "Enter Master Password" dialog shows up;
> - I hit [Esc];
> - eventually the two steps above again;
> - "Delete Stored Passwords" dialog shows up;
> - I hit [Esc];

Accept the option to delete the stored passwords. Then you can set a new master password.

(In reply to comment #9)
> Neither adding
>     -J-Dorg.netbeans.modules.keyring.level=0
> to netbeans.conf, not appending it as Netbeans' start parameter prevents the
> annoying dialogs from appearing.

Nor should it; this flag turns on logging, which would tell you why native keyring integration (GNOME or KDE) is not getting loaded and thus why the master password dialog ever appeared to begin with.
Comment 11 converginglight 2010-06-10 20:30:24 UTC
Yes: WHEN I accept the option to delete the password, and set a master password, then it is also asked at every start-up.

So it's more annoyance then hitting [esc] multiple times.

It's an anti-feature.
Comment 12 Jesse Glick 2010-06-10 21:27:44 UTC
(In reply to comment #11)
> WHEN I accept the option to delete the password, and set a master
> password, then it is also asked at every start-up.

Right - because something needs to load your passwords. So enter your master password and it will not be shown again.
Comment 13 converginglight 2010-08-17 18:04:09 UTC
> Right - because something needs to load your passwords.

I figured out that it is the Subversion module.
I am using several local repositories, but I can login there with username only (no password, because they're local anyway).
You mentioned that NB doesn't want no store unencrypted passwords. Well, in this case there are no passwords to store, just the username(s).

Would it be very complicated to make the Subversion module request this set-master-password-"feature" ONLY when some subversion-passwords are actually used?


> So enter your master password and it will not be shown again.

Except on each start, right? (Which is the case in my case)


Sorry to come up with that topic again.
Comment 14 Jesse Glick 2010-08-17 19:10:49 UTC
(In reply to comment #13)
> Would it be very complicated to make the Subversion module request this
> set-master-password-"feature" ONLY when some subversion-passwords are actually
> used?

That is how I would expect it to work; file a bug with steps to reproduce in the versioncontrol component if it does not.

>> enter your master password and it will not be shown again.
> 
> Except on each start, right?

Right, once per start.

Again, a better path would be to figure out why the GNOME Keyring (or KWallet) integration is not working in your case, using the logging flags I indicated.
Comment 15 converginglight 2011-02-28 18:08:24 UTC
Strange, but this bug went away, since around 7.0 beta or so.

(I mean the new 7.0, not that old one which became 6.7 or 6.9 or whatever).
Comment 16 converginglight 2011-08-22 14:52:02 UTC
I have to recall my last comment. The dialog did NOT went away.
As soon as I use remote SVN, I have to be annoyed by that dialog to enter anything even when NOT using a password for SVN itself.

Same as stated in this bug [ http://netbeans.org/bugzilla/show_bug.cgi?id=189644 ] in this attachment [ http://netbeans.org/bugzilla/attachment.cgi?id=101658 ], I have the following log line:

> FINE [org.netbeans.modules.keyring.gnome.GnomeProvider]: no GNOME_KEYRING_* environment variable set

One MIGHT assume, that's a desktop environment's "problem". But NB is the only app to fail on this, so it's NB's problem. It seems to be a frequent issue under KDE.

Possibly related bugs:
http://netbeans.org/bugzilla/show_bug.cgi?id=193978
http://netbeans.org/bugzilla/show_bug.cgi?id=189644
...and many many others, sadly I can't find right now.
Comment 17 Jesse Glick 2011-08-22 22:34:32 UTC
(In reply to comment #16)
>> FINE [org.netbeans.modules.keyring.gnome.GnomeProvider]: no GNOME_KEYRING_* environment variable set
> 
> It seems to be a frequent issue under KDE.

The above line is correct if you are using KDE; there is a separate integration with KWallet, but apparently

  qdbus org.kde.kwalletd /modules/kwalletd org.kde.KWallet.isEnabled

failed.