aboutsummaryrefslogtreecommitdiff
path: root/src/net.cpp
AgeCommit message (Collapse)Author
2011-09-21Framework for banning mis-behaving peersGavin Andresen
2011-09-19SocketHandler thread can be detachedPieter Wuille
2011-09-06Fix AddAddress cs_mapaddresses/db transaction deadlockGavin Andresen
2011-09-02Stay connected to seed nodes; disconnecting causes problems if you are ↵Gavin Andresen
trying to make the initial blockchain download.
2011-09-02Give hard-coded seed nodes a random last-seen time, to randomize order ↵Gavin Andresen
they're tried.
2011-09-02Update the list of seednodes.Daniel Folkinshteyn
Nodes culled from MagicalTux's database of bitcoin nodes, http://dump.bitcoin.it/misc/ by version and longevity, and tested for connectivity.
2011-09-01Merge branch 'code-cleanup' of git://github.com/muggenhor/bitcoinGavin Andresen
2011-08-23Upgrade dependancies and tweak build process.Matt Corallo
* Upgrade to use miniupnpc 1.6 * Upgrade to wxWidgets 2.9.2 * Upgrade to Bost 1.47 for Win32 Builds
2011-08-19Make some global variables less-global (static)Giel van Schijndel
Explicitly make these global variables less-global to reduce the maximum scope of this global state. In my experience global variables tend to be a major source of bugs. As such the less accessible they are the less likely they are to be the source of a bug. Signed-off-by: Giel van Schijndel <me@mortis.eu>
2011-08-11Merge pull request #458 from TheBlueMatt/copyrightGavin Andresen
Unify copyright notices.
2011-08-10Test for SO_NOSIGPIPE rather than assuming all BSDs support it.Venkatesh Srinivas
Signed-off-by: Jeff Garzik <jgarzik@exmulti.com>
2011-08-09Do-nothing MapPort() ifndef USE_UPNP. fixes #450Gavin Andresen
2011-08-09Unify copyright notices.Matt Corallo
To a variation on: // Copyright (c) 2009-2010 Satoshi Nakamoto // Copyright (c) 2011 The Bitcoin developers
2011-08-01Identify as "Bitcoin + version number" when mapping UPnP portJohannes Henninger
Makes Bitcoin identify itself as "Bitcoin + version number" instead of the nondescript "libminiupnpc" when forwarding a port via UPnP.
2011-07-14Single DB transaction for addresses from DNS seedsStéphane Gimenez
2011-07-14Single DB transaction for all addresses in a messagePatrick Varilly
Cuts disk activity at startup immensely
2011-07-13fix warning: unused variable 'X' [-Wunused-variable]Giel van Schijndel
Remove several unused variables. Signed-off-by: Giel van Schijndel <me@mortis.eu>
2011-07-13fix warning: comparison of unsigned expression < 0 is always false ↵Giel van Schijndel
[-Wtautological-compare] Don't check for a negative parameter count, because not only will it never happen, it doesn't make any sense either. Invalid sockets (as returned by socket(2)) are always exactly -1 (not just negative as negative file descriptors are technically not prohibited by POSIX) on POSIX systems. Since we store them in SOCKET (unsigned int), however, that really is ~0U (or MAX_UINT) which happens to be what INVALID_SOCKET is already defined to, so an additional check for being negative is not only unnecessary (unsigned integers aren't *ever* negative) its redundant as well (the INVALID_SOCKET comparison is enough). Signed-off-by: Giel van Schijndel <me@mortis.eu>
2011-07-05Added a couple minor things to match newer build process.Matt Corallo
This adds the relevent patches which are applied to wx, and updates for cross compiling.
2011-07-02Give more detailed error messages for connection failure.Matt Corallo
2011-07-01Merge pull request #368 from TheBlueMatt/dnsseedJeff Garzik
Only use dnsseeds when not on testnet.
2011-07-01Only use dnsseeds and static seeds when not on testnet.Matt Corallo
2011-07-01Limit response to getblocks to half of output buffer sizePieter Wuille
Introduce SendBufferSize() and ReceiveBufferSize(), and limit the blocks sent as response to the "getblocks" message to half of the active send buffer size.
2011-06-30Merge pull request #367 from TheBlueMatt/dnsseedJeff Garzik
Add new DNSSeed dnsseed.bluematt.me.
2011-06-30Add new DNSSeed dnsseed.bluematt.me.Matt Corallo
This seed will pull a random set of 20 nodes from the network which are tested to be online instead of a static list.
2011-06-28Fix connection failure debug outputJoerie de Gram
2011-06-15CWallet classPieter Wuille
* A new class CKeyStore manages private keys, and script.cpp depends on access to CKeyStore. * A new class CWallet extends CKeyStore, and contains all former wallet-specific globals; CWallet depends on script.cpp, not the other way around. * Wallet-specific functions in CTransaction/CTxIn/CTxOut (GetDebit, GetCredit, GetChange, IsMine, IsFromMe), are moved to CWallet, taking their former 'this' argument as an explicit parameter * CWalletTx objects know which CWallet they belong to, for convenience, so they have their own direct (and caching) GetDebit/... functions. * Some code was moved from CWalletDB to CWallet, such as handling of reserve keys. * Main.cpp keeps a set of all 'registered' wallets, which should be informed about updates to the block chain, and does not have any notion about any 'main' wallet. Function in main.cpp that require a wallet (such as GenerateCoins), take an explicit CWallet* argument. * The actual CWallet instance used by the application is defined in init.cpp as "CWallet* pwalletMain". rpc.cpp and ui.cpp use this variable. * Functions in main.cpp and db.cpp that are not used by other modules are marked static. * The code for handling the 'submitorder' message is removed, as it not really compatible with the idea that a node is independent from the wallet(s) connected to it, and obsolete anyway.
2011-06-14Merge pull request #226 from jordanlewis/betterheadersJeff Garzik
Optimize header dependencies; improve Makefile dependency graph
2011-06-12Faster timeout when connectingPieter Wuille
Use non-blocking connects, and a select() call to wait a predefined time (5s by default, but configurable with -timeout) for either success or failure. This allows much more connections to be tried per time unit. Based on a patch by phantomcircuit.
2011-06-07Fix CPU Usage bug when using -nolisten and have no connections.Matt Corallo
2011-06-02Fix rfc1918 and rfc3927 compliance for ignoring non-internet-routable hosts.Doug Huff
2011-06-02Bugfix for dnsseed introduced by dnslookupv0.3.22Pieter Wuille
2011-05-16Merge pull request #221 from gavinandresen/portoptionJeff Garzik
-port option to listen on arbitrary port
2011-05-15Only include strlcpy.h when we have toJordan Lewis
2011-05-15Only include init.h when we have toJordan Lewis
2011-05-15Only include net.h when we have toJordan Lewis
2011-05-15Only include db.h when we have to.Jordan Lewis
2011-05-15Only include irc.h when neededJordan Lewis
2011-05-15-port option to listen on arbitrary portGavin Andresen
2011-05-15make bitcoin include files more modularWladimir J. van der Laan
2011-05-14bugfix in dnslookup code: didn't compile in mingwPieter Wuille
2011-05-10Support for name lookups in -connect and -addnodePieter Wuille
* A new option -dns is introduced that enables name lookups in -connect and -addnode, which is not enabled by default, as it may be considered a security issue. * A Lookup function is added that supports retrieving one or more addresses based on a host name * CAddress constructors (optionally) support name lookups. * The different places in the source code that did name lookups are refactored to use NameLookup or CAddress instead (dns seeding, irc server lookup, getexternalip, ...). * Removed ToStringLog() from CAddress, and switched to ToString(), since it was empty.
2011-04-23directory re-organization (keeps the old build system)Jaromil
there is no internal modification of any file in this commit files are moved into directories according to established standards in sourcecode distribution; these directories contain: src - Files that are used in constructing the executable binaries, but are not installed. doc - Files in HTML and text format that document usage, quirks of the implementation, and contributor checklists. locale - Files that contain human language translation of strings used in the program contrib - Files contributed from distributions or other third party implementing scripts and auxiliary programs