Closed computersarecool closed 7 years ago
You can set circe-pass
to a function that returns the password. Does that help?
I am not sure I follow. In the documentation you give a helpful example of how to define a function called my-sasl-password
which reads a file.
This is set in the sasl-password
parameter of circe-network-options
. Are you saying that I could instead set the sasl-password
to a function and it would ask me to enter it each time?
@computersarecool That's the idea. How the function fetches the password is irrelevant (be it from a file, via user input, some credentials store, ...) as long as it returns the password so that Circe can use it. read-passwd
is a ready-made one for this purpose.
Sorry, got the variable names confused :-)
@jorgenschaefer Thanks for clearing up and @wasamasa Thanks so much!
I just have to fill in the field like so:
:sasl-password (lambda (x) (read-passwd "SASL password: "))
Hi there. I have this setup, but it doesn't seem to work. The only way I was passing simple strings. Authentication fails even though the pass' helper function seems to work. How can I check what's actuall passed through?
(after! circe
(set-irc-server! "Libera Chat (EU)"
'(:tls t
:host "irc.eu.libera.chat"
:port 6697
:nick "nashdidan"
:sasl-username ,(+pass-get-user "irc/libera.chat")
:sasl-password (lambda (&rest _) (+pass-get-secret "irc/libera.chat"))
:channels ("#emacs" "#guix" "#org-mode"))))
I would suggest to use auths-source-pass
and then set auth-source-debug
. Doing so will tell you everything is passed to circe.
See here if you want to use my setup: https://github.com/emacs-circe/circe/issues/82#issuecomment-1146557901
But if you want to to keep using that setup try to look in to the docs of pass-get-secret how to make it more verbose.
@oatmealm You need to use a backtick (instead of a quote) in combination with the comma, it will not work otherwise.
Thanks guys for the help. It worked with the backtick as suggested.
I have to use SASL to connect to Freenode, but sometimes I want to connect via Circe on a computer where I would not like to store my private SASL password.
Is there a way that I can just type in the password during login instead of being forced to store it externally?