wechaty / puppet-wechat

Wechaty Puppet Provider for WeChat
https://www.npmjs.com/package/wechaty-puppet-wechat
Apache License 2.0
419 stars 71 forks source link

Fix fail to download message file #197

Closed pacoyang closed 2 years ago

pacoyang commented 2 years ago

Ref to #194 WeChat server now redirects the HTTP link to HTTPS, making the FileBox download file get 0 bytes returns. e.g.

http://wx.qq.com/cgi-bin/mmwebwx-bin/webwxgetmsgimg
HTTP/1.1 302 Found
Connection: close
Date: Fri, 14-Jan-2022 09:09:03 GMT
Location: https://wx.qq.com/cgi-bin/mmwebwx-bin/webwxgetmsgimg?MsgID=xxx&skey=xxx
Content-Length: 0

I have not figured out why to replace HTTPS with HTTP here since I always download the file successfully through HTTPS.

leochen-g commented 2 years ago

目前发现头像这一块也是获取不到文件了,也是同样的问题,http也需要改成https,我本地已经测试了一下,发现只有https可以下载文件