summaryrefslogtreecommitdiff
path: root/itches
diff options
context:
space:
mode:
authorKévin Le Gouguec <kevin.legouguec@gmail.com>2020-10-09 23:18:13 +0200
committerKévin Le Gouguec <kevin.legouguec@gmail.com>2020-10-09 23:19:39 +0200
commitf9817cf817ed8337bfa55e30e7d32d5d1a74c2c7 (patch)
tree4d27ccd912192a88fc08abc179e23184cd54725d /itches
parent50aef4a8e2b6a53c12febf3728dfd0587915d248 (diff)
downloadmemory-leaks-f9817cf817ed8337bfa55e30e7d32d5d1a74c2c7.tar.xz
Note down ERC itch
Diffstat (limited to 'itches')
-rw-r--r--itches/emacs/tracker.org48
1 files changed, 48 insertions, 0 deletions
diff --git a/itches/emacs/tracker.org b/itches/emacs/tracker.org
index ba198b0..bec0311 100644
--- a/itches/emacs/tracker.org
+++ b/itches/emacs/tracker.org
@@ -154,6 +154,54 @@ Fixed by Dmitry.
:TestAdded: t
:END:
My commit message ran afoul of debbugs.el's =M-m= again.
+*** ERC
+**** TODO Support SASL authentication
+Got bitten by this when trying to connect to irc.freenode.net from
+=alyon-654-1-454-60.w109-213.abo.wanadoo.fr=:
+#+begin_quote
+ERROR from irc.freenode.net: Closing Link:
+alyon-654-1-454-60.w109-213.abo.wanadoo.fr (SASL access only)
+#+end_quote
+
+This was requested in [[bug:29108]]. Lars closed this report because
+while there is a third-party package to implement the feature, its
+author did not respond when prompted for copyright assignment.
+
+I did not have the patience to look at the package; instead I went
+straight to [[https://ircv3.net/specs/extensions/sasl-3.1][the description of SASL on ircv3.net]] and the [[https://tools.ietf.org/html/rfc4616#section-2][RFC for the
+=PLAIN= mechanism]], and cobbled this silly patch:
+
+#+begin_src diff
+diff --git a/lisp/erc/erc.el b/lisp/erc/erc.el
+index 1d5506e281..0da677ac18 100644
+--- a/lisp/erc/erc.el
++++ b/lisp/erc/erc.el
+@@ -6052,7 +6052,17 @@ erc-login
+ erc-session-server
+ erc-session-user-full-name))
+ (if erc-session-password
+- (erc-server-send (format "PASS %s" erc-session-password))
++ (progn
++ (erc-server-send "CAP REQ :sasl")
++ (erc-server-send "AUTHENTICATE PLAIN")
++ (erc-server-send
++ (concat "AUTHENTICATE " (base64-encode-string
++ (string-join (list
++ (user-login-name)
++ (erc-current-nick)
++ erc-session-password)
++ "\0"))))
++ (erc-server-send "CAP END"))
+ (message "Logging in without password"))
+ (erc-server-send (format "NICK %s" (erc-current-nick)))
+ (erc-server-send
+#+end_src
+
+AFAICT this is enough to get me authenticated on Freenode. It looks
+like it's not too hard to implement?
+
+Ideally Emacs's builtin =sasl.el= should be reused; that would let ERC
+support better SASL mechanisms than =PLAIN=.
*** Gnus
**** DONE [[bug:40520]] Prevent duplicate thread titles
:PROPERTIES: