Gmail S2S outgoing only, need fix for incoming

Hi All,

As the subject states, I can send IMs from my Openfire 3.4.5 server to Gmail, but can’t receive IMs from Gmail – Gtalk displays "user@email.com is offline and can’t receive messages right now". I’ve setup S2S and the SRV records according to the FAQs and forwarded the necessary ports on our firewall. I created test accounts on jabber.org and foxybanana.com, from which I am able to send/receive IMs, get status messages, add contacts perfectly via S2S. Just can’t get our server to work with Gmail successfully and seeking assistance.

Here is a debug log of trying to IM between Spark and Gtalk:

— Marker inserted by administrator at Mar 31, 2008 10:44:44 AM —

2008.03.31 10:45:14 Received iq packet: <iq id=“Pixey-243” to=“irc.hammerheadsystems.com” type=“get” from="jzell@hammerheadsystems.com/spark"><query xmlns=“http://jabber.org/protocol/disco#info”/></iq>

2008.03.31 10:45:14 irc: Sending packet: <iq type=“result” id=“Pixey-243” from=“irc.hammerheadsystems.comto="jzell@hammerheadsystems.com/spark"><query xmlns=“http://jabber.org/protocol/disco#info”><identity category=“gateway” type=“irc” name=“IRC Transport”/><feature var=“http://jabber.org/protocol/disco#info”/><feature var=“http://jabber.org/protocol/disco#items”/><feature var=“jabber:iq:gateway”/><feature var=“jabber:iq:register”/><feature var=“jabber:iq:version”/><feature var=“vcard-temp”/></query></iq>

2008.03.31 10:45:14 Received iq packet: <iq id=“Pixey-244” to=“yahoo.hammerheadsystems.com” type=“get” from="jzell@hammerheadsystems.com/spark"><query xmlns=“http://jabber.org/protocol/disco#info”/></iq>

2008.03.31 10:45:14 yahoo: Sending packet: <iq type=“result” id=“Pixey-244” from=“yahoo.hammerheadsystems.comto="jzell@hammerheadsystems.com/spark"><query xmlns=“http://jabber.org/protocol/disco#info”><identity category=“gateway” type=“yahoo” name=“Yahoo! Transport”/><feature var=“http://jabber.org/protocol/disco#info”/><feature var=“http://jabber.org/protocol/disco#items”/><feature var=“jabber:iq:gateway”/><feature var=“jabber:iq:register”/><feature var=“jabber:iq:version”/><feature var=“vcard-temp”/></query></iq>

2008.03.31 10:45:14 Received iq packet: <iq id=“Pixey-245” to=“msn.hammerheadsystems.com” type=“get” from="jzell@hammerheadsystems.com/spark"><query xmlns=“http://jabber.org/protocol/disco#info”/></iq>

2008.03.31 10:45:14 msn: Sending packet: <iq type=“result” id=“Pixey-245” from=“msn.hammerheadsystems.comto="jzell@hammerheadsystems.com/spark"><query xmlns=“http://jabber.org/protocol/disco#info”><identity category=“gateway” type=“msn” name=“MSN Transport”/><feature var=“http://jabber.org/protocol/disco#info”/><feature var=“http://jabber.org/protocol/disco#items”/><feature var=“jabber:iq:gateway”/><feature var=“jabber:iq:register”/><feature var=“jabber:iq:version”/><feature var=“vcard-temp”/></query></iq>

2008.03.31 10:45:14 Received iq packet: <iq id=“Pixey-246” to=“gtalk.hammerheadsystems.com” type=“get” from="jzell@hammerheadsystems.com/spark"><query xmlns=“http://jabber.org/protocol/disco#info”/></iq>

2008.03.31 10:45:14 gtalk: Sending packet: <iq type=“result” id=“Pixey-246” from=“gtalk.hammerheadsystems.comto="jzell@hammerheadsystems.com/spark"><query xmlns=“http://jabber.org/protocol/disco#info”><identity category=“gateway” type=“gtalk” name=“Google Talk Transport”/><feature var=“http://jabber.org/protocol/disco#info”/><feature var=“http://jabber.org/protocol/disco#items”/><feature var=“jabber:iq:gateway”/><feature var=“jabber:iq:register”/><feature var=“jabber:iq:version”/><feature var=“vcard-temp”/></query></iq>

