* Unable to authenticate to local dovecot server in Gnus using password-store as auth-source backend
@ 2022-10-26 19:08 bk
2022-10-27 8:24 ` Robert Pluim
0 siblings, 1 reply; 4+ messages in thread
From: bk @ 2022-10-26 19:08 UTC (permalink / raw)
To: ding
Hi,
As is written in subject I can't authenticate to my local dovecot server
when I have enabled pass backend in auth-source. I don't have this
problem in default ~/.authinfo file. If it's not exist it's generated by
Emacs and contain line as follows:
machine localhost login bk@asterio.cloud password pass
My minimal ~/.emacs file
(setq auth-source-debug 'trivia)
(setq auth-sources '(password-store))
(setq gnus-select-method '(nnnil ""))
(setq gnus-secondary-select-methods
'((nnimap "localhost"
(nnimap-address "127.0.0.1")
(nnimap-stream network)
(nnimap-authenticator login)
(nnimap-server-port 1143)
(nnimap-user "bk@asterio.cloud"))))
According to documentation [1] I tried numerous of entries of my user
password entry in pass:
pass ls
Password Store
├── 127.0.0.1
│ └── bk@asterio.cloud
├── bk@asterio.cloud@127.0.0.1
├── bk@asterio.cloud@localhost
└── localhost
└── bk@asterio.cloud
But none of this works and in *Messages* buffer I have always following
logs:
auth-source-backend-parse: invalid backend spec: password-store
auth-source-search: found 1 backends matching (:max 1 :host ("localhost"
"127.0.0.1") :port (1143 "imap" "143") :user "bk@asterio.cloud" :require
(:user :secret) :create t)
auth-source-search: found 0 results (max 1) matching (:max 1 :host
("localhost" "127.0.0.1") :port (1143 "imap" "143") :user
"bk@asterio.cloud" :require (:user :secret) :create t)
auth-source-search: CREATED 0 results (max 1) matching (:max 1 :host
("localhost" "127.0.0.1") :port (1143 "imap" "143") :user
"bk@asterio.cloud" :require (:user :secret) :create t)
Opening nnimap server on localhost...failed:
Does anyone has similar setup and it works?
[1]
https://www.gnu.org/software/emacs/manual/html_node/auth/The-Unix-password-store.html
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Unable to authenticate to local dovecot server in Gnus using password-store as auth-source backend
2022-10-26 19:08 Unable to authenticate to local dovecot server in Gnus using password-store as auth-source backend bk
@ 2022-10-27 8:24 ` Robert Pluim
2022-10-27 8:43 ` Emanuel Berg
0 siblings, 1 reply; 4+ messages in thread
From: Robert Pluim @ 2022-10-27 8:24 UTC (permalink / raw)
To: bk; +Cc: ding
>>>>> On Wed, 26 Oct 2022 21:08:33 +0200, bk@asterio.cloud said:
bk> My minimal ~/.emacs file
bk> (setq auth-source-debug 'trivia)
bk> (setq auth-sources '(password-store))
bk> (setq gnus-select-method '(nnnil ""))
bk> (setq gnus-secondary-select-methods
bk> '((nnimap "localhost"
bk> (nnimap-address "127.0.0.1")
bk> (nnimap-stream network)
bk> (nnimap-authenticator login)
bk> (nnimap-server-port 1143)
bk> (nnimap-user "bk@asterio.cloud"))))
Iʼve never used pass, but thatʼs not how the manual describes enabling
'pass' support. From (info "(auth) Help for users")
-- Variable: auth-sources
The ‘auth-sources’ variable tells the auth-source library where
your netrc files, Secret Service API collection items, or your
password store live for a particular host and protocol. While you
can get fancy, the default and simplest configuration is:
;;; old default: required :host and :port, not needed anymore
(setq auth-sources '((:source "~/.authinfo.gpg" :host t :port t)))
;;; mostly equivalent (see below about fallbacks) but shorter:
(setq auth-sources '((:source "~/.authinfo.gpg")))
;;; even shorter and the _default_:
(setq auth-sources '("~/.authinfo.gpg" "~/.authinfo" "~/.netrc"))
;;; use the Secrets API LOGIN collection
;;; (*note Secret Service API::)
(setq auth-sources '("secrets:Login"))
;;; use pass (~/.password-store)
;;; (*note The Unix password store::)
(auth-source-pass-enable) <--------------------------
;;; JSON data in format [{ "machine": "SERVER",
;;; "login": "USER", "password": "PASSWORD" }...]
(setq auth-sources '("~/.authinfo.json.gpg"))
Robert
--
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Unable to authenticate to local dovecot server in Gnus using password-store as auth-source backend
2022-10-27 8:24 ` Robert Pluim
@ 2022-10-27 8:43 ` Emanuel Berg
2022-10-27 9:18 ` Bartosz Kaczyński
0 siblings, 1 reply; 4+ messages in thread
From: Emanuel Berg @ 2022-10-27 8:43 UTC (permalink / raw)
To: ding
Robert Pluim wrote:
> I've never used pass, but that's not how the manual
> describes enabling 'pass' support. From (info "(auth) Help
> for users")
Yeah, in ~/.authinfo one line is, e.g.
machine libera.chat password ****
Then you do this to retrieve it
(auth-source-pick-first-password :host "libera.chat")
But if you eval it now you still don't get my password LOL
--
underground experts united
https://dataswamp.org/~incal
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Unable to authenticate to local dovecot server in Gnus using password-store as auth-source backend
2022-10-27 8:43 ` Emanuel Berg
@ 2022-10-27 9:18 ` Bartosz Kaczyński
0 siblings, 0 replies; 4+ messages in thread
From: Bartosz Kaczyński @ 2022-10-27 9:18 UTC (permalink / raw)
To: ding
On 10/27/22 10:43, Emanuel Berg wrote:
> Robert Pluim wrote:
>
>> I've never used pass, but that's not how the manual
>> describes enabling 'pass' support. From (info "(auth) Help
>> for users")
>
> Yeah, in ~/.authinfo one line is, e.g.
>
> machine libera.chat password ****
>
> Then you do this to retrieve it
>
> (auth-source-pick-first-password :host "libera.chat")
>
> But if you eval it now you still don't get my password LOL
>
Indeed, in Emacs build from master branch the command and manual differs
from the manual on website [1]
Now my config looks as follows:
(use-package auth-source
:config
(auth-source-pass-enable))
and I can authenticate to the server.
Thank you!
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2022-10-27 9:20 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-10-26 19:08 Unable to authenticate to local dovecot server in Gnus using password-store as auth-source backend bk
2022-10-27 8:24 ` Robert Pluim
2022-10-27 8:43 ` Emanuel Berg
2022-10-27 9:18 ` Bartosz Kaczyński
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).