Rewritten util::escapePath(). Now it does not replace bad chars:it
performs percent-encode against them. util::fixTaintedBasename()
now replaces "/" with "%2F". Added 0x7f as bad chars in
util::detectDirTraversal().
* src/util.cc
* test/UtilTest.cc
Non-UTF8 filenames are now percent-encoded. For example, filename
for http://example.org/%90%A2%8AE will be %90%A2%8AE because it is
Shift_JIS. The comments and name in .torrent file in XML-RPC
response are percent-encoded if they are not UTF-8.
* src/FtpNegotiationCommand.cc
* src/HttpRequestCommand.cc
* src/HttpResponseCommand.cc
* src/XmlRpcMethodImpl.cc
* src/bittorrent_helper.cc
* src/util.cc
* src/util.h
* test/BittorrentHelperTest.cc
* test/UtilTest.cc
Sort usedHosts by least used and faster download speed.
* src/Makefile.am
* src/RequestGroupMan.cc
* src/Triplet.h
* test/Makefile.am
* test/TripletTest.cc
Reset download start time of PeerStat because it is started before
file allocation begins. Without reset, we have incorrect download
time and aria2 wrongly determines that download speed is too low
if --lowest-speed-limit is used.
* src/StreamFileAllocationEntry.cc
Added keys parameter to aria2.tellStatus, aria2.tellActive,
aria2.tellWaiting and aria2.tellStopped XML-RPC method. 'keys' is
array of string. If it is specified, the response contains only
keys in 'keys' array. If 'keys' is empty or not specified, the
response contains all keys. This is useful when you just want
specific keys and avoid unnecessary transfers. For example,
*aria2.tellStatus*("1", ["gid", "status"]) returns 'gid' and
'status' key. Made get*Param() functions XmlRpcRequest's
methods and changed portions of the code that were affected by
this change.
* doc/aria2c.1.txt
* src/Makefile.am
* src/XmlRpcMethodImpl.cc
* src/XmlRpcMethodImpl.h
* src/XmlRpcRequest.cc
* src/XmlRpcRequest.h
* test/XmlRpcMethodTest.cc
Fixed the bug that a file gets overwritten if -V is given and no
hash is provided. Fixed the bug that --dry-run leads download
error. Added RequestGroup::createCheckIntegrityEntry() which
correctly creates CheckIntegrityEntry objects and open files based
on -V option and the existence of control file.
* src/AbstractCommand.cc
* src/AbstractCommand.h
* src/ChecksumCheckIntegrityEntry.cc
* src/DownloadContext.cc
* src/DownloadContext.h
* src/FtpNegotiationCommand.cc
* src/HttpResponseCommand.cc
* src/PieceHashCheckIntegrityEntry.cc
* src/RequestGroup.cc
* src/RequestGroup.h
* src/RequestGroupEntry.cc
* src/RequestGroupEntry.h
Added short option -k for --min-split-size option and -x for
--max-connection-per-server option. Raised maximum value of
--max-connection-per-server up to 16.
* src/OptionHandlerFactory.cc
* src/usage_text.h
Use uri::parse instead of Request::setUri() where just URI parser
is needed.
* src/AbstractCommand.cc
* src/AdaptiveURISelector.cc
* src/DefaultBtAnnounce.cc
* src/FeedbackURISelector.cc
* src/FileEntry.cc
* src/HttpResponseCommand.cc
* src/ProtocolDetector.cc
* src/Request.cc
* src/RequestGroupMan.cc
Moved URI parser code to uri.h, uri.cc to provide fast URI parser
without Request object initialization.
* src/Makefile.am
* src/Request.cc
* src/uri.cc
* src/uri.h
* test/Makefile.am
* test/RequestTest.cc
* test/UriTest.cc
Added --max-download-result=NUM option. This option sets maximum
number of download result kept in memory. The download results are
completed/error/ removed downloads. The download results are
stored in FIFO queue and it can store at most NUM download
results. When queue is full and new download result is created,
oldest download result is removed from the front of the queue and
new one is pushed to the back. Setting big number in this option
may result high memory consumption after thousands of
downloads. Specifying 0 means no download result is kept. Default
value is 1000.
* src/OptionHandlerFactory.cc
* src/RequestGroupMan.cc
* src/RequestGroupMan.h
* src/prefs.cc
* src/prefs.h
* src/usage_text.h
Check hash(hash for entire file, not piece hash) if
--check-integrity option is given and file is
downloaded(determined by file length). If it fails, re-download
file.
* src/AbstractCommand.cc
* src/ChecksumCheckIntegrityEntry.cc
* src/ChecksumCheckIntegrityEntry.h
* src/FtpNegotiationCommand.cc
* src/HttpResponseCommand.cc
* src/RequestGroup.cc
Moved connectedHostname, connectedAddr and connectedPort to
Request object. Mark cached IP address bad on timeout to allow
aria2 to renew IP address cache.
* src/AbstractCommand.cc
* src/AbstractProxyRequestCommand.cc
* src/AbstractProxyRequestCommand.h
* src/FtpInitiateConnectionCommand.cc
* src/FtpNegotiationCommand.cc
* src/FtpNegotiationCommand.h
* src/HttpInitiateConnectionCommand.cc
* src/HttpRequestCommand.cc
* src/HttpRequestCommand.h
* src/InitiateConnectionCommand.cc
* src/InitiateConnectionCommand.h
* src/Request.cc
* src/Request.h
Fixed the bug that aria2 reports error and exits with non-zero
status when file is already downloaded.
* src/FtpNegotiationCommand.cc
* src/HttpResponseCommand.cc
* src/RequestGroup.cc
Allow '@' in username and password embedded in URI. It should be
percent-encoded but many people use their mail address as an
username and forget about PE.
* src/Request.cc
* test/RequestTest.cc