Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Registration Number return "reason: old version" #2350

Closed
DwarfKiller opened this issue Nov 30, 2017 · 16 comments
Closed

Registration Number return "reason: old version" #2350

DwarfKiller opened this issue Nov 30, 2017 · 16 comments

Comments

@DwarfKiller
Copy link

DwarfKiller commented Nov 30, 2017

Hi there,

i tried to run yowsup but getting the well know "old version" fail at registration. I changed the env_android.py file as described in url https://coderus.openrepos.net/whitesoft/whatsapp_scratch ("letter 'a' and 'd'") for instance but keep getting der "old version" fail.

INFO:yowsup.common.http.warequest:b'{"login":"55xxxxxxxxxxx","status":"fail","reason":"old_version"}\n'
status: b'fail'
reason: b'old_version'
login: b'55xxxxxxxxxxx'

I use version in "env_android.py":
_MD5_CLASSES = "OyTf9XK7xoJkKIxLgY6/Lw=="
_VERSION = "2.17.426"

Could someone tell me if there is another version?

@DwarfKiller DwarfKiller changed the title Registrarion Number return "reason: old version" Registration Number return "reason: old version" Nov 30, 2017
@apopovic77
Copy link

Hi, I am having the same problem, reason 'old_version'.

  • Is this project dead?
  • Is WhatsApp itself responsible for that?

Thx for responses!

@DwarfKiller
Copy link
Author

I found the solution to my problem.

To perform the registration, it is necessary that the variable "DEFAULT" of the env.py file (path below) as defined as "android":

#DEFAULT = "s40"
DEFAULT = "android"

After this you need to recompile the lib (run the command at the root of the yowsup project and in the virtual environment, ex workon zapi):

python setup.py install​

@hgc2002
Copy link

hgc2002 commented Dec 2, 2017

that is working fine. I've just use version 2.177.426.
the command line for registration with android should look like this.

yowsup-cli registration --requestcode sms --phone countryandphone --cc countrycode --mcc yourmcc --mnc yourmnc --env android

This was referenced Dec 2, 2017
@gero112233
Copy link

Is there a solution?
I can't Register a new number.
With original S40 i get the error old_version.
With changed Android and Version 2.17.426 i get the error reason: bad_param

@manelmolina
Copy link

manelmolina commented Dec 2, 2017

I was having the same issue, the solution is edit env.py as follow

DEFAULT="android"

env_android.py:

_MD5_CLASSES = "OyTf9XK7xoJkKIxLgY6/Lw=="
_VERSION = "2.17.426"

After registration to be able to use yowsup-cli you have to modify again env.py to use s40

@gero112233
Copy link

gero112233 commented Dec 3, 2017

Sorry, what di i wrong? I have an raspberry and do:
cd /opt
sudo git clone https://github.com/tgalal/yowsup.git yowsup-master

Anlegen eines Konfig-Files

Editieren der Dateien wie oben beschrieben (env.py und env_android.py)

Registrierung:
python yowsup-cli registration -c /opt/yowsup-config/yowsup.config -r voice

Der Output:
yowsup-cli v2.0.15
yowsup v2.5.2

Copyright (c) 2012-2016 Tarek Galal
http://www.openwhatsapp.org

This software is provided free of charge. Copying and redistribution is
encouraged.

If you appreciate this software and you would like to support future
development please consider donating:
http://openwhatsapp.org/yowsup/donate

INFO:yowsup.common.http.warequest:{"login":"43313547554","status":"fail","reason":"bad_param","param":"number"}

status: fail
param: number
reason: bad_param
login: 4331xxxxxxx

Ich bin für jede Hilfe Dankbar!

Wenn ich die Registrierung - -E s40 mache, bekomme ich den bekannten Fehler old_version

@apopovic77
Copy link

apopovic77 commented Dec 4, 2017

Hi,

i had to do two things in order to make it run.

  1. get rid of metaclass error because of version incosistency with SIX.
    todo-> in env.py comment the line # __metaclass__ = YowsupEnvType

  2. use a different version and token for the env_s40.py
    todo-> _VERSION = "2.16.12"
    _TOKEN_STRING = "PdA2DJyKoUrwLw1Bg6EIhzh502dF9noR9uFCllGk1494451854337{phone}"

Greetings

@pabloruan0710
Copy link

pabloruan0710 commented Dec 11, 2017

Somebody update env_s40?? In android registration, I get block in one day.

@dbsdenis
Copy link

Baixem a versão mais recente, crie um MD5 usando dexMD5.py, modificando "env_android.py", como no tutorial, https://iamjagjeetubhi.wordpress.com/2017/09/21/how-to-use-yowsup-the-python-whatsapp-library-in-ubuntu/

python yowsup-cli registration --requestcode sms --phone 55XXXXXXXXXX --cc 55 --mcc 724 --mnc 03 -E android

@pabloruan0710
Copy link

@dbsdenis até conseguimos registar, mas quando se registra com android e utiliza com s40, o seu numero é banido bem rápido.

@DivelNick
Copy link

DivelNick commented Dec 22, 2017

@manelmolina
This method worked for me, but has ceased to work yesterday.

_MD5_CLASSES = "OyTf9XK7xoJkKIxLgY6/Lw=="
_VERSION = "2.17.426"

_VERSION = "2.16.12"

DEFAULT = "android"

request:
yowsup-cli registration --requestcode sms --phone 7хххххххххх --cc 7 --mcc 250 --mnc 01 -E android

response:
status: b'fail'
reason: b'old_version'
login: b'7xxxxxxxxxx'

@tgalal
Copy link
Owner

tgalal commented Dec 30, 2017

update yowsup, register using android env, login using s40 env

@tgalal tgalal closed this as completed Dec 30, 2017
@lazyjohny500
Copy link

