1

i've got yowsup on my linux and when I trying to execute yowsup-cli registration -C <CountryCode> -r sms -p <Phone Number with Country Code> I'm getting

INFO:yowsup.common.http.warequest:{"status":"fail","reason":"old_version"}

status: fail

reason: old_version

Is there any way to fix this?

Kaczper
  • 103
  • 1
  • 2
  • 11

2 Answers2

1

Note that there are two YowsupEnv implementations at: yowsup/env, specifically: env_android.py and env_s40.py.

First, change the values of the following attributes at env_android.py: _MD5_CLASSES = "7UDPOXwpiLBvEjT8uNwsuA=="

_KEY = "eQV5aq/Cg63Gsq1sshN9T3gh+UUp0wIw0xgHYT1bnCjEqOJQKCRrWxdAe2yvsDeCJL+Y4G3PRD2HUF7oUgiGo8vGlNJOaux26k+A2F3hj8A="

_VERSION = "2.12.440"

Then, you'll have to tell Yowsup to use the Android environment instead of the default S40 environment. To do so, modify the files:

yowsup/registration/coderequest.py

yowsup/common/http/warequest.py

In both of them, replace the variable: CURRENT_ENV = S40YowsupEnv()

With: CURRENT_ENV = AndroidYowsupEnv()

Don't forget to also change the corresponding import statement as: from yowsup.env import AndroidYowsupEnv

That should do the trick.

slondono
  • 26
  • 1
  • 2
  • this does not work anymore, we would need a answer from [where to get these keys](https://stackoverflow.com/questions/35991135/how-to-find-latest-md5-key-and-version-when-using-yowsup?noredirect=1&lq=1), because it seems that they are always changing. – data cosmos Oct 06 '16 at 08:46
  • Indeed. This doesn't work anymore and looks like Yowsup itself is no longer usable. – slondono Jun 14 '17 at 14:05
1

follow these 3 simple steps:

git remote add jlguardi https://github.com/jlguardi/yowsup.git
git pull jlguardi Android_2.12.440
git merge jlguardi/Android_2.12.440
sudo python setup.py install

It pretty much does the same as the above answer