I use the gloox open source API which works again several other XMPP servers. I use the following code
JID jid( "USERID@chat.facebook.com" );
j = new Client( jid, "PASSWORD" );
j->setServer("chat.facebook.com");
j->setPort(5222);
j->setSASLMechanisms(gloox::SaslMechPlain);
j->setTls(gloox::TLSPolicy::TLSRequired);
j->registerConnectionListener( this );
j->registerMessageSessionHandler( this, 0 );
j->disco()->setVersion( "messageTest", GLOOX_VERSION, "Windows" );
j->disco()->setIdentity( "client", "bot" );
j->disco()->addFeature( XMLNS_CHAT_STATES );
StringList ca;
It connects and opens the tls socket but always receives a SaslNotAuthorized back from facebook.
Is my userID correct? Am I missing something from facebook?
Any help would be greatly appreciated.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.