2
votes

Till now I've been using the old chat log on mechanism to login facebook chat (the one with the "sig" parameter).

Now after the support for it is gone, I changed my code corresponding to the new authentication system (i.e. without the sig parameter).

I am creating this kind of string which I send as a "response" tag after the challenge phase.

api_key=<apikey>&call_id=<callid>&method=<method from challenge>&nonce=<nonce from challenge>&access_token=<access token>&v=1.0  

And I get the following: <failure xmlns="urn:ietf:params:xml:ns:xmpp-sasl"><not-authorized/></failure>

The following occurs just on iOS. Android works fine (which tell my code is correct). The difference between those versions is that on iOS I get encrypted access token, and on Android I get the old access token.

i.e. on Android 213458xx1425|1.BGgrgnfWrdpG_X18.3600.1213xxx135.2-1334679|dHcDbxGbeYxxxxx on iOS AAAByQT1Vjdkxxxxxxxxxxx

Also, I tried to get into the app control panel and disabled the encrypted access token option but it didn't had any effect.
I am using Titanium's last SDK, 1.7.4 (v2011-10-21 18:18:15)

Anyone can put me some light on this issue? I saw other people with similar problem with no solution. Integrating Facebook chat

Thanks for advance, Netanel.

1
You should be able to use an encrypted or unencrypted access token interchangably once you're using the access token based auth for XMPP - see my answer to the question linked aboveIgy
Hi Igy, I've done what you told there about removing the session key and sig and putting the access token. The xmpp login is working fine with the new authentication but on android only. Any other ideas?Netanel Wachshtein
What error are you getting, i don't see anything in your question about a specific problemIgy
Sorry. for some reason the error didn't show up on my message.Netanel Wachshtein

1 Answers

0
votes

You should probably edit the original question to include the error message instead of adding it as a comment, but that error's not descriptive enough unfortunately - that's the error for most things that you could have done wrong in the auth flow Two thoughts:

  1. Check if the access token you're using definitely has the xmpp permissions with a call to `/me/permissions (maybe use the Graph API Explorer at https://developers.facebook.com/tools/explorer

  2. If possible, trace through the exact URL you're calling to make sure all the necessary parameters are populated correctly