tramp-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Passwords, stored in Gnome Keyring and KWallet


From: Ted Zlatanov
Subject: Re: Passwords, stored in Gnome Keyring and KWallet
Date: Tue, 23 Mar 2010 13:06:04 -0500
User-agent: Gnus/5.110011 (No Gnus v0.11) Emacs/24.0.50 (gnu/linux)

The major problem so far is that secrets-search-items on a nil (matching
any) collection doesn't tell me what collection matched.  So then I
can't say

(secrets-get-attributes nil (car (secrets-search-items nil :user "joe")))

to find the attributes of that item (although 

(secrets-get-secret nil "my item") 

does work, so this only fails when I need attributes).

When I do know the session, things work.  Attached is a patch to show
how auth-source-pick and auth-source-user-or-password would change, on
top of the recent check-ins to Gnus.  Basically auth-source-pick bakes a
list of results that includes the found collection in :search and the
found item in :item.  Then auth-source-user-or-password looks up the
:user attribute for the "login" attribute and the secret for the
"password" attribute.

The default session is looked up as the "default" alias and if that
fails, as the "default" session (with a message).  Otherwise most of the
code converts between the nil "match all" session parameter in
secrets.el and the t "match all" in auth-source.el and massages the
results.

I also redid the auth-sources customization a little bit.

If you can follow this, great.  Otherwise if you think it's too
complicated, it's time to redo auth-source.el to be more flexible about
taking extra parameters.  As the author it's hard for me to say if that
time is now :)

Ted

Attachment: auth-secrets.patch
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]