Commit Graph

503 Commits (465b3bb9619ae9718c62c1a31d4612ad222fe342)

Author SHA1 Message Date
Tatsuhiro Tsujikawa 465b3bb961 2008-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Updated translations. Added Finnish and Hebrew translations.
	Great thanks to all translators!
	* po/*.{po, gmo}
	* po/LINGUAS
2008-02-21 12:46:20 +00:00
Tatsuhiro Tsujikawa 7e6d037c97 2008-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Log more detailed information about each message.
	* src/DHTQueryMessage.{h, cc}
	* src/DHTGetPeersMessage.{h, cc}
	* src/DHTFindNodeReplyMessage.{h, cc}
	* src/DHTGetPeersReplyMessage.{h, cc}
	* src/DHTAnnouncePeerMessage.{h, cc}
	* src/DHTResponseMessage.{h, cc}
	* src/DHTFindNodeMessage.{h, cc}
2008-02-21 12:25:26 +00:00
Tatsuhiro Tsujikawa a8eeb81883 2008-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Use constants defined in prefs.h
	* src/option_processing.cc
2008-02-21 12:24:06 +00:00
Tatsuhiro Tsujikawa 4b67290f00 2008-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
* test/AllTest.cc: Added OpenSSL, GNUTLS initialization code.
2008-02-21 02:21:14 +00:00
Tatsuhiro Tsujikawa 0d130b77f4 2008-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Make room for future enchancements for IPv6 addresses.
	Bump up version number of dht.dat file format to 2.
	Not compatible with previous version.
	* src/DHTRoutingTableSerializer.cc
	* src/DHTRoutingTableDeserializer.cc
	* test/DHTRoutingTableSerializerTest.cc
2008-02-21 02:19:55 +00:00
Tatsuhiro Tsujikawa 24b91983e1 2008-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added handling for the return values from
	PeerMessageUtil::createcompact().
	* src/DefaultBtContext.cc (computeFastSet):
2008-02-21 00:56:14 +00:00
Tatsuhiro Tsujikawa 3274b6acc7 2008-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Fixed abort when peer's ip address is IPv4-mapped address.
	* src/DefaultBtContext.cc (computeFastSet)

	Removed number-and-dots criteria, since 
Util::isNumberAndDotsNotation()
	cannot handle IPv4-mapped addresses.
	* src/DefaultBtInteractive.cc (addPeerExchangeMessage)
2008-02-20 17:45:22 +00:00
Tatsuhiro Tsujikawa cfd0a40fdb 2008-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Proper return value handling for OpenSSL functions.
	* src/LibsslDHKeyExchange.h
2008-02-20 17:00:44 +00:00
Tatsuhiro Tsujikawa dd8f18956a 2008-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Random bytes generation using libgcrypt and OpenSSL.
	* src/DHTUtil.{h, cc}
	* test/DHTUtilTest.cc
2008-02-20 16:57:47 +00:00
Tatsuhiro Tsujikawa 1ea9033363 2008-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Fixed segmentation fault when a DHT message which doesn't have 
'y' key
	received.
	* src/DHTMessageReceiver.cc (receiveMessage)
2008-02-20 16:52:09 +00:00
Tatsuhiro Tsujikawa c4aaea3ca2 2008-02-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Fixed the bug that a return code is always 0. BUG#1897704
	If error occurred during the download or there exist unfinished
	downloads, aria2 returns with code 1.
	* src/RequestGroupMan.{h, cc}
	* src/MultiUrlRequestInfo.{h, cc}
	* src/main.cc
2008-02-20 16:46:56 +00:00
Tatsuhiro Tsujikawa 2cc471ebf6 2008-02-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
IPv6 support for SocketCore class.
	TODO: In SocketCore::establishConnection(), this is insufficient 
to
	determin the failure of connect() here because the socket is
	non-blocking state. The next addresses should be tried after 
select().
	TODO: NameResolver still uses c-ares(<= 1.4) 
ares_gethostbyname().
	If c-ares 1.5 or newer is installed, ares_getaddrinfo() should 
be used
	instead which address family independent.
	TODO: DHTRoutingTable{Deserializer,Serializer} currently saves 
peer
	information in a compact peer format which is for IPv4 only.
	
	Some BitTorrent functions in PeerMessageUtil still depends on 
IPv4 but
	this is a spec of BitTorrent protocol.
	* src/SocketCore.{h, cc}
	* src/PeerMessageUtil.cc
	* test/SocketCoreTest.cc
	* test/PeerMessageUtilTest.cc
	* test/DHTConnectionImplTest.cc

	Handle IPv4-mapped addresses.
	* src/DHTNode.cc: Now identity is determined by node id.
	* src/DHTMessageTrackerEntry.cc

	Because now PeerMessageUtil::unpackcompact() could fail, the 
caller
	should handle it.
	* src/DHTRoutingTableDeserializer.cc
	* src/DHTMessageFactoryImpl.cc
2008-02-20 13:02:48 +00:00
Tatsuhiro Tsujikawa 4708809094 2008-02-20 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Change the unit of --stop option from a minute to a second.
	* src/usage_text.h
	* src/DownloadEngineFactory.cc
	* src/OptionHandlerFactory.cc
	* src/message.h
	* src/TimedHaltCommand.cc
2008-02-20 12:33:16 +00:00
Tatsuhiro Tsujikawa 80bc9a8a21 2008-02-19 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Make listening socket non-block mode.
	* src/FtpConnection.cc
	* src/FtpNegotiationCommand.{h, cc}
	* src/PeerListenCommand.cc
	
	Fixed the bug that cause slow ftp negotiation.
	* src/FtpNegotiationCommand.{h, cc}
2008-02-19 13:36:39 +00:00
Tatsuhiro Tsujikawa 766e092af3 2008-02-19 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added basic tag to --enable-dht, --dht-listen-port option.
	* src/HelpItemFactory.cc (createHelpItems)
2008-02-19 12:05:21 +00:00
Tatsuhiro Tsujikawa c87b6b2984 2008-02-19 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Updated text.
	* src/usage_text.h
2008-02-18 17:37:54 +00:00
Tatsuhiro Tsujikawa 1d0175a29e 2008-02-19 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
* src/MSEHandshake.cc (encryptAndSendData): Use std::min().
2008-02-18 17:13:20 +00:00
Tatsuhiro Tsujikawa 3c41ea24bf 2008-02-19 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Determin _threadtholdSpeed in each constructor for
	ActivePeerConnectionCommand and PeerReceiveHandshakeCommand.
	* src/ActivePeerConnectionCommand.{h, cc}
	* src/PeerReceiveHandshakeCommand.{h, cc}
	* src/BtSetup.cc
	* src/BtConstants.h
2008-02-18 17:11:44 +00:00
Tatsuhiro Tsujikawa 20cd2e5246 2008-02-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added --bt-min-crypto-level and --bt-require-crypto options.
	* src/OptionHandlerFactory.cc
	* src/MSEHandshake.cc
	* src/HelpItemFactory.cc
	* src/option_processing.cc
	* src/ReceiverMSEHandshakeCommand.cc
	* src/prefs.h
	* src/DefaultBtAnnounce.cc
	* src/InitiatorMSEHandshakeCommand.cc
	* src/usage_text.h
	* test/MSEHandshakeTest.cc
2008-02-18 13:41:58 +00:00
Tatsuhiro Tsujikawa c37539eb25 2008-02-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Bump version number to 0.13.0b
	* configure.ac
2008-02-17 16:17:26 +00:00
Tatsuhiro Tsujikawa b7e841e885 2008-02-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Updated doc.
	* src/MessageDigestHelper.h:
2008-02-17 16:12:47 +00:00
Tatsuhiro Tsujikawa ebd524b6a2 2008-02-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Use raw message digest as a token instead of its hexadecimal
	representation.
	* src/DHTTokenTracker.cc (generateToken)
2008-02-17 16:10:10 +00:00
Tatsuhiro Tsujikawa c0d2223c77 2008-02-16 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added Message Stream Encryption(MSE) support.
	Currently, aria2 accepts incoming connections with Obfuscation Header
	and legacy BitTorrent Header and establishes connections with
	Obfuscation Header first and if failed then retry with legacy
	BitTorrent header. If plain text and ARC4 is provided, aria2 always
	choose ARC4. The new option to change the default behavior is planned.
	For tracker extension, "supportcrypto=1" is added statically.
	* src/PeerInitiateConnectionCommand.{h, cc}
	* src/PeerConnection.{h, cc}
	* src/HandleRegistry.h
	* src/SocketCore.h
	* src/PeerReceiveHandshakeCommand.{h, cc}
	* src/BtRegistry.{h, cc}
	* src/PeerListenCommand.cc
	* src/InitiatorMSEHandshakeCommand.{h, cc}
	* src/ReceiverMSEHandshakeCommand.{h, cc}
	* src/MSEHandshake.{h, cc}
	* src/ARC4Encryptor.h
	* src/ARC4Decryptor.h
	* src/LibgcryptARC4Encryptor.h
	* src/LibgcryptARC4Decryptor.h
	* src/LibgcryptARC4Context.h
	* src/LibsslARC4Encryptor.h
	* src/LibsslARC4Decryptor.h
	* src/LibsslARC4Context.h
	* src/DHKeyExchange.h
	* src/LibgcryptDHKeyExchange.h
	* src/LibsslDHKeyExchange.h
	* src/DefaultBtAnnounce.cc: Just added "supportcrypto=1" parameter.
	* test/DefaultBtAnnounceTest.cc
	* test/ARC4Test.cc
	* test/DHKeyExchangeTest.cc
	
	Removed prepareForRetry() because it is not used.
	* src/PeerAbstractCommand.{h, cc}
	* src/PeerInteractionCommand.{h, cc}
	* src/PeerInitiateConnectionCommand.{h, cc}
2008-02-17 15:56:47 +00:00
Tatsuhiro Tsujikawa 1302123368 2008-02-13 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added the ability to load nodes from torrent file. These nodes are
	added to the routing table when downloading that torrent.
	* src/BtContext.h
	* src/DefaultBtContext.{h, cc}
	* src/DHTSetup.cc
	* src/DHTEntryPointNameResolveCommand.{h, cc}: Now accepts list of
	hostname and port pair, and resolves all of them.
	* src/NameResolver.{h, cc}: Added reset().
	* src/RequestGroup.cc	
	* test/DefaultBtContextTest.cc 
	* test/MockBtContext.h
	
	Removed assert() from DefaultBtContext and throw exception instead.
	* src/DefaultBtContext.cc
2008-02-13 15:17:08 +00:00
Tatsuhiro Tsujikawa bfcc300670 2008-02-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Fixed segmentation fault bug when exiting if dht is disabled.
	* src/RequestGroup.cc
2008-02-12 13:49:39 +00:00
Tatsuhiro Tsujikawa bc1f1bdf35 2008-02-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Fixed typo in log message and define the message in message.h
	* src/TimedHaltCommand.cc
	* src/message.h
2008-02-12 13:45:54 +00:00
Tatsuhiro Tsujikawa 1700f5c1bc 2008-02-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Included RecoverableException.h to fix compilation error.
	* test/DHTMessageFactoryImplTest.cc
2008-02-11 13:41:16 +00:00
Tatsuhiro Tsujikawa bebb7e1976 2008-02-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added test 'testDoReceivedAction' for DHTQueryMessage 
subclasses.
	* test/DHTPingMessageTest.cc
	* test/DHTGetPeersMessageTest.cc
	* test/DHTFindNodeMessageTest.cc
	* test/DHTAnnouncePeerMessageTest.cc
	* test/MockDHTMessage.h
	* test/MockDHTMessageFactory.h
	* test/MockDHTMessageDispatcher.h: New class.
2008-02-11 12:32:46 +00:00
Tatsuhiro Tsujikawa e9f980afc7 2008-02-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added DHTMessageDispatcherImpl. Now DHTMessageDispatcher is pure
	virtual.
	* src/DHTMessageDispatcher.h
	* src/DHTMessageDispatcherImpl.{h, cc}
	* src/DHTSetup.cc
2008-02-11 07:50:35 +00:00
Tatsuhiro Tsujikawa 413cbe192b 2008-02-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Adding handling of DHT error message. Just log error message and
	throw exception.
	* src/DHTMessageFactoryImpl.cc
	* test/DHTMessageFactoryImplTest.cc
2008-02-11 06:23:01 +00:00
Tatsuhiro Tsujikawa 34e6a1dc9a 2008-02-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added handling of dynamic cast failure.
	* src/DHTNodeLookupTask.cc
	* src/DHTPeerLookupTask.cc
2008-02-11 05:54:08 +00:00
Tatsuhiro Tsujikawa 9c277148b9 2008-02-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added the ability to stop aria2 itself when given time has 
passed
	from start. Use --stop option to specify time in minutes.
	When 0 is given, this feature is disabled.
	* src/OptionHandlerFactory.cc
	* src/TimeBasedCommand.h: Make _interval protected scope.
	* src/HelpItemFactory.cc
	* src/option_processing.cc
	* src/prefs.h
	* src/FillRequestGroupCommand.cc: Evaluate _e->isHaltRequested()
	before calling RequestGroupMan::fillRequestGroupFromReserver().
	Without this modification, the result list shows "ERR" when 
aria2 is
	stopped by --stop option. It should be "INPR".
	* src/DownloadEngine.{h, cc}
	* src/DownloadEngineFactory.cc
	* src/usage_text.h
	* src/TimedHaltCommand.{h, cc}: New class.
2008-02-11 05:07:08 +00:00
Tatsuhiro Tsujikawa 5d6f1c046a 2008-02-11 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Bootstrap through node added by port message.
	Currently bootstrap is executed if the number of buckets in routing
	table is 1.
	* src/BtPortMessage.{h, cc}
	* src/DefaultBtMessageFactory.{h, cc}
	* src/PeerInteractionCommand.cc
	* test/BtPortMessageTest.cc
	* test/MockDHTTask.h
2008-02-10 15:57:00 +00:00
Tatsuhiro Tsujikawa c064a2cd9e 2008-02-10 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Extract the Peer class's member variables, which are only needed 
after
	PeerInteractionCommand, into PeerSessionResource class.
	This class is instantiated in PeerInteractionCommand class's 
ctor and
	released in its dtor.
	This will make Peer class lightweight and uses less memory for 
peers
	which are not connected and wait in the queue.
	* src/PeerChokeCommand.cc
	* src/PeerSessionResource.{h, cc}
	* src/PeerInteractionCommand.cc
	* src/PeerAbstractCommand.cc: Note: 0 is given to onAbort() 
function.
	* src/DefaultBtInteractive.cc
	* src/BtPieceMessage.cc
	* src/BtInterestedMessage.cc
	* src/BtUnchokeMessage.cc
	* src/DefaultPeerStorage.{h, cc}
	* src/PeerInitiateConnectionCommand.cc
	* src/ActivePeerConnectionCommand.cc
	* src/BtNotInterestedMessage.cc
	* src/DefaultBtMessageDispatcher.cc
	* src/BtChokeMessage.cc
	* src/BtRequestMessage.cc
	* src/Peer.{h, cc}
	* src/BtRegistry.h
	* src/TrackerWatcherCommand.cc
	* src/PeerReceiveHandshakeCommand.cc
	* test/BtExtendedMessageTest.cc
	* test/BtAllowedFastMessageTest.cc
	* test/BtCancelMessageTest.cc
	* test/DefaultPieceStorageTest.cc
	* test/BtBitfieldMessageTest.cc
	* test/BtHaveMessageTest.cc
	* test/BtNotInterestedMessageTest.cc
	* test/BtRequestMessageTest.cc
	* test/PeerSessionResourceTest.cc
	* test/DefaultBtMessageDispatcherTest.cc
	* test/PeerTest.cc
	* test/BtInterestedMessageTest.cc
	* test/BtRejectMessageTest.cc
	* test/BtChokeMessageTest.cc
	* test/DefaultPeerStorageTest.cc
	* test/BtHaveNoneMessageTest.cc
	* test/BtHaveAllMessageTest.cc
	* test/DefaultExtensionMessageFactoryTest.cc
	* test/BtUnchokeMessageTest.cc
	* test/DefaultBtMessageFactoryTest.cc
	* test/HandshakeExtensionMessageTest.cc
	* test/UTPexExtensionMessageTest.cc
	* test/DefaultBtRequestFactoryTest.cc
	* test/BtPieceMessageTest.cc
	
	Removed typedef PeerStats.
	* src/PeerStat.h
	* src/SegmentMan.cc
2008-02-09 17:14:40 +00:00
Tatsuhiro Tsujikawa 04a7052013 2008-02-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added std namespace to copy, remove_copy, back_inserter,
	front_inserter.
	* src/RequestGroupMan.cc
	* src/DefaultPieceStorage.cc
	* src/StreamFileAllocationEntry.cc
	* src/BtFileAllocationEntry.cc
	* src/RequestGroup.cc
	* src/MetalinkEntry.cc
	* src/DelegatingPeerListProcessor.cc
	* src/DefaultBtRequestFactory.cc
	* src/DefaultBtMessageDispatcher.cc
	* src/version_usage.cc: Included <algorithm>
	* src/main.cc
	* src/MetalinkParserController.cc
	* src/DefaultBtContext.cc
	* src/DownloadEngineFactory.cc
	* src/a2algo.h

	Removed.
	* test/StreamUriListParserTest.cc
2008-02-08 18:39:26 +00:00
Tatsuhiro Tsujikawa 7fdbd0e104 2008-02-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Use PREF_MAX_DOWNLOAD_LIMIT as a threshold for
	ActivePeerConnectionCommand when it is given and
	PREF_MAX_DOWNLOAD_LIMIT < default threshold.
	* src/ActivePeerConnectionCommand.{h, cc}
	* src/BtSetup.cc
2008-02-08 18:30:46 +00:00
Tatsuhiro Tsujikawa f38eb15ca9 2008-02-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Only add socket to DownloadEngine's select routine when peer or
	localhost is unchoked and interested. This lowers CPU usage a
	little bit.
	* src/PeerInteractionCommand.cc
	* src/PeerAbstractCommand.{h, cc}
	* src/BtInteractive.h
	* src/DefaultBtInteractive.{h, cc}
2008-02-08 18:27:28 +00:00
Tatsuhiro Tsujikawa 9ab0ece87f 2008-02-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Revert previous change because get_peers message is needed for
	announce_peer anyway.	
	* src/DHTGetPeersCommand.cc
2008-02-08 18:21:19 +00:00
Tatsuhiro Tsujikawa f1d786469c 2008-02-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Request peers thought DHT only when download hasn't finished.
	* src/DHTGetPeersCommand.cc
2008-02-08 16:17:07 +00:00
Tatsuhiro Tsujikawa 6fe7b7c8f3 2008-02-09 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Force refresh bucket when startup if certain time has 
passed(currently 15 minutes).
	* src/DHTBucketRefreshTask.{h, cc}
	* src/DHTSetup.cc
2008-02-08 16:11:21 +00:00
Tatsuhiro Tsujikawa 1b7c198289 2008-02-08 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Removed "using namespace std;" from all sources. Appended std:: 
prefix to c++
	standard classes.
	Included string.h where mem* function are used.
2008-02-08 15:53:45 +00:00
Tatsuhiro Tsujikawa d82e183d34 2008-02-06 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Create directory before saving DHT routing table.
	Now ios::failure is now handled properly.
	* src/DHTAutoSaveCommand.cc
2008-02-05 17:38:24 +00:00
Tatsuhiro Tsujikawa 7b0a940ab4 2008-02-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Removed unnecessary cerr.
	* src/DownloadEngine.cc
2008-02-05 14:16:58 +00:00
Tatsuhiro Tsujikawa bdb1a25ca7 2008-02-05 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Catch exception inside DHTMessageReceiver::receiveMessage().
	Log unknown message.
	* src/DHTMessageReceiver.{h, cc}
	* src/DHTMessageFactory.h
	* src/DHTMessageFactoryImpl.{h, cc}
	* src/DHTMessageTracker.cc (handleTimeout): Catch and handle exception.
	* src/DHTInteractionCommand.cc
	* src/DHTUnknownMessage.{h, cc}
	* test/DHTUnknownMessageTest.cc
	* test/MockDHTMessageFactory.h
2008-02-05 14:15:50 +00:00
Tatsuhiro Tsujikawa 20621d011d 2008-02-02 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Commented out ip address comparison because a host can have 
multiple
	ip addresses and it is hard to predict the hostname is resolved 
into
	which one.
	* test/SocketCoreTest.cc (testWriteAndReadDatagram)
2008-02-02 13:06:55 +00:00
Tatsuhiro Tsujikawa af471b931e 2008-02-02 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
* po/Makefile.in: Removed since this is generated by configure.
2008-02-02 11:28:07 +00:00
Tatsuhiro Tsujikawa 79764a1f11 2008-02-02 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Fixed compiler warning about redefinition of SIZE_MAX.
	Use common.h instead of config.h directly here.
	* src/Platform.{h, cc}

	The check of ENABLE_NLS is made in gettext.h, so it is not 
required
	here.
	* common.h
	
2008-02-02  gettextize  <bug-gnu-gettext@gnu.org>

	Updated gettext related files.
	* configure.ac (AC_CONFIG_FILES): Add intl/Makefile.
	* configure.ac (AM_GNU_GETTEXT_VERSION): Bump to 0.17.
2008-02-02 04:38:24 +00:00
Tatsuhiro Tsujikawa 0f13363229 2008-02-01 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added DHT functionality, compatible with mainline.
	DHT is disabled by default. To enable it, give --enable-dht to 
aria2c.
	You may need to specify entry point to DHT network using
	--dht-entry-point. DHT uses UDP port to listen incoming message.
	Use --dht-listen-port to specify port number. Make sure that 
your
	firewall configuration can pass through UDP traffic to the port.
	The routing table is saved in $HOME/.aria2/dht.dat.
	* src/DHT*
	* src/BNode.{h, cc}
	* src/PeerInteractionCommand.cc: enable DHT functionality for a
	particular torrent.
	* src/Data.cc: Rewritten ctor.
	* src/OptionHandlerFactory.cc: Added --enable-dht, 
--dht-listen-port,
	--dht-entry-point.
	* src/DefaultBtInteractive.cc: Send port message if dht is 
enabled.
	* src/RequestGroup.cc: Initialize DHT functionality. When 
download
	ends, remove BtContext from DHTPeerAnnounceStorage.
	* src/BtPortMessage.{h, cc}: Rewritten.
	* src/message.h
	* src/OptionHandlerImpl.cc
	* src/option_processing.cc: Added --enable-dht, 
--dht-listen-port,
	--dht-entry-point.
	* src/Dictionary.{h, cc} (remove): New function.
	* src/prefs.h
	* src/DefaultBtMessageFactory.h
	* src/BtHandshakeMessage.cc
	* src/ActivePeerConnectionCommand.cc
	* src/SocketCore.{h, cc}: Added datagram socket support.
	* src/DefaultBtMessageFactory.cc
	* src/BtSetup.cc: Add BtContext to DHTPeerAnnounceStorage here.
	Create DHT commands.
	* src/BtMessageFactory.h
	* src/PeerMessageUtil.{h, cc}
2008-02-01 17:36:33 +00:00
Tatsuhiro Tsujikawa 0bce06348e 2008-01-21 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Fixed the bug that log file is not written when configuration 
file doesn't exist.
	This is caused by using Logger class before LogFactory is not 
configured.
	BUG #1875079
	* src/option_processing.cc

	Warning message "configuration doesn't exist" is only printed 
when --conf is
	given.
	* src/option_processing.cc
2008-01-20 15:20:16 +00:00
Tatsuhiro Tsujikawa a548f956fe 2008-01-12 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Use BencodeVisitor and MessageDigestHelper instead of 
ShaVisitor.
	ShaVisitor is now deprecated and slated to be removed.
	* src/DefaultBtContext.cc
2008-01-11 15:47:31 +00:00