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

Free-ride policy: give users with lower token balances less priority at the exit nodes #3573

Closed
devos50 opened this issue Apr 8, 2018 · 0 comments

Comments

@devos50
Copy link
Contributor

devos50 commented Apr 8, 2018

Now that the payouts and anonymous downloading is functional, we should actually use the token balance to do something useful. The first iteration of such a policy will focus on the exit nodes. In particular, we create a basic mechanism that works in the case of over- and undersupply of bandwidth where freeriders get less priority.

After a small discussion with @synctext, we came up with a design for this. We create a fixed amount of slots on each exit node process. Each slot is capable of managing exactly one circuit. The current implementation restricts the maximum number of open circuits on the exit nodes to 100 but I think this is rather high. Instead, we could use 20 slots for a first version or even less?

We assume two types of slots: competing slots and equal opportunity slots. Competing slots are reserved for users with the highest token amount. This also means that when all slots are filled and a circuit request comes in from a user with a high token balance, an existing circuit in one of the competing slots might be destroyed. Equal opportunity slots are comparable with the optimistic unchoke slots in BitTorrent and accept all incoming circuit requests.

Note that the total number of slots and the number of competing/equal opportunity slots can be easily changed.

To implement this, we need to do the following code changes:

  • allow exit nodes to reject circuit requests. The initiator of a circuit should pick a new exit node when a circuit extension fails.
  • next, an exit node needs to keep track of the allocated slots and circuits.
  • finally, we implement the competing and equal opportunity slots.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

1 participant