@tgalal So there is no solution for registration with s40?

@TTP1106
Copy link

TTP1106 commented Apr 14, 2018

In my case it works fine to Register with android. Login with android does disconnect after connecting.
With s40 env I get this strange error:

Auth: Logged in!
[connected]:WARNING:axolotl.sessionbuilder:We've already setup a session for this V3 message, letting bundled message fall through...
WARNING:yowsup.layers.axolotl.layer_receive:Received a message that we've previously decrypted, goint to send the delivery receipt myself
WARNING:axolotl.sessionbuilder:We've already setup a session for this V3 message, letting bundled message fall through...
[491705405445@s.whatsapp.net(14-04-2018 08:11)]:[3599B8E6E25593889B*] [Media Type:image, Size:53906, URL:https://mmg-fna.whatsapp.net/d/f/AhmurL3iIAwuTUIPA_4-REZp5f8tLlhgL9]
Message 3599B8E6E2559*: Sent delivered receipt and Read
[connected]:
Traceback (most recent call last):
File "/usr/local/bin/yowsup-cli", line 4, in
import('pkg_resources').run_script('yowsup2==2.5.7', 'yowsup-cli')
File "/usr/lib/python2.7/dist-packages/pkg_resources/init.py", line 739, in run_script
self.require(requires)[0].run_script(script_name, ns)
File "/usr/lib/python2.7/dist-packages/pkg_resources/init.py", line 1494, in run_script
exec(code, namespace, namespace)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/EGG-INFO/scripts/yowsup-cli", line 368, in
if not parser.process():
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/EGG-INFO/scripts/yowsup-cli", line 268, in process
self.startCmdline()
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/EGG-INFO/scripts/yowsup-cli", line 297, in startCmdline
stack.start()
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/demos/cli/stack.py", line 26, in start
self.stack.loop(timeout = 0.5, discrete = 0.5)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/stacks/yowstack.py", line 189, in loop
asyncore.loop(*args, **kwargs)
File "/usr/lib/python2.7/asyncore.py", line 216, in loop
poll_fun(timeout, map)
File "/usr/lib/python2.7/asyncore.py", line 156, in poll
read(obj)
File "/usr/lib/python2.7/asyncore.py", line 87, in read
obj.handle_error()
File "/usr/lib/python2.7/asyncore.py", line 83, in read
obj.handle_read_event()
File "/usr/lib/python2.7/asyncore.py", line 449, in handle_read_event
self.handle_read()
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/network/layer.py", line 102, in handle_read
self.receive(data)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/network/layer.py", line 110, in receive
self.toUpper(data)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/init.py", line 79, in toUpper
self.__upper.receive(data)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/stanzaregulator/layer.py", line 29, in receive
self.processReceived()
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/stanzaregulator/layer.py", line 52, in processReceived
self.processReceived()
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/stanzaregulator/layer.py", line 49, in processReceived
self.toUpper(oneMessageData)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/init.py", line 79, in toUpper
self.__upper.receive(data)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/auth/layer_crypt.py", line 65, in receive
self.toUpper(payload)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/init.py", line 79, in toUpper
self.__upper.receive(data)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/coder/layer.py", line 35, in receive
self.toUpper(node)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/init.py", line 79, in toUpper
self.__upper.receive(data)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/logger/layer.py", line 14, in receive
self.toUpper(data)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/init.py", line 79, in toUpper
self.__upper.receive(data)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/axolotl/layer_control.py", line 44, in receive
self.toUpper(protocolTreeNode)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/init.py", line 79, in toUpper
self.__upper.receive(data)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/init.py", line 194, in receive
s.receive(data)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/axolotl/layer_receive.py", line 41, in receive
self.onMessage(protocolTreeNode)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/axolotl/layer_receive.py", line 74, in onMessage
self.handleEncMessage(protocolTreeNode)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/axolotl/layer_receive.py", line 86, in handleEncMessage
self.handlePreKeyWhisperMessage(node)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/axolotl/layer_receive.py", line 129, in handlePreKeyWhisperMessage
self.parseAndHandleMessageProto(pkMessageProtocolEntity, plaintext[:-padding])
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/axolotl/layer_receive.py", line 188, in parseAndHandleMessageProto
self.handleConversationMessage(node, m.conversation)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/axolotl/layer_receive.py", line 217, in handleConversationMessage
self.toUpper(messageNode)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/init.py", line 79, in toUpper
self.__upper.receive(data)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/init.py", line 194, in receive
s.receive(data)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/init.py", line 130, in receive
recv(node)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/protocol_messages/layer.py", line 21, in recvMessageStanza
self.toUpper(entity)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/init.py", line 79, in toUpper
self.__upper.receive(data)
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/layers/interface/interface.py", line 80, in receive
self.entity_callbacksentityType
File "/usr/local/lib/python2.7/dist-packages/yowsup2-2.5.7-py2.7.egg/yowsup/demos/cli/layer.py", line 512, in onMessage
MESSAGE_ID = message.getId()
UnicodeEncodeError: 'ascii' codec can't encode characters in position 9-11: ordinal not in range(128)

Seems that somebody send me message that crash this script after register....

@dharampal123
Copy link

Did the below changes and worked for me:

Change in env.py file
set DEFAULT="android"

Change on env_android.py
_MD5_CLASSES = "DAPy33TbNMg0Yuplp2II0A=="
_VERSION = "2.18.339"

python setup.py build

python setup.py install

yowsup-cli registration -r sms -m 000 -n 00 -p 91XXXXXXXXXX -C 91 -E android

@cool4tec
Copy link

cool4tec commented Apr 9, 2019

hello i have the same problem i am using centos 6 i installed it by pip install yowsup how to fix the problem

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests