aboutsummaryrefslogtreecommitdiffstats
path: root/protocols/jabber/jabber.c
diff options
context:
space:
mode:
authordequis <dx@dxzone.com.ar>2015-12-04 22:52:48 -0300
committerdequis <dx@dxzone.com.ar>2015-12-04 22:52:48 -0300
commit9b02bab9832308cf88d86a379b3afd2f142816e2 (patch)
tree99ad03455e1c15c0b3804d04c50e6d693eeb88f7 /protocols/jabber/jabber.c
parent48b5fef4553ff38711bbdf1773b13841cf0f13c3 (diff)
Remove facebook XMPP code, show error pointing at the new plugin
Facebook's oauth has been broken for months, and in the last few days they broke plain logins too, so I just added an error message that says this when you do "account on": Facebook's XMPP service is gone. Try this instead: https://wiki.bitlbee.org/HowtoFacebookMQTT Also nuked all the oauth related code, except some parts of lib/oauth2.c which seemed generic enough to maybe help in the future with other not-really-compliant not-really-implementations of the not-really-oauth2 not-really-spec
Diffstat (limited to 'protocols/jabber/jabber.c')
-rw-r--r--protocols/jabber/jabber.c14
1 files changed, 9 insertions, 5 deletions
diff --git a/protocols/jabber/jabber.c b/protocols/jabber/jabber.c
index ddf4f2d3..0da65c84 100644
--- a/protocols/jabber/jabber.c
+++ b/protocols/jabber/jabber.c
@@ -150,6 +150,12 @@ static void jabber_login(account_t *acc)
return;
}
+ if (strstr(jd->server, ".facebook.com")) {
+ imcb_error(ic, "Facebook's XMPP service is gone. Try this instead: https://wiki.bitlbee.org/HowtoFacebookMQTT");
+ imc_logout(ic, FALSE);
+ return;
+ }
+
if ((s = strchr(jd->server, '/'))) {
*s = 0;
set_setstr(&acc->set, "resource", s + 1);
@@ -169,11 +175,9 @@ static void jabber_login(account_t *acc)
jd->fd = jd->r_inpa = jd->w_inpa = -1;
- if (strstr(jd->server, ".facebook.com")) {
- jd->oauth2_service = &oauth2_service_facebook;
- } else {
- jd->oauth2_service = &oauth2_service_google;
- }
+ /* There are no other options atm, so assume google for everything
+ Facebook and MSN XMPP used to be here. RIP. */
+ jd->oauth2_service = &oauth2_service_google;
oauth_params_parse(&p_in, ic->acc->pass);