在分析微信网页版,想发送图片,看了一下,微信通过下面的 multipart post 上传图片到服务器,但奇怪的是没看到图片的 2 进制啊,怎么上传的呢,
Request URL:https://file.wx.qq.com/cgi-bin/mmwebwx-bin/webwxuploadmedia?f=json
------WebKitFormBoundary4t32GXtXdZesZUzK
Content-Disposition: form-data; name="id"
WU_FILE_1
------WebKitFormBoundary4t32GXtXdZesZUzK
Content-Disposition: form-data; name="name"
[email protected]
------WebKitFormBoundary4t32GXtXdZesZUzK
Content-Disposition: form-data; name="type"
image/png
------WebKitFormBoundary4t32GXtXdZesZUzK
Content-Disposition: form-data; name="lastModifiedDate"
Sat May 09 2015 15:04:48 GMT+0800 (CST)
------WebKitFormBoundary4t32GXtXdZesZUzK
Content-Disposition: form-data; name="size"
4773
------WebKitFormBoundary4t32GXtXdZesZUzK
Content-Disposition: form-data; name="mediatype"
pic
------WebKitFormBoundary4t32GXtXdZesZUzK
Content-Disposition: form-data; name="uploadmediarequest"
{"BaseRequest":{"Uin":1324081430,"Sid":"kLiK1rL2q8hQoYN9","Skey":"@crypt_c4afdbd8_c10795dc7bdec30d21267fc1284f4050","DeviceID":"e690928520634770"},"ClientMediaId":1453465224337,"TotalLen":4773,"StartPos":0,"DataLen":4773,"MediaType":4}
------WebKitFormBoundary4t32GXtXdZesZUzK
Content-Disposition: form-data; name="webwx_data_ticket"
AQdQY+GQOJsNhTQRxBBFFOhZ
------WebKitFormBoundary4t32GXtXdZesZUzK
Content-Disposition: form-data; name="pass_ticket"
eGahUyL63xtx3P6tKM30iZkKlXNpypJcvv+0K5fwRBEJYerp4g290NooKh38Z1Vc
------WebKitFormBoundary4t32GXtXdZesZUzK
Content-Disposition: form-data; name="filename";
filename="[email protected]"
Content-Type: image/png
------WebKitFormBoundary4t32GXtXdZesZUzK--