WhatsApp / proxy

This repository contains the WhatsApp proxy implementation for users to host their own proxy infrastructure to connect to WhatsApp for chat (VoIP is not currently supported)
MIT License
1.41k stars 385 forks source link

"Connected" but only can send text, can't send/receive pictures videos and documents #200

Open MikeStick opened 1 year ago

MikeStick commented 1 year ago

I m using VPS to create a whatsapp proxy server following the tutorial all no problem . now showing "Connected" on my whatsapp

but only can send text, can't send/receive pictures videos and documents. it will be a great help and convenient if this can be fixed.

Telegram Proxy works perfectly by using SOCKS 5 / HTTPS/ MTP Proto Proxy . Learn from each other not a bad thing.

mvscode commented 1 year ago

+1

slawlor commented 1 year ago

We're presently rolling out the updated application which supports media proxying. There is an updated user-interface which and status on both chat + media connections for the proxy. It should be coming in the next couple of weeks to everyone.

Unfortunately it's a 2-phased update, we can publish the proxy (this github) which supports media, but there's also client changes (Android + iOS applications) necessary to also support proxying media traffic.

Thanks!

mx4994 commented 1 year ago

We're presently rolling out the updated application which supports media proxying. There is an updated user-interface which and status on both chat + media connections for the proxy. It should be coming in the next couple of weeks to everyone.

Unfortunately it's a 2-phased update, we can publish the proxy (this github) which supports media, but there's also client changes (Android + iOS applications) necessary to also support proxying media traffic.

Thanks!

Finally, there is a clear explanation. Will the Windows client have a proxy function?

slawlor commented 1 year ago

Finally, there is a clear explanation. Will the Windows client have a proxy function?

You mean the companion application? Unfortunately there are not (current) plans to add support to the companion apps (web/macOS/Windows/etc) at this time that I'm aware of. However I'll ask around.

mx4994 commented 1 year ago

You mean the companion application? Unfortunately there are not (current) plans to add support to the companion apps (web/macOS/Windows/etc) at this time that I'm aware of. However I'll ask around.

Yes, only the mobile app has this feature right now, not the desktop app.

okay, thank you.

MikeStick commented 1 year ago

We're presently rolling out the updated application which supports media proxying. There is an updated user-interface which and status on both chat + media connections for the proxy. It should be coming in the next couple of weeks to everyone.

Unfortunately it's a 2-phased update, we can publish the proxy (this github) which supports media, but there's also client changes (Android + iOS applications) necessary to also support proxying media traffic.

Thanks!

Thanks so much for your update ,we will be waiting for the big improvement if media problem solved. also I have found a way to avoid the server getting blocked by establishing a secondary tunnel to encrpt the data and protect the port for long time use ,this needs another server in local ,which will be extra expense but effective.

eozturk1 commented 1 year ago

Hi @MikeStick! We have rolled out the media enabling feature to all users. After setting a media port (or leaving it as default), you should get feedback on the UI whether the proxy you are using supports media.

mx4994 commented 1 year ago

Hi @MikeStick! We have rolled out the media enabling feature to all users. After setting a media port (or leaving it as default), you should get feedback on the UI whether the proxy you are using supports media.

image

I tried it, but it still doesn’t work. It’s supported by the application. Doesn’t this repository support it?

eozturk1 commented 1 year ago

Could you check the URL for the stats port the proxy you are using (<proxyAddress>:8199) to see if wa_whatsapp_net is listed there? If not, the proxy will need to be re-built from the latest changes on this repo and re-started to support media.

You will also need to enter the media port on your device that corresponds to the port(s) of haproxy_v4_whatsapp_net. These are 587 and 7777 in this repo's configuration but might be different for the proxy you are using.

mx4994 commented 1 year ago

您能否检查您正在使用的代理 ( ) 的统计端口的 URL,<proxyAddress>:8199看看是否wa_whatsapp_net已在其中列出?如果没有,则需要根据此存储库上的最新更改重新构建代理并重新启动以支持媒体。

您还需要输入设备上与 的端口相对应的媒体端口haproxy_v4_whatsapp_net。在此存储库的配置中,这些是 587 和 7777,但对于您正在使用的代理可能有所不同。

image

I tried pre-built images and images built from the repository, also tried default ports and custom ports, IPV4 and IPV6; but all can only proxy text, not media.

Waiting for other people's reports, I'm going to bed first.

imanihb2007 commented 1 year ago

Finally, there is a clear explanation. Will the Windows client have a proxy function?

You mean the companion application? Unfortunately there are not (current) plans to add support to the companion apps (web/macOS/Windows/etc) at this time that I'm aware of. However I'll ask around. hi-proxy media not work

MikeStick commented 1 year ago

Today just tried again , media still not work. I use Google cloud server (Debian 11 ) to create the whatsapp server exactly following the official tutorial. now showing "Connected" ;

Chat port Default no problem text can send , but the media port default not working , I tried 587 or 7777, both no work . I tried to update the Whatsapp APP to latest version also reboot my phone . tried many times , still no working

I checked the ports status on ping.pe . it shows all okay and the port is open all green .

Now I really don't know what to do next , until now I don't see anyone can successfully work both in text and media , just some youtuber making useless tutorial video to be freeloaders by using public whatsapp proxy IPs not consiering any risk , just want to wait someone else do the hard work and feed the food to his month.

eozturk1 commented 1 year ago

@MikeStick,

  1. From a computer on the same network as your phone, can you send a curl request to the media port of the proxy address as follows and share the output?
curl -k https://<proxy_address>:<media_port>
  1. If your phone is connected to WiFi, can you try cellular as well?

When you say it shows "Connected", do you mean it is not showing "Media: unavailable"? If "Media: unavailable" is not shown, then media should work.

  1. If you are still having trouble, can you please submit a report through the Help on the app and describe the issue you are having?
MikeStick commented 1 year ago
  1. image

  2. tried both WiFi and cellular 1692339030074

    1692339050454

eozturk1 commented 1 year ago

Looks like you do have an active media connection. ("WhatsApp Error" responses are expected when sending the curl request.) I am curious to see what the underlying issue is. Please make sure to submit a report!

When you say media is not working, do you mean while proxy enabled, you can't send media messages (e.g., a photo) that are delivered (one-tick)?

eozturk1 commented 1 year ago

One other thing to check is whether the proxy still shows "Connected" as in the picture you shared after 15-30 seconds.

MikeStick commented 1 year ago
1692341920678 1692342015275

The first picture using WiFi , the second cellular , just show "Retry" and I retry , but still goes on like that and I just submitted a ticket to whatsapp help center ,hopefully the problem can be solved , if working , I will feedback here the way

MikeStick commented 1 year ago

Feedback from whatsapp offcial , they can't deal with it , so now we are back to the beginning, text works ,media no

eozturk1 commented 1 year ago

Really appreciate the debugging information shared here @MikeStick ! Can you please try connecting to the proxy and sending media again, and submit a bug report after?

Thanks!

Shanukuttoth commented 1 year ago

Don't mail me more, please

On Tue, 29 Aug 2023, 07:02 Ercan Ozturk, @.***> wrote:

Really appreciate the debugging information shared here @MikeStick https://github.com/MikeStick ! Can you please try connecting to the proxy and sending media again, and submit a bug report after?

Thanks!

— Reply to this email directly, view it on GitHub https://github.com/WhatsApp/proxy/issues/200#issuecomment-1696731550, or unsubscribe https://github.com/notifications/unsubscribe-auth/A6533DCX3VBDFBCPFLV6HWTXXVSTXANCNFSM6AAAAAAZU75AJQ . You are receiving this because you are subscribed to this thread.Message ID: @.***>

fungjigroup commented 1 year ago

Hi, could you please let me know the proxy address you are using and let me try if it works for me or not? Thanks!

JellyVPN commented 1 year ago

