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

couldn't match token 247 #3090

Open
Whomakes opened this issue Sep 7, 2021 · 39 comments
Open

couldn't match token 247 #3090

Whomakes opened this issue Sep 7, 2021 · 39 comments
Assignees

Comments

@Whomakes
Copy link

Whomakes commented Sep 7, 2021

Exception: readString couldn't match token 247

what is this error? how can it be corrected or ignored?

@bahtiarp
Copy link

bahtiarp commented Sep 16, 2021

This because you get message from WhatsApp Web That activated Multi-device beta.
The data that receive contain new type of node child "device-identity". I still don't know how to skip the message,
because whatsapp server keep send this message until a period of time. Send receipt not solve the problem also.

<message from="628564901xxxx@s.whatsapp.net" type="text" id="3EB0F4FC58ED4673741C" t="1631698621" notify="SomeOne"> <enc v="2" type="pkmsg"> 0x3328b76f08403000122105841a0f7dbea754558af641301eff80f47877794193636b5bc846e072f25c83251a21053ae0da77b78c2ca571eebe52a75d2b92f11941ceb9be2d97c7fd7b170b0cbd4c2242330a21059c77a3087f875ead349544531591d1c27e197462435dbaccc88dc36df526764a100018002210e1f45b4863cf470e27d92026599d9d8610297bc0ceb233e6 </enc> <device-identity> 0x0a0e08b799e9e30210dffc868a0618011220e630ce8ad2eaae411e3dd9936345a03116c5beca4294df3c38fbfd725755170d1a40612ce0b9d520d7c698f2d62c4a3add568f76e953312c871744060eac6d30314c8895b40b433c104416b044a1994a6d1a5884d303101b1a1ef57b54ab2e67d e0f22408ebd1e9b27769afb894e5caf43d8450c96bc652a58e9395a1e8b70a3d58b31deebb6a262023caafcf6f9a5516cb7bacea3990be2832c6c29b4e0b69f913a038c </device-identity> </message>

@Whomakes
Copy link
Author

This because you get message from WhatsApp Web That activated Multi-device beta.
The data that receive contain new type of node child "device-identity". I still don't know how to skip the message,
because whatsapp server keep send this message until a period of time. Send receipt not solve the problem also.

<message from="628564901xxxx@s.whatsapp.net" type="text" id="3EB0F4FC58ED4673741C" t="1631698621" notify="SomeOne"> <enc v="2" type="pkmsg"> 0x3328b76f08403000122105841a0f7dbea754558af641301eff80f47877794193636b5bc846e072f25c83251a21053ae0da77b78c2ca571eebe52a75d2b92f11941ceb9be2d97c7fd7b170b0cbd4c2242330a21059c77a3087f875ead349544531591d1c27e197462435dbaccc88dc36df526764a100018002210e1f45b4863cf470e27d92026599d9d8610297bc0ceb233e6 </enc> <device-identity> 0x0a0e08b799e9e30210dffc868a0618011220e630ce8ad2eaae411e3dd9936345a03116c5beca4294df3c38fbfd725755170d1a40612ce0b9d520d7c698f2d62c4a3add568f76e953312c871744060eac6d30314c8895b40b433c104416b044a1994a6d1a5884d303101b1a1ef57b54ab2e67d e0f22408ebd1e9b27769afb894e5caf43d8450c96bc652a58e9395a1e8b70a3d58b31deebb6a262023caafcf6f9a5516cb7bacea3990be2832c6c29b4e0b69f913a038c </device-identity> </message>

if you find a solution please share.

@ghost
Copy link

ghost commented Sep 19, 2021

bahtiarp, 247 token:

  • first byte: agent
  • second byte: device
  • third byte: size
  • next: user name (number of phone)
    In total have format: 628564901xxxx.0:x@s.whatsapp.net
    Now web-client and phone-client - two different users.
    Device-identity node can ignored

@bahtiarp
Copy link

bahtiarp commented Sep 20, 2021

👍👍👍
Hi ghost you are great, finally i can read incoming messages.
but the problem now is the ack/receipt response from yowsup is not understood by whatsapp server, so the same message always comes after reconnection, Have you found the same problem? How to overcome this.
This is yowsup standard receipt stanza:
<receipt id="3EB083E5F64BD0C29384" to="62851234567.0:2@s.whatsapp.net" />
thank you very much. 🙏

@ORMiK0
Copy link

ORMiK0 commented Sep 20, 2021

On
receipt id="3EB083E5F64BD0C29384" to="62851234567.0:2@s.whatsapp.net"
send
ack to="62851234567.0:2@s.whatsapp.net" class="receipt" id="3EB083E5F64BD0C29384
I have already written: "Now web-client and phone-client - two different users".

@bahtiarp
Copy link

bahtiarp commented Sep 21, 2021

Thanks ORMiK0,
But I have done this also, but still not got response from WA server.
What was i doing wrong?
image

<stream:error> <ack id="3EB060F53BD0FC1D987D" /> </stream:error>

image
What is 0 and x, actually?

I interpreted as:
image

@ORMiK0
Copy link

ORMiK0 commented Sep 21, 2021

bahtiarp, for send node You need use 247 token too.
"What is 0 and x, actually?" - yes.
I think, "0" always. "x" - number of device. You can receive "x" if You use sync node (devices)

@bahtiarp
Copy link

bahtiarp commented Sep 21, 2021

Thanks ORMiK0,
sending node using 247 token is something new for me,
can you give me a clue how to do it. 🙏, while i'm looking to find out also now.

@bahtiarp
Copy link

Thanks ORMiK0 for the clue:, i reverse the porcess.
It seems works now.
image

