Incentivising Tor nodes with a decentralised endowment fund
EthCC[8] · 1 Jul 2025 · 16:28
Mentor.eth presents OnionDAO’s on-chain endowment for Tor exit-node operators. The project uses staked ETH received through Octant to fund privacy infrastructure.
Speakers
Topics
From EthCC[8], hosted by Ethereum France.
Transcript
[Music] Hello everyone. So I'm going to take the coming 20 minutes to tell you about onion dowo and our onchan uh onchain endowment fund. First off my name is mentor. Uh if you want to find me anywhere online you can find me under the handle actually mentor on most platforms because my name is actually mentor. So, at Onion, we run an onchain endowment fund. And over the coming 20 minutes, I want to show you how it works. And perhaps it's something that you would find useful for uh for one of your projects.
And I'd like to take you for a minute to our origin story. Um, which of you know what happened on the 21st or for sorry 24th of February 2022? Ukraine. Ukraine indeed. So when Russia invaded Ukraine, um you know, it doesn't affect the Netherlands where I'm from, but you start wondering, you know, is there something I can do to to help a situation? And in those situations, I uh I like to ask myself, what am I uniquely suited to do? Or phrased differently, what is something that's easy for me that's much harder for other people? At the time, what was top of mind for me was VPN technology. I was running a a nonfor-profit VPN company. I was very active in the rocket pool discord thinking about node management and that
kind of thing and I was working at POA app which is the the collectibles that you guys see strewn around this this conference. So I was thinking what if I create an easy tour exit note setup script and give people po apps. Now a quick uh quick check with you guys. Who here knows what tour is? Maybe better question. Is there someone who doesn't know what tour is? That makes this very easy for me. Thank you. Um, so the one thing that is always in short supply with tour is exit nodes. Entry nodes aren't that high risk.
People don't mind running bridges, but the exit node is what makes people nervous. Uh, because that's where everyone's traffic is going to go through. Uh, including the legit the the journalists, the political dissident, but also the people buying illegal things on the dark web. So people feel nervous about running exit nodes, but it's not actually that complicated. So I figured what if we tap into the Dens that want all the PO apps and give them a PO app if they run a tour exit node. Within 24 hours uh a number of people got interested, told me they should totally become a DAO. Someone from the actual tour project reached out wanting to collaborate. People were setting up their nodes and within no time it kind of ran out of hand and within about a
month we ran over 3% of all tour exit nodes. Now, of course, for the nerds here, running the total amount of nodes didn't mean 3% of traffic. We were just running a lot of nodes. There were very like low power boxes because people just wanted to get their POP. But it did trigger uh the realization that there's a lot of fellow nerds out there who really don't mind running a tour exit node, especially if you give them a little something. So, that triggered the next next thought process. For me, what matters always is results and what to do for those results. I'm quite ambivalent about I have this conversation with friends a lot. Uh some people find morals more important. I personally think the world should care less about moral purity and
more about the changes that you want to uh want to affect. And in this case what I was wondering is what if we don't give pol to run an exit node? Will that incentivize people to uh to run more of them? Enter Octant. Uh, who here knows what Octant is? Ah, that's far less. There we go. Who remembers Golem? You guys have been around for a little while. So, Golem had a huge treasury and in part of it, uh, they decided, you know what we're going to do? We're going to stake all of the ETH that we have, which is quite a lot, and we're going to use the proceeds of this stake and use it to fund public goods. So what they do is if you have the GLM token every epoch you get to choose whether you claim the
staking rewards for yourself uh or you distribute them to public goods and if you do so then your your money gets matched. So we asked Optins whether uh we could join in a grant round and we won a grant of about at the time $30,000 uh in ETH and we decided to put it in an endowment fund. Now the definition of an endowment fund is that it's a fund. So a financial entity that invests money and only ever distributes the returns of the money. So the nice thing about that is the returns basically come forever. So you never run out of money. Downside is of course you're not distributing the principle.
So you're not giving as much money but you can create long-term alignment. So we figured we do is we take the ETH, we stake the ETH and then we only distribute the rewards of the ETH staking uh which results in a situation where you get ETH rewards forever. And the hypothesis was this will attract people who will run long-term nodes for tour because for them it's not actually that useful for people to run exit nodes for a week or a month just to get a quick uh a quick return. Uh so in the words of Naval Roant, you want to play long-term games with long-term people. Uh and that's the idea behind uh behind running an endowment fund.
So I drafted up a contract which runs an endowment fund of ERC20 tokens. And I'll just quickly run you through uh the principles of how the contract works. So I'm not going to go like super deep into the tech, but if you look this up on Arbcan, so it's uh deployed on Arbitum, you can buy the functions kind of see how it works. So the contract is owned by an owner who can in theory move the funds that are in the endowment fund. You make that an extremely cold key, a multi-IG, a hardware wallet, something like that. You can add accountants and accountants can do semi-ensitive actions. They can choose where the money goes. They can add new uh new tokens to the funds, that kind of thing, but they can't take all the money away. So that's like an administrative function or an administrative key. You can add new
ERC20 tokens. So if people donate ERC20 tokens to the fund, it isn't automatically like managed by the fund. You need to take an ERC20 token, say, I expect this amount of return on it. For example, with staked ETH, it's relatively predictable. Um, and then the contract knows what kind of return to expect. The endowee is where the money goes. And in the next slide, I'll show you how we set that up and how we make sure that we reward the right uh node operators with that money. Uh, of course you can remove an accountant, remove a token, the owner can renounce ownership. The eighth one is the most interesting function, the trigger distribution because we know or we've estimated the returns for about a year. If we distribute every hour, week,
month, whatever interval you choose, when you trigger a distrib distribution, you can calculate back how much returns should have been made and those are distributed. So it is a relatively naive way of doing this. We're not actually checking the returns. were operating based on expected returns. So the way that we set set this up, so Octant gave us the grant in ETH because that's the rewards they get from their stake. We turn it into rockpool ETH because it's the most decentralized uh version of staked ETH. We have nothing against uh more centralized operators like Lido, but we chose the most uh decentralized gold standard. the ERC20s go into the endowment contract and the endowment contract uh holds the funds.
So whenever that distribution is triggered based on the expected responses uh expected returns, it goes to a 0x splits wallet which is a really cool application where you can create like a synthetic wallet that sends money to other wallets based on a percentage uh split. We have an off-chain oracle that can basically with a hotkey set that reward split based on like real actual uh tour contribution. So what we do is every day we query the tour API. We look at the nodes that are registered with onion dow. We check the actual bandwidth that they provided. So not in theory whether the node is up but what their next network actually sees. Uh and then we update the splits wallet to make sure that people get rewarded based on the
amount of bandwidth they provide. And for my fellow nerds out there, we use a square root function to do that just so that the powerful nodes don't like slurp up all the money because there is actual value in having uh more independent operators doing these nodes. The advantage of this is the endowment is relatively self-contained. Also from a security perspective, you can set a cold key or a multisig uh that owns the contract that administers a contract. This is something you don't actually have to update very frequently. uh and you can use a hotkey to update the splitter wallet.
So the upsides of doing an onchain endowment contract like this relative to for example a treasury for one of your community funds is um the administration is super easy. So the endowment fund just returns the money to a specific location and that location can change. That can even be a community fund where people are manually distributing things and so forth. Um, but you never run into a situation where the treasury gets plundered, is empty, and now there's nothing more to do. Uh, so you have basically funds forever. That's the design of an endowment. Uh, and it is super flexible. The endowment once it runs, it can point its money anywhere and you can set that up like we did with a splitter contract or manual committees uh or any way that you like.
If you want to run an onion node, which you totally should, you can go to onionow.web.app app and you can join us or scan this QR code. Uh also I had a little chat with the uh tour people and they asked me to tell you that tour really really needs uh help. Uh most people forget that tour is a community-led effort. The nodes are run by volunteers. This isn't an actual like the money is just donated money and the people who run the nodes they just do it. So if you know what a VPS is and you know what a terminal looks like definitely run a run a tour node, ideally an exit node. And if you can't do that, run a bridge node. Um, and any donation to them, they're they're super happy with that because they're paying
engineers to continuously like uh develop the network. If you want to check out Octant, either to fund one of your projects or to help uh fund public goods, you can find them at octant.app. Uh they have an epoch every so many months. You can apply to uh to be joined in one of their public funding rounds. Uh or if you have GLM tokens, you can help uh fund public goods and your funds will get matched, which is kind of cool. If you have any questions anytime, you can tag me uh on X or anything else. Again, my handle in most places is actually mentor. Uh and I think we do have some time for questions. I already saw a hand uh hand go up there. Is that correct, my ECC friend with the cap? We have time. I think we have time.
Hi uh thanks for the talk. Uh I think incentivization in tour network is very important topic but actually um recently uh I had the opportunity to join the talk by the tour foundation but I asked about this kind of approaches and also I I know other than use there are some other project try to incentivize try employee incentivization in ter network but the the tour founder said the it's truly we are true music project so he is against any like incentivization in tour network uh how what is your opinion yeah so it's
a very interesting line so just if if I may rephrase tour is an altruistic network and one of the founder of tour is against making money off of it or people incentivizing things it's an interesting line so we've we're in touch with the tour people and I think there's a project called anyone uh if I remember from top of my head they even forked for and they're making like a real like incentivized network out of it. I if I understand correctly, what they're against is uh a situation where someone can exert control over tour because they have like a financial incentive which means that the altruists are overrun by mercenary people. Um we've always had a very good relationship with tour.
They're very happy with us. I don't know if that's because we're relatively small. Uh I don't know if if that's because we're not very den. are just giving small amounts of money from a grant for people to to run nodes. Uh but I think it's a very interesting question like where do you draw the line between altruism and incentives and as I put on one of my slides I feel like you need to do whatever is necessary to uh to have things done. Like for example, if there is a a fellow crypto bro here somewhere who spends a couple million feeding hungry people uh just so he can you know feel cool at some dinner party, I don't actually mind that. I just mind that the people get fed kind of thing. Uh so if you ask for my opinion that's that's mine. Thanks. Is there another question
then I want to ask another one. Yeah. Yeah. Thanks. So another project I know is the you know the session the the privacy messenger. No. Oh yes the messenger. Yes. Yeah messenger. So they use the tour network internally and seems their instantivization the project kind of doesn't work because I when I connect there are only like a some always US servers and a few German servers. So and what I can f found was the their like token economics kind of failed. Mhm. So, um do you have do you uh how do you have like um some bigger uh token economics
planned for this when it's like scalable? So, we we've thought about this. So, right now we just have an endowment fund which is just ETH that was donated to us and we're just streaming that and barring the ETH price changing it's a pretty static amount of money people get. So if if ETH goes to the moon uh then suddenly a lot of people will be running exit nodes I guess uh we have considered starting a separate token to see if we can get some DGEN energy involved but there you run into that problem of long-term people uh because once you start doing the DGEN thing the Dgens come in and I love my Dgens but they're not very long-term people. So it's a very good question. If your thoughts on it come chat to me after because I've not yet figured out how I want to do that. Sure. I like to
discuss it. All right, any other questions before we round off? Thank you very much for the talk. Um, I just had one technical question. May maybe it's a stupid one just on the graph that you showed. Uh, it seemed to me like the Oracle update was the only kind of centralized operation. Correct. Then do you have any plan to decentralize it? Yes, actually. Um, and what I'm looking for is a way to have basically an onchain reading of an offchain API. So, I talked to the API 3 people over here and and things like that, but these setups are usually quite complex. The tour API is very simple.
Uh, and currently I have no way of quering through a smart contract and offchain uh non-pric feed data because not a lot of people are interested in like tour metrics on chain. Once I can do that onchain, then everything can be can be done on chain. So if you have ideas about that definitely uh definitely find me. Okay. Okay. Thank you very much. Any others? So when people run the exit node So when people run the exit node, how how do they prove to you that they actually the ones running the node and they're entitled to the money? That's surprisingly simple. So we have a custom setup script and the only thing that
really does is it calls the offchain oracle to just say knock knock knock um I'm an onion down node and then on the actual toxit node there's a default HTTP page that is shown when you open the node that explains it's a toxit node and we just have an HTML comment in there that has the address of the person. So I can you can publicly query like whether what was claimed is indeed was on the server anymore and thank you very [Applause]