mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-27 05:09:23 +01:00
Fix registration timeout when SASL is refused
https://github.com/ProgVal/Limnoria/issues/854#issuecomment-70414650
This commit is contained in:
parent
7b7a515568
commit
bf418756a9
@ -962,13 +962,12 @@ class Irc(IrcCommandDispatcher):
|
||||
elif self.sasl_username and self.sasl_password:
|
||||
self.sasl = 'plain'
|
||||
|
||||
if self.sasl:
|
||||
self.queueMsg(ircmsgs.IrcMsg(command='CAP', args=('REQ', 'sasl')))
|
||||
|
||||
self.queueMsg(ircmsgs.IrcMsg(command='CAP', args=('REQ', 'account-notify')))
|
||||
self.queueMsg(ircmsgs.IrcMsg(command='CAP', args=('REQ', 'extended-join')))
|
||||
|
||||
if not self.sasl:
|
||||
if self.sasl:
|
||||
self.queueMsg(ircmsgs.IrcMsg(command='CAP', args=('REQ', 'sasl')))
|
||||
else:
|
||||
self.queueMsg(ircmsgs.IrcMsg(command='CAP', args=('END',)))
|
||||
|
||||
if self.password:
|
||||
@ -1031,6 +1030,11 @@ class Irc(IrcCommandDispatcher):
|
||||
log.warning('%s: Server refused capability %r',
|
||||
self.network, cap)
|
||||
|
||||
if cap == 'sasl':
|
||||
self.queueMsg(ircmsgs.IrcMsg(
|
||||
command='CAP',
|
||||
args=('END',)))
|
||||
|
||||
def do903(self, msg):
|
||||
log.info('%s: SASL authentication successful', self.network)
|
||||
self.queueMsg(ircmsgs.IrcMsg(command='CAP', args=('END',)))
|
||||
|
Loading…
Reference in New Issue
Block a user