2008.03.31 10:45:14 Received iq packet: <iq id=“Pixey-247” to=“aim.hammerheadsystems.com” type=“get” from="jzell@hammerheadsystems.com/spark"><query xmlns=“http://jabber.org/protocol/disco#info”/></iq>

2008.03.31 10:45:14 aim: Sending packet: <iq type=“result” id=“Pixey-247” from=“aim.hammerheadsystems.comto="jzell@hammerheadsystems.com/spark"><query xmlns=“http://jabber.org/protocol/disco#info”><identity category=“gateway” type=“aim” name=“AIM Transport”/><feature var=“http://jabber.org/protocol/disco#info”/><feature var=“http://jabber.org/protocol/disco#items”/><feature var=“jabber:iq:gateway”/><feature var=“jabber:iq:register”/><feature var=“jabber:iq:version”/><feature var=“vcard-temp”/></query></iq>

2008.03.31 10:45:14 Received iq packet: <iq id=“Pixey-248” to=“icq.hammerheadsystems.com” type=“get” from="jzell@hammerheadsystems.com/spark"><query xmlns=“http://jabber.org/protocol/disco#info”/></iq>

2008.03.31 10:45:14 icq: Sending packet: <iq type=“result” id=“Pixey-248” from=“icq.hammerheadsystems.comto="jzell@hammerheadsystems.com/spark"><query xmlns=“http://jabber.org/protocol/disco#info”><identity category=“gateway” type=“icq” name=“ICQ Transport”/><feature var=“http://jabber.org/protocol/disco#info”/><feature var=“http://jabber.org/protocol/disco#items”/><feature var=“jabber:iq:gateway”/><feature var=“jabber:iq:register”/><feature var=“jabber:iq:version”/><feature var=“vcard-temp”/></query></iq>

2008.03.31 10:45:14 Received iq packet: <iq id=“Pixey-249” to=“gadugadu.hammerheadsystems.com” type=“get” from="jzell@hammerheadsystems.com/spark"><query xmlns=“http://jabber.org/protocol/disco#info”/></iq>

2008.03.31 10:45:14 gadugadu: Sending packet: <iq type=“result” id=“Pixey-249” from=“gadugadu.hammerheadsystems.comto="jzell@hammerheadsystems.com/spark"><query xmlns=“http://jabber.org/protocol/disco#info”><identity category=“gateway” type=“gadugadu” name=“Gadu-Gadu Transport”/><feature var=“http://jabber.org/protocol/disco#info”/><feature var=“http://jabber.org/protocol/disco#items”/><feature var=“jabber:iq:gateway”/><feature var=“jabber:iq:register”/><feature var=“jabber:iq:version”/><feature var=“vcard-temp”/></query></iq>

2008.03.31 10:45:23 006630 -000001 (01/05/00) - Connection #28 tested: OK

2008.03.31 10:45:23 006631 -000001 (01/05/00) - Connection #28 tested: OK

2008.03.31 10:45:23 006631 -000001 (01/05/00) - Connection #29 tested: OK

2008.03.31 10:45:23 006632 -000001 (01/05/00) - Connection #29 tested: OK

2008.03.31 10:45:23 LocalOutgoingServerSession: OS - Trying to connect to gmail.com:5269(DNS lookup: xmpp-server.l.google.com:5269)

2008.03.31 10:45:23 LocalOutgoingServerSession: OS - Plain connection to gmail.com:5269 successful

2008.03.31 10:45:23 LocalOutgoingServerSession: OS - Going to try connecting using server dialback with: gmail.com

2008.03.31 10:45:23 ServerDialback: OS - Trying to connect to gmail.com:5269(DNS lookup: xmpp-server1.l.google.com:5269)

2008.03.31 10:45:23 ServerDialback: OS - Connection to gmail.com:5269 successful

2008.03.31 10:45:23 ServerDialback: OS - Sent dialback key to host: gmail.com id: ABBB1FDBF438407F from domain: hammerheadsystems.com

