* Enabling Local BadPeer Filter.
- This will remove any peer you detect is spoofing yourself or your friends.
- This list is also shared with you friends. (in Test Mode).
* added Cleanup of BadPeer Filter.
- Instead of permanent ban, peers are be banned for 6 hours.
- bdManager periodically calls this - which prints out ban list too.
* added #define to disable the Filter - for testing purposes.
NOTES: This Ip Filter should probably be moved from DHT level to UdpLayer level.
This will enable it to filter STUN / UDP Connection Packets too.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/branches/v0.5-dhtmods@4716 b45a01b8-16f6-495d-af2f-9b41ad6348cc
- At this level it takes significantly longer for the searches to complete, but
there are no DOS warnings on the router. This should hopefully make users happy.
* Added DhtMode() Interface call to dynamically change this rate.
- Can be switched between (HIGH: 50/sec, MED: 20/sec, LOW: 5/sec & TRICKLE: 3/sec)
* Disable additional Queries if PotentialPeer Queue gets too big.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/branches/v0.5-dhtmods@4703 b45a01b8-16f6-495d-af2f-9b41ad6348cc
Added Knowledge of Friends, Friends of Friends and Relays.
- Added bdfriendlist class to store information.
- New interface function updateKnownPeer().
- includes IP addresses, if known. (for filtering)
Bad Peer Filtering.
- Check IDs against known peer IP addresses.
- Added checks in checkPotentialPeer().
- Added checks in addPeer().
- Running in TestMode at the moment (Bad Peers are only flagged).
Other Fixes:
- Removed some warning about int/uint comparisons.
- added bdSpace::flagpeer() fn to support above.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/branches/v0.5-dhtmods@4680 b45a01b8-16f6-495d-af2f-9b41ad6348cc
* Compilation for FreeBSD.
* Notes that MT is not cryptographically secure.
* modified sorting of DHT Window.
Only one change that I didn't commit:
bitdht {
- LIBS += ../../libbitdht/src/lib/libbitdht.a
- PRE_TARGETDEPS *= ../../libbitdht/src/lib/libbitdht.a
+ LIBS += ../../libbitdht/src/libbitdht.a
+ PRE_TARGETDEPS *= ../../libbitdht/src/libbitdht.a
}
As this would have broken compilation on the other platforms.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@4619 b45a01b8-16f6-495d-af2f-9b41ad6348cc
* added quick and dirty BitDht Packet check. test against "d1:" for the first 3 bytes. This should not conflict with Stun, Relay or TOU packets.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@4480 b45a01b8-16f6-495d-af2f-9b41ad6348cc
* Bandwidth are for RELAY connections.
* Delays are for Exclusive NAT Proxy connections.
* Lots of changes to achieve this. (Mainly added "param" to msgs).
* Various Bugfixes too.
* Updated BITDHT Version to 01 as we've changed Message Format.
* Increased Connection Timeout to 180
* Added extra checks to kill duplicate connections early.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/branches/v0.5-netupgrade@4462 b45a01b8-16f6-495d-af2f-9b41ad6348cc
Each attempt should be completeable in < 10 Secs.
This could increase up to 20 secs, if pings are required.
So with 3 Proxy attempts, should take 20-30 secs.
* Removed as many of the pauses as possible.
* connection attempt DONE if OUTOFPROXY, DUPLICATE, TEMPUNAVAIL or EXTCONNECT timeout
* Fixed AutoAuth for Proxy (was triggering for Relay as well)
* Increased QUERY_UPDATES to every 10 secs.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/branches/v0.5-netupgrade@4454 b45a01b8-16f6-495d-af2f-9b41ad6348cc
* added bool return value to ConnectionRequest. only returns false if MODE not allowed.
* added checks for an existingConnectionRequest - results in a NOOP.
* made each ConnectionRequest result in only one UDP start.
* a START message will not kill a local ConnectionRequest (even in remotely started).
* increased CONNECTION_TIMEOUT as this should never happen at this level.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/branches/v0.5-netupgrade@4449 b45a01b8-16f6-495d-af2f-9b41ad6348cc
Bugfixes and a couple of small improvements to the DHT code.
* fixed up buggy overloading for the udplayer (for testing).
* added processing multiple (5) remote processes per tick.
- (1 wasn't enough in testing, and led to dropped peers)
* removed unused variables from query data structure.
* #defined out debugging in bdSpace, removed old functions.
* More agressive attempts to find proxies for connections.
* made "final query attempt" use exact peer address rather than midid.
- mid id meant that the target wasn't always returned.
* tweaked bdconnection debugging.
* increase CONNECTION_MAX_TIMEOUT from 30 => 45. wasn't enough!
* Limited bdQuery::QueryIdlePeriod to 15min (was unlimited).
* added bdQuery::PotentialPeer cleanup functions - for more robust reporting.
* fixed bdQuery debugging printouts.
* Implemented BITDHT_QFLAGS_UPDATES flag.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@4398 b45a01b8-16f6-495d-af2f-9b41ad6348cc
There are many significant improvements to the DHT here.
See commit logs on v0.5-peernet branch for details.
This is not the final merge, but brings over the majority of expected v0.5-peernet/libbitdht changes
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@4354 b45a01b8-16f6-495d-af2f-9b41ad6348cc
- authssl would call OPENSSL_malloc without OPENSSL_free
- pqistore was not deleting items in pqiSSLStore when BIN_FLAGS_NO_DELETE is not here
- rsdir/rsinit were calling opendir withoug closedir (which might eat FDs, in addition)
- udplayer was not freeing it's 16KB buffer at end of loop.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@3948 b45a01b8-16f6-495d-af2f-9b41ad6348cc
* properly initialised bdId.addr and other struct sockaddr_in.
* This should fix the windows bitdht - not send - issue.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@3687 b45a01b8-16f6-495d-af2f-9b41ad6348cc
* Added maximum msg limits (20, 50, 100 msgs per sec). 50 = default.
* Priority send out pings, with 10% queries.
* switched bdquery list in bdnode to use pointers... so peers can be
easily reordered (queue for queries).
* Add all find peers, once dht initialised.
* Added reset if FINDSELF fails. (don't know if this is a good idea!)
* simplified DHT printouts. verbose versions are enabled with debug.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@3686 b45a01b8-16f6-495d-af2f-9b41ad6348cc
* Advertises client as DBxxxx where xxxx is provided by using app.
* Added COMPILE switches to enable ANONYMOUS version or remove BD portion.
* Fixed version code.
* Added slow increase in retry timeout, to reduce DHT traffic over time.
now RETRY PERIOD = query age / 2
* initialised bdToken bdVersion etc length.
* new bdboot.txt
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@3615 b45a01b8-16f6-495d-af2f-9b41ad6348cc
* Changed getDhtPeerAddress() / Value() function to use const *bdNodeId.
* Filled in getDhtPeerAddress()... to support UDP connections.
* fixed bug in bdnode:: pong msg... wasn't checking if version existed.
* printed out version string, as part of debug.
* added IpAddr field to bdmanager peer search data.
* stored IpAddr from queries... when peer found.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@3604 b45a01b8-16f6-495d-af2f-9b41ad6348cc
* Added bdHistory, to monitoring all the p2p dht messages (disabled normally)
* cleaned up all compile warnings on OSX.
* added Found timestamp to peer info.
* disable save, until store is close to full.
* ...?other stuff?
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@3559 b45a01b8-16f6-495d-af2f-9b41ad6348cc
RetroShare crashes on start, when the initial address on port 7812 is in use.
The thread in UdpLayer::openSocket was not started and the member mTid was uninitialized.
Then a call to join in UdpLayer::reset during the load of the configuration crashes.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@3337 b45a01b8-16f6-495d-af2f-9b41ad6348cc
* decreased nodes per bucket to 10 - to try reduce traffic.
* changed operator< to non const.
* fixed up debuging.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@3322 b45a01b8-16f6-495d-af2f-9b41ad6348cc
* brought over tou_net / tou_error => bdnet for windoze compatibility.
* updated udplayer to inline with rs changes + win compatibility.
* removed unix only networking #includes, replaced with "util/bdnet.h"
* added subdirectory to #includes.
* made udpbitdht_nettest use a random node id.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@3302 b45a01b8-16f6-495d-af2f-9b41ad6348cc
============================================================
This is intended to be a completely independent library from RS,
(hosted at sf.net/projects/bitdht) hence is being commited at the top level.
As initial further development / testing will be driven by RS integration
it is being added to the RS repository. Equally important is ensuring
that RS can compile without requiring aux libraries.
Once libbitdht is further developed, this section of the repository
is expected to be removed... But that will not be for a while, I expect.
drbob.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@3276 b45a01b8-16f6-495d-af2f-9b41ad6348cc