Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Whitelist P2P Mode #179

Open
moshababo opened this issue Jun 28, 2018 · 10 comments
Open

Whitelist P2P Mode #179

moshababo opened this issue Jun 28, 2018 · 10 comments
Labels
p2p Peer to peer networking P3 low priority

Comments

@moshababo
Copy link
Collaborator

moshababo commented Jun 28, 2018

The default behavior is that a node will create/accept connection to any peer which is not on the black list. We previously discussed about having a strict mode, that unlike the permissive one, will block all peers by default, except these who are explicitly mentioned in a white list.

@moshababo moshababo added p2p Peer to peer networking P3 low priority labels Jun 28, 2018
@kilrau kilrau added this to the 1.0.0-alpha milestone Jun 30, 2018
@kilrau kilrau assigned moshababo and unassigned kilrau Aug 7, 2018
@kilrau
Copy link
Contributor

kilrau commented Aug 7, 2018

Based on nodePubKey and let's stick with the whitelist terminology for now. Easier to understand. Blacklist is the default mode and functionality will exist as ban (#336) and I don't think we need a separate blacklist mode for that anymore.

Basics for whitelist mode:

@kilrau kilrau modified the milestones: 1.0.0-alpha, 1.0.0-beta Aug 7, 2018
@kilrau kilrau changed the title Strict/Permissive p2p modes Black/Whitelist4 p2p mode Aug 7, 2018
@kilrau kilrau changed the title Black/Whitelist4 p2p mode Whitelist P2P Mode Oct 27, 2018
@kilrau kilrau modified the milestones: 1.0.0-alpha.3, 1.0.0-alpha.4 Oct 27, 2018
@kilrau kilrau modified the milestones: 1.0.0-alpha.5, 1.0.0-alpha.7 Nov 18, 2018
@kilrau kilrau modified the milestones: 1.0.0-alpha.7, 1.0.0-alpha.8 Jan 2, 2019
@kilrau kilrau modified the milestones: 1.0.0-alpha.8, 1.0.0-alpha.9 Jan 23, 2019
@kilrau kilrau modified the milestones: 1.0.0-alpha.9, 1.0.0-beta.1 Feb 5, 2019
@kilrau kilrau assigned reliveyy and unassigned moshababo Mar 26, 2019
@kilrau kilrau modified the milestones: 1.0.0-sprint.12, 1.0.0-sprint.13 Mar 26, 2019
@kilrau
Copy link
Contributor

kilrau commented Mar 26, 2019

Would you be ok taking this? @reliveyy Sth not clear?

@reliveyy
Copy link
Contributor

reliveyy commented Apr 3, 2019

@kilrau OK

@kilrau kilrau modified the milestones: 1.0.0-sprint.13, 1.0.0-sprint.14 Apr 9, 2019
@ghost ghost added the in progress label Apr 12, 2019
@kilrau
Copy link
Contributor

kilrau commented Apr 17, 2019

EDIT of my comment above:
Default mode and functionality will exist as ban (#336) and there is no need for a separate blacklist mode for that anymore.

Basics for whitelist mode:

  • only allow to connect to whitelisted nodePubKeys
  • these live in db and offer same functionality as "ban": whitelist <node_pub_key>, unwhitelist <node_pub_key> and additionally viewwhitelist.
  • don't close P2P port, rather return WHITELIST_RESTRICTED packet after handshake reveals nodePubKey is not on whitelist.
  • Receiving ``WHITELIST_RESTRICTED` should result in same behavior than ban packet (Implement behavior for #152 disconnect package "banned" #693) - stop connecting. Anyone not following this, will eventually be caught by Ban by IP address (fail2ban) #458.

@sangaman
Copy link
Collaborator

Is the plan to drop the configurable whitelist IP addresses?

I think those whitelist rpc calls make sense, then I imagine we'd have a configurable option as to whether to only allow node pub keys found on the whitelist.

I think we might want a different disconnection reason from "banned" for when a node is not on the white list.

@kilrau
Copy link
Contributor

kilrau commented Apr 19, 2019

Is the plan to drop the configurable whitelist IP addresses?

IP addresses are not too permanent and were never planned to be whitelisted. xud NodePubKeys are.

then I imagine we'd have a configurable option as to whether to only allow node pub keys found on the whitelist.

Exactly.

I think we might want a different disconnection reason from "banned" for when a node is not on the white list.

Ok. Proposal? @sangaman

@sangaman
Copy link
Collaborator

Ok. Proposal?

Something like WHITELIST_RESTRICTED I guess - exactly what we call it isn't too important as long as there's a separate reason for it.

@kilrau
Copy link
Contributor

kilrau commented Apr 20, 2019

WHITELIST_RESTRICTED sounds good to me. All clear? @reliveyy

@kilrau kilrau modified the milestones: 1.0.0-sprint.14, 1.0.0-sprint.15 Apr 27, 2019
@kilrau kilrau assigned sangaman and unassigned reliveyy Apr 27, 2019
@kilrau kilrau added the P1 top priority label Apr 30, 2019
@kilrau kilrau removed the P1 top priority label May 7, 2019
@kilrau kilrau modified the milestones: 1.0.0-sprint.15, 1.0.0 May 8, 2019
@kilrau
Copy link
Contributor

kilrau commented May 23, 2019

Did you already start with this? If not please move to post-1.0.0 @sangaman

It's not important enough to loose focus of the more pressing raiden and swap issues.

@sangaman
Copy link
Collaborator

I haven't, moving the milestone.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
p2p Peer to peer networking P3 low priority
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants