mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-05-25 17:21:05 -04:00
Rewrite of the discovery system to be more private, with less traffic.
Split the visState into seperate vs_disc and vs_dht for easier handling. Split the heartbeat system into a separate service. Added IPv4 and IPv6 local/ext addresses into discovery & peer config. Fixed up samenet and samesubnet ipv4 calls. git-svn-id: http://svn.code.sf.net/p/retroshare/code/branches/v0.6-initdev@6773 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
70c947ba90
commit
90aa57a0f0
38 changed files with 3248 additions and 1543 deletions
|
@ -58,8 +58,13 @@ const uint32_t RS_NETMODE_HIDDEN = 0x0004;
|
|||
const uint32_t RS_NETMODE_UNREACHABLE = 0x0005;
|
||||
|
||||
/* Visibility */
|
||||
const uint32_t RS_VS_DHT_ON = 0x0001;
|
||||
const uint32_t RS_VS_DISC_ON = 0x0002;
|
||||
const uint32_t RS_VS_DISC_OFF = 0x0000;
|
||||
const uint32_t RS_VS_DISC_MINIMAL = 0x0001;
|
||||
const uint32_t RS_VS_DISC_FULL = 0x0002;
|
||||
|
||||
const uint32_t RS_VS_DHT_OFF = 0x0000;
|
||||
const uint32_t RS_VS_DHT_PASSIVE = 0x0001;
|
||||
const uint32_t RS_VS_DHT_FULL = 0x0002;
|
||||
|
||||
/* State */
|
||||
const uint32_t RS_PEER_STATE_FRIEND = 0x0001;
|
||||
|
@ -219,7 +224,9 @@ class RsPeerDetails
|
|||
std::list<std::string> ipAddressList;
|
||||
|
||||
uint32_t netMode;
|
||||
uint32_t visState;
|
||||
/* vis State */
|
||||
uint16_t vs_disc;
|
||||
uint16_t vs_dht;
|
||||
|
||||
/* basic stats */
|
||||
uint32_t lastConnect; /* how long ago */
|
||||
|
@ -321,7 +328,7 @@ class RsPeers
|
|||
virtual bool setExtAddress( const std::string &ssl_id, const std::string &addr, uint16_t port) = 0;
|
||||
virtual bool setDynDNS(const std::string &id, const std::string &addr) = 0;
|
||||
virtual bool setNetworkMode(const std::string &ssl_id, uint32_t netMode) = 0;
|
||||
virtual bool setVisState(const std::string &ssl_id, uint32_t vis) = 0;
|
||||
virtual bool setVisState(const std::string &ssl_id, uint16_t vs_disc, uint16_t vs_dht) = 0;
|
||||
|
||||
virtual void getIPServersList(std::list<std::string>& ip_servers) = 0;
|
||||
virtual void allowServerIPDetermination(bool) = 0;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue