I was looking for a way to download files from Rapidshare in my Linux (CentOS) server. Since I have a Rapidshare premium account the tool should support it and it should work from Linux shell (it’s a server, so no GUI). So here is two tools I found in my search.
Just now I found out a few articles explaining the use of wget and CURL to download files as a Rapidshare Premium user. So here is an update.
Use Wget to download Rapidshare files
Even though it’s a command line tool, wget supports saving and loading cookies. As you know to download Rapidshare links directly, the premium user should log in at least once and the Direct Downloads must be enabled.
First of all create a directory to download the files and cd to that directory and create a directory named .cookies in that. Use the following command for saving the premium cookie in your linux box.
wget --save-cookies .cookies/rapidshare --post-data "login=USERNAME&password=PASSWORD" -O - https://ssl.rapidshare.com/cgi-bin/premiumzone.cgi > /dev/null
The USERNAME & PASSWORD are off course the rapidshare premium login credentials. A premium cookie will be set in the file rapidshare in our cookie jar folder .cookie.
Now use the following command to download the files:
wget -c --load-cookies .cookies/rapidshare http://rapidshare.com/files/123456789/myfile.zip
the argument -c enables the resume support.
Use CURL to download from Rapidshare
This is exactly same as the Wget method. So the commands are shown below:
To set the Rapidshare Premium cookie:
curl --cookie-jar .cookies/rapidshare --data "login=USERNAME&password=PASSWORD" https://ssl.rapidshare.com/cgi-bin/premiumzone.cgi > /dev/null
If you get an SSL Certificate error as the one quoted below use the -k switch in the above command to disable certificate validation.
curl: (60) SSL certificate problem, verify that the CA cert is OK.
Now for downloading:
curl -L -O --cookie .cookies/rapidshare http://rapidshare.com/files/123456789/myfile.zip
gRapid allows premium users of RapidShare to automate downloading of files without having to attend to them. It relies on Java and GNU Wget to process downloads from a file containing Rapidshare links, one on each line. It can perform simultaneous downloads of any number you may desire.
Few caveats with this release:
- You must have JRE 1.5+ installed (in short, the java command should work)
- gRapid should be able to find the Wget binary (this is included for Windows)
- A default ‘Downloads’ directory (already created) must exist, as this is hard coded (!)
- If you queue more than one download, Wget writes all it’s verbose output to a single output file, which (due to lack of file locking) can be quite messy
- Doesn’t warn you if links provided in the input file are not present, i.e. not found on Rapidshare or deleted, etc.
Usage: java -jar gRapid.jar username password input_file simultaneous_downloads
In the above command line username & password means your Rapidshare premium account username and password, input_file is a text file with the rapidshare links one per line, simultaneous_downloads means the number of files to downlaod at a time.
e.g. java -jar gRapid.jar jade 6a%d*4s input.txt 8
It’s a good tool, the only problem is you need messy JRE installed in your Linux machine.
rapidshare-dl (Rapidshare Download)
rapidshare-dl (Rapidshare Download) is a program which helps downloading files from Rapidshare using a Premium Account. The files to download can be specified as parameters, or they can be retrieved from a local file, an URL or from the clipboard.
They have a compiled Debian package available or you can install it from the source. A simple usage example is:
rapidshare-dl links.txt
This tool is a bit old and I haven’t tested it personally. So it may not work now.
And finally if you have a linux box with KDE or GENOME installed there is lot of graphical options. I prefer Flashgot plugin for firefox.


{ 1 comment… read it below or add one }
You’re a life saver, thanks.