I can confirm Proxy only works for text Video, Photo, Voice Call and Video Call not working Incoming call will show but when answer stay in connecting this is a huge issue

Sujanayasa commented 1 year ago

Ok

Pada tanggal Sen, 4 Sep 2023 06.22, JellyVPN @.***> menulis:

I can confirm Proxy only works for text Video, Photo, Voice Call and Video Call not working Incoming call will show but when answer stay in connecting this is a huge issue

— Reply to this email directly, view it on GitHub https://github.com/WhatsApp/proxy/issues/200#issuecomment-1704420657, or unsubscribe https://github.com/notifications/unsubscribe-auth/BB4A44MJD7HBTVQJUFXHYV3XYT7JZANCNFSM6AAAAAAZU75AJQ . You are receiving this because you are subscribed to this thread.Message ID: @.***>

fungjigroup commented 1 year ago

Voice call and video call can use under proxy service. However, voice message, video message and other media message cannot be sent and received under proxy service. This is a big issue and MUST BE SOLVED asap.

eozturk1 commented 1 year ago

I can confirm Proxy only works for text Video, Photo, Voice Call and Video Call not working Incoming call will show but when answer stay in connecting this is a huge issue

Voice and video calls are currently not supported via proxies.

If you are using a proxy with media support -- i.e., the proxy page does not show "Media: unavailable", please create an issue on this repo regarding proxy set up issues, and file a bug report through WhatsApp help on the app.

fungjigroup commented 1 year ago

My wife in Mainland China uses one of the proxy server provided by https://whatsapp-proxy.com/ to connect to Whatsapp. She confirmed that voice call & video call CAN BE USED under proxy connection in Mainland China. However, voice messages, pictures & files cannot be sent & received under proxy connection.

mahanmi commented 1 year ago

I have the same issue My proxy works on my iOS devices very well and it can send media but it doesn't work on my android devices (it connects but it can't send media (I have tried to change ports to 587 and 7777 and it says connected for both media and chat but it only can send chats))

fungjigroup commented 1 year ago

I have the same issue My proxy works on my iOS devices very well and it can send media but it doesn't work on my android devices (it connects but it can't send media (I have tried to change ports to 587 and 7777 and it says connected for both media and chat but it only can send chats))

Hi, can I have the IP address of your proxy so that I can test if it works for me or not? Thanks!

fungjigroup commented 1 year ago

Hi, can I have the IP address of your proxy so that I can test if it works for me or not? Thanks!

On Fri, Sep 15, 2023, 21:29 Mahan MI @.***> wrote:

I have the same issue My proxy works on my iOS devices very well and it can send media but it doesn't work on my android devices (it connects but it can't send media (I have tried to change ports to 587 and 7777 and it says connected for both media and chat but it only can send chats))

— Reply to this email directly, view it on GitHub https://github.com/WhatsApp/proxy/issues/200#issuecomment-1721285525, or unsubscribe https://github.com/notifications/unsubscribe-auth/BCCWOEVAYXQ2BCROFDAT7FDX2RJ2NANCNFSM6AAAAAAZU75AJQ . You are receiving this because you commented.Message ID: @.***>

eozturk1 commented 1 year ago

I have the same issue My proxy works on my iOS devices very well and it can send media but it doesn't work on my android devices (it connects but it can't send media (I have tried to change ports to 587 and 7777 and it says connected for both media and chat but it only can send chats))

Could you please submit a bug report in the app and let us know in here when you do?

OliverZSS commented 11 months ago

Hi Guys, I am here in mainland china. I Don't know how to build my own proxy server. I just tested almost every free proxy listed on https://whatsapp-proxy.com/ Some of them are working well on my iPhone but none of them supports media. Can some one provide me with a proxy which works for media just for trying? Or could someone teach me how to build my own server if it is not that expensive.

fungjigroup commented 11 months ago

Hi Guys, I am here in mainland china. I Don't know how to build my own proxy server. I just tested almost every free proxy listed on https://whatsapp-proxy.com/ Some of them are working well on my iPhone but none of them supports media. Can some one provide me with a proxy which works for media just for trying? Or could someone teach me how to build my own server if it is not that expensive.

