mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-05-06 08:05:18 -04:00
added new flag to allow peers auto-download recommended files from trusted neighbor nodes, which give the possibility to push data to other nodes
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7955 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
d029dd0368
commit
d2c4c3bb09
15 changed files with 69 additions and 52 deletions
|
@ -75,9 +75,11 @@ const uint32_t RS_PEER_STATE_UNREACHABLE= 0x0008;
|
|||
|
||||
// Service option flags.
|
||||
//
|
||||
const ServicePermissionFlags RS_SERVICE_PERM_NONE ( 0x00000000 ) ;
|
||||
const ServicePermissionFlags RS_SERVICE_PERM_DIRECT_DL ( 0x00000008 ) ;
|
||||
const ServicePermissionFlags RS_SERVICE_PERM_ALL = RS_SERVICE_PERM_DIRECT_DL ;
|
||||
const ServicePermissionFlags RS_NODE_PERM_NONE ( 0x00000000 ) ;// 0x1, 0x2 and Ox4 are deprecated.
|
||||
const ServicePermissionFlags RS_NODE_PERM_DIRECT_DL ( 0x00000008 ) ;// Accept to directly DL from this peer (breaks anonymity)
|
||||
const ServicePermissionFlags RS_NODE_PERM_ALLOW_PUSH ( 0x00000010 ) ;// Auto-DL files recommended by this peer
|
||||
const ServicePermissionFlags RS_NODE_PERM_DEFAULT = RS_NODE_PERM_DIRECT_DL ;
|
||||
const ServicePermissionFlags RS_NODE_PERM_ALL = RS_NODE_PERM_DIRECT_DL | RS_NODE_PERM_ALLOW_PUSH;
|
||||
|
||||
// ...
|
||||
|
||||
|
@ -321,7 +323,7 @@ class RsPeers
|
|||
virtual bool gpgSignData(const void *data, const uint32_t len, unsigned char *sign, unsigned int *signlen) = 0;
|
||||
|
||||
/* Add/Remove Friends */
|
||||
virtual bool addFriend(const RsPeerId &ssl_id, const RsPgpId &gpg_id,ServicePermissionFlags flags = RS_SERVICE_PERM_ALL) = 0;
|
||||
virtual bool addFriend(const RsPeerId &ssl_id, const RsPgpId &gpg_id,ServicePermissionFlags flags = RS_NODE_PERM_DEFAULT) = 0;
|
||||
virtual bool removeFriend(const RsPgpId& pgp_id) = 0;
|
||||
virtual bool removeFriendLocation(const RsPeerId& sslId) = 0;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue