1 00:00:00,000 --> 00:00:03,360 Hello, everybody. My name is Nathan Evans. This is Christian Grothoff. 2 00:00:03,680 --> 00:00:06,340 Here to talk to you today about routing in the dark, pitch black. 3 00:00:07,360 --> 00:00:12,340 Basically, this is a talk about security problems in the latest version of FreeNet's routing algorithm. 4 00:00:14,140 --> 00:00:16,180 So, the first important thing I'm going to say is, 5 00:00:16,440 --> 00:00:20,220 what exactly is the question FreeNet's, or the problem that FreeNet's trying to solve? 6 00:00:20,680 --> 00:00:25,580 Basically, performing efficient routing in decentralized networks is a very difficult problem 7 00:00:25,580 --> 00:00:28,540 for peer-to-peer file sharing networks and all kinds of different networks. 8 00:00:29,400 --> 00:00:32,420 FreeNet claims to solve this problem with logarithmic routing, 9 00:00:33,180 --> 00:00:34,500 logarithmic to the size of the network. 10 00:00:35,280 --> 00:00:39,140 Our question is whether or not FreeNet's new routing algorithm is resilient, robust, 11 00:00:39,440 --> 00:00:41,180 and resistant to our attacks. 12 00:00:42,300 --> 00:00:45,140 In order to explain the attack, first I'm going to go over some of the, 13 00:00:45,600 --> 00:00:48,160 exactly how routing works, so that it's easier to understand. 14 00:00:49,520 --> 00:00:54,260 But, as a spoiler alert, we don't really think that it is robust, resilient to our attacks. 15 00:00:55,300 --> 00:00:57,640 So, what exactly is FreeNet, for those of you who don't know? 16 00:00:58,540 --> 00:01:00,640 FreeNet is an anonymous file-sharing network. 17 00:01:01,520 --> 00:01:03,540 Well, it's touted as an anonymous file-sharing network. 18 00:01:04,280 --> 00:01:09,980 FreeNet adds structure to an unstructured network by using node locations in a cyclic address space. 19 00:01:10,500 --> 00:01:13,900 It's a friend-to-friend network, which means that all the peers are defined. 20 00:01:14,020 --> 00:01:16,360 They're not discovered in any way like a lot of other peer-to-peer networks. 21 00:01:17,880 --> 00:01:21,320 The important thing to remember is that our focus is only on the routing, 22 00:01:21,400 --> 00:01:23,040 not the other aspects of the network. 23 00:01:23,860 --> 00:01:26,260 And, for the routing, you need to understand two things. 24 00:01:26,520 --> 00:01:28,100 First off, routing, in the best case, 25 00:01:28,540 --> 00:01:32,360 assumes that all the data is stored at the node's location, 26 00:01:32,520 --> 00:01:33,880 which is closest to the data's key. 27 00:01:34,260 --> 00:01:36,120 All data is identified by a key, 28 00:01:36,200 --> 00:01:38,560 which is in the same cyclic address space as the location's. 29 00:01:39,700 --> 00:01:43,720 Also, you assume that all nodes forward requests 30 00:01:43,720 --> 00:01:47,300 based on the proximity of the key to the node's location. 31 00:01:47,480 --> 00:01:50,160 So, it forwards it to the closest peer that it has. 32 00:01:51,880 --> 00:01:55,360 So, there is a theoretical basis for the FreeNet routing protocol. 33 00:01:55,580 --> 00:01:56,840 It's based on small world networks. 34 00:01:57,660 --> 00:01:58,520 Since routing... 35 00:01:58,540 --> 00:02:02,440 uses node locations to determine proximity to the data, 36 00:02:02,580 --> 00:02:04,600 the algorithm works best in small world networks, 37 00:02:04,800 --> 00:02:06,520 but it would work in any kind of network. 38 00:02:06,940 --> 00:02:09,720 And also, we need to remember or know that 39 00:02:10,820 --> 00:02:12,360 FreeNet uses location swapping 40 00:02:12,360 --> 00:02:13,720 in order to help structure the network 41 00:02:13,720 --> 00:02:15,720 and make the routing more efficient. 42 00:02:17,180 --> 00:02:20,140 So, in order to understand how the swapping works, 43 00:02:20,360 --> 00:02:21,900 we have an example here. 44 00:02:22,560 --> 00:02:24,900 First off, since we're going to use this example throughout the talk, 45 00:02:25,100 --> 00:02:27,240 we need to know that the circles represent nodes, 46 00:02:27,420 --> 00:02:28,240 the locations... 47 00:02:28,540 --> 00:02:29,860 are the numbers inside the nodes. 48 00:02:30,900 --> 00:02:33,160 On the edges are the distances between the nodes. 49 00:02:33,500 --> 00:02:36,160 They're only listed on the two nodes that we're considering swapping 50 00:02:36,160 --> 00:02:37,700 because those are the only ones we really care about. 51 00:02:38,600 --> 00:02:42,480 We're looking here at a potential swap between 0.90 and 0.60. 52 00:02:43,820 --> 00:02:47,300 And, as you can see, the edge distances are large. 53 00:02:47,500 --> 00:02:49,320 And the idea, basically, for a swap 54 00:02:49,320 --> 00:02:51,580 is that we want to reduce the average edge distances. 55 00:02:53,180 --> 00:02:54,580 So, here's the result of the swap. 56 00:02:54,760 --> 00:02:57,020 And, as you can see, the average edge distances have gone down. 57 00:02:57,120 --> 00:02:57,740 So, that's... 58 00:02:58,540 --> 00:02:58,940 a good swap. 59 00:03:01,480 --> 00:03:04,040 Here's the actual equation for how... 60 00:03:04,040 --> 00:03:06,500 or formula, I guess, of how swapping actually happens. 61 00:03:07,820 --> 00:03:11,760 Another thing to remember is that all peers randomly initiate swaps. 62 00:03:11,780 --> 00:03:14,500 So, any peer tries to swap with its neighbors all the time. 63 00:03:15,620 --> 00:03:20,200 And, basically, P of A B is determined by the ratio of the products of the distances 64 00:03:20,200 --> 00:03:23,180 to all the neighbors that a peer has before and after a swap. 65 00:03:23,940 --> 00:03:25,160 That's kind of a mouthful. 66 00:03:25,260 --> 00:03:27,440 If you want to look at the equation, that's what it says. 67 00:03:27,440 --> 00:03:30,660 But, basically, if the result of this is greater than 1, 68 00:03:30,800 --> 00:03:31,880 a swap always happens. 69 00:03:32,020 --> 00:03:36,160 And, otherwise, a swap happens with probability of P of A B, as it's shown up there. 70 00:03:38,380 --> 00:03:40,160 So, again, in order to understand the routing, 71 00:03:40,300 --> 00:03:42,020 I'm going to go over get and put requests. 72 00:03:42,320 --> 00:03:44,320 So, this is how a get request works. 73 00:03:44,820 --> 00:03:47,800 Again, we have to remember that the peers use the location 74 00:03:47,800 --> 00:03:49,980 and the proximity to the data's key for routing. 75 00:03:50,540 --> 00:03:52,700 Basically, a client starts a get request, 76 00:03:52,920 --> 00:03:54,920 and it sends to its neighbor whose closest... 77 00:03:54,920 --> 00:03:57,420 whose location is nearest to the key that it's routing. 78 00:03:57,440 --> 00:03:58,200 Trying to find... 79 00:03:58,700 --> 00:04:00,180 Unless the data is at the neighbor, 80 00:04:00,340 --> 00:04:03,240 the request is forwarded to that peer's nearest neighbor 81 00:04:04,020 --> 00:04:05,260 with relation to the key again. 82 00:04:05,520 --> 00:04:06,780 And this kind of... 83 00:04:06,780 --> 00:04:08,840 This forwarding stops when the HTL equals 0, 84 00:04:08,980 --> 00:04:09,680 the data is found, 85 00:04:09,820 --> 00:04:11,320 or the request has been seen before, 86 00:04:11,480 --> 00:04:13,400 and that's just to avoid circular routing. 87 00:04:15,160 --> 00:04:17,960 So, now we have an example of an actual get request 88 00:04:17,960 --> 00:04:19,440 in our example network again. 89 00:04:20,660 --> 00:04:21,360 Here we are. 90 00:04:21,400 --> 00:04:23,560 We're starting from .90, the node .90, 91 00:04:23,660 --> 00:04:26,240 and we're searching for data identified by the key .22. 92 00:04:27,440 --> 00:04:30,020 So, first .90 finds its closest peer, which is .1, 93 00:04:30,140 --> 00:04:31,120 and it routes to it. 94 00:04:32,380 --> 00:04:33,940 .1 doesn't have anybody to route to, 95 00:04:34,000 --> 00:04:35,400 so it replies that it doesn't have the data. 96 00:04:36,220 --> 00:04:38,880 .90 then tries its next closest peer, which is .6. 97 00:04:39,740 --> 00:04:42,200 .6 forwards to its closest peer, which is .25. 98 00:04:43,220 --> 00:04:44,880 .25 responds that it has the data, 99 00:04:45,000 --> 00:04:46,360 responds to .6, 100 00:04:46,440 --> 00:04:47,520 and .6 responds back. 101 00:04:48,260 --> 00:04:49,440 I know this is kind of boring, 102 00:04:49,500 --> 00:04:51,180 but it's important to understand the routing 103 00:04:51,180 --> 00:04:52,080 before we get to the attack. 104 00:04:52,560 --> 00:04:54,380 So, this is how put requests work. 105 00:04:54,540 --> 00:04:56,660 Basically, they're really similar to get requests. 106 00:04:57,440 --> 00:04:59,860 A client initiates the put request or an insert, 107 00:05:00,020 --> 00:05:01,240 routes to its nearest neighbor. 108 00:05:01,480 --> 00:05:03,220 The neighbor checks whether any of its peers 109 00:05:03,220 --> 00:05:06,200 have a closer location than it does to the key, 110 00:05:06,320 --> 00:05:08,500 and if so, it forwards it to that peer. 111 00:05:08,840 --> 00:05:12,780 And if it is the closest peer out of all of its other neighbors, 112 00:05:13,400 --> 00:05:15,340 it resets the HTL to its maximum 113 00:05:15,340 --> 00:05:17,740 and then forwards the request out to all of its peers. 114 00:05:18,860 --> 00:05:20,140 This is kind of weird. 115 00:05:20,200 --> 00:05:21,960 We think it's mostly for replication, 116 00:05:23,120 --> 00:05:24,940 but it's relatively irrelevant 117 00:05:24,940 --> 00:05:26,560 to what we're doing with the attack. 118 00:05:27,440 --> 00:05:28,400 And again, the routing continues 119 00:05:28,400 --> 00:05:29,920 until the hops to live equals zero 120 00:05:30,440 --> 00:05:31,600 or a circular route happens. 121 00:05:31,900 --> 00:05:33,400 So, here's a quick put example. 122 00:05:35,960 --> 00:05:38,840 This one starts from our node .25, 123 00:05:38,980 --> 00:05:41,380 and we're inserting data with the key .93. 124 00:05:42,080 --> 00:05:44,280 So, .25 sends to its nearest neighbor, 125 00:05:44,360 --> 00:05:45,200 which is .6. 126 00:05:45,740 --> 00:05:47,460 .6 has a closer peer than itself, 127 00:05:47,620 --> 00:05:49,100 so it forwards the request to .90. 128 00:05:49,920 --> 00:05:51,960 .90 decides that it's the closest peer 129 00:05:51,960 --> 00:05:53,560 out of all of its neighbors, 130 00:05:53,780 --> 00:05:56,260 so it resets the HTL to max, 131 00:05:56,260 --> 00:05:59,440 and forwards the request to all of its neighbors again. 132 00:06:00,520 --> 00:06:02,020 So, now we get into the fun part. 133 00:06:02,400 --> 00:06:04,120 The basic idea for our attack here 134 00:06:04,120 --> 00:06:06,380 is that Freenet has a large reliance 135 00:06:06,380 --> 00:06:08,240 on a balanced distribution of node locations 136 00:06:08,240 --> 00:06:09,640 for storage and routing. 137 00:06:10,800 --> 00:06:12,880 But if there's some way that we could reverse 138 00:06:12,880 --> 00:06:14,540 the diversity of all these locations, 139 00:06:15,100 --> 00:06:18,360 unfair storage responsibility and bad routing starts to happen. 140 00:06:18,980 --> 00:06:20,540 And basically, this is because 141 00:06:20,540 --> 00:06:23,520 if there's a lack of close locations to a key for data, 142 00:06:24,060 --> 00:06:25,420 all data ends up clustered 143 00:06:25,420 --> 00:06:26,320 at a few nodes, 144 00:06:26,460 --> 00:06:28,680 and all routing responsibilities go to a few nodes. 145 00:06:29,080 --> 00:06:31,140 And the way we can do this 146 00:06:31,140 --> 00:06:33,400 is that peers can't verify 147 00:06:33,400 --> 00:06:34,820 the neighbors of their neighbors. 148 00:06:34,960 --> 00:06:36,700 So, basically, you can force swapping 149 00:06:36,700 --> 00:06:39,240 if you lie about who your neighbors are. 150 00:06:40,920 --> 00:06:42,840 So, here's the details of our attack. 151 00:06:43,080 --> 00:06:44,920 Basically, we just create malicious nodes 152 00:06:44,920 --> 00:06:47,820 or a node with specific location or locations. 153 00:06:48,600 --> 00:06:50,440 When a swap occurs with a malicious node, 154 00:06:50,640 --> 00:06:52,860 a random location is removed from the network. 155 00:06:52,960 --> 00:06:54,580 A good location is removed. 156 00:06:54,580 --> 00:06:56,640 And then the malicious node resets itself 157 00:06:56,640 --> 00:06:57,960 to a bad location again. 158 00:06:59,680 --> 00:07:02,000 Locations also can spread between non-malicious nodes 159 00:07:02,000 --> 00:07:03,760 just through the regular swapping protocol. 160 00:07:05,200 --> 00:07:06,480 And after enough time, 161 00:07:06,540 --> 00:07:08,780 we found that even few attackers 162 00:07:08,780 --> 00:07:11,560 can create large storage problems 163 00:07:11,560 --> 00:07:14,580 and clusters around certain bad locations. 164 00:07:15,380 --> 00:07:17,060 So, here's our example network again, 165 00:07:17,200 --> 00:07:18,360 this time showing the attack. 166 00:07:19,080 --> 00:07:22,240 So, in this network, we tell 0.90 to go bad. 167 00:07:22,580 --> 00:07:24,560 So, 0.90 then resets its location 168 00:07:24,580 --> 00:07:26,120 to one that we choose. 169 00:07:26,920 --> 00:07:29,080 It then forces a swap with each of its neighbors, 170 00:07:29,160 --> 00:07:29,900 first with 0.85. 171 00:07:30,900 --> 00:07:32,360 And then it resets its location. 172 00:07:32,520 --> 00:07:34,200 And it forces a swap with 0.10. 173 00:07:34,900 --> 00:07:36,080 Resets its location again. 174 00:07:36,800 --> 00:07:39,140 And then it forces a swap with 0.60. 175 00:07:40,080 --> 00:07:41,200 Resets its location again. 176 00:07:41,820 --> 00:07:43,680 And you can see that it's taken over 177 00:07:43,680 --> 00:07:45,220 pretty much all of its peers, 178 00:07:45,360 --> 00:07:46,920 which we can, again, force swaps 179 00:07:46,920 --> 00:07:48,260 by lying about who its peers are. 180 00:07:49,960 --> 00:07:51,940 And although they would swap with a low probability, 181 00:07:52,740 --> 00:07:54,140 we're showing 0.50, 182 00:07:54,580 --> 00:07:56,120 0.00, and 0.45 swapping, 183 00:07:56,220 --> 00:07:58,520 just so you can see that swaps do occur 184 00:07:58,520 --> 00:07:59,920 between non-malicious nodes 185 00:07:59,920 --> 00:08:01,300 and still spread to malicious locations. 186 00:08:01,860 --> 00:08:03,340 And then after that swap happens, 187 00:08:04,220 --> 00:08:06,100 the malicious node again forces a swap 188 00:08:06,100 --> 00:08:07,060 with the new 0.45, 189 00:08:07,620 --> 00:08:09,240 and then resets its location again. 190 00:08:10,460 --> 00:08:13,100 So, imagine storage or routing in this network 191 00:08:13,100 --> 00:08:15,560 for any data whose key is above 0.5. 192 00:08:15,800 --> 00:08:17,620 You can see that all routing requests 193 00:08:17,620 --> 00:08:19,180 are going to go to the highest 194 00:08:20,840 --> 00:08:22,440 malicious location in the network, 195 00:08:22,600 --> 00:08:23,860 which in this case happens to be 196 00:08:24,580 --> 00:08:25,880 the node, but it could be any of them. 197 00:08:26,200 --> 00:08:29,440 But this puts a large portion 198 00:08:29,440 --> 00:08:31,420 of the storage responsibilities 199 00:08:31,420 --> 00:08:33,360 and routing requests 200 00:08:33,360 --> 00:08:34,940 to go through one node, 201 00:08:35,080 --> 00:08:36,580 which is the problem. 202 00:08:40,420 --> 00:08:41,920 So how did we implement the attack? 203 00:08:42,620 --> 00:08:44,080 You don't need to be an elite hackser 204 00:08:44,080 --> 00:08:45,340 to write what we did. 205 00:08:46,020 --> 00:08:47,720 The code is very minor changes 206 00:08:47,720 --> 00:08:49,220 to the actual Freenet codebase. 207 00:08:49,620 --> 00:08:51,840 The attack nodes follow all the steps of the protocol 208 00:08:51,840 --> 00:08:54,820 except lying about who their peers are. 209 00:08:55,220 --> 00:08:57,000 We found that over a long enough period, 210 00:08:57,100 --> 00:08:59,060 a single attacker can spread malicious locations 211 00:08:59,060 --> 00:09:00,820 to most nodes in the network. 212 00:09:01,620 --> 00:09:03,000 Using multiple locations 213 00:09:03,000 --> 00:09:04,520 and multiple attackers in our attack 214 00:09:04,520 --> 00:09:07,200 helps make it go faster 215 00:09:07,200 --> 00:09:12,600 and makes the effects more defined. 216 00:09:15,260 --> 00:09:17,640 Okay, so here's the testbed we used. 217 00:09:17,760 --> 00:09:19,500 It's an 800-node testbed. 218 00:09:20,420 --> 00:09:21,820 We created an overlay testbed 219 00:09:21,840 --> 00:09:23,620 topology that conforms to the small world networks, 220 00:09:23,840 --> 00:09:25,240 as defined by Watts and Strogatz. 221 00:09:25,660 --> 00:09:27,580 We monitor the network to find path links 222 00:09:27,580 --> 00:09:29,420 and to monitor the swapping locations. 223 00:09:30,620 --> 00:09:32,080 For simplicity in our network, 224 00:09:32,200 --> 00:09:34,500 content is stored at the closest node 225 00:09:35,400 --> 00:09:36,700 with relation to the key. 226 00:09:38,160 --> 00:09:39,980 This is the assumption, again, for routing, 227 00:09:40,100 --> 00:09:42,560 but we just put it at that one node 228 00:09:42,560 --> 00:09:44,000 because we don't want to worry about replication 229 00:09:44,000 --> 00:09:44,960 and things like that. 230 00:09:46,280 --> 00:09:49,980 Also, we set a bound on the storage at each node, 231 00:09:50,080 --> 00:09:51,780 which is true in the real world, 232 00:09:51,840 --> 00:09:52,120 as well. 233 00:09:53,480 --> 00:09:57,420 So here's an example of how our malicious nodes 234 00:09:57,420 --> 00:09:58,260 attack the network. 235 00:09:58,540 --> 00:10:00,760 Basically, the picture on the left you can see 236 00:10:00,760 --> 00:10:03,480 is an initial distribution of node locations 237 00:10:03,480 --> 00:10:04,320 for our 800 nodes. 238 00:10:04,720 --> 00:10:06,660 You can see it's pretty well distributed 239 00:10:06,660 --> 00:10:07,420 around the circle. 240 00:10:08,140 --> 00:10:09,440 In the picture on the right, 241 00:10:09,480 --> 00:10:12,160 you can see that there's large clusters 242 00:10:12,160 --> 00:10:13,840 around our malicious locations 243 00:10:13,840 --> 00:10:16,200 and there's large gaps 244 00:10:16,200 --> 00:10:17,980 where we've basically taken away 245 00:10:18,620 --> 00:10:20,440 all the good locations around there. 246 00:10:24,780 --> 00:10:26,680 Okay, so now the fun examples. 247 00:10:26,780 --> 00:10:28,640 These are our data loss examples in our network. 248 00:10:30,320 --> 00:10:32,140 It's important to go over how the data loss 249 00:10:32,140 --> 00:10:33,120 actually happens. 250 00:10:34,500 --> 00:10:36,380 Basically, if you remember the example 251 00:10:36,380 --> 00:10:39,900 I showed you with the 0.5 as a malicious node, 252 00:10:40,020 --> 00:10:43,380 if somebody was inserting data again above 0.5, 253 00:10:43,460 --> 00:10:46,560 all that data would end up stored at 0.504 254 00:10:46,560 --> 00:10:48,320 with a high probability. 255 00:10:49,040 --> 00:10:51,660 Once 0.504 loses its... 256 00:10:52,240 --> 00:10:54,460 storage capacity, or runs out of storage capacity, 257 00:10:54,800 --> 00:10:56,100 it then has to push out data 258 00:10:57,000 --> 00:11:00,040 in a first-in, first-out fashion. 259 00:11:00,240 --> 00:11:02,960 So that's how the data actually gets lost. 260 00:11:03,380 --> 00:11:04,560 So here's our example. 261 00:11:05,800 --> 00:11:07,820 On the x-axis is time. 262 00:11:08,000 --> 00:11:09,440 It goes from 0 to 200. 263 00:11:09,580 --> 00:11:11,020 It's roughly 5 1⁄2 hours. 264 00:11:11,760 --> 00:11:14,300 On the y-axis is the percent of data lost 265 00:11:14,300 --> 00:11:15,080 in the network. 266 00:11:17,260 --> 00:11:20,920 Also, the attack always starts at 75 time increments. 267 00:11:20,920 --> 00:11:24,660 You can see here that after about 2 hours of attack time, 268 00:11:24,820 --> 00:11:28,260 roughly 20% of the data in the network is lost. 269 00:11:28,500 --> 00:11:31,600 And this is with only 2 attack nodes out of 800. 270 00:11:33,960 --> 00:11:35,440 So here's the data loss example, 271 00:11:35,520 --> 00:11:37,120 this time with 4 attack nodes, 272 00:11:37,740 --> 00:11:39,860 again in our 800-node network. 273 00:11:41,660 --> 00:11:43,320 Exact same scales for everything. 274 00:11:43,520 --> 00:11:45,620 Here we have about 30% data loss 275 00:11:45,620 --> 00:11:47,280 with 4 attack nodes. 276 00:11:50,920 --> 00:11:52,980 Okay, so here's with 8 attack nodes, 277 00:11:53,160 --> 00:11:54,740 which is 1% of the network. 278 00:11:55,100 --> 00:11:56,900 And it's pretty drastic. 279 00:11:56,940 --> 00:12:01,700 You can see that there's about 60% data loss in the network. 280 00:12:02,680 --> 00:12:05,860 Also, the above and below lines are the standard deviation 281 00:12:05,860 --> 00:12:08,220 because we did this over average runs. 282 00:12:08,940 --> 00:12:11,540 So you can see that sometimes it's a lot more drastic 283 00:12:11,540 --> 00:12:12,400 and sometimes it's less. 284 00:12:12,620 --> 00:12:16,560 This is because we don't choose our malicious nodes in any way. 285 00:12:16,620 --> 00:12:17,760 We just randomly choose them. 286 00:12:18,060 --> 00:12:20,900 So we don't know exactly what the topology looks like. 287 00:12:20,920 --> 00:12:21,820 when we choose them. 288 00:12:23,220 --> 00:12:24,600 So what are some possible protections 289 00:12:24,600 --> 00:12:26,200 that Freenet could use to protect against this? 290 00:12:27,680 --> 00:12:29,580 One thing they could do is check how frequently 291 00:12:29,580 --> 00:12:30,880 a node swaps similar locations. 292 00:12:31,940 --> 00:12:33,540 But as soon as you define similar, 293 00:12:34,500 --> 00:12:36,040 you're limiting the size of your network. 294 00:12:36,180 --> 00:12:37,780 And as all peer-to-peer networks want to be, 295 00:12:38,240 --> 00:12:39,860 they want to have as many peers as possible. 296 00:12:40,040 --> 00:12:42,200 So that's not a good solution. 297 00:12:42,740 --> 00:12:44,580 Another idea is limiting the number of swaps 298 00:12:44,580 --> 00:12:45,360 with a particular peer. 299 00:12:45,600 --> 00:12:47,860 But if you stop the number of swaps 300 00:12:47,860 --> 00:12:49,260 at, say, 5 with a certain peer, 301 00:12:49,440 --> 00:12:50,820 and it's still advantageous 302 00:12:50,920 --> 00:12:52,060 for routing to swap with that peer, 303 00:12:52,220 --> 00:12:53,720 then you're screwed, 304 00:12:53,820 --> 00:12:55,340 and that's not a very good protection either. 305 00:12:56,580 --> 00:12:58,040 Can you determine a node is bad 306 00:12:58,040 --> 00:13:00,300 because its location is really, really close to yours? 307 00:13:01,000 --> 00:13:03,600 No, because again, if your network is large enough, 308 00:13:03,700 --> 00:13:06,000 you're going to expect to be swapping 309 00:13:06,580 --> 00:13:08,320 with people whose locations are really close to you. 310 00:13:10,740 --> 00:13:13,100 Another idea is secure multiparting computation 311 00:13:14,540 --> 00:13:16,700 to compute the formula we showed you earlier. 312 00:13:16,940 --> 00:13:18,820 But that doesn't really do anything 313 00:13:18,820 --> 00:13:20,820 because an attacker can always lie 314 00:13:20,820 --> 00:13:21,720 about who his friends are, 315 00:13:21,800 --> 00:13:25,260 and there's no way to fix that. 316 00:13:25,480 --> 00:13:27,840 You can never know who the friends of your friends are 317 00:13:27,840 --> 00:13:28,720 in a friend-to-friend network. 318 00:13:30,200 --> 00:13:33,160 So in conclusion, we don't believe 319 00:13:33,160 --> 00:13:36,360 that Freenet's routing algorithm is robust enough to be used. 320 00:13:37,200 --> 00:13:39,840 Adversaries can remove the diversity of node locations 321 00:13:39,840 --> 00:13:42,440 and therefore screw storage responsibilities 322 00:13:42,440 --> 00:13:44,700 and routing responsibilities, 323 00:13:45,040 --> 00:13:46,900 and we cause significant content loss 324 00:13:46,900 --> 00:13:47,780 with even a few attackers. 325 00:13:48,400 --> 00:13:50,480 We use Freenet's own code against itself, 326 00:13:50,820 --> 00:13:53,620 so it's not like we're doing anything really bad. 327 00:13:53,760 --> 00:13:55,620 We're just tweaking a little bit. 328 00:13:56,080 --> 00:13:58,280 And since swapping is such a crucial part 329 00:13:58,280 --> 00:13:59,780 of the routing algorithm, 330 00:14:00,000 --> 00:14:01,940 it's a really tough problem to fix, 331 00:14:02,100 --> 00:14:04,680 and it's just a fundamental problem. 332 00:14:05,580 --> 00:14:08,280 We also think that churn in the network, 333 00:14:08,340 --> 00:14:11,520 natural churn, can cause similar location loss. 334 00:14:12,520 --> 00:14:15,360 But to find that out, come read our paper. 335 00:14:15,740 --> 00:14:17,980 And the code's available there. 336 00:14:20,820 --> 00:14:22,000 Thanks, everybody, for listening. 337 00:14:22,140 --> 00:14:22,640 Questions? 338 00:14:42,640 --> 00:14:46,400 Could you repeat that? 339 00:14:46,480 --> 00:14:47,640 Are you saying that... 340 00:14:50,960 --> 00:14:51,480 Yes. 341 00:14:51,480 --> 00:14:51,700 Yes. 342 00:15:06,340 --> 00:15:08,080 Okay, so the question is, 343 00:15:08,220 --> 00:15:10,260 if everybody has a huge data store, 344 00:15:10,420 --> 00:15:12,300 does that solve this problem? 345 00:15:14,780 --> 00:15:17,300 In the short term, probably. 346 00:15:17,500 --> 00:15:19,040 I mean, you could tweak a lot of the parameters. 347 00:15:19,040 --> 00:15:20,640 In our network, we're using... 348 00:15:20,640 --> 00:15:23,760 We're inserting 25% of the total storage capacity 349 00:15:23,760 --> 00:15:24,240 of the network. 350 00:15:25,000 --> 00:15:26,200 So, yeah, if you tweak that, 351 00:15:26,280 --> 00:15:27,720 it's gonna change it either way. 352 00:15:28,020 --> 00:15:29,520 Essentially, what it mostly changes 353 00:15:29,520 --> 00:15:32,020 is that how much data loss occurs how quickly. 354 00:15:32,420 --> 00:15:33,520 If you've got whatever... 355 00:15:33,520 --> 00:15:35,120 Every node has a terabyte of storage space, 356 00:15:35,240 --> 00:15:37,900 and your overall network only contains a terabyte of data, 357 00:15:38,040 --> 00:15:38,940 then you're fine. 358 00:15:39,140 --> 00:15:39,840 Nothing will happen. 359 00:15:40,520 --> 00:15:42,680 If every node only has, whatever, 360 00:15:44,020 --> 00:15:45,560 500 megabytes of storage space, 361 00:15:45,780 --> 00:15:49,020 and your network contains 10 times as much, right, 362 00:15:49,020 --> 00:15:50,320 then your results will be much worse 363 00:15:50,320 --> 00:15:51,280 than what we have right now. 364 00:15:52,640 --> 00:15:53,880 So the point is, 365 00:15:55,380 --> 00:15:56,440 it's really just gradual. 366 00:15:56,840 --> 00:15:59,380 And we just picked one quarter as a data point 367 00:15:59,380 --> 00:16:00,480 to show kind of, okay, 368 00:16:00,520 --> 00:16:01,540 what would we realistically expect 369 00:16:01,540 --> 00:16:04,460 for such kind of network to be able to handle, right? 370 00:16:10,860 --> 00:16:11,260 Yeah. 371 00:16:20,400 --> 00:16:22,300 It approaches, essentially, 100%. 372 00:16:22,300 --> 00:16:23,620 If you keep it going, 373 00:16:23,720 --> 00:16:25,200 it will approach 100%, as you can see. 374 00:16:25,280 --> 00:16:25,800 The graphs... 375 00:16:25,800 --> 00:16:27,640 I mean, obviously, the curve flattens out, 376 00:16:27,760 --> 00:16:30,040 but as the malicious node locations spread, right, 377 00:16:30,640 --> 00:16:32,560 and they start spreading slower and slower over time, 378 00:16:32,620 --> 00:16:33,580 but they will continue to spread 379 00:16:33,580 --> 00:16:35,880 because of the random swaps that the network does, 380 00:16:36,060 --> 00:16:37,860 you will eventually take over everything. 381 00:16:40,200 --> 00:16:41,760 Even with just one malicious node, 382 00:16:41,800 --> 00:16:43,060 you would eventually take over everything. 383 00:16:43,280 --> 00:16:44,040 Question is, you know, 384 00:16:44,100 --> 00:16:45,840 how long do you want to run these simulations, 385 00:16:45,960 --> 00:16:49,000 and 800 nodes per day? 386 00:16:49,020 --> 00:16:49,340 This is a lot. 387 00:16:49,460 --> 00:16:51,240 We don't have that much processing time. 388 00:16:51,340 --> 00:16:52,240 Anybody who didn't hear that, 389 00:16:52,280 --> 00:16:52,860 the question was, 390 00:16:53,060 --> 00:16:54,400 what happens if you run this 391 00:16:54,400 --> 00:16:56,840 for a really long period of time? 392 00:16:57,000 --> 00:16:59,060 And our answer is that, 393 00:16:59,140 --> 00:17:00,380 eventually, even one attacker 394 00:17:00,380 --> 00:17:03,500 can take over all the locations in the network. 395 00:17:03,700 --> 00:17:04,500 I mean, given enough time, 396 00:17:04,580 --> 00:17:05,940 random swaps are going to happen, 397 00:17:06,020 --> 00:17:09,600 and all the nodes will become bad. 398 00:17:10,620 --> 00:17:11,060 Yeah. 399 00:17:11,160 --> 00:17:12,620 So is this just an architectural issue 400 00:17:12,620 --> 00:17:13,960 with GreenNet specifically, 401 00:17:14,280 --> 00:17:17,480 or is it GreenNet-directed, 402 00:17:17,480 --> 00:17:18,180 or are there other... 403 00:17:20,740 --> 00:17:21,140 ? 404 00:17:23,100 --> 00:17:24,640 Well, of course there's other networks 405 00:17:24,640 --> 00:17:25,400 that don't suffer from this, 406 00:17:25,480 --> 00:17:25,820 but... 407 00:17:27,680 --> 00:17:29,220 So the question here is, 408 00:17:29,400 --> 00:17:31,260 is this an architectural Freenet problem, 409 00:17:31,540 --> 00:17:33,060 I think, or is it... 410 00:17:34,560 --> 00:17:34,960 ? 411 00:17:40,720 --> 00:17:41,440 Oh, okay. 412 00:17:41,500 --> 00:17:43,320 And then how general a problem 413 00:17:43,320 --> 00:17:44,980 with friend-to-friend networks it is? 414 00:17:45,140 --> 00:17:47,120 Well, here it's a real big problem 415 00:17:47,120 --> 00:17:48,040 because of the swapping, 416 00:17:48,040 --> 00:17:50,240 because they really rely on 417 00:17:50,240 --> 00:17:52,000 who your friends are for this equation. 418 00:17:52,760 --> 00:17:53,800 And a friend-to-friend network 419 00:17:53,800 --> 00:17:54,840 that doesn't rely on swapping 420 00:17:54,840 --> 00:17:56,880 for such a big portion of the routing, 421 00:17:56,940 --> 00:17:57,800 then it wouldn't really be 422 00:17:57,800 --> 00:17:58,680 as much of a problem. 423 00:17:58,860 --> 00:17:59,440 And essentially, 424 00:17:59,520 --> 00:18:00,700 it's an architectural problem 425 00:18:00,700 --> 00:18:02,700 in the sense of the Freenet routing algorithm 426 00:18:02,700 --> 00:18:03,200 specifically. 427 00:18:03,600 --> 00:18:03,900 Yeah. 428 00:18:03,940 --> 00:18:04,820 The other parts of Freenet 429 00:18:04,820 --> 00:18:05,480 are not impacted, 430 00:18:06,420 --> 00:18:07,440 but it's kind of essential 431 00:18:07,440 --> 00:18:08,280 that you, you know, 432 00:18:08,280 --> 00:18:09,160 find your data quickly 433 00:18:09,160 --> 00:18:11,680 and where you store your data and so on. 434 00:18:11,760 --> 00:18:12,740 And so in that sense, 435 00:18:13,140 --> 00:18:14,440 yes, it's the Freenet architecture. 436 00:18:14,520 --> 00:18:16,060 It's not a general friend-to-friend problem. 437 00:18:16,640 --> 00:18:17,460 I would just say 438 00:18:17,460 --> 00:18:18,100 friend-to-friend networks 439 00:18:18,100 --> 00:18:19,220 make it incredibly hard 440 00:18:19,220 --> 00:18:20,600 to do these kind of things 441 00:18:20,600 --> 00:18:21,140 to begin with. 442 00:18:21,420 --> 00:18:22,580 And the answer is just 443 00:18:22,580 --> 00:18:23,400 this is not a solution, 444 00:18:23,660 --> 00:18:24,620 at least not a good one. 445 00:18:25,460 --> 00:18:25,940 Yeah. 446 00:18:26,120 --> 00:18:27,340 In your research, 447 00:18:27,580 --> 00:18:28,500 your attack algorithm, 448 00:18:28,780 --> 00:18:30,460 what's your order of magnitude 449 00:18:30,460 --> 00:18:31,280 on average? 450 00:18:32,000 --> 00:18:33,520 Order of magnitude of? 451 00:18:33,800 --> 00:18:34,280 . 452 00:18:36,020 --> 00:18:37,360 For, for routing? 453 00:18:37,680 --> 00:18:39,260 No, your attack algorithm 454 00:18:39,260 --> 00:18:41,020 actually affects the entire network. 455 00:18:42,580 --> 00:18:43,180 I'm not sure. 456 00:18:43,180 --> 00:18:44,000 Well, the number of swaps. 457 00:18:44,160 --> 00:18:44,900 Okay, the question was 458 00:18:44,900 --> 00:18:46,160 what's the order of magnitude 459 00:18:46,160 --> 00:18:46,880 of our algorithm 460 00:18:47,460 --> 00:18:47,860 to the network, 461 00:18:47,980 --> 00:18:48,680 what we have to do? 462 00:18:48,800 --> 00:18:49,580 Well, the answer is 463 00:18:49,580 --> 00:18:50,820 obviously you have to have 464 00:18:50,820 --> 00:18:51,800 kind of an O of N 465 00:18:51,800 --> 00:18:53,140 as a linear number of swaps 466 00:18:53,140 --> 00:18:54,300 to take over the entire network. 467 00:18:55,000 --> 00:18:55,360 Right. 468 00:18:55,520 --> 00:18:56,040 And the rest, 469 00:18:56,260 --> 00:18:57,900 I mean, this is swaps 470 00:18:57,900 --> 00:18:58,340 with your neighbors. 471 00:18:58,720 --> 00:18:59,080 Right. 472 00:18:59,860 --> 00:19:01,280 How long it will take to spread, 473 00:19:01,400 --> 00:19:02,220 again, depends on 474 00:19:02,220 --> 00:19:04,300 how often the nodes themselves swap. 475 00:19:04,880 --> 00:19:05,240 Right. 476 00:19:05,440 --> 00:19:05,800 . 477 00:19:10,080 --> 00:19:10,440 No. 478 00:19:11,060 --> 00:19:12,540 We didn't actually, well. 479 00:19:12,640 --> 00:19:14,220 The question doesn't make sense. 480 00:19:14,280 --> 00:19:15,120 That's what I mean, so. 481 00:19:17,460 --> 00:19:18,200 Any more questions? 482 00:19:20,180 --> 00:19:20,540 Okay. 483 00:19:20,780 --> 00:19:21,420 Thanks, everybody. 484 00:19:21,580 --> 00:19:21,880 Thank you.