Hi, my wife is also in mainland china. She also has the same problem. We also wish to have a proxy which works for media. Whatsapp introduced media supporting in June 2023. The free proxies listed on https://whatsapp-proxy.com/ were built in January 2023. I guess the owners of the proxy servers do not updated the function of the servers. This is a big problem for Whatsapp proxy service. They should make sure the proxy service which works for media before launched in January 2023. Now, they are lazy to update the servers since almost nobody complain for this issue. I wish a free media supporting Whatsapp proxy server will be available in the nearest future.

thantez commented 11 months ago

I also have this problem, sometimes proxy is "connected" and texts send rapidly but medias don't, sometimes proxy for chat is connected but for media not, and sometimes everything works. This "sometimes" words are so random situations. For example, on a specific cellular network service provider it works great but on other providers don't. Also, minutes or location can be change the behavior of proxy. I think maybe it's a GFW issue, but I don't know why chats work well always but media not. Isn't their protocol and encryption the same?

JerichoWord commented 11 months ago

Like you, I changed the default port of WhatsApp and the solution was solved. [NOTICE] (1) : haproxy version is 2.4.0-6cbbecf [ALERT] (1) : Starting frontend frontend-web80: cannot bind socket (Permission denied) [0.0.0.0:80] [ALERT] (1) : Starting frontend frontend-web443: cannot bind socket (Permission denied) [0.0.0.0:443] [ALERT] (1) : [haproxy.main()] Some protocols failed to start their listeners! Exiting. This problem, but soon I found that it could not connect media files, and later I found that in the \proxy-main\proxy\src\proxy_config.cfg file I accidentally modified the WhatsApp server

frontend haproxy_v4_whatsapp_net maxconn 27495

PUBLIC_IP

bind ipv4@:587 bind ipv4@:7777

default_backend wa_whatsapp_net

backend wa_whatsapp_net default-server check inter 60000 observe layer4 server whatsapp_net_443 whatsapp.net:443

backend wa default-server check inter 60000 observe layer4 send-proxy server g_whatsapp_net_5222 g.whatsapp.net:5222

backend wa_http default-server check inter 60000 observe layer4 send-proxy server g_whatsapp_net_80 g.whatsapp.net:80

Please do not modify g.whatsapp.net:5222 and g.whatsapp.net:80, this is the only channel to the WhatsApp server media files

JerichoWord commented 11 months ago

I also have this problem, sometimes proxy is "connected" and texts send rapidly but medias don't, sometimes proxy for chat is connected but for media not, and sometimes everything works. This "sometimes" words are so random situations. For example, on a specific cellular network service provider it works great but on other providers don't. Also, minutes or location can be change the behavior of proxy. I think maybe it's a GFW issue, but I don't know why chats work well always but media not. Isn't their protocol and encryption the same?

check \proxy-main\proxy\src\proxy_config.cfg file

` frontend haproxy_v4_whatsapp_net maxconn 27495

PUBLIC_IP

bind ipv4@:587 bind ipv4@:7777

default_backend wa_whatsapp_net

backend wa_whatsapp_net default-server check inter 60000 observe layer4 server whatsapp_net_443 whatsapp.net:443

backend wa default-server check inter 60000 observe layer4 send-proxy server g_whatsapp_net_5222 g.whatsapp.net:5222

backend wa_http default-server check inter 60000 observe layer4 send-proxy server g_whatsapp_net_80 g.whatsapp.net:80 `

thantez commented 11 months ago

I also have this problem, sometimes proxy is "connected" and texts send rapidly but medias don't, sometimes proxy for chat is connected but for media not, and sometimes everything works. This "sometimes" words are so random situations. For example, on a specific cellular network service provider it works great but on other providers don't. Also, minutes or location can be change the behavior of proxy. I think maybe it's a GFW issue, but I don't know why chats work well always but media not. Isn't their protocol and encryption the same?

