mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2025-12-31 00:50:12 +01:00
vpn: don't fail if no system secrets exist
The VPN connection requests secrets a few times; first it retrieves
only system-owned secrets to see if they are sufficient (and thus
doesn't need to bother the user), then it retrieves existing agent
owned secrets (so the user doesn't get a popup), then finally if
those aren't sufficient it asks the user interactively.
But if there was some error retrieving system secrets, or if there
weren't any system secrets at all, don't fail the VPN connection.
Just go on and ask the user for the secrets.
(cherry picked from commit 5b1cde1bfc)
This commit is contained in:
parent
aaf6e6b1cf
commit
a0ec4bf521
1 changed files with 1 additions and 1 deletions
|
|
@ -1894,7 +1894,7 @@ get_secrets_cb (NMSettingsConnection *connection,
|
|||
|
||||
priv->secrets_id = 0;
|
||||
|
||||
if (error) {
|
||||
if (error && priv->secrets_idx >= SECRETS_REQ_NEW) {
|
||||
nm_log_err (LOGD_VPN, "Failed to request VPN secrets #%d: (%d) %s",
|
||||
priv->secrets_idx + 1, error->code, error->message);
|
||||
_set_vpn_state (self, STATE_FAILED, NM_VPN_CONNECTION_STATE_REASON_NO_SECRETS, FALSE);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue