1 00:00:25,620 --> 00:00:29,960 Thank you for watching. 2 00:00:30,000 --> 00:00:59,960 Thank you for watching. 3 00:01:00,000 --> 00:01:29,920 Thank you for watching. 4 00:01:42,000 --> 00:01:59,900 Thank you for watching. 5 00:02:00,000 --> 00:02:14,160 Thank you for watching. 6 00:02:44,380 --> 00:02:59,940 Thank you for watching. 7 00:03:00,000 --> 00:03:12,560 Thank you for watching. 8 00:03:41,280 --> 00:03:52,780 Thank you for watching. 9 00:04:11,580 --> 00:04:19,700 Thank you for watching. 10 00:04:40,820 --> 00:04:59,180 Thank you for watching. 11 00:05:00,000 --> 00:05:29,100 Thank you for watching. 12 00:05:56,280 --> 00:05:59,980 Thank you for watching. 13 00:06:12,360 --> 00:06:27,940 Thank you for watching. 14 00:06:40,920 --> 00:06:55,900 Thank you for watching. 15 00:07:00,000 --> 00:07:25,140 Thank you for watching. 16 00:07:40,880 --> 00:07:53,860 Thank you for watching. 17 00:08:00,040 --> 00:08:02,580 Thank you for watching. 18 00:08:32,480 --> 00:08:32,880 Thank you for watching. 19 00:08:33,340 --> 00:08:33,740 Posing. 20 00:08:33,880 --> 00:08:34,020 Okay. 21 00:08:34,020 --> 00:08:34,420 Okay. 22 00:08:34,420 --> 00:08:38,780 You have a fairly large organization, you got a building with multiple floors, and 23 00:08:38,780 --> 00:08:43,060 they are all connected, and you don't know everybody around them, and I come around saying, 24 00:08:43,120 --> 00:08:46,880 listen, I'm the network administrator, there seems to be something wrong with your machine. 25 00:08:47,260 --> 00:08:51,620 Sit down, play with the machine, have a floppy with me, install a backdoor or trojan, go 26 00:08:51,620 --> 00:08:51,840 away. 27 00:08:52,280 --> 00:08:52,680 Okay. 28 00:08:53,540 --> 00:08:55,580 It could happen, it does happen. 29 00:08:55,800 --> 00:08:59,980 If you don't think posing is too technical, you know, you could term it as human spoofing. 30 00:09:00,000 --> 00:09:02,520 Okay, I've walked in as someone else. 31 00:09:03,780 --> 00:09:06,500 Dumpster diving, everybody's heard about, you know, throw stuff away. 32 00:09:06,860 --> 00:09:09,200 The last point is really the most important. 33 00:09:09,380 --> 00:09:13,680 You have a disgruntled employee and you've got a bad enemy, okay, 34 00:09:13,720 --> 00:09:15,940 because the guy is sitting inside of your organization. 35 00:09:16,920 --> 00:09:21,840 Most people protect their organization with a fence outside, an electronic or digital fence. 36 00:09:22,040 --> 00:09:22,860 What do you do inside? 37 00:09:23,460 --> 00:09:28,260 Very, very few people take enough security precautions within an organization. 38 00:09:28,260 --> 00:09:35,000 And 65% of the attacks happen from inside was based on a study which happened maybe one and a half years ago. 39 00:09:35,140 --> 00:09:38,200 I actually think the number is probably higher. 40 00:09:38,280 --> 00:09:42,380 Maybe 75-80% of the attacks originate because of inside information. 41 00:09:45,000 --> 00:09:47,620 Okay, now to the slightly more interesting stuff. 42 00:09:49,060 --> 00:09:54,160 The programmable dangers today include this entire list that is out there, 43 00:09:54,260 --> 00:09:57,620 you know, starting from viruses and backdoors and denial of service attacks 44 00:09:57,620 --> 00:09:58,120 and... 45 00:09:58,120 --> 00:09:59,580 sniffing and spoofing. 46 00:10:03,060 --> 00:10:03,620 Okay. 47 00:10:04,420 --> 00:10:05,320 Viruses and worms. 48 00:10:06,300 --> 00:10:11,660 My opinion, this is the biggest threat and the worst pain in the butt for most corporations. 49 00:10:13,720 --> 00:10:14,680 Very simple. 50 00:10:16,080 --> 00:10:17,480 To use or... 51 00:10:17,480 --> 00:10:23,100 I mean, I don't need to get into your machine when you are online, 52 00:10:23,360 --> 00:10:27,520 try and get the root password and then do a rm-rf slash or... 53 00:10:28,120 --> 00:10:29,860 l-star-dot-star-from-slash. 54 00:10:30,500 --> 00:10:31,280 That's complex. 55 00:10:31,960 --> 00:10:37,460 What if I could simply send you an email which contained a piece of malicious code which did exactly that? 56 00:10:37,980 --> 00:10:38,420 Okay. 57 00:10:38,480 --> 00:10:40,160 The mail comes to you from someone you know. 58 00:10:40,600 --> 00:10:41,900 There's an attachment on it. 59 00:10:41,980 --> 00:10:42,660 You click it. 60 00:10:42,880 --> 00:10:47,140 Or there's a program which, you know, kind of is supposed to do something else. 61 00:10:47,220 --> 00:10:47,980 You click on it. 62 00:10:48,060 --> 00:10:51,340 And it actually launches a piece of virus which goes and sits in your boot sector 63 00:10:52,040 --> 00:10:53,460 and toasts your hard disk. 64 00:10:54,600 --> 00:10:56,740 So, you have an organization now 65 00:10:56,740 --> 00:10:57,980 with, let's say, 66 00:10:57,980 --> 00:10:59,100 three, four hundred people. 67 00:11:00,260 --> 00:11:02,300 And you know how the internet is, right? 68 00:11:02,360 --> 00:11:06,380 You kind of keep forwarding jokes and you forward pictures and you forward stuff to each other. 69 00:11:06,600 --> 00:11:08,720 So, something interesting comes into this organization. 70 00:11:09,160 --> 00:11:11,200 And before you know it, everybody else has got it. 71 00:11:11,740 --> 00:11:13,320 Now, why is this so dangerous? 72 00:11:13,640 --> 00:11:16,880 Simply because port 25, your mail server port, 73 00:11:16,980 --> 00:11:19,720 or the machine that's going to pick up mail from your POP account, 74 00:11:20,220 --> 00:11:23,920 is really going to allow connections through to 110 to 25. 75 00:11:25,020 --> 00:11:26,600 You download stuff off the web. 76 00:11:26,600 --> 00:11:30,620 Most firewalls would allow connections to port 80. 77 00:11:31,160 --> 00:11:35,480 So, it's really a very loose fence that lies over there. 78 00:11:35,640 --> 00:11:37,060 And therein lies the danger. 79 00:11:37,340 --> 00:11:39,420 You know, people get stuff down before you know it. 80 00:11:39,440 --> 00:11:41,020 And it's so easy to write viruses these days. 81 00:11:41,240 --> 00:11:43,100 I mean, you've got do-it-yourself kits. 82 00:11:43,680 --> 00:11:44,600 You've got Microsoft. 83 00:11:48,200 --> 00:11:49,080 It's easy. 84 00:11:50,740 --> 00:11:53,540 Viruses is actually a super specialized shopping in itself. 85 00:11:53,660 --> 00:11:54,640 I don't know much about it. 86 00:11:54,720 --> 00:11:55,880 I'm not very interested in it. 87 00:11:55,880 --> 00:11:57,160 So, we'll go ahead to the next one. 88 00:11:58,380 --> 00:11:58,920 Excuse me. 89 00:12:06,780 --> 00:12:07,500 Okay, Trojans. 90 00:12:07,540 --> 00:12:08,760 Everybody heard of Trojans? 91 00:12:10,300 --> 00:12:11,160 Trojan horse programs? 92 00:12:12,160 --> 00:12:12,700 Yes? No? 93 00:12:13,760 --> 00:12:14,120 Wonderful. 94 00:12:16,360 --> 00:12:17,520 Pretends to do something useful. 95 00:12:18,980 --> 00:12:21,300 And, I mean, the slide is self-explanatory. 96 00:12:21,380 --> 00:12:23,840 I remember the first time I did this about ten years ago 97 00:12:23,840 --> 00:12:26,580 during post-graduation of software technology, 98 00:12:26,800 --> 00:12:30,660 I wrote a login emulator into the mainframe. 99 00:12:30,980 --> 00:12:35,140 And it was unbelievable the number of passwords one picked up. 100 00:12:35,540 --> 00:12:41,980 More importantly, all the guys, or let's say 80% of the guys, 101 00:12:42,180 --> 00:12:45,120 you'd know which woman they were hot after 102 00:12:45,120 --> 00:12:48,020 simply because that was the password they'd selected. 103 00:12:48,440 --> 00:12:53,820 So, the next time you go and login into your system, 104 00:12:53,840 --> 00:12:57,820 and it comes back with, you know, login failure and the login prompt comes again, 105 00:12:57,960 --> 00:13:00,880 ask yourself, listen, was that something else? 106 00:13:01,320 --> 00:13:03,520 Or was that me making a typo? 107 00:13:09,120 --> 00:13:09,680 Okay. 108 00:13:11,700 --> 00:13:13,620 What is a denial of service attack? 109 00:13:17,300 --> 00:13:21,860 Anything that prevents the normal function of services, 110 00:13:22,200 --> 00:13:23,460 servers, networks, 111 00:13:23,840 --> 00:13:24,320 hosts, 112 00:13:25,780 --> 00:13:27,860 it cuts you away from resources, 113 00:13:28,480 --> 00:13:30,020 can be termed as a DOS. 114 00:13:30,660 --> 00:13:33,340 And DOS in principle is not really new. 115 00:13:33,460 --> 00:13:37,720 In the olden days where computing power was still looked up to, 116 00:13:37,780 --> 00:13:38,500 it was still precious, 117 00:13:38,720 --> 00:13:42,980 where RAM and CPU was valuable, 118 00:13:43,740 --> 00:13:45,740 these things have existed since that time. 119 00:13:46,020 --> 00:13:50,640 So, for example, if I wrote a small script which kind of said, 120 00:13:50,780 --> 00:13:51,480 while true, 121 00:13:52,580 --> 00:13:53,680 make directory A, 122 00:13:54,580 --> 00:13:55,860 change directory into A, 123 00:13:56,440 --> 00:13:57,420 and repeat the loop. 124 00:13:58,220 --> 00:13:59,180 Okay, what would happen? 125 00:14:01,840 --> 00:14:03,880 It would recursively go all the way in. 126 00:14:03,880 --> 00:14:05,200 Okay, now let's say on a Unix system, 127 00:14:05,300 --> 00:14:08,520 you're limited by the fact that you're a particular user 128 00:14:08,520 --> 00:14:11,300 and you have constraints on what you can use up. 129 00:14:11,460 --> 00:14:12,720 But let's say if it was run as root, 130 00:14:12,840 --> 00:14:16,200 or in the olden days where limits were not imposed so tightly, 131 00:14:16,420 --> 00:14:18,120 you would run out of inodes on the system. 132 00:14:18,720 --> 00:14:19,120 Okay. 133 00:14:19,120 --> 00:14:24,020 Every available inode where you can hook on a directory or a file 134 00:14:24,020 --> 00:14:24,880 would be taken up, 135 00:14:24,960 --> 00:14:28,080 and in effect you've done a DOS on the particular machine. 136 00:14:28,540 --> 00:14:31,960 The DOS that we are interested in today is a little more advanced. 137 00:14:32,540 --> 00:14:34,500 I'm interested in being able to sit here 138 00:14:34,500 --> 00:14:37,520 and launch something which kind of goes and does something on a server 139 00:14:37,520 --> 00:14:39,960 which is probably sitting in Iceland or Alaska or something, 140 00:14:40,060 --> 00:14:40,980 or maybe the other way around. 141 00:14:46,040 --> 00:14:46,500 Okay. 142 00:14:46,620 --> 00:14:48,240 Now there are multiple ways in which 143 00:14:48,240 --> 00:14:50,680 you can execute denial of service attacks. 144 00:14:51,160 --> 00:14:54,260 One of them is called, let's call it magic packets. 145 00:14:56,930 --> 00:15:01,380 The principle here is to send a small, 146 00:15:01,460 --> 00:15:05,040 maybe even a single malformed packet to your target host. 147 00:15:06,100 --> 00:15:10,240 Now the malformed packet is what causes the magic to happen. 148 00:15:10,840 --> 00:15:11,100 Okay. 149 00:15:12,920 --> 00:15:18,220 This packet will really break accepted de facto network links. 150 00:15:18,240 --> 00:15:20,560 So for example, the packet could be oversized. 151 00:15:21,620 --> 00:15:24,160 If the packet is a TCP packet, 152 00:15:24,380 --> 00:15:27,180 there are various control flags that a TCP packet has. 153 00:15:27,720 --> 00:15:32,720 These control flags would signify what stage of the connection 154 00:15:34,120 --> 00:15:36,280 this entire connection is in itself. 155 00:15:36,460 --> 00:15:37,520 Am I making a connection? 156 00:15:37,760 --> 00:15:38,480 Am I transmitting? 157 00:15:38,540 --> 00:15:39,120 Am I acknowledging? 158 00:15:39,500 --> 00:15:44,380 Now if I could set up flags which were not expected by the remote system, 159 00:15:45,120 --> 00:15:46,340 that could be a problem. 160 00:15:47,880 --> 00:15:49,360 Injecting out of sequence packets. 161 00:15:49,720 --> 00:15:50,160 Okay. 162 00:15:50,240 --> 00:15:53,920 Now the reason why this particular attack would succeed 163 00:15:53,920 --> 00:15:57,360 is because the TCP IP stack on the target machine 164 00:15:57,360 --> 00:16:01,760 is not stable or robust enough to handle exceptional cases. 165 00:16:02,680 --> 00:16:03,240 Okay. 166 00:16:03,280 --> 00:16:04,580 Anybody heard of WinUK? 167 00:16:04,640 --> 00:16:07,080 It's a very old thing. 168 00:16:07,220 --> 00:16:08,100 How many heard of WinUK? 169 00:16:08,780 --> 00:16:09,340 Yeah. 170 00:16:09,660 --> 00:16:10,480 Not too many. 171 00:16:10,580 --> 00:16:10,700 Okay. 172 00:16:10,780 --> 00:16:12,940 When Windows 95 actually popped up, 173 00:16:12,960 --> 00:16:14,960 you know, it was a nice, good, clean, 174 00:16:16,140 --> 00:16:17,420 graphical user interface. 175 00:16:18,400 --> 00:16:20,020 That's when this thing was formulated. 176 00:16:20,340 --> 00:16:21,660 The way this attack worked was 177 00:16:21,660 --> 00:16:24,920 it targeted your Windows machine on port 139, 178 00:16:25,040 --> 00:16:26,260 which was the net IO port. 179 00:16:26,600 --> 00:16:29,140 It sent the packet with the OOB, 180 00:16:29,280 --> 00:16:31,540 the out-of-band flag marked as on. 181 00:16:31,940 --> 00:16:33,960 The remote machine didn't know how to handle it, 182 00:16:34,000 --> 00:16:34,660 and thuck. 183 00:16:35,000 --> 00:16:35,300 You know? 184 00:16:35,440 --> 00:16:39,880 So the story is like if you're on ISE and you're chatting with someone 185 00:16:39,880 --> 00:16:43,240 and you kind of get into an online virtual argument, 186 00:16:43,980 --> 00:16:44,420 and, 187 00:16:44,420 --> 00:16:46,880 all of a sudden you see a screen go blue, 188 00:16:46,980 --> 00:16:47,860 the blue screen of death, 189 00:16:47,960 --> 00:16:48,700 and your machines crash, 190 00:16:49,000 --> 00:16:50,020 it's probably, 191 00:16:50,200 --> 00:16:51,180 or was probably, 192 00:16:51,360 --> 00:16:52,800 a WinUK packet which was generated. 193 00:16:53,660 --> 00:16:55,340 The reason the machine crashed, 194 00:16:55,460 --> 00:16:57,160 your Microsoft OS went down was, 195 00:16:58,360 --> 00:16:58,900 anybody? 196 00:16:59,960 --> 00:17:00,500 Simple. 197 00:17:00,880 --> 00:17:03,400 Whenever a Microsoft program doesn't know what to do, 198 00:17:03,660 --> 00:17:06,940 it does what all good Microsoft programs do, 199 00:17:07,100 --> 00:17:08,820 but it crashes. 200 00:17:09,740 --> 00:17:10,280 Okay? 201 00:17:10,420 --> 00:17:10,940 So, 202 00:17:11,040 --> 00:17:13,100 and the story here is that 203 00:17:13,100 --> 00:17:15,200 the minute this thing happened, 204 00:17:16,520 --> 00:17:17,720 Microsoft was informed, 205 00:17:18,000 --> 00:17:19,120 they released a patch, 206 00:17:19,880 --> 00:17:23,200 and it is ridiculous as the story goes. 207 00:17:23,360 --> 00:17:23,420 Okay. 208 00:17:23,500 --> 00:17:24,620 The patch was like this. 209 00:17:24,720 --> 00:17:26,380 If I sent you a WinUK packet, 210 00:17:26,720 --> 00:17:29,340 the payload of the packet contained a particular string. 211 00:17:29,520 --> 00:17:30,640 If I recall correctly, 212 00:17:30,820 --> 00:17:32,220 it was BEWM. 213 00:17:32,460 --> 00:17:34,660 So what Microsoft did in all its wisdom, 214 00:17:34,920 --> 00:17:38,900 it filtered anything that came to port 139, 215 00:17:39,060 --> 00:17:40,940 had the OOB flag on, 216 00:17:41,080 --> 00:17:43,080 and had a payload of BEWM. 217 00:17:43,100 --> 00:17:44,000 Okay? 218 00:17:44,180 --> 00:17:45,200 It silently ignored that. 219 00:17:45,700 --> 00:17:48,900 It was a matter of a few hours before WinUK 2 happened, 220 00:17:49,140 --> 00:17:51,580 which completely randomized the payload, 221 00:17:52,620 --> 00:17:54,160 put in various other things, 222 00:17:54,300 --> 00:17:58,000 and then Microsoft was forced to actually release a real patch. 223 00:17:58,360 --> 00:18:01,700 But why WinUK is so important is 224 00:18:01,700 --> 00:18:05,200 it became the first piece of software that used magic packets 225 00:18:05,200 --> 00:18:07,680 and was distributed widely over the world. 226 00:18:07,820 --> 00:18:09,400 I mean, you had variations where 227 00:18:09,400 --> 00:18:11,500 I could set up one piece of, 228 00:18:12,180 --> 00:18:13,080 one attachment, 229 00:18:13,080 --> 00:18:13,200 one tackle, 230 00:18:14,060 --> 00:18:16,100 shooting to various machines and stuff like that. 231 00:18:16,200 --> 00:18:17,460 It was fairly crazy. 232 00:18:20,400 --> 00:18:20,920 Okay. 233 00:18:23,320 --> 00:18:26,140 Another style of DOS is a network saturation attack. 234 00:18:26,640 --> 00:18:27,860 As the name implies, 235 00:18:28,200 --> 00:18:30,860 you flood a network with so much of traffic 236 00:18:30,860 --> 00:18:33,360 that machines and routers on that network 237 00:18:34,260 --> 00:18:35,720 simply can't handle it anymore. 238 00:18:36,060 --> 00:18:37,620 What happens is they go into 239 00:18:37,620 --> 00:18:39,840 high strain trying to, you know, 240 00:18:39,880 --> 00:18:42,480 route and process the packets as they're coming in. 241 00:18:43,080 --> 00:18:44,300 And all these packets, 242 00:18:44,440 --> 00:18:45,400 because they're illegitimate, 243 00:18:45,500 --> 00:18:46,960 are actually taking away resources, 244 00:18:47,240 --> 00:18:48,580 bandwidth as well as CPU power. 245 00:18:48,840 --> 00:18:50,620 As a result, what happens? 246 00:18:50,960 --> 00:18:53,180 Real applications like web and email 247 00:18:53,180 --> 00:18:54,440 and FTP and stuff like that 248 00:18:54,440 --> 00:18:56,440 that legitimate users might want to use 249 00:18:56,440 --> 00:18:57,440 also get affected. 250 00:18:57,980 --> 00:19:00,680 So a network saturation attack actually affects 251 00:19:00,680 --> 00:19:02,700 a large number of people. 252 00:19:02,900 --> 00:19:05,160 You know, I might be wanting to target that particular thing 253 00:19:05,160 --> 00:19:07,360 for one particular individual or organization, 254 00:19:07,700 --> 00:19:10,180 but anybody that's using that network is going to get affected. 255 00:19:10,580 --> 00:19:13,000 All networks which are enroute, 256 00:19:13,000 --> 00:19:15,820 the attacker and the victim would also get affected 257 00:19:15,820 --> 00:19:17,200 because of a huge amount of traffic. 258 00:19:28,080 --> 00:19:28,500 Okay. 259 00:19:28,580 --> 00:19:30,760 There are other ways in which you can do DOS. 260 00:19:31,660 --> 00:19:34,080 It's really dependent on your imagination and innovation 261 00:19:34,080 --> 00:19:35,920 and how much you know of the protocols. 262 00:19:36,560 --> 00:19:37,700 Everybody heard of ping? 263 00:19:37,820 --> 00:19:39,660 You ping a machine to see if it's alive or not. 264 00:19:40,720 --> 00:19:42,040 Now, what happens 265 00:19:42,040 --> 00:19:43,720 if I send out a ping packet 266 00:19:44,220 --> 00:19:45,560 as a broadcast ping 267 00:19:45,560 --> 00:19:48,440 to multiple machines on my subnet, for example? 268 00:19:49,300 --> 00:19:51,300 Each of these machines is going to get a ping packet 269 00:19:51,300 --> 00:19:53,340 and each of these machines is going to reply back to me. 270 00:19:53,560 --> 00:19:55,000 So instead of pinging one machine, 271 00:19:55,080 --> 00:19:55,700 I've pinged multiple 272 00:19:55,700 --> 00:19:57,320 and I've got multiple replies back. 273 00:19:58,780 --> 00:19:59,180 Okay. 274 00:19:59,260 --> 00:20:00,800 So where is the trick here? 275 00:20:01,960 --> 00:20:03,140 What I could do is 276 00:20:03,140 --> 00:20:04,540 I don't like him. 277 00:20:05,000 --> 00:20:06,380 He's my, whatever, neighbor, 278 00:20:06,500 --> 00:20:07,420 and I know he sits here. 279 00:20:07,480 --> 00:20:08,260 I know his IP address. 280 00:20:08,840 --> 00:20:10,120 I spoof a ping 281 00:20:10,620 --> 00:20:11,840 to a huge network, 282 00:20:12,040 --> 00:20:13,320 with his IP address. 283 00:20:14,320 --> 00:20:14,800 Okay. 284 00:20:15,320 --> 00:20:16,440 So what happens is 285 00:20:16,440 --> 00:20:18,620 all the machines that receive that ping request 286 00:20:18,620 --> 00:20:20,340 actually send a response back 287 00:20:20,340 --> 00:20:22,640 and this guy's machine is hit with that. 288 00:20:22,860 --> 00:20:23,200 Okay. 289 00:20:23,220 --> 00:20:23,780 So things like that. 290 00:20:24,100 --> 00:20:25,260 Similarly, SYN flooding. 291 00:20:25,400 --> 00:20:27,760 You know, you set up so many connections to a machine 292 00:20:29,580 --> 00:20:30,680 that the machine is 293 00:20:31,220 --> 00:20:33,880 every machine's got a finite capacity for accepting connections. 294 00:20:34,200 --> 00:20:35,360 I mean, it's configured. 295 00:20:35,820 --> 00:20:37,260 Now, once you exceed that, 296 00:20:37,800 --> 00:20:40,180 any other connection that happens to come to the machine 297 00:20:40,180 --> 00:20:40,940 is going to get dropped. 298 00:20:40,940 --> 00:20:42,860 We'll look at SYN flooding a little later. 299 00:20:43,160 --> 00:20:44,860 Similarly, connection killing and hijacking. 300 00:20:44,960 --> 00:20:46,980 You have a running connection between two machines. 301 00:20:47,100 --> 00:20:48,360 I can actually try and break it. 302 00:20:49,040 --> 00:20:51,000 We'll look at both of these. 303 00:20:53,560 --> 00:20:54,000 Okay. 304 00:20:55,920 --> 00:20:58,120 They say you can't get too much of a good thing. 305 00:20:58,260 --> 00:21:00,640 So when you're doing a DOS all by yourself, 306 00:21:01,880 --> 00:21:05,460 the next logical step is to have a distributed denial of service 307 00:21:05,460 --> 00:21:07,060 where the principle is simple. 308 00:21:07,160 --> 00:21:08,560 It says united, we deny. 309 00:21:11,100 --> 00:21:13,740 A plain DOS will have a single point of launch. 310 00:21:13,920 --> 00:21:14,000 Okay. 311 00:21:14,060 --> 00:21:17,520 So if it is identified that there is a DOS happening 312 00:21:17,520 --> 00:21:19,360 from this particular machine off this network, 313 00:21:19,560 --> 00:21:21,080 it's easy to filter out those packets. 314 00:21:22,280 --> 00:21:24,800 Authorities which actually handle the links and route 315 00:21:24,800 --> 00:21:26,220 can also start dropping those packets. 316 00:21:27,480 --> 00:21:31,100 But in a DDoS, you have several launch points. 317 00:21:31,300 --> 00:21:33,160 So the typical accepted method is 318 00:21:33,160 --> 00:21:34,920 you compromise a huge number of machines 319 00:21:34,920 --> 00:21:36,340 based on bugs that may be there. 320 00:21:37,300 --> 00:21:38,540 On every compromise method, 321 00:21:38,540 --> 00:21:39,920 you set up a DOS client. 322 00:21:40,660 --> 00:21:44,400 The DOS client is triggered eventually with a DOS server. 323 00:21:44,620 --> 00:21:46,880 So what happens is at one point in time, 324 00:21:46,940 --> 00:21:52,180 I use my DDoS server to activate thousands of DDoS clients, 325 00:21:52,520 --> 00:21:55,140 all of which can then target a particular network 326 00:21:55,140 --> 00:21:59,120 or a host or whatever it is that you need to do. 327 00:22:05,780 --> 00:22:06,340 Okay. 328 00:22:07,020 --> 00:22:07,580 No. 329 00:22:08,540 --> 00:22:11,100 The benefits with a question mark 330 00:22:11,100 --> 00:22:13,040 depends on which side of the fence you are sitting. 331 00:22:13,320 --> 00:22:13,620 Okay. 332 00:22:13,620 --> 00:22:15,140 If you're the guy who's doing the DDoS, 333 00:22:15,220 --> 00:22:15,960 then these are benefits. 334 00:22:16,700 --> 00:22:18,520 You can now, I mean, 335 00:22:18,540 --> 00:22:20,180 disabling a few individual machines 336 00:22:20,180 --> 00:22:21,220 is not going to stop the attack. 337 00:22:21,460 --> 00:22:23,620 You can now target larger networks. 338 00:22:24,700 --> 00:22:26,520 About, I think, three years ago, 339 00:22:26,620 --> 00:22:29,620 when Netscape Corporation was still up and alive 340 00:22:29,620 --> 00:22:30,700 and, you know, really big, 341 00:22:30,840 --> 00:22:33,820 I remember reading somewhere that the total bandwidth 342 00:22:34,680 --> 00:22:37,300 that went into the Netscape Corporation's office 343 00:22:37,300 --> 00:22:40,800 was greater than the entire international bandwidth 344 00:22:40,800 --> 00:22:41,560 that India had. 345 00:22:42,600 --> 00:22:43,040 Okay. 346 00:22:43,740 --> 00:22:45,260 So in case I needed to, 347 00:22:45,280 --> 00:22:46,320 I mean, I was a Microsoft fan 348 00:22:46,320 --> 00:22:47,820 and I wanted to knock off Netscape, 349 00:22:47,880 --> 00:22:49,300 there was no way I could do anything about it 350 00:22:49,300 --> 00:22:50,280 using a DOS. 351 00:22:50,520 --> 00:22:52,460 But a DDoS may have been successful. 352 00:22:52,940 --> 00:22:55,600 We have had incidents where Yahoo, eBay, and stuff, 353 00:22:55,740 --> 00:22:59,380 big portals like that have been knocked off. 354 00:23:01,700 --> 00:23:02,140 Okay. 355 00:23:02,720 --> 00:23:03,740 Am I going too fast? 356 00:23:03,800 --> 00:23:04,460 Is the speed okay? 357 00:23:05,680 --> 00:23:06,120 Wonderful. 358 00:23:07,480 --> 00:23:09,380 The next thing we're looking at is sniffing. 359 00:23:11,760 --> 00:23:13,560 Most corporate networks, okay, 360 00:23:13,620 --> 00:23:14,440 are broadcast networks, 361 00:23:14,700 --> 00:23:16,620 which means when machines are talking to each other, 362 00:23:16,680 --> 00:23:17,340 there is a chance, 363 00:23:17,460 --> 00:23:19,800 I mean, everybody actually gets to see the broadcast. 364 00:23:20,300 --> 00:23:21,340 In the olden days, 365 00:23:21,400 --> 00:23:23,000 where you had physical cables connecting 366 00:23:23,000 --> 00:23:24,340 and you didn't have hubs and switches, 367 00:23:25,180 --> 00:23:26,720 it was truly broadcast. 368 00:23:27,000 --> 00:23:29,120 I mean, I could see and hear everything 369 00:23:29,120 --> 00:23:30,560 that happened on that particular network. 370 00:23:30,900 --> 00:23:32,080 Today, it's slightly different. 371 00:23:32,640 --> 00:23:34,760 Switches make it a little more difficult to sniff, 372 00:23:34,900 --> 00:23:36,740 but if they're non-configured, 373 00:23:36,740 --> 00:23:39,040 they can also be compromised, 374 00:23:39,200 --> 00:23:40,260 and you can sniff on it. 375 00:23:40,580 --> 00:23:42,500 The way it works is you have a sniffer program 376 00:23:42,500 --> 00:23:44,880 which puts your network interface card 377 00:23:44,880 --> 00:23:46,600 into something known as promiscuous mode. 378 00:23:47,400 --> 00:23:50,100 Normally, what happens is your machine is going to accept packets 379 00:23:50,100 --> 00:23:51,600 that are designed only for it. 380 00:23:52,200 --> 00:23:54,060 The minute it goes into promiscuous mode, 381 00:23:54,180 --> 00:23:57,140 it's going to accept any packet that travels past it, 382 00:23:57,220 --> 00:23:59,340 which is all the broadcast packets. 383 00:24:00,740 --> 00:24:02,440 The card will now accept the packet. 384 00:24:02,740 --> 00:24:05,220 It will push it up to the sniffer program, 385 00:24:05,360 --> 00:24:06,500 and the sniffer program, 386 00:24:06,740 --> 00:24:08,480 then decides and chooses packets 387 00:24:08,480 --> 00:24:09,640 that are of interest to it. 388 00:24:10,400 --> 00:24:12,100 What do you think we could use a sniffer for? 389 00:24:12,540 --> 00:24:13,740 Most obvious applications? 390 00:24:14,940 --> 00:24:16,120 Username and password. 391 00:24:16,300 --> 00:24:17,160 Username and password. 392 00:24:17,340 --> 00:24:17,800 What else? 393 00:24:20,220 --> 00:24:20,980 Email traffic. 394 00:24:21,240 --> 00:24:22,060 Email traffic. 395 00:24:22,220 --> 00:24:22,520 What else? 396 00:24:22,840 --> 00:24:23,700 Credit card numbers. 397 00:24:23,780 --> 00:24:24,760 Credit card numbers. 398 00:24:25,960 --> 00:24:26,480 Okay. 399 00:24:28,800 --> 00:24:31,480 All of you guys are on this negative trip. 400 00:24:31,700 --> 00:24:35,080 How about analyzing network traffic? 401 00:24:36,100 --> 00:24:36,620 Okay. 402 00:24:38,660 --> 00:24:42,500 The good guys really call the sniffer a network analyzer. 403 00:24:42,640 --> 00:24:43,860 I mean, but... 404 00:24:46,820 --> 00:24:47,380 Okay. 405 00:24:48,860 --> 00:24:50,200 Characteristics are it's passive. 406 00:24:50,300 --> 00:24:50,960 You're just listening. 407 00:24:51,020 --> 00:24:52,040 It's not really intruding. 408 00:24:52,120 --> 00:24:53,920 So it's fairly difficult to detect it. 409 00:24:57,440 --> 00:24:59,140 These are the users we talked about. 410 00:25:00,320 --> 00:25:00,880 Okay. 411 00:25:00,920 --> 00:25:06,060 If I log every byte that travels on the wire, 412 00:25:06,060 --> 00:25:07,420 where my machine is, 413 00:25:07,480 --> 00:25:09,540 in effect, it's a remote key logger. 414 00:25:10,760 --> 00:25:12,140 And the last two points, really. 415 00:25:12,800 --> 00:25:13,360 That's true. 416 00:25:13,500 --> 00:25:15,120 It helps to paint a very accurate picture 417 00:25:15,120 --> 00:25:15,920 of the network traffic. 418 00:25:20,980 --> 00:25:21,420 Okay. 419 00:25:22,520 --> 00:25:24,400 Often the only indications you'll have 420 00:25:24,400 --> 00:25:26,040 is when you see that hard disk light, 421 00:25:26,760 --> 00:25:28,760 you know, beaming and beeping frantically, 422 00:25:28,880 --> 00:25:30,540 and the CPU load going fairly high, 423 00:25:30,600 --> 00:25:32,880 because now this guy's accepting and processing all packets. 424 00:25:33,460 --> 00:25:34,920 So it has to write them somewhere 425 00:25:34,920 --> 00:25:35,860 if you're going to capture them, 426 00:25:35,860 --> 00:25:36,760 it has to process them, 427 00:25:36,800 --> 00:25:39,840 so the CPU is very active. 428 00:25:41,280 --> 00:25:42,140 Somebody might say, 429 00:25:42,200 --> 00:25:43,800 listen, what if I run a PS? 430 00:25:44,020 --> 00:25:44,700 You know, if I get a... 431 00:25:45,060 --> 00:25:46,280 Can I get a process listing? 432 00:25:46,460 --> 00:25:47,000 Yes, you can. 433 00:25:47,220 --> 00:25:48,860 But if the system has been compromised, 434 00:25:49,580 --> 00:25:52,580 these programs would have been trojaned and replaced. 435 00:25:53,100 --> 00:25:54,680 So you run a PSAX, 436 00:25:54,720 --> 00:25:56,060 and you would actually see all the processes 437 00:25:56,060 --> 00:25:57,320 minus the sniffer. 438 00:25:57,760 --> 00:25:59,340 You run an ifconfig, 439 00:25:59,380 --> 00:26:00,840 which actually checks the status 440 00:26:00,840 --> 00:26:02,620 of your network interface card, 441 00:26:02,760 --> 00:26:04,920 and you would see that it is not in promiscuous mode, 442 00:26:04,920 --> 00:26:06,480 whereas it really is. 443 00:26:13,440 --> 00:26:13,960 Okay. 444 00:26:16,020 --> 00:26:18,300 The first one is something that we've already 445 00:26:19,080 --> 00:26:21,460 talked about in the first slide, human spoofing. 446 00:26:21,480 --> 00:26:24,760 But in reality, it applies into the digital world also. 447 00:26:24,780 --> 00:26:26,820 The minute you pretend to be someone else, 448 00:26:27,040 --> 00:26:30,100 you've gone into what is termed as a spoofing attack. 449 00:26:30,540 --> 00:26:31,700 There are various types. 450 00:26:33,920 --> 00:26:35,940 IP, DNS, web, and... 451 00:26:38,180 --> 00:26:38,660 Okay. 452 00:26:39,640 --> 00:26:41,440 So what is IP spoofing, really? 453 00:26:42,200 --> 00:26:46,060 You forge the source IP of your first packet, 454 00:26:46,180 --> 00:26:46,980 of your connection packet, 455 00:26:47,100 --> 00:26:49,180 of the packet that's actually going to talk to people, 456 00:26:50,320 --> 00:26:52,380 with an IP address that is not yours, 457 00:26:52,920 --> 00:26:54,620 and you've spoofed, 458 00:26:54,620 --> 00:26:56,220 or you've pretended to be someone else. 459 00:26:56,540 --> 00:27:00,060 The typical method in which a hacker or a cracker 460 00:27:00,060 --> 00:27:01,200 might use this is to use, 461 00:27:01,700 --> 00:27:03,300 they use a denial of service attack 462 00:27:03,300 --> 00:27:05,180 to knock a particular machine off the network 463 00:27:05,680 --> 00:27:06,840 if it's not already off. 464 00:27:06,980 --> 00:27:08,320 I mean, if there's a machine off and you know 465 00:27:09,040 --> 00:27:10,460 that this machine's not alive 466 00:27:10,460 --> 00:27:11,800 and it cannot respond to packets, 467 00:27:12,040 --> 00:27:13,320 then you don't have to use a DOS, 468 00:27:13,400 --> 00:27:15,660 but otherwise you use a DOS, knock a machine off. 469 00:27:15,960 --> 00:27:17,420 You masquerade as the machine, 470 00:27:18,100 --> 00:27:19,280 talk to the target host. 471 00:27:19,860 --> 00:27:21,520 Because you're masquerading as the machine, 472 00:27:21,700 --> 00:27:24,380 if there is a trust relationship between these two machines, 473 00:27:24,480 --> 00:27:26,820 between the target and the machine which is now knocked off, 474 00:27:26,960 --> 00:27:28,620 you can exploit that trust relationship. 475 00:27:39,560 --> 00:27:43,960 A lot of these concepts and ideas really work together in harmony 476 00:27:43,960 --> 00:27:46,560 to create a completely successful attack. 477 00:27:47,080 --> 00:27:49,280 So when we talk of IP spoofing, 478 00:27:49,300 --> 00:27:52,320 I can use IP spoofing for SYN flooding 479 00:27:52,320 --> 00:27:54,680 and use that as a denial of service attack. 480 00:27:55,460 --> 00:27:58,120 The idea is, you have two machines A and B. 481 00:28:00,040 --> 00:28:01,880 This thing is termed as non-blind 482 00:28:01,880 --> 00:28:03,680 simply because it happens to be in the subnet. 483 00:28:03,760 --> 00:28:05,800 So I can actually see packets travelling between the two. 484 00:28:06,880 --> 00:28:09,100 Let's assume I knock A off the network. 485 00:28:09,420 --> 00:28:10,800 A can no longer respond. 486 00:28:12,240 --> 00:28:14,120 I've used a DOS or the machine is off 487 00:28:14,120 --> 00:28:15,100 or I know someone's not there. 488 00:28:15,340 --> 00:28:16,320 That machine is off. 489 00:28:16,420 --> 00:28:17,540 Now I want to target B. 490 00:28:18,160 --> 00:28:20,260 What I really do is I send it packets 491 00:28:21,100 --> 00:28:22,640 impersonating as machine A. 492 00:28:23,260 --> 00:28:25,480 Now really what's going to happen is every packet, 493 00:28:25,600 --> 00:28:27,200 every connection that is initiated 494 00:28:27,200 --> 00:28:29,540 is going to go with the SYN flag on. 495 00:28:29,840 --> 00:28:31,520 In my packet, it says I want to 496 00:28:32,000 --> 00:28:33,220 this is my initial packet. 497 00:28:33,340 --> 00:28:34,740 I want to synchronize the connection with you. 498 00:28:35,140 --> 00:28:36,280 B gets that connection. 499 00:28:37,100 --> 00:28:39,340 How many people have heard of the three-way handshake? 500 00:28:39,440 --> 00:28:40,400 TCP three-way handshake? 501 00:28:41,760 --> 00:28:44,620 So it's really exploiting the TCP three-way handshake. 502 00:28:45,640 --> 00:28:47,600 A packet supposed to have come from A 503 00:28:47,600 --> 00:28:49,180 goes to B with a SYN flag on. 504 00:28:49,580 --> 00:28:50,900 B accepts the connection. 505 00:28:51,320 --> 00:28:53,240 It responds back with its own packet 506 00:28:53,240 --> 00:28:55,220 saying that I'm also going to synchronize. 507 00:28:55,240 --> 00:28:56,500 This is my initial sequence number. 508 00:28:56,500 --> 00:28:58,020 Switches on his SYN flag. 509 00:28:58,280 --> 00:29:01,240 And he acknowledges the first packet from A. 510 00:29:01,540 --> 00:29:03,680 Now in reality, A is not alive. 511 00:29:04,500 --> 00:29:06,600 So this packet has gone back to A. 512 00:29:06,840 --> 00:29:09,880 If A were alive, A would respond with its own acknowledgement. 513 00:29:11,100 --> 00:29:12,260 One, two, three. 514 00:29:12,340 --> 00:29:13,940 The three-way handshake would have taken place 515 00:29:13,940 --> 00:29:15,420 and that would be the start of the connection. 516 00:29:15,760 --> 00:29:17,360 Now since A is not on, 517 00:29:17,820 --> 00:29:19,900 B is going to go into a timeout stage. 518 00:29:20,380 --> 00:29:23,100 Now while B is waiting for an acknowledgement to come, 519 00:29:23,220 --> 00:29:24,700 he's actually got a data 520 00:29:24,700 --> 00:29:29,300 a data buffer in memory 521 00:29:29,300 --> 00:29:31,840 which logs the state of all connections 522 00:29:31,840 --> 00:29:32,940 that are still pending, 523 00:29:33,140 --> 00:29:35,360 all connections that have not been picked up by the application. 524 00:29:35,660 --> 00:29:38,220 Now this queue, which we will call the backlog, 525 00:29:38,460 --> 00:29:39,520 is of finite size. 526 00:29:40,400 --> 00:29:42,600 If I can send enough SYN connections 527 00:29:42,600 --> 00:29:44,180 and fill up this queue, 528 00:29:44,720 --> 00:29:47,760 B is actually going to be waiting in that particular state 529 00:29:47,760 --> 00:29:49,500 and not accepting any more connections 530 00:29:49,500 --> 00:29:51,060 until all of them timeout. 531 00:29:51,840 --> 00:29:53,840 Now eventually they will timeout 532 00:29:53,840 --> 00:29:55,260 and B will start accepting connections, 533 00:29:55,520 --> 00:29:57,720 but it's trivial for me to keep initiating 534 00:29:57,720 --> 00:29:59,000 new connections every few seconds. 535 00:29:59,780 --> 00:30:00,260 Okay? 536 00:30:00,360 --> 00:30:02,420 So this is called a SYN flooding attack. 537 00:30:02,720 --> 00:30:04,160 B is completely knocked off. 538 00:30:08,140 --> 00:30:09,540 Okay, this is the problem. 539 00:30:10,360 --> 00:30:11,000 One second. 540 00:30:26,160 --> 00:30:26,640 Okay. 541 00:30:27,000 --> 00:30:29,700 You can see that A has been knocked off. 542 00:30:29,960 --> 00:30:31,560 Host X impersonates A. 543 00:30:32,460 --> 00:30:34,640 It causes the backlog of B to be exceeded 544 00:30:34,640 --> 00:30:36,520 and B won't accept any more connections. 545 00:30:36,640 --> 00:30:37,680 So you've just done a DOS 546 00:30:37,680 --> 00:30:39,920 using SYN flooding and IP spoofing. 547 00:30:41,540 --> 00:30:42,020 Okay. 548 00:30:43,320 --> 00:30:45,000 Now you can use the same principle 549 00:30:45,000 --> 00:30:47,140 to actually kill an active connection 550 00:30:47,140 --> 00:30:48,040 between two machines. 551 00:30:50,260 --> 00:30:53,480 You know that TCP maintains its so-called reliability 552 00:30:53,840 --> 00:30:55,640 based on sequence numbers and acknowledgments 553 00:30:55,640 --> 00:30:56,780 between an active connection. 554 00:30:57,080 --> 00:31:00,400 The sequence numbers actually allow machines 555 00:31:00,400 --> 00:31:04,040 to put out-of-order information back into order, 556 00:31:04,160 --> 00:31:05,320 to discard duplicates, 557 00:31:05,340 --> 00:31:07,100 to make sure the connection is being established 558 00:31:07,100 --> 00:31:08,240 with a three-way handshake, 559 00:31:08,400 --> 00:31:10,060 breaking with a four-way exchange, 560 00:31:10,200 --> 00:31:11,000 and so on and so forth. 561 00:31:11,440 --> 00:31:15,040 If I can now compute the sequence and acknowledgments 562 00:31:15,040 --> 00:31:17,740 of packets as they travel past my machine, 563 00:31:17,800 --> 00:31:18,780 so I sniff the packets, 564 00:31:19,020 --> 00:31:21,940 I compute the sequence numbers that are happening, 565 00:31:21,940 --> 00:31:25,680 and let's say that I want to now terminate this connection. 566 00:31:26,180 --> 00:31:29,280 I can create a packet with the reset flag on, 567 00:31:29,360 --> 00:31:30,060 the RST flag. 568 00:31:30,260 --> 00:31:31,940 The RST flag, when it is received, 569 00:31:32,780 --> 00:31:35,300 only needs to have the correct sequence number. 570 00:31:35,680 --> 00:31:36,160 Okay? 571 00:31:36,300 --> 00:31:38,440 The machine that receives this flag, 572 00:31:38,520 --> 00:31:39,840 for that machine, 573 00:31:39,900 --> 00:31:41,520 it's a signal to tear down the connection immediately. 574 00:31:42,320 --> 00:31:45,140 So you have A and B running a connection 575 00:31:45,140 --> 00:31:46,780 which is live in real time. 576 00:31:47,020 --> 00:31:48,860 I'm sniffing the packets as they go through. 577 00:31:49,120 --> 00:31:50,820 I compute the sequence number. 578 00:31:50,820 --> 00:31:54,060 I create a fresh packet with the expected sequence number 579 00:31:54,060 --> 00:31:54,960 for, let's say, B. 580 00:31:55,560 --> 00:31:57,280 I set the reset flag to on, 581 00:31:57,340 --> 00:31:58,500 and I inject it onto the network. 582 00:31:59,260 --> 00:32:00,940 Now, if your computation is correct, 583 00:32:01,040 --> 00:32:01,840 if the timing is correct, 584 00:32:01,940 --> 00:32:02,960 if nothing really goes wrong, 585 00:32:03,120 --> 00:32:04,380 B is going to accept this. 586 00:32:04,460 --> 00:32:05,820 It's going to see the reset flag down. 587 00:32:05,960 --> 00:32:07,600 It's going to tear down that connection instantly. 588 00:32:08,280 --> 00:32:10,860 All of the packets that come from A into B 589 00:32:10,860 --> 00:32:12,180 are simply going to be discarded 590 00:32:12,180 --> 00:32:13,940 because they will be assumed as bogus. 591 00:32:14,040 --> 00:32:15,920 In fact, we might even send a reset back. 592 00:32:16,580 --> 00:32:16,980 Okay? 593 00:32:17,000 --> 00:32:19,180 So we will call this an evil reset flag. 594 00:32:19,520 --> 00:32:20,800 Now, you could do the same thing 595 00:32:20,800 --> 00:32:22,000 using the fin flag, 596 00:32:24,140 --> 00:32:26,960 where when a machine legitimately wants 597 00:32:26,960 --> 00:32:27,900 to shut down a connection, 598 00:32:28,020 --> 00:32:29,400 it actually switches the fin on, 599 00:32:29,520 --> 00:32:31,680 sends the packet to the remote machine. 600 00:32:31,940 --> 00:32:33,780 The remote machine acknowledges it, 601 00:32:33,840 --> 00:32:35,820 and when he is through with whatever he wants to do, 602 00:32:35,880 --> 00:32:37,000 he sends his own fin back. 603 00:32:37,240 --> 00:32:39,900 So just the way a three-way handshake sets up a connection, 604 00:32:40,120 --> 00:32:41,960 a four-way transaction breaks the connection. 605 00:32:42,420 --> 00:32:42,860 Okay? 606 00:32:42,920 --> 00:32:45,040 The beauty of using a fin instead of a reset is 607 00:32:45,040 --> 00:32:47,180 you will always get an acknowledgement back 608 00:32:47,180 --> 00:32:48,020 from the remote guy. 609 00:32:48,620 --> 00:32:50,540 So if I've injected a fin inside, 610 00:32:50,800 --> 00:32:52,720 and for some reason I don't get an acknowledgement, 611 00:32:52,860 --> 00:32:54,580 I don't sniff the acknowledgement from B, 612 00:32:54,720 --> 00:32:56,020 I know something went wrong, 613 00:32:56,100 --> 00:32:58,160 and I can attempt to do that again. 614 00:32:58,920 --> 00:33:00,160 But the principle is the same. 615 00:33:05,580 --> 00:33:08,720 Okay, now you take this one step higher logically. 616 00:33:09,320 --> 00:33:11,180 If I can kill a connection, 617 00:33:12,380 --> 00:33:14,220 why can't I hijack a connection? 618 00:33:15,740 --> 00:33:18,300 So let's assume you've telneted into a particular machine. 619 00:33:18,680 --> 00:33:20,000 You're running a shell over there. 620 00:33:20,000 --> 00:33:21,580 Someone from A has telneted into B. 621 00:33:22,140 --> 00:33:24,360 Why can't I, you know, 622 00:33:24,380 --> 00:33:26,560 get in and actually take over the connection 623 00:33:26,560 --> 00:33:27,460 and pretend to be A? 624 00:33:28,460 --> 00:33:29,040 You can. 625 00:33:29,560 --> 00:33:31,160 The way to do it here is 626 00:33:31,160 --> 00:33:33,200 to compute the sequence number and acknowledgement. 627 00:33:34,580 --> 00:33:35,020 Yeah? 628 00:33:36,020 --> 00:33:37,960 So as a result, what will happen is 629 00:33:37,960 --> 00:33:40,300 A will continue transmitting what it had to transmit, 630 00:33:40,440 --> 00:33:42,480 but since B has updated his counter, 631 00:33:42,720 --> 00:33:45,480 he's going to treat those packets as bogus packets, 632 00:33:45,720 --> 00:33:47,380 which leaves A completely confused. 633 00:33:47,660 --> 00:33:49,200 Your packets are traveling to B. 634 00:33:49,200 --> 00:33:50,940 Your packets have got the correct sequence numbers. 635 00:33:51,140 --> 00:33:52,980 TCP only cares about the sequence numbers. 636 00:33:53,140 --> 00:33:54,580 That's how it's maintaining reliability. 637 00:33:55,420 --> 00:33:58,040 And in effect, you have actually taken over that connection. 638 00:33:58,460 --> 00:34:00,620 So if this were a shell that were running there, 639 00:34:00,780 --> 00:34:02,980 you could simply install a backdoor program, 640 00:34:03,100 --> 00:34:05,220 or if the R commands have been enabled, 641 00:34:05,300 --> 00:34:08,260 you could set up a .ros file with a plus plus inside it, 642 00:34:08,380 --> 00:34:09,360 break the connection. 643 00:34:09,720 --> 00:34:12,180 The guy who's sitting on A will probably think, 644 00:34:12,280 --> 00:34:13,940 you know, I mean, if he's dialed in, for example, 645 00:34:14,020 --> 00:34:15,840 or it's a bad connection or the program's hung, 646 00:34:15,980 --> 00:34:17,480 normally people kind of break it 647 00:34:17,480 --> 00:34:19,360 and just log in again. 648 00:34:19,880 --> 00:34:22,360 So, I mean, real-life breaks do happen. 649 00:34:22,460 --> 00:34:24,240 Just because the thing happens to break 650 00:34:24,240 --> 00:34:25,420 doesn't mean you've been hijacked, 651 00:34:25,560 --> 00:34:30,420 but these are ways in which people could take over a running connection. 652 00:34:41,060 --> 00:34:43,540 Any particular questions so far? 653 00:34:46,720 --> 00:34:48,240 Does that mean everybody's understanding, 654 00:34:48,420 --> 00:34:49,520 or does that mean you're not understanding? 655 00:34:50,780 --> 00:34:51,940 I'm not going to ask that one. 656 00:34:51,980 --> 00:34:52,160 Okay. 657 00:34:54,360 --> 00:34:57,600 Okay, this one is, as you can see, 658 00:34:57,640 --> 00:34:59,760 it's based on a technical report at Princeton University, 659 00:35:00,520 --> 00:35:01,800 which happened in 1997. 660 00:35:03,400 --> 00:35:06,380 But I believe it is so applicable in real life, 661 00:35:06,420 --> 00:35:07,420 the thoughts and the principles, 662 00:35:07,560 --> 00:35:10,660 that this is something that I would be very happy to share with you. 663 00:35:12,560 --> 00:35:13,520 The idea is, 664 00:35:13,540 --> 00:35:14,620 the idea in web spoofing is 665 00:35:15,100 --> 00:35:18,980 that the attacker actually creates a shadow copy of the web. 666 00:35:19,480 --> 00:35:19,880 Okay? 667 00:35:19,940 --> 00:35:21,200 And if you are a victim, 668 00:35:21,800 --> 00:35:22,760 when you are surfing, 669 00:35:23,400 --> 00:35:26,220 you actually believe you're surfing the real World Wide Web, 670 00:35:26,760 --> 00:35:29,940 whereas you are actually surfing the web that has been set up by the attacker. 671 00:35:30,920 --> 00:35:33,440 Okay, I can almost say the first question, 672 00:35:33,560 --> 00:35:34,100 somebody says, 673 00:35:34,200 --> 00:35:36,380 hey, you mean somebody's going to copy the entire World Wide Web? 674 00:35:36,560 --> 00:35:37,620 No, it's not like that. 675 00:35:37,980 --> 00:35:39,760 We will look at what really happens here. 676 00:35:40,840 --> 00:35:41,880 If you look at the point, 677 00:35:41,880 --> 00:35:43,040 the second point, 678 00:35:43,160 --> 00:35:44,840 you know, it's applicable for all spoofing. 679 00:35:44,860 --> 00:35:46,020 Spoofing is like a con game. 680 00:35:46,220 --> 00:35:48,920 You set up an environment which is convincing, 681 00:35:49,620 --> 00:35:51,460 but simply because you're doing spoofing, 682 00:35:51,480 --> 00:35:52,420 it's really a false environment. 683 00:35:53,020 --> 00:35:55,220 And based on how well you set up that environment, 684 00:35:55,600 --> 00:35:57,620 you're going to affect the behavior of the victim, 685 00:35:58,120 --> 00:35:59,860 completely based on contextual cues. 686 00:36:05,380 --> 00:36:05,820 Okay. 687 00:36:06,980 --> 00:36:08,780 Now, if this is successful, 688 00:36:09,120 --> 00:36:09,840 what does it do? 689 00:36:09,940 --> 00:36:11,260 What really happens? 690 00:36:11,260 --> 00:36:15,100 This will influence all security-relevant decisions 691 00:36:15,100 --> 00:36:16,480 that the victim is going to make. 692 00:36:16,620 --> 00:36:17,980 When I say security-relevant, 693 00:36:18,060 --> 00:36:18,920 what am I talking about? 694 00:36:19,000 --> 00:36:20,420 I'm talking about names and passwords. 695 00:36:20,680 --> 00:36:21,940 You might want to log into a service. 696 00:36:22,120 --> 00:36:23,640 You might give credit card information. 697 00:36:23,960 --> 00:36:25,580 You might accept documents. 698 00:36:25,920 --> 00:36:28,940 And we've already seen the dangers of, 699 00:36:28,960 --> 00:36:31,600 you know, let's say viruses or malicious programs 700 00:36:31,600 --> 00:36:32,760 being embedded in documents. 701 00:36:33,540 --> 00:36:35,380 You might accept the accuracy of information. 702 00:36:35,720 --> 00:36:36,500 So if you're trading, 703 00:36:36,880 --> 00:36:39,440 and you actually are looking at a website which says 704 00:36:39,440 --> 00:36:41,240 the shares or the, you know, 705 00:36:41,240 --> 00:36:42,780 the prices of, you know, whatever, 706 00:36:42,940 --> 00:36:44,980 VA Linux or Microsoft have gone up or down, 707 00:36:45,100 --> 00:36:46,860 and you base decisions based on that, 708 00:36:46,980 --> 00:36:48,800 these are all security-relevant decisions. 709 00:36:49,140 --> 00:36:51,520 And all of these will be affected 710 00:36:51,520 --> 00:36:53,080 in this kind of an attack. 711 00:36:58,720 --> 00:36:59,900 So why does it work? 712 00:37:00,100 --> 00:37:02,240 Okay, this works because the attacker 713 00:37:02,240 --> 00:37:04,360 has very intelligently used context. 714 00:37:04,880 --> 00:37:06,320 When you're surfing the web, 715 00:37:06,400 --> 00:37:09,160 most experienced servers behave like drivers. 716 00:37:09,580 --> 00:37:09,800 Okay? 717 00:37:09,880 --> 00:37:10,760 So you're driving the road. 718 00:37:11,240 --> 00:37:11,600 You're really thinking, 719 00:37:11,800 --> 00:37:14,200 I need to press the, okay, 720 00:37:14,300 --> 00:37:16,460 most of you guys drive automatic transmission, 721 00:37:16,620 --> 00:37:17,780 so I don't need to press, you know, 722 00:37:17,820 --> 00:37:20,080 the clutch now or the brake now and stuff like that. 723 00:37:20,120 --> 00:37:20,840 Somebody runs across. 724 00:37:21,020 --> 00:37:21,780 You jam it. 725 00:37:21,840 --> 00:37:22,400 It's all automatic. 726 00:37:22,700 --> 00:37:24,700 Now, exactly in the same fashion, 727 00:37:25,460 --> 00:37:27,540 you go to a website or you see a logo 728 00:37:27,540 --> 00:37:29,080 that materializes in front of you, 729 00:37:29,140 --> 00:37:31,460 and the mind has subconsciously accepted 730 00:37:31,460 --> 00:37:33,340 that you're connected to the server you want to connect. 731 00:37:34,100 --> 00:37:35,880 Okay, so the appearance of the object, 732 00:37:36,120 --> 00:37:37,440 the name of the object, 733 00:37:37,960 --> 00:37:38,760 manual.doc. 734 00:37:38,800 --> 00:37:40,860 Is manual.doc the manual 735 00:37:40,860 --> 00:37:42,840 for the software that you have just downloaded, 736 00:37:43,060 --> 00:37:45,000 or is it something else altogether? 737 00:37:45,280 --> 00:37:46,740 For all you know, it might be an executable. 738 00:37:47,340 --> 00:37:48,720 Finally, the timing of events. 739 00:37:49,040 --> 00:37:52,000 If I fed in www.mybank.com 740 00:37:52,440 --> 00:37:55,060 and I get a pop-up which says name and password, 741 00:37:56,100 --> 00:37:57,820 simply because of the timing of events, 742 00:37:57,900 --> 00:37:59,760 I am going to enter the name and the password 743 00:37:59,760 --> 00:38:03,160 that is my login into this particular bank. 744 00:38:09,400 --> 00:38:10,700 Now, if all of these happen, 745 00:38:10,700 --> 00:38:13,540 what are the dangers that are alive? 746 00:38:13,780 --> 00:38:14,660 Surveillance, obviously. 747 00:38:15,280 --> 00:38:15,760 Tampering. 748 00:38:16,720 --> 00:38:19,960 That brand new Dell or whatever that you order, 749 00:38:20,080 --> 00:38:22,940 if I could change the delivery address to mine, 750 00:38:23,100 --> 00:38:24,620 then you've paid for my machine. 751 00:38:24,920 --> 00:38:27,920 And quantity numbers and product numbers 752 00:38:27,920 --> 00:38:28,600 and so on and so forth, 753 00:38:28,640 --> 00:38:29,480 anything can take place. 754 00:38:31,040 --> 00:38:31,520 Okay. 755 00:38:31,820 --> 00:38:33,560 Now, let's look at how it really works. 756 00:38:36,600 --> 00:38:38,120 These are the principles on which 757 00:38:38,120 --> 00:38:39,960 this particular spoofing attack will work. 758 00:38:40,460 --> 00:38:43,060 It's termed as a man-in-the-middle attack. 759 00:38:43,920 --> 00:38:45,360 I'm not sexist. 760 00:38:45,380 --> 00:38:46,440 I didn't coin this phrase. 761 00:38:46,620 --> 00:38:48,120 It could be a woman-in-the-middle attack. 762 00:38:49,820 --> 00:38:53,740 But the idea is here is the victim, 763 00:38:53,940 --> 00:38:56,900 here is the desired web URL, 764 00:38:57,060 --> 00:38:58,160 and in the middle is the attacker. 765 00:38:58,460 --> 00:39:00,560 So it's a man-in-the-middle attack between a client server. 766 00:39:00,860 --> 00:39:03,240 It works on URL rewriting. 767 00:39:03,900 --> 00:39:07,620 So if you go to www.hotmail.com, 768 00:39:08,340 --> 00:39:09,780 the page is fetched. 769 00:39:09,780 --> 00:39:11,460 The URL on that page is, 770 00:39:11,500 --> 00:39:13,400 all URLs on that page are rewritten to, 771 00:39:13,440 --> 00:39:15,880 let's say, www.attacker.org 772 00:39:15,880 --> 00:39:20,240 slash www.microsoft.com, whatever else. 773 00:39:20,520 --> 00:39:23,500 So every subsequent click on a link 774 00:39:23,500 --> 00:39:25,660 will actually go to the attacker's machine first. 775 00:39:26,040 --> 00:39:27,960 From there, it will go out to the real web. 776 00:39:28,080 --> 00:39:30,220 And then information would come back to you 777 00:39:30,560 --> 00:39:31,720 after having been tampered. 778 00:39:32,160 --> 00:39:34,780 Now, this would work completely with forms 779 00:39:34,780 --> 00:39:36,760 because forms are so closely integrated 780 00:39:36,760 --> 00:39:37,740 with the web protocols. 781 00:39:37,740 --> 00:39:41,200 You might even see a secure connection indicator light up. 782 00:39:41,240 --> 00:39:44,180 Let's say Hotmail now gives you a secure connection 783 00:39:44,180 --> 00:39:45,100 into your email box. 784 00:39:45,820 --> 00:39:47,720 Now, sure, you have a secure connection. 785 00:39:48,000 --> 00:39:50,280 The only difference is your secure connection 786 00:39:50,280 --> 00:39:52,920 is between your machine and the attacker's machine. 787 00:39:53,280 --> 00:39:54,720 It's not between you and Hotmail. 788 00:39:54,860 --> 00:39:56,160 It's between you and the attacker, 789 00:39:56,240 --> 00:39:59,320 and you have the secure connection, the lock, going up. 790 00:40:05,980 --> 00:40:07,720 So how would this attack actually work? 791 00:40:07,740 --> 00:40:07,920 How would you start? 792 00:40:08,280 --> 00:40:09,600 You know, how would you begin it? 793 00:40:10,200 --> 00:40:12,420 You would need to have a false link 794 00:40:13,320 --> 00:40:14,560 on some web page. 795 00:40:15,180 --> 00:40:18,480 You could transmit a false link using webmail 796 00:40:18,480 --> 00:40:19,840 where you've got HTML enabled. 797 00:40:20,620 --> 00:40:22,720 Or you could even have a poisoned search engine. 798 00:40:22,820 --> 00:40:25,540 For example, a search engine has actually indexed a page 799 00:40:25,540 --> 00:40:27,400 which seems to contain good information 800 00:40:27,400 --> 00:40:29,540 but really serves as a starting point 801 00:40:29,540 --> 00:40:30,580 for this kind of an attack. 802 00:40:39,520 --> 00:40:39,920 Okay. 803 00:40:41,240 --> 00:40:41,640 Okay. 804 00:40:41,780 --> 00:40:43,040 Let's assume the attack is on. 805 00:40:44,120 --> 00:40:46,620 The way I've described it so far is fairly effective. 806 00:40:46,840 --> 00:40:47,000 Okay? 807 00:40:47,040 --> 00:40:47,720 It would work. 808 00:40:47,780 --> 00:40:50,080 It would be able to take your request. 809 00:40:50,360 --> 00:40:52,700 It would be able to pull out your request from the web, 810 00:40:53,160 --> 00:40:54,440 translate each of the URLs, 811 00:40:54,600 --> 00:40:55,780 and feed that back to you. 812 00:40:56,300 --> 00:40:58,560 But the attack, the way we've talked about, 813 00:40:58,720 --> 00:40:59,380 is not perfect. 814 00:41:00,740 --> 00:41:02,120 Can anybody tell me what... 815 00:41:02,120 --> 00:41:04,440 There are still contextual cues that will tell the victim 816 00:41:04,440 --> 00:41:05,440 he or she is being attacked. 817 00:41:06,020 --> 00:41:06,820 Things like... 818 00:41:08,440 --> 00:41:08,920 Sorry. 819 00:41:09,140 --> 00:41:10,160 Malformed URL, yes. 820 00:41:10,500 --> 00:41:11,160 What else? 821 00:41:13,600 --> 00:41:14,720 Doesn't anybody surf? 822 00:41:16,180 --> 00:41:17,720 You guys are experienced surfers. 823 00:41:17,800 --> 00:41:17,960 Okay. 824 00:41:18,320 --> 00:41:19,020 It's simple. 825 00:41:19,700 --> 00:41:22,060 Every time you move your cursor over a link, 826 00:41:22,140 --> 00:41:23,400 when it turns into a hand, 827 00:41:23,580 --> 00:41:25,280 you have the status line at the bottom 828 00:41:25,280 --> 00:41:26,760 that would reflect the link. 829 00:41:26,820 --> 00:41:29,500 So you would actually see www.attacker.org 830 00:41:29,500 --> 00:41:31,280 slash the real server. 831 00:41:32,060 --> 00:41:33,740 Every time you click on a link, 832 00:41:34,560 --> 00:41:36,320 for a brief instant, 833 00:41:36,420 --> 00:41:37,640 as the browser makes a connection, 834 00:41:37,640 --> 00:41:38,960 to the remote machine, 835 00:41:39,040 --> 00:41:41,020 you will actually see connecting to www.attacker.org. 836 00:41:41,280 --> 00:41:43,780 Now these are things which the victim could see 837 00:41:43,780 --> 00:41:45,120 and realize something is going wrong. 838 00:41:45,680 --> 00:41:47,860 So as an attacker, what do you do? 839 00:41:48,720 --> 00:41:50,560 You fall back on the premise that 840 00:41:51,360 --> 00:41:54,840 the major browser makers have made life comfortable for you. 841 00:41:55,140 --> 00:41:56,960 They've let the browser be very customizable. 842 00:41:57,340 --> 00:42:00,240 So you embed a piece of JavaScript into your page. 843 00:42:01,160 --> 00:42:03,240 JavaScript is allowed to write to the status line. 844 00:42:04,120 --> 00:42:06,840 So this piece of JavaScript is now going to get rid of 845 00:42:06,840 --> 00:42:07,620 both of these problems. 846 00:42:07,620 --> 00:42:10,140 Every time I hover my cursor over a link, 847 00:42:10,340 --> 00:42:12,120 it's not going to show www.attacker.org 848 00:42:12,120 --> 00:42:12,880 slash whatever. 849 00:42:13,060 --> 00:42:15,460 It's going to show me what I really expect to see. 850 00:42:15,740 --> 00:42:17,140 Every time I click the link, 851 00:42:17,260 --> 00:42:19,360 although the browser is connecting to my machine, 852 00:42:19,520 --> 00:42:20,940 to the attacker's machine, 853 00:42:21,140 --> 00:42:23,980 it actually shows a connection to the target 854 00:42:23,980 --> 00:42:25,220 that you really want to reach. 855 00:42:25,620 --> 00:42:27,700 So you've overcome obstacle number one. 856 00:42:28,640 --> 00:42:30,000 Any other things you can think of 857 00:42:30,000 --> 00:42:30,780 that might be a problem? 858 00:42:31,540 --> 00:42:33,500 That might give the victim an indication 859 00:42:33,500 --> 00:42:34,660 of the attack in progress? 860 00:42:37,700 --> 00:42:39,160 There's something even easier than that. 861 00:42:41,320 --> 00:42:41,760 Yeah? 862 00:42:46,280 --> 00:42:46,840 I'm sorry. 863 00:42:46,920 --> 00:42:47,500 I can't hear you. 864 00:42:50,660 --> 00:42:51,100 Right. 865 00:42:51,480 --> 00:42:51,920 Sure. 866 00:42:52,060 --> 00:42:53,480 I'll come to SSL in a moment. 867 00:42:53,540 --> 00:42:53,660 Yeah. 868 00:42:54,600 --> 00:42:55,040 Okay. 869 00:42:56,160 --> 00:42:56,600 Okay. 870 00:42:57,280 --> 00:42:59,700 Once you are connected to a particular site, 871 00:42:59,820 --> 00:43:01,520 if you realize the top bar, 872 00:43:01,600 --> 00:43:02,440 the location line, 873 00:43:02,500 --> 00:43:04,380 actually shows the page that you are on. 874 00:43:04,420 --> 00:43:04,640 You can see that the location line 875 00:43:04,660 --> 00:43:06,540 in this case, 876 00:43:06,580 --> 00:43:08,520 even though the status line has not given me any clues, 877 00:43:08,700 --> 00:43:11,140 will actually show me that I am at attacker.org 878 00:43:11,660 --> 00:43:12,680 slash whatever else. 879 00:43:13,360 --> 00:43:15,460 Once again, JavaScript comes to the rescue. 880 00:43:15,640 --> 00:43:18,880 You can actually replace the location line completely. 881 00:43:19,540 --> 00:43:22,740 And the people who did this study in Princeton, 882 00:43:22,840 --> 00:43:23,500 who did this report, 883 00:43:23,600 --> 00:43:25,480 they actually made a working model of this thing. 884 00:43:25,720 --> 00:43:28,740 So the location line also reflected the correct URL. 885 00:43:29,260 --> 00:43:31,160 The next question most people ask is, 886 00:43:31,180 --> 00:43:33,080 listen, what happens if I go and feed in information 887 00:43:33,080 --> 00:43:34,100 into the location line? 888 00:43:34,100 --> 00:43:35,420 Again, very valid. 889 00:43:35,600 --> 00:43:37,820 The JavaScript will allow me to accept info. 890 00:43:38,320 --> 00:43:41,340 So I say www.hotmail.com 891 00:43:41,340 --> 00:43:42,600 simply because we're talking Hotmail. 892 00:43:43,080 --> 00:43:45,580 Internally, this guy will make a connection via attacker.org. 893 00:43:46,020 --> 00:43:48,780 So you've suddenly eliminated all visual trace. 894 00:43:49,680 --> 00:43:50,180 Okay. 895 00:43:50,200 --> 00:43:51,860 There is one more thing that you could do, 896 00:43:51,900 --> 00:43:52,860 as the gentleman here mentioned. 897 00:43:53,040 --> 00:43:55,680 What happens if I view the document source? 898 00:43:56,620 --> 00:43:58,840 The document source is going to show me the presence 899 00:43:58,840 --> 00:44:00,500 of both of these pieces of JavaScript. 900 00:44:01,480 --> 00:44:03,400 And immediately, the attack is known. 901 00:44:04,400 --> 00:44:06,340 My question is, in real life, 902 00:44:06,520 --> 00:44:08,980 how many of you view the document source 903 00:44:08,980 --> 00:44:10,420 every time you visit a website? 904 00:44:12,600 --> 00:44:13,380 Not too many. 905 00:44:13,700 --> 00:44:17,440 Let's assume for a moment that all of us got paranoid 906 00:44:17,440 --> 00:44:19,000 when we went away after this presentation 907 00:44:19,000 --> 00:44:21,240 and we started viewing the document source 908 00:44:21,240 --> 00:44:23,620 of every page we visited for the next three days. 909 00:44:24,260 --> 00:44:26,080 For the moment, hypothetically. 910 00:44:27,700 --> 00:44:30,660 Now, it would be very clear that there's something going wrong here. 911 00:44:31,100 --> 00:44:31,240 Okay? 912 00:44:31,720 --> 00:44:32,480 Once again, 913 00:44:32,480 --> 00:44:34,100 JavaScript is your friend. 914 00:44:34,620 --> 00:44:35,920 What these guys did was, 915 00:44:35,980 --> 00:44:38,000 they replaced the menu button on top, 916 00:44:38,200 --> 00:44:39,020 the menu drop-down, 917 00:44:40,320 --> 00:44:42,620 which shows view document source, 918 00:44:42,900 --> 00:44:44,340 and they embedded their own stuff. 919 00:44:44,680 --> 00:44:47,020 So when you went and actually clicked on view document source, 920 00:44:47,300 --> 00:44:49,760 this guy showed you the real page that had come from the web, 921 00:44:50,720 --> 00:44:53,380 minus the attacker URL rewritten links, 922 00:44:54,680 --> 00:44:56,660 and the illusion was complete. 923 00:44:57,040 --> 00:44:57,480 Okay? 924 00:44:57,500 --> 00:44:58,660 There was no way to get out of it. 925 00:45:02,480 --> 00:45:02,800 Okay? 926 00:45:02,880 --> 00:45:06,720 So this is completing the illusion. 927 00:45:06,900 --> 00:45:09,500 This encapsulates the points we just spoke about. 928 00:45:17,960 --> 00:45:20,140 The remedies that were suggested are things like, 929 00:45:20,200 --> 00:45:20,340 you know, 930 00:45:20,340 --> 00:45:21,100 disable JavaScript, 931 00:45:21,460 --> 00:45:22,320 be very alert, 932 00:45:22,460 --> 00:45:23,540 look at the URL lines, 933 00:45:23,760 --> 00:45:24,880 look at the location lines. 934 00:45:26,280 --> 00:45:28,160 They recommended software enhancements. 935 00:45:28,180 --> 00:45:29,820 So when you're doing an SSL kind of connect, 936 00:45:29,940 --> 00:45:31,440 instead of simply having an indicator 937 00:45:31,440 --> 00:45:32,180 which kind of, 938 00:45:32,200 --> 00:45:32,820 you know, 939 00:45:32,860 --> 00:45:34,000 you have a lock which is on, 940 00:45:34,100 --> 00:45:36,020 how about if that guy actually said, 941 00:45:36,120 --> 00:45:37,880 I am connected to Microsoft.com, 942 00:45:37,960 --> 00:45:41,120 because your information exchange 943 00:45:41,120 --> 00:45:42,720 would have that kind of information. 944 00:45:45,920 --> 00:45:46,600 I'm sure. 945 00:45:53,280 --> 00:45:53,800 That's true. 946 00:45:54,160 --> 00:45:55,720 I completely agree. 947 00:45:55,840 --> 00:45:56,360 See, it's a, 948 00:45:57,240 --> 00:45:59,540 unfortunately there are these two things, 949 00:45:59,620 --> 00:46:00,380 the good and the evil. 950 00:46:01,000 --> 00:46:01,400 Sorry. 951 00:46:01,440 --> 00:46:03,660 But you have a lot of good with JavaScript. 952 00:46:03,880 --> 00:46:04,560 I understand that. 953 00:46:04,680 --> 00:46:06,660 All I'm saying is that the same tool 954 00:46:06,660 --> 00:46:08,120 can be utilized for evil also. 955 00:46:08,460 --> 00:46:09,880 So somewhere it's a fine line, 956 00:46:09,960 --> 00:46:10,880 somewhere you kind of decide, 957 00:46:11,000 --> 00:46:11,140 you know. 958 00:46:11,220 --> 00:46:11,380 I mean, 959 00:46:11,880 --> 00:46:14,220 if you know nobody's really going to target your grandmom 960 00:46:14,220 --> 00:46:15,820 and there's really nothing tough for them, 961 00:46:16,000 --> 00:46:17,260 you keep it at evil. 962 00:46:17,800 --> 00:46:18,240 Yeah. 963 00:46:21,120 --> 00:46:22,380 I'm not very sure. 964 00:46:22,440 --> 00:46:23,980 Java would be more difficult to do 965 00:46:23,980 --> 00:46:25,760 simply because of the sandbox rules. 966 00:46:26,860 --> 00:46:27,740 For example, 967 00:46:27,960 --> 00:46:29,080 on Linux now, 968 00:46:29,220 --> 00:46:31,340 Conqueror lets you specify, 969 00:46:31,340 --> 00:46:33,880 per site enabling of, 970 00:46:33,980 --> 00:46:36,300 let's say I could enable JavaScript on a per site basis. 971 00:46:36,420 --> 00:46:38,280 I could enable Java on a per URL basis. 972 00:46:38,600 --> 00:46:41,720 So if you know you are connecting to a trusted source, 973 00:46:42,000 --> 00:46:43,800 you may choose to enable it over there. 974 00:46:43,880 --> 00:46:45,240 But the recommendation would be to, 975 00:46:45,300 --> 00:46:46,420 by default, disable. 976 00:46:46,760 --> 00:46:48,260 And then enable only small. 977 00:46:54,300 --> 00:46:56,600 Okay, what are normal regular countermeasures? 978 00:46:56,760 --> 00:46:58,340 Most of these things that we spoke about 979 00:46:58,340 --> 00:47:00,160 actually arise out of ignorance. 980 00:47:00,760 --> 00:47:01,940 Pure and simple ignorance. 981 00:47:02,180 --> 00:47:04,040 So user awareness is very critical. 982 00:47:04,480 --> 00:47:05,440 In an organization, 983 00:47:05,600 --> 00:47:06,920 you need to set up policies. 984 00:47:07,900 --> 00:47:08,420 You know, 985 00:47:08,440 --> 00:47:09,740 things you put down on paper would say, 986 00:47:09,820 --> 00:47:11,900 I will let my employees serve only at this time. 987 00:47:11,980 --> 00:47:13,060 I will let these sites be available. 988 00:47:13,420 --> 00:47:14,860 I will allow email to happen 989 00:47:14,860 --> 00:47:16,160 or I won't allow email to happen. 990 00:47:18,720 --> 00:47:21,080 Put up things like password tighteners. 991 00:47:21,160 --> 00:47:23,560 So you won't kind of simply put in girlfriend names, 992 00:47:23,760 --> 00:47:24,200 pet names, 993 00:47:24,340 --> 00:47:25,120 and so on and so forth. 994 00:47:25,200 --> 00:47:26,200 Set up expiry dates. 995 00:47:27,660 --> 00:47:29,340 Completely avoid clear text programs. 996 00:47:29,340 --> 00:47:31,000 If you're doing any kind of terminal work, 997 00:47:31,060 --> 00:47:32,020 you're logging into systems, 998 00:47:32,220 --> 00:47:33,280 throw away telnet. 999 00:47:33,540 --> 00:47:33,740 Okay? 1000 00:47:33,960 --> 00:47:34,860 Use SSH. 1001 00:47:35,160 --> 00:47:35,920 Bypass FTP. 1002 00:47:42,300 --> 00:47:44,620 Okay, now the next three or four slides, 1003 00:47:44,720 --> 00:47:46,420 really I'm not sure if we have time to get into 1004 00:47:46,420 --> 00:47:48,360 because I've just been told I've got something like 1005 00:47:48,360 --> 00:47:49,340 two and a half minutes left. 1006 00:47:52,420 --> 00:47:56,420 But my next four or five slides actually talked a little bit 1007 00:47:56,420 --> 00:47:57,440 about firewalls, 1008 00:47:57,460 --> 00:47:58,620 what kind of things you can apply. 1009 00:47:59,360 --> 00:48:00,760 For those of you who are interested, 1010 00:48:00,920 --> 00:48:01,680 if you send me an email, 1011 00:48:01,760 --> 00:48:02,980 I'll try and make sure the presentation 1012 00:48:02,980 --> 00:48:03,920 is available online. 1013 00:48:04,900 --> 00:48:05,640 Next two minutes, 1014 00:48:05,700 --> 00:48:06,800 should we just take up questions, 1015 00:48:06,900 --> 00:48:07,220 if any? 1016 00:48:08,220 --> 00:48:08,580 Yes. 1017 00:48:15,160 --> 00:48:15,520 Right. 1018 00:48:26,680 --> 00:48:27,040 Okay. 1019 00:48:27,740 --> 00:48:29,200 When I was talking sniffing, 1020 00:48:29,200 --> 00:48:31,840 I actually meant being able to read the low-level packets. 1021 00:48:31,980 --> 00:48:34,880 So it's not so much about spoofing using email. 1022 00:48:35,380 --> 00:48:36,560 On a switched network, 1023 00:48:36,800 --> 00:48:38,680 what would happen is the device, 1024 00:48:38,800 --> 00:48:40,660 the physical device is a little more intelligent. 1025 00:48:40,880 --> 00:48:42,960 So even if you've got 50 machines connected, 1026 00:48:43,420 --> 00:48:46,800 it would route information only between the two required machines. 1027 00:48:47,120 --> 00:48:47,540 Right? 1028 00:48:47,660 --> 00:48:50,280 Which is why it becomes difficult to sniff on a switched network. 1029 00:48:50,600 --> 00:48:53,060 But I believe you can do things like ARP spoofing. 1030 00:48:53,220 --> 00:48:58,720 So a level lower than your IP level, for example. 1031 00:48:59,300 --> 00:49:01,600 So every time a packet is sent out on the Ethernet, 1032 00:49:01,760 --> 00:49:03,320 he needs to figure out the hardware address 1033 00:49:03,320 --> 00:49:04,600 of the machine to write to. 1034 00:49:05,040 --> 00:49:07,200 Now, there are programs and there are ways. 1035 00:49:07,300 --> 00:49:09,920 I'm not really an expert to that level, 1036 00:49:10,020 --> 00:49:11,360 but there are ways in which I can... 1037 00:49:11,760 --> 00:49:13,380 When an ARP request is sent out, 1038 00:49:13,520 --> 00:49:16,340 the response that comes back directs the packet 1039 00:49:16,340 --> 00:49:17,200 to come to my machine. 1040 00:49:18,060 --> 00:49:19,100 Now, if I am smart, 1041 00:49:19,240 --> 00:49:20,880 what I will do is I will make sure my machine 1042 00:49:20,880 --> 00:49:22,380 becomes a man-in-the-middle kind of thing. 1043 00:49:22,460 --> 00:49:23,660 So I will relay stuff. 1044 00:49:24,000 --> 00:49:25,420 So for all practical purposes, 1045 00:49:25,660 --> 00:49:26,860 A is talking to B. 1046 00:49:27,000 --> 00:49:27,340 Okay? 1047 00:49:27,400 --> 00:49:28,160 You are doing stuff. 1048 00:49:28,720 --> 00:49:29,660 Everything is going through my machine. 1049 00:49:29,900 --> 00:49:33,960 Simply because I have been able to ARP spoof 1050 00:49:33,960 --> 00:49:34,820 that particular connection. 1051 00:49:37,720 --> 00:49:38,520 Anything else? 1052 00:49:39,600 --> 00:49:40,040 Yeah? 1053 00:49:40,460 --> 00:49:42,860 When you were talking about IP spoofing, 1054 00:49:42,860 --> 00:49:45,160 you said you could do the sequence number. 1055 00:49:45,300 --> 00:49:46,740 How do you do the sequence number? 1056 00:49:46,780 --> 00:49:47,220 Okay. 1057 00:49:47,280 --> 00:49:48,000 There are really, again, 1058 00:49:48,120 --> 00:49:51,340 that's getting to be more and more difficult, 1059 00:49:51,440 --> 00:49:52,700 but there are many ways of doing it. 1060 00:49:53,720 --> 00:49:56,440 Normally, it was well accepted that the stack, 1061 00:49:56,580 --> 00:49:58,180 when machines actually came up, 1062 00:49:58,180 --> 00:49:59,980 they kind of started with one, okay? 1063 00:50:00,040 --> 00:50:00,660 Right in the beginning. 1064 00:50:00,980 --> 00:50:02,100 And every second, 1065 00:50:02,220 --> 00:50:05,020 the counter got incremented by 128,000. 1066 00:50:05,180 --> 00:50:06,080 For every connect, 1067 00:50:06,340 --> 00:50:08,260 you got an increment of 64,000. 1068 00:50:08,460 --> 00:50:09,640 Now, really what happens is 1069 00:50:09,640 --> 00:50:11,940 when you're trying to predict sequence numbers, 1070 00:50:12,040 --> 00:50:13,600 you would try and make legitimate connections 1071 00:50:13,600 --> 00:50:15,580 to a machine, multiple connections. 1072 00:50:15,780 --> 00:50:18,000 So you kind of compute three, four things. 1073 00:50:18,080 --> 00:50:19,700 One is you get to see what the ISN is, 1074 00:50:19,760 --> 00:50:20,660 the initial sequence number. 1075 00:50:20,800 --> 00:50:21,620 You kind of log that. 1076 00:50:21,900 --> 00:50:23,460 You send three or four connections. 1077 00:50:23,580 --> 00:50:25,100 You get to see how the increment is happening. 1078 00:50:25,640 --> 00:50:27,680 Then you also figure out how much time 1079 00:50:27,680 --> 00:50:29,200 it's taking your packet to come back, 1080 00:50:29,300 --> 00:50:30,060 the round-trip time. 1081 00:50:30,480 --> 00:50:31,740 So you need to know roughly 1082 00:50:31,740 --> 00:50:33,180 how much time it takes to reach there, 1083 00:50:33,240 --> 00:50:34,600 because with every packet reaching, 1084 00:50:34,800 --> 00:50:36,540 your counter's going up by 64K. 1085 00:50:37,180 --> 00:50:37,460 Okay? 1086 00:50:37,520 --> 00:50:38,700 Based on these kind of things, 1087 00:50:38,820 --> 00:50:39,780 you initiate a connection, 1088 00:50:40,060 --> 00:50:42,740 and hopefully someone else has not gotten before that, 1089 00:50:42,840 --> 00:50:44,300 where you can predict the sequence number. 1090 00:50:44,820 --> 00:50:45,220 Okay. 1091 00:50:45,280 --> 00:50:46,520 These are getting more and more difficult 1092 00:50:46,520 --> 00:50:47,840 because, logically, 1093 00:50:47,980 --> 00:50:49,500 the next steps were to randomize 1094 00:50:49,500 --> 00:50:50,940 the way sequence numbers were happening. 1095 00:50:51,280 --> 00:50:53,100 So if you run NMAP, for example, 1096 00:50:53,100 --> 00:50:54,720 which is a port scanner and OS detector 1097 00:50:54,720 --> 00:50:55,600 on a lot of machines, 1098 00:50:55,780 --> 00:50:56,780 it comes back saying, 1099 00:50:56,780 --> 00:50:58,680 Listen, I've detected Windows here, 1100 00:50:58,760 --> 00:50:59,320 and it's trivial. 1101 00:50:59,600 --> 00:51:01,040 Your sequence number prediction is trivial. 1102 00:51:01,320 --> 00:51:02,800 Or if it's Linux, it says, 1103 00:51:03,460 --> 00:51:04,260 Bad stuff. 1104 00:51:04,340 --> 00:51:05,520 Good luck to you, friend. 1105 00:51:05,800 --> 00:51:05,860 You know? 1106 00:51:05,880 --> 00:51:06,380 Things like that. 1107 00:51:06,540 --> 00:51:07,520 So it's... 1108 00:51:09,140 --> 00:51:09,580 Yeah? 1109 00:51:10,220 --> 00:51:11,820 Is there anywhere on the website 1110 00:51:11,820 --> 00:51:13,080 where you can check the cell frequency? 1111 00:51:19,560 --> 00:51:20,760 I don't think so. 1112 00:51:21,900 --> 00:51:22,720 I don't think so. 1113 00:51:22,820 --> 00:51:24,800 I mean, let's look at it. 1114 00:51:24,880 --> 00:51:26,580 If the packet never reaches you, 1115 00:51:26,780 --> 00:51:28,660 you don't know that you are 1116 00:51:28,660 --> 00:51:30,040 being denied information 1117 00:51:30,040 --> 00:51:31,560 or requests that are coming to you. 1118 00:51:31,980 --> 00:51:33,400 Sure, you might notice that 1119 00:51:34,300 --> 00:51:36,140 my web traffic has gone down. 1120 00:51:36,380 --> 00:51:38,080 But there could be multiple reasons for that. 1121 00:51:38,180 --> 00:51:38,760 I mean, for example, 1122 00:51:38,820 --> 00:51:40,280 if I did a denial of service attack 1123 00:51:40,280 --> 00:51:41,500 against a particular site, 1124 00:51:42,060 --> 00:51:43,420 let's assume there's an ISP 1125 00:51:43,420 --> 00:51:45,480 who's got lots of clients over there. 1126 00:51:45,580 --> 00:51:47,260 You're targeting one particular client. 1127 00:51:47,580 --> 00:51:49,380 Simply because you are creating 1128 00:51:49,380 --> 00:51:50,680 so much of network saturation 1129 00:51:50,680 --> 00:51:51,960 and you're making life miserable 1130 00:51:51,960 --> 00:51:52,960 for all his clients, 1131 00:51:53,180 --> 00:51:54,360 what will the ISP do? 1132 00:51:54,520 --> 00:51:56,680 He'll simply filter out any packets 1133 00:51:56,680 --> 00:51:58,080 that's coming to the target site. 1134 00:51:58,760 --> 00:52:00,080 In effect, what has he done? 1135 00:52:00,160 --> 00:52:01,040 He's helped the attacker. 1136 00:52:01,620 --> 00:52:02,520 I mean, he's done 1137 00:52:02,520 --> 00:52:04,240 what the attacker was trying to do 1138 00:52:04,240 --> 00:52:05,000 much more effectively. 1139 00:52:05,160 --> 00:52:06,260 He just pulled the plug on that guy. 1140 00:52:06,820 --> 00:52:06,860 Okay? 1141 00:52:07,380 --> 00:52:08,180 So it's... 1142 00:52:09,700 --> 00:52:10,100 Yeah? 1143 00:52:12,480 --> 00:52:12,880 Sir? 1144 00:52:13,680 --> 00:52:14,280 Yes, please. 1145 00:52:19,800 --> 00:52:23,600 Frankly, I haven't used commercial firewalls. 1146 00:52:23,800 --> 00:52:26,300 Most of my work is with packet filtering 1147 00:52:26,300 --> 00:52:26,840 on Linux, 1148 00:52:26,960 --> 00:52:28,580 so I really am not the right person 1149 00:52:28,580 --> 00:52:29,860 to give you information on that. 1150 00:52:30,360 --> 00:52:30,840 Sorry. 1151 00:52:32,180 --> 00:52:32,660 Yeah? 1152 00:52:32,940 --> 00:52:35,840 With the episode of compromise, 1153 00:52:38,120 --> 00:52:40,480 my information first is on the site 1154 00:52:40,480 --> 00:52:42,800 where I would show up in your statements, right? 1155 00:52:43,000 --> 00:52:43,700 Sure it would. 1156 00:52:45,100 --> 00:52:45,700 I'm sure. 1157 00:52:45,960 --> 00:52:46,940 But it's like saying 1158 00:52:46,940 --> 00:52:48,160 you're taking corrective action 1159 00:52:48,160 --> 00:52:49,800 after the event has taken place, 1160 00:52:50,360 --> 00:52:51,580 after something's happened. 1161 00:52:51,820 --> 00:52:53,080 At that point of time, 1162 00:52:53,180 --> 00:52:55,100 the amount of loss that has taken place 1163 00:52:55,100 --> 00:52:58,440 and the amount of negative that has happened 1164 00:52:58,440 --> 00:53:00,340 is something which you probably can't reverse. 1165 00:53:01,400 --> 00:53:02,000 Isn't it? 1166 00:53:04,840 --> 00:53:05,320 Sure. 1167 00:53:06,820 --> 00:53:08,920 Now we're getting into business policies, 1168 00:53:08,960 --> 00:53:09,920 again, which would vary 1169 00:53:09,920 --> 00:53:11,220 from different parts of the world. 1170 00:53:11,500 --> 00:53:12,700 My premise is 1171 00:53:13,500 --> 00:53:15,120 I've gone and deleted all the information 1172 00:53:15,120 --> 00:53:15,780 on your server. 1173 00:53:16,640 --> 00:53:17,280 Doesn't help. 1174 00:53:19,580 --> 00:53:21,360 I'll give you my last... 1175 00:53:23,180 --> 00:53:25,080 Just in case anybody needs to read 1176 00:53:25,100 --> 00:53:25,600 or write to me. 1177 00:53:37,180 --> 00:53:37,620 Okay. 1178 00:53:37,760 --> 00:53:38,840 That's my email address. 1179 00:53:39,440 --> 00:53:41,300 In case somebody needs to write and ask, 1180 00:53:41,360 --> 00:53:42,440 I'd be happy to... 1181 00:53:42,440 --> 00:53:42,940 Yeah? 1182 00:53:46,460 --> 00:53:46,900 Sorry? 1183 00:53:57,340 --> 00:53:59,340 1997 is when the report came out, 1184 00:53:59,420 --> 00:54:01,020 and they said at that point of time 1185 00:54:01,020 --> 00:54:03,360 it affected both Microsoft Internet Explorer 1186 00:54:03,360 --> 00:54:04,420 as well as Netscape. 1187 00:54:05,300 --> 00:54:06,880 I'm not sure of current status. 1188 00:54:07,060 --> 00:54:08,100 But the idea of... 1189 00:54:09,640 --> 00:54:10,120 Sorry? 1190 00:54:10,560 --> 00:54:11,040 . 1191 00:54:12,340 --> 00:54:12,820 No. 1192 00:54:12,980 --> 00:54:14,120 They actually said 1193 00:54:14,120 --> 00:54:15,340 we have a working model 1194 00:54:15,340 --> 00:54:16,180 which you've demonstrated, 1195 00:54:16,500 --> 00:54:18,160 but we're not going to release it to the web. 1196 00:54:18,280 --> 00:54:19,720 But it was pure JavaScript. 1197 00:54:20,760 --> 00:54:21,240 . 1198 00:54:23,420 --> 00:54:25,320 They actually replaced the real menu 1199 00:54:26,140 --> 00:54:26,960 with their own. 1200 00:54:27,060 --> 00:54:27,980 So when you clicked on it, 1201 00:54:28,060 --> 00:54:29,660 internally the intelligence was built in 1202 00:54:29,660 --> 00:54:30,720 to actually get the real page 1203 00:54:30,720 --> 00:54:31,360 and show it to you. 1204 00:54:31,560 --> 00:54:31,960 . 1205 00:54:34,620 --> 00:54:35,020 Yes. 1206 00:54:35,180 --> 00:54:35,520 Yes. 1207 00:54:35,760 --> 00:54:36,100 Yes. 1208 00:54:36,120 --> 00:54:36,440 Yes. 1209 00:54:37,920 --> 00:54:38,320 Okay. 1210 00:54:38,940 --> 00:54:39,340 Thanks. 1211 00:54:40,180 --> 00:54:41,000 I'll stop here.