check \proxy-main\proxy\src\proxy_config.cfg file

` frontend haproxy_v4_whatsapp_net maxconn 27495 #PUBLIC_IP

bind ipv4@:587 bind ipv4@:7777

default_backend wa_whatsapp_net

backend wa_whatsapp_net default-server check inter 60000 observe layer4 server whatsapp_net_443 whatsapp.net:443

backend wa default-server check inter 60000 observe layer4 send-proxy server g_whatsapp_net_5222 g.whatsapp.net:5222

backend wa_http default-server check inter 60000 observe layer4 send-proxy server g_whatsapp_net_80 g.whatsapp.net:80 `

@JerichoWord Hi. I couldn't understand your solution. Do you solve this issue by changing HAProxy config? If this works for you, please write new config as code (by write triple ` around code), I think some of your codes are compiled as Markdown and made the text wrong! Thanks.

ttimasdf commented 11 months ago

I also have this problem, sometimes proxy is "connected" and texts send rapidly but medias don't, sometimes proxy for chat is connected but for media not, and sometimes everything works. This "sometimes" words are so random situations. For example, on a specific cellular network service provider it works great but on other providers don't. Also, minutes or location can be change the behavior of proxy. I think maybe it's a GFW issue, but I don't know why chats work well always but media not. Isn't their protocol and encryption the same?

Media proxy is currently implemented in a very bad (and non-standard) way. The client expect the proxy server to be a CDN endpoint of whatsapp media CDN and send plaintext whatsapp domain names in TLS SNI field, making it very easy to sniff and block connections to proxy servers. And SNI blocking has already been a known thing for some countries.

The only way to solve this problem is to implement a highly anonymous proxy which immunes to MITM attack, which we all know there's been plenty of them. Also it's out of the responsibility of WhatsApp team to solve this problem, ~because the users in the countries blocking access to whatsapp are also not its target users~ 🫠

