Google Authenticator crashes on Sony Xperia Zx

I had this issue from a long time but I had never dedicated the time to solve it. 

Today I was doing some stuff with PC, Picassa and my phone (Sony Xperia ZL with Android 4.3, 10.4.B.0.569) that involved using Google 2 steps Authentication. One way to use it is to wait for a SMS with the code and here in Argentina, I dont know why, some days the SMS service doesnt work. The other solution is to use Google Authenticator but the app was not working on my phone and crashed every time I tried to use it.

So I googled for a solution and found some thing related to my problem and also realized that a lot of people were facing the same problem as I. The solution was here https://code.google.com/p/google-authenticator/issues/detail?id=353, in the project home page obviously :)

The solution came from this 2 guys:

  • #7 brokenha...@gmail.comwas having the same problem, but found a workaround for this. Instead of clicking "begin setup" go to options at the top right and click setup account. I then used the barcode scanner to add my device using the "change device" option on my google account settings (on pc). Seems that the issue only exists in the "begin setup" option, however i have not verified other setup options device: xperia z1s OS: 4.3 app: authenticator 2.49 Feb 10, 2014
  • #8 glennerooI saw a warning message that Authenticator can only be installed on one device at a time. It could be possible that because Authenticator is already activated on an old device, it crashes trying to setup on a new device instead of (sensibly) displaying an error message e.g. "Sorry you already activated... scan a barcode...". If you are moving to a new device, go here: https://accounts.google.com/b/0/SmsAuthSettings And select the option to "Move to a different phone". On your phone, do as comment #7 suggested (scan the barcode provided) and it should work. device: xperia z1 compact os: 4.3
It seems there is some issue when you dont have Google Authenticator enabled as your "PRIMARY WAY YOU RECEIVE CODES" or when you have it activated on other device. Also I think there is an issue when you try to active it using other method than scanning the QR code with your app.

So to solve it, these are the steps I followed:

  1. Go to https://accounts.google.com/b/0/SmsAuthSettings
  2. Set to use Google Authenticator my "PRIMARY WAY YOU RECEIVE CODES"
  3. Scan the QR code using the app
And voila! Google Authenticator is now working!