summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDennis Kaarsemaker <dennis@kaarsemaker.net>2017-11-03 21:44:49 +0100
committerJunio C Hamano <gitster@pobox.com>2017-11-04 10:59:21 +0900
commit9c109e9bbcadb21cd6f955301f81583a74f8aa8c (patch)
tree0347ce947a78a94cf5e19f9b263620c158fb2c81
parent39aaab109972d6bbc1d0ffe5d4de47bbd4b8bb07 (diff)
downloadgit-dk/libsecret-unlock-to-load-fix.tar.gz
credential-libsecret: unlock locked secretsdk/libsecret-unlock-to-load-fix
Credentials exposed by the secret service DBUS interface may be locked. Setting the SECRET_SEARCH_UNLOCK flag will make the secret service unlock these secrets, possibly prompting the user for credentials to do so. Without this flag, the secret is simply not loaded. Signed-off-by: Dennis Kaarsemaker <dennis@kaarsemaker.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
-rw-r--r--contrib/credential/libsecret/git-credential-libsecret.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/contrib/credential/libsecret/git-credential-libsecret.c b/contrib/credential/libsecret/git-credential-libsecret.c
index 4c56979d8a..b4750c9ee8 100644
--- a/contrib/credential/libsecret/git-credential-libsecret.c
+++ b/contrib/credential/libsecret/git-credential-libsecret.c
@@ -104,7 +104,7 @@ static int keyring_get(struct credential *c)
items = secret_service_search_sync(service,
SECRET_SCHEMA_COMPAT_NETWORK,
attributes,
- SECRET_SEARCH_LOAD_SECRETS,
+ SECRET_SEARCH_LOAD_SECRETS | SECRET_SEARCH_UNLOCK,
NULL,
&error);
g_hash_table_unref(attributes);