So the best way is to first establish a robust tunnel through the firewall, and deploy a whatsapp proxy server (better a private one) behind the firewall using this tunnel to access whatsapp server. I've added instructions to setup a private server (which won't be scanned and abused by script kiddos) in a PR (#229), you could probably check it out @thantez

thantez commented 11 months ago

So the best way is to first establish a robust tunnel through the firewall, and deploy a whatsapp proxy server (better a private one) behind the firewall using this tunnel to access whatsapp server. I've added instructions to setup a private server (which won't be scanned and abused by script kiddos) in a PR (#229), you could probably check it out @thantez

I see. I will test it and notice you and others. Thanks for your help.

thantez commented 10 months ago

@ttimasdf Hello again. I tested your implementation by Traefik and till issue is there. Chat is ok, but media can't connect yet. I don't use any custom SSL and follow instruction.

fungjigroup commented 10 months ago

Can you give me the IP address of the proxy you are using so that I can test if it works for me or not? Thanks!

On Sat, 11 Nov 2023 at 23:04, M.Mahdi Bakhshi @.***> wrote:

@ttimasdf https://github.com/ttimasdf Hello again. I tested your implementation by Traefik and till issue is there. Chat is ok, but media can't connect yet. I don't use any custom SSL and follow instruction.

— Reply to this email directly, view it on GitHub https://github.com/WhatsApp/proxy/issues/200#issuecomment-1806838849, or unsubscribe https://github.com/notifications/unsubscribe-auth/BCCWOEVUXYAHJGU7ZA5KHPTYD6HXBAVCNFSM6AAAAAAZU75AJSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQMBWHAZTQOBUHE . You are receiving this because you commented.Message ID: @.***>

JerichoWord commented 10 months ago

@ttimasdf Hello again. I tested your implementation by Traefik and till issue is there. Chat is ok, but media can't connect yet. I don't use any custom SSL and follow instruction.

did you try your server ping to to whatsapp.net:443 g.whatsapp.net:5222 g.whatsapp.net:80 ? if your server is have ms , that your server is work

JerichoWord commented 10 months ago

I also have this problem, sometimes proxy is "connected" and texts send rapidly but medias don't, sometimes proxy for chat is connected but for media not, and sometimes everything works. This "sometimes" words are so random situations. For example, on a specific cellular network service provider it works great but on other providers don't. Also, minutes or location can be change the behavior of proxy. I think maybe it's a GFW issue, but I don't know why chats work well always but media not. Isn't their protocol and encryption the same?

check \proxy-main\proxy\src\proxy_config.cfg file frontend haproxy_v4_whatsapp_net maxconn 27495 #PUBLIC_IP bind ipv4@_:587 bind ipv4@_:7777 default_backend wa_whatsapp_net backend wa_whatsapp_net default-server check inter 60000 observe layer4 server whatsapp_net_443 whatsapp.net:443 backend wa default-server check inter 60000 observe layer4 send-proxy server g_whatsapp_net_5222 g.whatsapp.net:5222 backend wa_http default-server check inter 60000 observe layer4 send-proxy server g_whatsapp_net_80 g.whatsapp.net:80

@JerichoWord Hi. I couldn't understand your solution. Do you solve this issue by changing HAProxy config? If this works for you, please write new config as code (by write triple ` around code), I think some of your codes are compiled as Markdown and made the text wrong! Thanks.

因为我无法使用5000以下的端口,我把端口修改成了其他端口,然后我就发现了我无法使用媒体文件后来我才知道。

如果你修改了WhatsApp的默认端口80和443和5222和8080和8443和7777,那你要注意 你是否不小心修改到了\proxy-main\proxy\src\proxy_config.cfg这个文件,因为这个文件是把数据传递到WhatsApp服务器的,不要修改\proxy-main\proxy\src\proxy_config.cfg中的whatsapp.net:443和g.whatsapp.net:5222和g.whatsapp.net:80否则你将无法使用媒体文件

thantez commented 9 months ago

@ttimasdf Hello again. I tested your implementation by Traefik and till issue is there. Chat is ok, but media can't connect yet. I don't use any custom SSL and follow instruction.

did you try your server ping to to whatsapp.net:443 g.whatsapp.net:5222 g.whatsapp.net:80 ? if your server is have ms , that your server is work

Yup. It's ok.

JellyVPN commented 8 months ago

After more than 6 months and still this is known bug and developers didn't fixed it yet

eozturk1 commented 8 months ago

Hi @JellyVPN,

Can you please submit a bug report when you experience the issue and let me know here when you do?

Thanks!

habibi1365 commented 6 months ago

Hello Please provide an update as soon as possible so that we can send media through a proxy, WhatsApp is limited in our country and we are very annoyed, it is not necessary to be a proxy, you can add Socks5

eozturk1 commented 5 months ago

Hi @habibi1365,

If the proxy you are connecting to supports media and you are not able send media -- even though the app shows "Connected", please file a bug and let us know, we will investigate!

habibi1365 commented 5 months ago

Hi @habibi1365,

If the proxy you are connecting to supports media and you are not able send media -- even though the app shows "Connected", please file a bug and let us know, we will investigate!

Thank you for your reply, please leave a telegram ID so that I can send you the proxy

t.me/habibi1365

Imran100124 commented 4 months ago

WhatsApp Image 2024-05-27 at 4 41 40 PM (1) "I fixed the media chat issue by allowing port 587 & 443 on the firewall and enabling TLS on the WhatsApp proxy feature. It worked like a charm!"

but still VOIP Is not working!

WhatsApp Image 2024-05-27 at 4 41 40 PM

habibi1365 commented 4 months ago

WhatsApp Image 2024-05-27 at 4 41 40 PM (1) "I fixed the media chat issue by allowing port 587 & 443 on the firewall and enabling TLS on the WhatsApp proxy feature. It worked like a charm!"

but still VOIP Is not working!

WhatsApp Image 2024-05-27 at 4 41 40 PM

What server did you use and where is your region? If I give you a server, you can configure it for me Can we communicate with each other on Telegram?