Fix SASL where additional caps are requested

Where additional caps were requested using `RequestCaps`, SASL would
send an `AUTHENTICATE` command for each one which servers don't like.
Check that we're responding to the correct `CAP ACK`.
This commit is contained in:
Russ Garrett 2019-02-21 12:20:50 +00:00
parent 14f3614f28
commit 9fa2a77567
No known key found for this signature in database
GPG Key ID: 68880BB652AB0570

View File

@ -20,7 +20,7 @@ func (irc *Connection) setupSASLCallbacks(result chan<- *SASLResult) {
result <- &SASLResult{true, errors.New("no SASL capability " + e.Arguments[2])}
}
}
if e.Arguments[1] == "ACK" {
if e.Arguments[1] == "ACK" && e.Arguments[2] == "sasl" {
if irc.SASLMech != "PLAIN" {
result <- &SASLResult{true, errors.New("only PLAIN is supported")}
}