1 00:00:00,990 --> 00:00:02,040 Instructor: Welcome back. 2 00:00:02,040 --> 00:00:04,320 So, in this lecture, we're going to take a look 3 00:00:04,320 --> 00:00:09,090 at how we can install VPN inside of our Kali Linux system 4 00:00:09,090 --> 00:00:12,000 in order to anonymize our traffic. 5 00:00:12,000 --> 00:00:14,010 So it's a rather simple process, 6 00:00:14,010 --> 00:00:16,920 and what we want to do is we want to, first of all, 7 00:00:16,920 --> 00:00:20,070 open up our Firefox and we're going to use, 8 00:00:20,070 --> 00:00:23,460 as I mentioned, OpenVPN to do this. 9 00:00:23,460 --> 00:00:26,970 Now to install OpenVPN, you want to navigate 10 00:00:26,970 --> 00:00:30,663 to the website called vpnbook.com. 11 00:00:32,100 --> 00:00:36,360 But before we proceed with the installation of the VPN, 12 00:00:36,360 --> 00:00:39,390 what I want you to do is I want you to go on your Firefox 13 00:00:39,390 --> 00:00:43,350 inside of your Kali Linux system, type what is my ip, 14 00:00:43,350 --> 00:00:47,100 and you should see your public IP displayed 15 00:00:47,100 --> 00:00:50,190 as well as the location of the public IP. 16 00:00:50,190 --> 00:00:52,710 And we're going to see that changing 17 00:00:52,710 --> 00:00:54,690 after we configure our VPN. 18 00:00:54,690 --> 00:00:57,900 So once you're on the VPNBook website, 19 00:00:57,900 --> 00:01:02,250 you want to scroll down until you see this OpenVPN tab. 20 00:01:02,250 --> 00:01:05,310 Click on it, and here we will have different 21 00:01:05,310 --> 00:01:08,370 configuration files depending on the server 22 00:01:08,370 --> 00:01:10,110 that you want to choose. 23 00:01:10,110 --> 00:01:13,020 So, me personally, I'm going to go with this server 24 00:01:13,020 --> 00:01:17,130 right here, which is French if I'm not mistaken. 25 00:01:17,130 --> 00:01:18,990 And you might notice down here 26 00:01:18,990 --> 00:01:20,670 that we have username and password, 27 00:01:20,670 --> 00:01:23,340 which will be useful for us in just a second, 28 00:01:23,340 --> 00:01:24,780 but before we use them, 29 00:01:24,780 --> 00:01:27,300 let's download any of these servers here. 30 00:01:27,300 --> 00:01:29,910 You can choose the US server or the Canada, 31 00:01:29,910 --> 00:01:31,680 whichever you prefer. 32 00:01:31,680 --> 00:01:33,180 I'm going to go with this one. 33 00:01:34,230 --> 00:01:36,900 And it will download the zip file, 34 00:01:36,900 --> 00:01:40,110 which we want to open and then extract. 35 00:01:40,110 --> 00:01:42,750 And to extract this file, we'll just right-click 36 00:01:42,750 --> 00:01:45,210 and click on Extract Here. 37 00:01:45,210 --> 00:01:48,930 And once that is extracted, we will have this folder 38 00:01:48,930 --> 00:01:53,520 with our VPN configurations, as we can see right here. 39 00:01:53,520 --> 00:01:55,830 Now for most of these servers, you will actually get 40 00:01:55,830 --> 00:01:58,890 four configuration files, as mentioned right here, 41 00:01:58,890 --> 00:02:02,363 TCP port 80, TCP port 443, UDP 25000, 42 00:02:03,467 --> 00:02:05,940 and UDP port 53 for DNS. 43 00:02:05,940 --> 00:02:08,669 But here, we got only three, which doesn't really matter. 44 00:02:08,669 --> 00:02:13,670 We're going to use the TCP port 80 since that is HDP port. 45 00:02:14,010 --> 00:02:17,250 Okay, so now that we got that, 46 00:02:17,250 --> 00:02:19,353 all we want to do is open terminal, 47 00:02:20,190 --> 00:02:23,430 and let me enlarge this so we can see everything better. 48 00:02:23,430 --> 00:02:24,780 Type ls. 49 00:02:24,780 --> 00:02:27,360 Here are our configuration files, 50 00:02:27,360 --> 00:02:30,930 and we can run the configuration file from the command line 51 00:02:30,930 --> 00:02:34,900 or from the terminal by typing openvpn --config 52 00:02:37,740 --> 00:02:40,470 and then the file name. 53 00:02:40,470 --> 00:02:42,693 In my case, that will be tcp80.ovpn. 54 00:02:44,610 --> 00:02:46,140 So I'm going to use this one. 55 00:02:46,140 --> 00:02:47,910 You can use that one, as well, 56 00:02:47,910 --> 00:02:50,040 for the purposes of the tutorial. 57 00:02:50,040 --> 00:02:55,040 And if I press enter, it will ask for username and password. 58 00:02:55,290 --> 00:02:58,290 And if you remember, we have username here, 59 00:02:58,290 --> 00:03:02,500 which is vpnbook, and password, which is rxtasfh, 60 00:03:06,510 --> 00:03:08,970 if I'm not mistaken, yes, h. 61 00:03:08,970 --> 00:03:11,790 And keep in mind, this will probably be different for you 62 00:03:11,790 --> 00:03:14,670 so don't type in what I'm typing in right here, 63 00:03:14,670 --> 00:03:17,970 but rather check on the VPNBook page. 64 00:03:17,970 --> 00:03:21,690 Once you type that in, press enter, 65 00:03:21,690 --> 00:03:25,080 and it seems that we get a fatal error. 66 00:03:25,080 --> 00:03:26,700 Now once you get this error, 67 00:03:26,700 --> 00:03:28,950 there are two different things that you want to try. 68 00:03:28,950 --> 00:03:32,193 You either want to try running the command with sudo. 69 00:03:34,290 --> 00:03:39,290 Type in our password, type these two passwords again, 70 00:03:45,210 --> 00:03:47,400 and if it still doesn't work, well, 71 00:03:47,400 --> 00:03:50,580 then we need to alter the configuration file. 72 00:03:50,580 --> 00:03:54,000 So to do that, we want to nano the file that we're running. 73 00:03:54,000 --> 00:03:59,000 So in my case, it's vpnbook-tcp80.ovpn. 74 00:04:00,930 --> 00:04:02,850 And once you open it, you want to scroll 75 00:04:02,850 --> 00:04:06,210 all the way down up to this redirect-gateway, 76 00:04:06,210 --> 00:04:08,820 press enter to make space, 77 00:04:08,820 --> 00:04:11,460 and you want to type this line in. 78 00:04:11,460 --> 00:04:16,459 So you want to type tls-cipher, space, open double quotes, 79 00:04:17,399 --> 00:04:22,233 then capital letters "DEFAULT:@SECLEVEL, 80 00:04:23,940 --> 00:04:26,610 and then that will be equal to 0, 81 00:04:26,610 --> 00:04:29,550 and then close the double quotes. 82 00:04:29,550 --> 00:04:33,720 So you want to type in this line right here. 83 00:04:33,720 --> 00:04:37,530 Once you type it in, you can Control + O to save, 84 00:04:37,530 --> 00:04:39,480 Control + X to exit. 85 00:04:39,480 --> 00:04:41,640 And we want to run the same command, 86 00:04:41,640 --> 00:04:44,550 which is sudo openvpn --config, 87 00:04:44,550 --> 00:04:46,830 and then the configuration name. 88 00:04:46,830 --> 00:04:49,113 We need to type in password once again, 89 00:04:54,600 --> 00:04:56,970 and you can see this time it works. 90 00:04:56,970 --> 00:04:58,890 We are not getting the fatal error, 91 00:04:58,890 --> 00:05:01,350 and we can check whether VPN is indeed active 92 00:05:01,350 --> 00:05:05,193 by going and typing what is my ip. 93 00:05:07,290 --> 00:05:10,890 Here, we can see that this is my current public IP address. 94 00:05:10,890 --> 00:05:14,160 If I go on this website to check what is the location 95 00:05:14,160 --> 00:05:17,550 of this ip, it seems to be in Indonesia, 96 00:05:17,550 --> 00:05:20,700 which is definitely not where I am from, 97 00:05:20,700 --> 00:05:23,130 so it is indeed working. 98 00:05:23,130 --> 00:05:24,900 Our VPN is working. 99 00:05:24,900 --> 00:05:26,580 Now you're probably going to get a different 100 00:05:26,580 --> 00:05:31,580 IP address every time, but nonetheless, your VPN is working. 101 00:05:32,250 --> 00:05:33,810 Okay, awesome. 102 00:05:33,810 --> 00:05:36,990 That will be about it when it comes to installing 103 00:05:36,990 --> 00:05:38,790 OpenVPN in Kali Linux. 104 00:05:38,790 --> 00:05:40,440 Now if you want, you can choose 105 00:05:40,440 --> 00:05:43,230 any other VPN provider that you want. 106 00:05:43,230 --> 00:05:45,480 This is a free one, that's why we chose it. 107 00:05:45,480 --> 00:05:48,930 You can use a paid VPN of your choice, but nonetheless, 108 00:05:48,930 --> 00:05:50,580 let's not make this any longer, 109 00:05:50,580 --> 00:05:53,373 and let's continue to the next lecture.