2008.03.31 10:45:24 Connect Socket[http://addr=/72.14.252.129,port=61409,localport=5269|http://addr=/72.14.252.129, port=61409,localport=5269]

2008.03.31 10:45:24 Error creating session

java.io.EOFException: input contained no data

at org.xmlpull.mxp1.MXParser.fillBuf(MXParser.java:3003)

at org.xmlpull.mxp1.MXParser.more(MXParser.java:3046)

at org.xmlpull.mxp1.MXParser.parseProlog(MXParser.java:1410)

at org.jivesoftware.openfire.net.MXParser.nextImpl(MXParser.java:331)

at org.xmlpull.mxp1.MXParser.next(MXParser.java:1093)

at org.jivesoftware.openfire.net.SocketReader.createSession(SocketReader.java:363)

at org.jivesoftware.openfire.net.BlockingReadingMode.run(BlockingReadingMode.java: 53)

at org.jivesoftware.openfire.net.SocketReader.run(SocketReader.java:119)

at java.lang.Thread.run(Unknown Source)

2008.03.31 10:45:24 Connection closed before session established

Socket[http://addr=/72.14.252.129,port=61409,localport=5269|http://addr=/72.14.252.129, port=61409,localport=5269]

2008.03.31 10:45:24 Connect Socket[http://addr=/72.14.252.129,port=61410,localport=5269|http://addr=/72.14.252.129, port=61410,localport=5269]

2008.03.31 10:45:24 ServerDialback: RS - Received dialback key from host: gmail.com to: hammerheadsystems.com

2008.03.31 10:45:24 ServerDialback: RS - Trying to connect to Authoritative Server: gmail.com:5269(DNS lookup: xmpp-server2.l.google.com:5269)

2008.03.31 10:45:24 ServerDialback: RS - Connection to AS: gmail.com:5269 successful

2008.03.31 10:45:24 ServerDialback: RS - Asking AS to verify dialback key for id76bdedec

2008.03.31 10:45:24 ServerDialback: RS - Key was VERIFIED by the Authoritative Server for: gmail.com

2008.03.31 10:45:24 ServerDialback: RS - Closing connection to Authoritative Server: gmail.com

2008.03.31 10:45:24 ServerDialback: RS - Sending key verification result to OS: gmail.com

2008.03.31 10:45:24 ServerDialback: AS - Verifying key for host: gmail.com id: ABBB1FDBF438407F

2008.03.31 10:45:24 ServerDialback: AS - Key was: VALID for host: gmail.com id: ABBB1FDBF438407F

2008.03.31 10:45:24 ServerDialback: OS - Validation GRANTED from: gmail.com id: ABBB1FDBF438407F for domain: hammerheadsystems.com

2008.03.31 10:46:23 Logging off gmail.com on org.jivesoftware.openfire.net.SocketConnection@afad58 socket: Socket[http://addr=/72.14.252.129,port=61410,localport=5269|http://addr=/72.14.252.129, port=61410,localport=5269] session: org.jivesoftware.openfire.session.LocalIncomingServerSession@455b4d status: -1 address: gmail.com id: 76bdedec

Have you tried using the gateway plugin instead?

The plugin works fine, but it doesn’t solve this problem.

After a bit of searching on the net, turns out quite a few folks with XMPP servers are having similar S2S issues with Gtalk. Anyone know if Google is going to fix their code or if Openfire 3.5.0 is going to contain a ‘fix’ to work with Gtalk?

Google’s implementation changes and release schedule is know only to them. As for using google with openfire, I can not answer development questions, but I can say the gateway plugin works well for me. Why are you looking to use S2S instead of the plugin?

It sounds like you’ve been bitten by the google apps team edition bug. Basicaly someone with an email address activated google apps for the domain before you had the _srv record (or before google changed their code to check for that). So now google thinks that it handles xmpp routing for the domain. To fix it you need to mail xmpp@gmail.com

Dave

Regarding S2S v. transport, I want folks to be able to connect to/from any service without having to create Gtalk accounts and be accessible using their known email address instead of some random Gtalk name.

The Google Apps SRV record bug makes perfect sense now as I signed up for the demo a couple months ago and completely forgot about it. Sent them email to see about getting it fixed. btw, the correct email appears to be xmpp@google.com, the gmail acct you posted bounced.

Logged in to Google apps as an admin, deleted the chat service, works great now. Thanks much!