Rapidshare hack for Linux
As it turns out it's unbelievably easy to overcome annoying time delay between downloads of the free Rapidshare account. And it's even easier if you happen to run Linux.
Rapidshare "remembers" the IP address you used to download, so all you have to do is to change it between subsequent downloads by restarting DHCP client. In order to ensure that you will not get the same IP address (Linux DHCP client tries to get the same IP by first issuing the DHCP REQUEST and only if it fails - DHCP DISCOVER; and most DHCP servers will try to lease the same IP address for the same MAC address) you have to change... right, the MAC address. And, as I mentioned above, this is yet another example of Linux being much more user-oriented OS than the other one - changing MAC address on Linux is a breeze.
#!/bin/sh
ifdown eth0
let "rnum = $RANDOM % 255"
d=`printf "%02X\n" $rnum`
ifconfig eth0 hw ether 00:0F:EA:37:9F:$d
rm /var/lib/dhclient/dhclient-eth0.leases
ifup eth0
Remember to change the MAC address of the correct interface, i.e. the one on which you get the normal (routable) IP address.
Rapidshare "remembers" the IP address you used to download, so all you have to do is to change it between subsequent downloads by restarting DHCP client. In order to ensure that you will not get the same IP address (Linux DHCP client tries to get the same IP by first issuing the DHCP REQUEST and only if it fails - DHCP DISCOVER; and most DHCP servers will try to lease the same IP address for the same MAC address) you have to change... right, the MAC address. And, as I mentioned above, this is yet another example of Linux being much more user-oriented OS than the other one - changing MAC address on Linux is a breeze.
#!/bin/sh
ifdown eth0
let "rnum = $RANDOM % 255"
d=`printf "%02X\n" $rnum`
ifconfig eth0 hw ether 00:0F:EA:37:9F:$d
rm /var/lib/dhclient/dhclient-eth0.leases
ifup eth0
Remember to change the MAC address of the correct interface, i.e. the one on which you get the normal (routable) IP address.
Labels: hack, IP, linux, MAC, rapidshare