From a23ba089a4e715e68b8c8d4179290692215784a2 Mon Sep 17 00:00:00 2001 From: xengineering Date: Tue, 4 Jul 2023 22:04:05 +0200 Subject: Re-implement resource binding and presence This was removed for refactoring. --- xmpp/routing.go | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'xmpp/routing.go') diff --git a/xmpp/routing.go b/xmpp/routing.go index a9dd8b6..5cd2040 100644 --- a/xmpp/routing.go +++ b/xmpp/routing.go @@ -9,6 +9,10 @@ func route(s *xml.StartElement, d *xml.Decoder, c chan<- any) { switch (*s).Name { case xml.Name{`http://etherx.jabber.org/streams`, `features`}: parse(streamFeatures{}, s, d, c) + case xml.Name{`urn:ietf:params:xml:ns:xmpp-sasl`, `success`}: + parse(saslSuccess{}, s, d, c) + case xml.Name{`jabber:client`, `iq`}: + parse(iqResponse{}, s, d, c) default: d.Skip() } @@ -27,6 +31,10 @@ func handle(s *session, element any) { switch t := element.(type) { case streamFeatures: handleStreamFeatures(s, t) + case saslSuccess: + handleSaslSuccess(s) + case iqResponse: + handleIqResponse(s, t) default: log.Printf("Unknown parsed element: %v", t) } -- cgit v1.2.3-70-g09d2