linux wget直接下载  360网盘文件

登陆各类网盘后,可以直接下载,但是在linux上无法直接下载,百度的可以下载
测试了几个后,发现下载时增加cookie后就可以了

如360,直接下载报错
wget -S “http://dl29.yunpan.360.cn/intf.php?method=Download.downloadFile&qid=319220505&fname=%2Fclear_squid_cache.sh&fhash=0801266682348c9f387baa9483db111da40ca6d2&dt=29_29.725986d3ed7e789b875767803e0ab696&v=1.0.1&rtick=13750707843331&devtype=web&sign=c720c3d457880d94bccd0cdbb4761505&”
–2013-07-29 15:52:35– http://dl29.yunpan.360.cn/intf.php?method=Download.downloadFile&qid=319220505&fname=%2Fclear_squid_cache.sh&fhash=0801266682348c9f387baa9483db111da40ca6d2&dt=29_29.725986d3ed7e789b875767803e0ab696&v=1.0.1&rtick=13750707843331&devtype=web&sign=c720c3d457880d94bccd0cdbb4761505&
Resolving dl29.yunpan.360.cn… 180.153.189.26
Connecting to dl29.yunpan.360.cn|180.153.189.26|:80… connected.
HTTP request sent, awaiting response…
HTTP/1.1 514 FatalError
Server: 360Server
Date: Mon, 29 Jul 2013 07:52:38 GMT
Content-Type: text/html;charset=utf-8
Connection: keep-alive
X-Powered-By: PHP/5.2.5
errno: 1001
errmsg: param invalid
Content-Length: 0
2013-07-29 15:52:35 ERROR 514: FatalError.

那增加cookie后呢
cookie是抓取出来的
wget -S -c -O test.sh –header “Cookie:__guid=3537848.2086352217863328500.1375067579500.3325; Hm_lvt_3d143f0a07b6487f65609d8411e5464f=1375067580,1375067664,1375068919,1375069468; Hm_lpvt_3d143f0a07b6487f65609d8411e5464f=1375069468; Q=u%3D360H319220505%26n%3D%26r%3D%26qid%3D319220505%26im%3D220255dq9816%26s%3Dquc%26src%3Dpcw_cloud%26t%3D1%26le%3DLKOjMUIiMUIiWGDjZGLmYzAioD%3D%3D; T=s%3D05af15c930bf2e656b8d3d792e43b78c%26t%3D1375069479%26a%3D0%26v%3D1.0; YUNPAN_USER=%2520appduoduo%2540163.com; token=2013210022.29.7b012980.319220505.1375069480; __utma=148900148.819829526.1375063012.1375063012.1375067580.2; __utmb=148900148.8.10.1375067580; __utmc=148900148; __utmz=148900148.1375067580.2.2.utmcsr=baidu|utmccn=(organic)|utmcmd=organic|utmctr=360%E7%BD%91%E7%9B%98” “http://dl29.yunpan.360.cn/intf.php?method=Download.downloadFile&qid=319220505&fname=%2Fclear_squid_cache.sh&fhash=0801266682348c9f387baa9483db111da40ca6d2&dt=29_29.725986d3ed7e789b875767803e0ab696&v=1.0.1&rtick=13750707843331&devtype=web&sign=c720c3d457880d94bccd0cdbb4761505&”
–2013-07-29 15:54:22– http://dl29.yunpan.360.cn/intf.php?method=Download.downloadFile&qid=319220505&fname=%2Fclear_squid_cache.sh&fhash=0801266682348c9f387baa9483db111da40ca6d2&dt=29_29.725986d3ed7e789b875767803e0ab696&v=1.0.1&rtick=13750707843331&devtype=web&sign=c720c3d457880d94bccd0cdbb4761505&
Resolving dl29.yunpan.360.cn… 180.153.189.26
Connecting to dl29.yunpan.360.cn|180.153.189.26|:80… connected.
HTTP request sent, awaiting response…
HTTP/1.1 200 OK
Server: 360Server
Date: Mon, 29 Jul 2013 07:54:25 GMT
Content-Type: application/octet-stream
Connection: keep-alive
X-Powered-By: PHP/5.2.5
Accept-Ranges: bytes
Content-Length: 308
Content-Transfer-Encoding: binary
Content-Disposition: attachment; filename=”clear_squid_cache.sh”
SIP: 10.140.80.206
Length: 308 [application/octet-stream]
Saving to: 鈥渢est.sh鈥?

100%[==========================================================================================>] 308 –.-K/s in 0s

2013-07-29 15:54:23 (45.7 MB/s) – 鈥渢est.sh鈥?saved [308/308]

via:http://jamesbond0479.blog.163.com/blog/static/2414758201362935022170/

发表评论

邮箱地址不会被公开。 必填项已用*标注