[network-manager-vpnc] auth-dialog: always return found secrets for ExternalUiMode
- From: Dan Williams <dcbw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [network-manager-vpnc] auth-dialog: always return found secrets for ExternalUiMode
- Date: Wed, 4 Dec 2013 21:52:17 +0000 (UTC)
commit 942e59d36a05a8d5a23ff8c020718a730b06ebb8
Author: Dan Williams <dcbw redhat com>
Date: Wed Dec 4 15:50:07 2013 -0600
auth-dialog: always return found secrets for ExternalUiMode
Like the original stdout-based communication, always return any secrets
which were found. If the secret doesn't need to be requeted from the
user, ensure "ShouldAsk" is FALSE.
This fixes a problem with GNOME Shell where both secrets were
stored by the user agent. Since agents delete any saved secrets before
saving new secrets, this would delete the "IPSec secret" item, but since
that item was not included in the returned secrets, it wouldn't be
re-saved, and would be lost.
auth-dialog/main.c | 6 ++----
1 files changed, 2 insertions(+), 4 deletions(-)
---
diff --git a/auth-dialog/main.c b/auth-dialog/main.c
index 178facf..62ae146 100644
--- a/auth-dialog/main.c
+++ b/auth-dialog/main.c
@@ -203,10 +203,8 @@ get_secrets (const char *vpn_uuid,
g_key_file_set_string (keyfile, UI_KEYFILE_GROUP, "Description", prompt);
g_key_file_set_string (keyfile, UI_KEYFILE_GROUP, "Title", _("Authenticate VPN"));
- if (need_upw)
- keyfile_add_entry_info (keyfile, NM_VPNC_KEY_XAUTH_PASSWORD, upw ? upw : "",
_("Password:"), TRUE, allow_interaction);
- if (need_gpw)
- keyfile_add_entry_info (keyfile, NM_VPNC_KEY_SECRET, gpw ? gpw : "", _("Group
Password:"), TRUE, allow_interaction);
+ keyfile_add_entry_info (keyfile, NM_VPNC_KEY_XAUTH_PASSWORD, upw ? upw : "", _("Password:"),
TRUE, need_upw && allow_interaction);
+ keyfile_add_entry_info (keyfile, NM_VPNC_KEY_SECRET, gpw ? gpw : "", _("Group Password:"),
TRUE, need_gpw && allow_interaction);
keyfile_print_stdout (keyfile);
g_key_file_unref (keyfile);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]