Not logged in. · Lost password · Register
Forum: agsXMPP RSS
Avatar
flyingmoose #1
Member since Feb 2017 · 1 post
Group memberships: Members
Show profile · Link to this post
Subject: Firebase Problems, Please help!
I'm trying to use agsXMPP to connect to google's firebase service, using the following client connection definition:
  1. xmpp = new XmppClientConnection("fcm-xmpp.googleapis.com",5235);
  2. xmpp.Username = Cfg.Id + "@gcm.googleapis.com";
  3. xmpp.Password = Cfg.AccessKey;
  4. xmpp.KeepAlive = true;
  5. xmpp.UseSSL = true;
  6. xmpp.UseStartTLS = false;
  7. xmpp.AutoRoster = false;
  8. xmpp.AutoPresence = false;

Logs below.

  1. 2017-02-02 21:47:31,665 INFO  r.Service.GcmService: Connection State Changed To: Connecting
  2. 2017-02-02 21:47:31,935 INFO  r.Service.GcmService: Connection State Changed To: Connected
  3. 2017-02-02 21:47:31,936 INFO  r.Service.GcmService: SND: <stream:stream to='fcm-xmpp.googleapis.com' xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' version='1.0' xml:lang='en'>
  4. 2017-02-02 21:47:32,007 INFO  r.Service.GcmService: REC: <stream:stream xmlns:stream="http://etherx.jabber.org/streams" version="1.0" id="(REMOVED)" from="fcm-xmpp.googleapis.com" >
  5. 2017-02-02 21:47:32,014 INFO  r.Service.GcmService: REC: <stream:features xmlns:stream="http://etherx.jabber.org/streams"><mechanisms xmlns="urn:ietf:params:xml:ns:xmpp-sasl"><mechanism>X-OAUTH2</mechanism><mechanism>X-GOOGLE-TOKEN</mechanism><mechanism>PLAIN</mechanism></mechanisms></stream:features>
  6. 2017-02-02 21:47:32,020 INFO  r.Service.GcmService: SND: <auth xmlns="urn:ietf:params:xml:ns:xmpp-sasl" mechanism="PLAIN">(REMOVED)</auth>
  7. 2017-02-02 21:47:32,054 INFO  r.Service.GcmService: REC: <failure xmlns="urn:ietf:params:xml:ns:xmpp-sasl"><not-authorized /></failure>
  8. 2017-02-02 21:47:32,055 INFO  r.Service.GcmService: REC: </stream:stream>
  9. 2017-02-02 21:47:32,056 INFO  r.Service.GcmService: Connection State Changed To: Disconnected

I noticed the Access key being sent does not match the key I'm providing, not sure if its being encoded somewhere along the way. and I'm concerned that agxmpp doesnt have the OldStyleSsl option that MatriX has in all its examples. Anyone have experience getting this to work correctly? I can connect just fine with the credentials via a node-xcs app.
This post was edited on 2017-02-23, 03:09 by flyingmoose.
Avatar
Alex #2
Member since Feb 2003 · 4327 posts · Location: Germany
Group memberships: Administrators, Members
Show profile · Link to this post
Please look at this blog post:
https://www.ag-software.net/2016/09/24/firebase-cloud-mess…

Your XMPP domain seems to be wrong.
Please check also if your username is set to the correct Sender id.

Alex
Close Smaller – Larger + Reply to this post:
Verification code: VeriCode Please enter the word from the image into the text field below. (Type the letters only, lower case is okay.)
Smileys: :-) ;-) :-D :-p :blush: :cool: :rolleyes: :huh: :-/ <_< :-( :'( :#: :scared: 8-( :nuts: :-O
Special characters:
Forum: agsXMPP RSS