@pupan
Copy link

pupan commented Sep 22, 2021

hi @bahtiarp could you care to share what file and patch code to solve this issue? thank you

@bahtiarp
Copy link

@pupan
yowsup\layers\coder:
on decoder.py: readString add this:
image
on encoder.py : modify:
image

@pupan
Copy link

pupan commented Sep 22, 2021

Thank you @bahtiarp, your patch work nicely in private message.. but I can't see the message if using group message, do you have any clue?

@bahtiarp
Copy link

I haven't checked that far.
Besides, there are many other problems related to MD, like message don't sync correctly to all other devices .
But for now, it's solved my problem.
If there is an error code, please let me know, if I have free time I will try to check it.

@Whomakes
Copy link
Author

@bahtiarp thanks for the work you've done!!! maybe you have a solution to the problem with syncing contacts?

@bahtiarp
Copy link

Whomakes,
i never used syncing contacts, what it's for? how's it work?

@Whomakes
Copy link
Author

Whomakes,
i never used syncing contacts, what it's for? how's it work?

#3047

@pupan
Copy link

pupan commented Sep 23, 2021

I haven't checked that far.
Besides, there are many other problems related to MD, like message don't sync correctly to all other devices .
But for now, it's solved my problem.
If there is an error code, please let me know, if I have free time I will try to check it.

i'm aware of this too the message not readable to all device, my guess every multiple device has own encryption key and current axolotl manager doesn't support it because different jid number. CMIIW..

@bizzu
Copy link

bizzu commented Sep 24, 2021

@pupan
yowsup\layers\coder:
on decoder.py: readString add this:
image
on encoder.py : modify:
image

Thanks @bahtiarp @ORMiK0 @ghost for the investigation & fix which is working nicely here !

@Whomakes
Copy link
Author

Whomakes,
i never used syncing contacts, what it's for? how's it work?

friend write me in Watsapp +79990589348

@bahtiarp
Copy link

Whomakes,
i never used syncing contacts, what it's for? how's it work?

friend write me in Watsapp +79990589348

image

@zek
Copy link

zek commented Sep 27, 2021

@bahtiarp are you able to solve stream error ? After getting stream:error, number gets banned.

<stream:error>
  <bad-mac />
</stream:error>

@Whomakes
Copy link
Author

Whomakes,
i never used syncing contacts, what it's for? how's it work?

friend write me in Watsapp +79990589348

image

Thanks! but the server is not responding (can anyone help fix this issue?

@Whomakes Whomakes closed this as completed Oct 1, 2021
@Whomakes Whomakes reopened this Oct 1, 2021
@Whomakes
Copy link
Author

Whomakes commented Oct 5, 2021

Whomakes,
i never used syncing contacts, what it's for? how's it work?

friend write me in Watsapp +79990589348

image

Thanks! but the server is not responding (can anyone help fix this issue?

I am willing to pay to solve this problem. My WA +79990589348

@Analog303
Copy link

hi @bahtiarp could you care to share what file and patch code to solve this issue? thank you
fixed.zip

bizzu added a commit to bizzu/yowsup that referenced this issue Oct 25, 2021
bizzu added a commit to bizzu/yowsup that referenced this issue Oct 25, 2021
@HeinzFo
Copy link

HeinzFo commented Nov 29, 2021

Hello
I have installed the two file from fixed.zip but messages send from yowsup will only receive on the SmartPhone App.
On the Whatsapp Windows Desktop App only the hint "Wait for Message check your Phone".
The two blue hook will be displayed right on both Apps.
Can you help for a solution?
Regards

@Analog303
Copy link

Analog303 commented Nov 29, 2021 via email

@HeinzFo
Copy link

HeinzFo commented Nov 29, 2021

Hello
Okay I will wait for your message!
Beste Grüße
Heinz

@HeinzFo
Copy link

HeinzFo commented Dec 4, 2021

Hello Analog303
Friendly reminder regarding your script :-)
Tanks and best Regards

@ferack
Copy link

ferack commented Dec 6, 2021

Hello @bahtiarp
How can I reach you? I have a job and that I think is simple to do for you and I am willing to pay for it. I need it as quickly as possible.

@Analog303
Copy link

Analog303 commented Dec 7, 2021 via email

@HeinzFo
Copy link

HeinzFo commented Dec 7, 2021

Hallo Analog303
Kann aus deinen comment leider nichts entsprechendes finden!
Grüße

@Analog303
Copy link

Analog303 commented Dec 9, 2021 via email

@HeinzFo
Copy link

HeinzFo commented Dec 9, 2021

Hallo Analog303
Vielen Dank1
Wie hast Du die Datei genannt und wo hast Du sie abgelegt?
Beste Grüße

@Analog303
Copy link

Analog303 commented Dec 9, 2021 via email

@Analog303
Copy link

Analog303 commented Dec 9, 2021 via email

@barart
Copy link

barart commented Mar 18, 2022

Can someone summarize this? There are mixed responses and languages, does this fix the WhatsApp Web Multidevice messages?

@bahtiarp
Copy link

Can someone summarize this? There are mixed responses and languages, does this fix the WhatsApp Web Multidevice messages?

yes, partially fixed.

@barart
Copy link

barart commented Mar 29, 2022

Can somebody summarize this? what exact files do i need to change and what lines do i need to put on those files?

Im little confused because the languages and im lost in the conversation/posts ..

@rafaelnordavind
Copy link

Has anyone had success in receiving messages in groups both on the mobile app and on Whatsapp Web or on the desktop app?

Repository owner deleted a comment Jul 13, 2022
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