YouTube2Text

YouTube transcript (TtlKFgfN3PU) — Transcript

8,098 words · 1,181 segments · language en · Watch on YouTube

Full transcript

  1. 0:05hello everyone my name is Abhishek and
  2. 0:08welcome to day five of AWS Zero to Hero
  3. 0:10series before we start today's topic
  4. 0:13let's quickly recap what we have learned
  5. 0:15as part of day 4 because DFI is going to
  6. 0:18be an extension of day 4 or you can
  7. 0:21consider it as a part two of D4
  8. 0:24so what we have learned as part of day 4
  9. 0:26is firstly we understood the concept of
  10. 0:28VPC virtual private Cloud we discussed
  11. 0:32about the different components of VPC we
  12. 0:35try to understand these things with a
  13. 0:36real life example we took an example of
  14. 0:39a secure gated community and try to
  15. 0:41relate it with the world of AWS and VPC
  16. 0:45after that what we did is the most
  17. 0:48important thing that is we understood
  18. 0:50how traffic flows within VPC and finally
  19. 0:54reach the application right so let's say
  20. 0:56this is a user and this is the
  21. 0:58application we discussed how multiple
  22. 1:00components of VPC in the real world
  23. 1:03right so in the world of public private
  24. 1:05subnet or in the world where
  25. 1:08organizations use AWS we discussed how
  26. 1:11different components of vpcs such as
  27. 1:13internet gateway load balancer route
  28. 1:16tables how each of them interact with
  29. 1:18each other and finally send the traffic
  30. 1:20to the application so this is what we
  31. 1:23understood theoretically on day four
  32. 1:26and I explained you on day 4 that VPC is
  33. 1:29one of the most important services on
  34. 1:32AWS why because VPC is the one that
  35. 1:36introduces the concept of
  36. 1:38private cloud in the world of public
  37. 1:40cloud
  38. 1:41what is that I mean to say VPC is the
  39. 1:44one that introduces the concept of
  40. 1:46virtual private cloud in the world of
  41. 1:49public cloud and adds a lot of security
  42. 1:52so without VPC Security on AWS will not
  43. 1:56be as good as what it is today so it is
  44. 2:00important for every devops engineer or
  45. 2:02the one who is learning AWS let's say
  46. 2:04you are just learning AWS it is
  47. 2:06important for everyone to understand the
  48. 2:09concept of virtual private Cloud if you
  49. 2:11are learning AWS that means VPC is the
  50. 2:14one that you need to understand by
  51. 2:16default
  52. 2:17so that is the reason why I told you
  53. 2:20in day four as well we will do day five
  54. 2:23day six that means today's class and
  55. 2:26also tomorrow's class on understanding
  56. 2:28the components of VPC in detail right as
  57. 2:32part of that in today's video what we
  58. 2:34will do is it is going to be both Theory
  59. 2:37and practical and theoretically
  60. 2:40practically we will understand one of
  61. 2:43the most important concepts of VPC which
  62. 2:45adds additional security that is
  63. 2:48security groups as well as
  64. 2:51NaCl right so this is what we are going
  65. 2:55to learn in detail today both
  66. 2:57theoretically and practically so please
  67. 2:59watch the video till the end so that
  68. 3:01even you can perform this activity like
  69. 3:03even you can take this as an assessment
  70. 3:07and you can try this at your end by
  71. 3:09watching this entire video
  72. 3:11got it so now without wasting any time
  73. 3:14let's quickly see what is this Security
  74. 3:16Group what is this NaCl and what exactly
  75. 3:19they are going to do within the VPC
  76. 3:23so if we go back to yesterday's video
  77. 3:25very quickly what I told you is if you
  78. 3:28consider this as VPC right let's say
  79. 3:30this is a virtual private cloud and I
  80. 3:33have explained that okay in the world of
  81. 3:35virtual private Cloud the very first
  82. 3:37thing what you will do this is a real
  83. 3:38life example right how organizations use
  84. 3:41VPC as of today this is the same thing
  85. 3:44so initially you will have something
  86. 3:46called as an
  87. 3:47internet gateway right so usually what
  88. 3:51happens is within the VPC there will be
  89. 3:53a public subnet so and there will be
  90. 3:57private subnet right so what is a subnet
  91. 3:59basically I explained in the last class
  92. 4:01when you create VPC you will Define what
  93. 4:04should be the IP range or what should be
  94. 4:06the IP address range of your VPC it is
  95. 4:09just in the similar terms you can
  96. 4:11consider how many IP addresses you want
  97. 4:14inside this VPC right so usually let's
  98. 4:17say that when I create a VPC if I say
  99. 4:20that the IP range has to be
  100. 4:2210.1.0.0 hyphen 16. then that
  101. 4:25technically means you will have within
  102. 4:28the VPC 65536 IP addresses okay so this
  103. 4:32defines the size of VPC how big a VPC or
  104. 4:34how small a VPC so when you have 65536
  105. 4:38VPC IP addresses that means technically
  106. 4:40you can use six double five three six
  107. 4:44applications components within this VPC
  108. 4:47okay so let's not go into the detail of
  109. 4:49this but just understand that when you
  110. 4:51create VPC then you define an IP address
  111. 4:53range which defines what should be the
  112. 4:55size of your VPC now within that you can
  113. 4:58divide subnets so subnets are basically
  114. 5:00like within VPC if you have multiple
  115. 5:02projects okay so as a devops engineer
  116. 5:05you have created an AWS account then you
  117. 5:07have created a VPC for one of the
  118. 5:09project within the project also there
  119. 5:10will be internal projects right so for
  120. 5:13each internal project for group of
  121. 5:14applications you can Define private
  122. 5:16subnets okay so this private subnet
  123. 5:19basically will not have access to
  124. 5:21Internet that's why they are called
  125. 5:22private subnets so by default these
  126. 5:24applications cannot be accessed from
  127. 5:26internet so that's where VPC comes comes
  128. 5:29into picture and what VPC does is
  129. 5:31whenever let's say this is a user
  130. 5:34okay I know that I'm taking time here
  131. 5:37but this is very very important for
  132. 5:38everyone to understand when user
  133. 5:40eventually want to reach here like you
  134. 5:43know user want to access an application
  135. 5:44here what happens is user firstly tries
  136. 5:46to go through this internet gateway okay
  137. 5:49and this is a public subnet where anyone
  138. 5:51can access this public subnet okay
  139. 5:54saying that you can add few conditions
  140. 5:56here through the internet gateway and
  141. 5:58through the API gateways you can add
  142. 6:00conditions and validate few things is
  143. 6:01this user good user bad user hacker or
  144. 6:04whatever it is we will talk about that
  145. 6:05later so through the internet gateway
  146. 6:07initially what happens is within this
  147. 6:09public subnet devops Engineers usually
  148. 6:12place a load balancer
  149. 6:14okay so load balancer can be directly
  150. 6:16accessed from outside world and what
  151. 6:18happens is this load balancer will talk
  152. 6:21to this private subnet okay so load
  153. 6:23balancer is the one that has access to
  154. 6:25private subnet and this user has the
  155. 6:27access to load balancer and within the
  156. 6:29load balancer also you can do a lot of
  157. 6:31configurations you can restrict traffic
  158. 6:33you can say that okay
  159. 6:35etc etc and you can make this more
  160. 6:37secure with the load balancer as well
  161. 6:39but today's topic is about
  162. 6:42once the load balancer forwards the
  163. 6:44request to the private subnet okay so
  164. 6:47there are two things one is you can add
  165. 6:50additional security at the layer of the
  166. 6:52subnet okay for each subnet AWS says
  167. 6:55that hey you can add more security at
  168. 6:58the subnet level okay so if you add more
  169. 7:01security at the subnets level what we
  170. 7:03will do is we will start using nacls
  171. 7:05whereas even if you bypass this let's
  172. 7:08say you have not added anything at the
  173. 7:10uh sublet level you can as a devops
  174. 7:13engineer or the application owner what
  175. 7:15you can do is you can add more security
  176. 7:17at the ec2 instance level
  177. 7:20okay the level where your application is
  178. 7:23actually deployed so at the ec2 instance
  179. 7:26level if you add security then we call
  180. 7:28it as security groups so using security
  181. 7:30groups you can add more security at the
  182. 7:33ec2 instance level
  183. 7:34whereas if you want to add more security
  184. 7:37here at the subnet level then we will
  185. 7:39call I mean we will use nacls okay don't
  186. 7:43worry even if you haven't understood
  187. 7:44exactly what is happening here when I
  188. 7:46deep dive and explain it further you
  189. 7:48will understand but for now here what I
  190. 7:50wanted to explain is
  191. 7:52in AWS there are multiple layers where
  192. 7:54you can add security because security is
  193. 7:57one of the key components for any
  194. 7:59organization if they want to move to
  195. 8:01public Cloud what they will first see is
  196. 8:03is that public Cloud secure enough or
  197. 8:05not you can talk about costing you can
  198. 8:08talk about any level of things but for
  199. 8:10any public Cloud tomorrow if there is
  200. 8:12new public Cloud what you will first see
  201. 8:14is how secure this public cloud is
  202. 8:15because you are going to put all of your
  203. 8:17application in the public Cloud right so
  204. 8:20if you if your automation is using AWS
  205. 8:22it will have your organizational user
  206. 8:25details you will have details like the
  207. 8:27database and everything is hosted on AWS
  208. 8:29so first thing organizations look at is
  209. 8:31how secure is AWS and that's where AWS
  210. 8:35says that okay we will do our part so
  211. 8:39the fundamental thing that AWS says is
  212. 8:42in AWS security is a
  213. 8:45shared responsibility
  214. 8:48understand this sentence very keen
  215. 8:50in AWS security is always a shared
  216. 8:53responsibility what does this mean so
  217. 8:55AWS says that okay from our side we will
  218. 8:59try to add as much security as possible
  219. 9:01like we will tell you that you can use
  220. 9:03VPC we will tell you that hey you can
  221. 9:06add security groups you can add nacls
  222. 9:10you can add API Gateway you can add a
  223. 9:13lot of security
  224. 9:15but along with that we will need that
  225. 9:18means AWS is saying along with the
  226. 9:20things that we are adding we need help
  227. 9:22of devops Engineers or AWS admins
  228. 9:26whoever it is like right most of the
  229. 9:28times AWS admins are also devops
  230. 9:30Engineers these days or network admin
  231. 9:32system admins whatever your company
  232. 9:33calls it but AWS says that security
  233. 9:36should be a shared responsibility we
  234. 9:39will do our part as devops Engineers AWS
  235. 9:41admins or network admins you also have
  236. 9:43to do your part and that way I mean
  237. 9:46that's exactly where all of this
  238. 9:48component comes into picture whether
  239. 9:49adding load balancer for your
  240. 9:51organization uh do you want to use
  241. 9:53default load balancer different load
  242. 9:55balancer do you want to use API Gateway
  243. 9:57or not and how exactly you want to
  244. 9:59configure security groups and nacls all
  245. 10:02of these things devops engineer plays a
  246. 10:04very critical role in today's topic we
  247. 10:07will debug and deep dive into security
  248. 10:09groups and nacls which comes at the last
  249. 10:13point of security
  250. 10:14right which comes at the last point of
  251. 10:17security but this is very critical
  252. 10:19because if you are not taking necessary
  253. 10:21actions at the last point then your
  254. 10:24application will be easily hacked right
  255. 10:26nacls and security groups
  256. 10:29are very critical because of this very
  257. 10:31reason that is they act as a last point
  258. 10:33of security in your AWS account just
  259. 10:36before the user request reads the
  260. 10:39application right if this is user
  261. 10:42and this is where the application is
  262. 10:45it has to travel a long path right the
  263. 10:48request has to travel a long path within
  264. 10:51the VPC it goes through multiple
  265. 10:53components but when it reach here before
  266. 10:56this point the last point of security is
  267. 10:59served by security groups and nacls
  268. 11:03okay so that's why this is very
  269. 11:05important and we will try to focus I
  270. 11:07will explain you like what and when to
  271. 11:10use Security Group and what and when to
  272. 11:12use nacls so firstly let's start with
  273. 11:15this concept on understanding what is
  274. 11:18the primary difference between security
  275. 11:20groups and nacls
  276. 11:23so Security Group basically serves at
  277. 11:26the instance level okay now what do I
  278. 11:29mean by this
  279. 11:30on day three so whoever has followed our
  280. 11:33day three's video or in general what we
  281. 11:35have done on day three is firstly we
  282. 11:37created an AWS account right in the AWS
  283. 11:40account in the default VPC like whenever
  284. 11:42you create AWS account itself
  285. 11:45AWS will give a default VPC without VPC
  286. 11:48AWS will not deal with anything if you
  287. 11:50want to create custom vpcs you can do as
  288. 11:52we will do today but by default AWS will
  289. 11:55give you a VPC and what we have noticed
  290. 11:57is we created an ec2 instance and within
  291. 12:00the cc2 instance we tried to deploy a
  292. 12:02Jenkins application and as a user we try
  293. 12:06to access this Jenkins application what
  294. 12:08happened we were not able to access this
  295. 12:11application by default because as I
  296. 12:14showed you in that video there was
  297. 12:16something that was blocking this one
  298. 12:18right so by default as I told you in AWS
  299. 12:22security is a shared responsibility and
  300. 12:24by default what AWS says is we will not
  301. 12:27allow anything to your instance directly
  302. 12:29okay so if you want to do that you need
  303. 12:32to configure your Security Group
  304. 12:35okay so if we want to configure anything
  305. 12:38at the instance level that we do within
  306. 12:41the security group Concept in AWS and
  307. 12:44that's exactly where to access the
  308. 12:46Jenkins application deployed in the ec2
  309. 12:48instance we have allowed Port 8018 or
  310. 12:52you can also allow all traffic
  311. 12:55okay so this is where devops engineers
  312. 12:58and the applications on owners have to
  313. 12:59be very careful instead of opening port
  314. 13:028080 let's say in your organization you
  315. 13:05have opened some other Port let's say
  316. 13:07you have opened Port 9000 10 000 and
  317. 13:09multiple other ports and there was one
  318. 13:11hacker who was trying to access this and
  319. 13:13they were luckily able to access these
  320. 13:15ports and they try to hack something
  321. 13:17okay or additionally whenever you open
  322. 13:20ports that are not used or you keep
  323. 13:22opening a lot of ports then there can be
  324. 13:24some kind of unwanted traffic that can
  325. 13:27flow to your ec2 instance and reach the
  326. 13:29application so AWS is doing the part of
  327. 13:32by default not accepting any traffic
  328. 13:34whereas as devops engineer you have to
  329. 13:37do your part by allowing only specified
  330. 13:39traffic into your ec2 instance and into
  331. 13:41your application that thing is done by
  332. 13:44security groups Concept in AWS I hope
  333. 13:47this is clear if you still feel that
  334. 13:49this is not clear when we do the
  335. 13:51Practical you will understand we will
  336. 13:53deploy a python application and I'll
  337. 13:55show you the same thing again using the
  338. 13:57security groups now you might ask me
  339. 14:00okay this is a very easy topic
  340. 14:02so it is an easy topic but there are few
  341. 14:04things to understand in the security
  342. 14:06group so within the security group
  343. 14:08basically there are two things one is
  344. 14:11there is inbound traffic
  345. 14:15and there is outbound traffic
  346. 14:19what is inbound and what is outbound
  347. 14:20basically when you deploy your
  348. 14:22application inside the ec2 instance
  349. 14:24right so if this is an ec2 instance and
  350. 14:26this is your application there are two
  351. 14:28kind of activities right what is the
  352. 14:30first activity as a user
  353. 14:33user will try to access your application
  354. 14:35and as an application probably you will
  355. 14:38try to access google.com or you will try
  356. 14:40to access something to get some kind of
  357. 14:42information or you want to access some
  358. 14:43third party application so this traffic
  359. 14:45that is flowing into your application
  360. 14:49okay this is called as inbound traffic
  361. 14:52and this traffic which is Flowing
  362. 14:54outside of your application is called as
  363. 14:56an outbound traffic
  364. 14:59for example let's say this application
  365. 15:01that we are talking about is amazon.com
  366. 15:04this is just a blunt example okay so
  367. 15:07user today I can be an user who will try
  368. 15:10to access amazon.com and amazon.com
  369. 15:13probably can access any third party
  370. 15:14application for example Razer pay
  371. 15:17or amazon.com can access other
  372. 15:19applications like Amazon pay
  373. 15:22to access Amazon pay amazon.com this
  374. 15:25request has to move out of uh this one
  375. 15:27right go out of
  376. 15:29your ec2 instance and access some other
  377. 15:31application that is Amazon pay and user
  378. 15:34will try to access the application so
  379. 15:35this
  380. 15:37access where user is trying to access
  381. 15:39amazon.com is called as inbound traffic
  382. 15:41whereas amazon.com trying to access
  383. 15:44the Razer pay or the Amazon pay is
  384. 15:46called as a outbound traffic okay so as
  385. 15:50part of security groups you can manage
  386. 15:51both inbound traffic and you can manage
  387. 15:54the outbound traffic that is traffic
  388. 15:56coming into your ec2 instance and
  389. 15:58traffic going out of your ec2 instance
  390. 15:59again like I told you you should be very
  391. 16:02careful because AWS by default what it
  392. 16:05does okay by default when you create a
  393. 16:07security group or by default when you
  394. 16:09create an ec2 instance AWS will assign a
  395. 16:11default Security Group because AWS will
  396. 16:14also take care of your security right so
  397. 16:17in this default Security Group what AWS
  398. 16:19says is hey what I'll do is by default I
  399. 16:23will allow
  400. 16:25all the outbound traffic okay all the
  401. 16:28outbound traffic I will allow like using
  402. 16:30your application you can access anything
  403. 16:32in the internet except for Port 25 I
  404. 16:35will tell you why uh there is a story
  405. 16:37behind this port 25 but except for Port
  406. 16:3925 I'll allow you all the outbound
  407. 16:42traffic and what AWS says is but
  408. 16:45anything that is coming inside okay
  409. 16:47anyone who is trying to access your
  410. 16:49application as inbound traffic I will
  411. 16:51deny everything by default okay in the
  412. 16:55security groups what aw is doing is for
  413. 16:57the inbound traffic and for the outboard
  414. 16:59traffic okay for the inbound traffic
  415. 17:00what AWS is saying is okay I have lot of
  416. 17:04restrictions here I don't want to allow
  417. 17:06anything if you want to allow anything
  418. 17:07then you can use the concept of Security
  419. 17:10Group inbound traffic rules and you can
  420. 17:12add the specific port number or the
  421. 17:14specific IP address where the traffic
  422. 17:16has to be accepted but as part of
  423. 17:18outbound traffic I'll allow everything
  424. 17:20and if you want to restrict okay or if
  425. 17:24you want to do any specific
  426. 17:25configuration you can do in the outbound
  427. 17:27traffic
  428. 17:28okay so this is the thing related to
  429. 17:31inbound and outbound traffic we will see
  430. 17:33in the Practical video how we can use
  431. 17:35this inbound traffic outbound traffic
  432. 17:36now talking about the story of Port 25
  433. 17:40so what happens with Port 25 is that so
  434. 17:43in this story AWS does not allow the
  435. 17:46outbound traffic default on the port 25
  436. 17:48because Port 25 is basically a mailing
  437. 17:51service okay so AWS does not want you to
  438. 17:54uh you know their AWS does not want any
  439. 17:57kind of spam activity or you know AWS
  440. 17:59does not want to record the IP address
  441. 18:01of this ec2 instance or record the IP
  442. 18:03address where your application is hosted
  443. 18:06so AWS by default blocks the port 25
  444. 18:08only outbound traffic there can be a lot
  445. 18:10of spamming activities or something like
  446. 18:12that
  447. 18:13okay so now let us see if Security Group
  448. 18:16is doing all of these things now why I
  449. 18:18need NaCl
  450. 18:20first of all what is NaCl right you
  451. 18:22might have this question Abhishek you
  452. 18:24have been talking about NaCl you uh keep
  453. 18:26saying NaCl NaCl what exactly is this
  454. 18:28NaCl so NaCl basically stands for
  455. 18:32Network
  456. 18:36access
  457. 18:39control list okay so this is a very
  458. 18:42complicated name that's why in the world
  459. 18:45of AWS people just call it as NaCl okay
  460. 18:49so NaCl network access control list
  461. 18:53basically goes a level Beyond okay so
  462. 18:57security groups is applied at the ec2
  463. 18:59instance level whereas NaCl is applied
  464. 19:02at the subnet level
  465. 19:04okay NaCl is applied at the subnet level
  466. 19:08now with NaCl devops Engineers can play
  467. 19:12even critical role because let's say you
  468. 19:15gave an ec2 instance for development
  469. 19:17team one
  470. 19:19and what this development team did is
  471. 19:22you know just to make their process
  472. 19:25quicker what they have done is they have
  473. 19:27deployed a Jenkins application or any
  474. 19:29other application they know that they
  475. 19:31should not allow all the traffic but to
  476. 19:34make it easy what they have done is they
  477. 19:36just said that okay I love all the
  478. 19:38traffic inside my ec2 instance instead
  479. 19:40they could have just opened port 8080
  480. 19:42but what they have done is they said
  481. 19:43okay accept everything
  482. 19:45I love all the traffic to my ec2
  483. 19:47instance and allow from all the IP
  484. 19:49address in the world it can be IP
  485. 19:51address from Turkey it can be IP address
  486. 19:53from India I love everywhere everything
  487. 19:55and you know I am fine with it so the
  488. 19:58problem is that this particular instance
  489. 19:59owner or this particular development
  490. 20:01green Development Group they have for
  491. 20:04some reason they have
  492. 20:06ignored the security aspect in the AWS
  493. 20:09right because security groups are meant
  494. 20:11to open only specific ports and allow
  495. 20:14only specific traffic into the ec2
  496. 20:16instance so how and what you can do as
  497. 20:18devops Engineers is instead of okay so
  498. 20:21this is fine every instance owner they
  499. 20:24can open specific ports whatever the
  500. 20:26traffic they would like to but
  501. 20:27additionally what AWS says is if you go
  502. 20:30back to the previous diagram where I
  503. 20:32said this is VPC and if this is public
  504. 20:34subnet this is private subnet right
  505. 20:37similarly there will be lot of private
  506. 20:39subnets
  507. 20:40so what AWS said is we will give you
  508. 20:43more access instead of instance owner
  509. 20:45defining what kind of ports or what kind
  510. 20:48of traffic is allowed if they do some
  511. 20:50kind of mistake there and if they say
  512. 20:51that allow all kind of traffic as devops
  513. 20:54internets or administrators you will
  514. 20:56have one more layer where at the subnet
  515. 20:58level at each of the subnet level what
  516. 21:01you can do is you can Define what kind
  517. 21:03of traffic do you want to deny
  518. 21:05understand this carefully here I am
  519. 21:08saying what kind of traffic do you want
  520. 21:09to deny so if you deny some traffic at
  521. 21:12the subnet layer even if you try to do
  522. 21:15that or even if you try to accept that
  523. 21:17at the security group layer there will
  524. 21:20not be any advantage so devops engineer
  525. 21:23Network Engineers or AWS administrators
  526. 21:25what they can do is they can make
  527. 21:28advantage of nacls to Define their
  528. 21:31organizational Network traffic
  529. 21:34okay so if something is applied at the
  530. 21:37subnet level then it is by default
  531. 21:39applied to all the instances within the
  532. 21:41subnet okay so if there are 50 ec2
  533. 21:44instances sorry if there are yeah if
  534. 21:47there are 50 ec2 instances inside this
  535. 21:49private subnet let's say you give this
  536. 21:51private subnet to development stream 3.
  537. 21:54this is just an example you gave them to
  538. 21:55development team 3 and what they have
  539. 21:58done is they have created 50 ec2
  540. 22:00instances in inside this private subnet
  541. 22:02and for some reason they said allow all
  542. 22:04traffic
  543. 22:05but because you have applied NaCl
  544. 22:08configuration and you said by default
  545. 22:10deny all the traffic and allow only
  546. 22:12specific things if you say that at the
  547. 22:14NaCl layer what will happen is AWS will
  548. 22:18deny all the traffic that is flowing in
  549. 22:20and only allow the configuration that is
  550. 22:22defined in the NaCl so NaCl will add as
  551. 22:26an additional layer of security
  552. 22:28got it so instead of applying the
  553. 22:31configuration for easer each and every
  554. 22:32ec2 instance also you can use NaCl for
  555. 22:35automation
  556. 22:36so maybe in your organization devops
  557. 22:40Engineers are the one who is taking care
  558. 22:41of the instance level security that is
  559. 22:44security groups as well as nacls then
  560. 22:47what you can do effectively is instead
  561. 22:49of adding security groups for each and
  562. 22:51every ec2 instance if you just apply
  563. 22:54NaCl to the subnet
  564. 22:56if there are 10 000 ec2 instances also
  565. 22:58this NaCl configuration is directly
  566. 23:01applied to all the 10 000 ec2 instances
  567. 23:04okay so that you can automate this
  568. 23:07manual activity of assigning the rules
  569. 23:10to each and every instance using
  570. 23:12Security Group
  571. 23:13so it is up to you whether you want to
  572. 23:16use Security Group whether you want to
  573. 23:18use NaCl or you want to use the
  574. 23:20combination of Security Group plus NaCl
  575. 23:24okay so NaCl basically the primary
  576. 23:28purpose is you can deny what kind of
  577. 23:30traffic that you would want to and you
  578. 23:32can allow what kind of traffic you want
  579. 23:33to whereas security groups is only for
  580. 23:36allowing Security Group does not have
  581. 23:39deny thing in Security Group you will
  582. 23:42only configure the rules for allowing
  583. 23:45so now we discussed so much here uh
  584. 23:48probably for some people there might be
  585. 23:50some kind of confusion so what we will
  586. 23:52do is we will try to deal this same
  587. 23:54thing practically and make it
  588. 23:57understandable for people
  589. 23:58practical part that I am going to
  590. 24:01demonstrate on the AWS account today so
  591. 24:04if you watch this carefully what I'm
  592. 24:06going to do today is this dotted lines
  593. 24:09represents virtual private Cloud so
  594. 24:11firstly I'll create a custom virtual
  595. 24:13private Cloud you haven't seen how to
  596. 24:15create virtual private Cloud so that's
  597. 24:16going to be interesting so firstly I'll
  598. 24:18show you how to create this virtual
  599. 24:20private Cloud on AWS and when you create
  600. 24:23virtual private Cloud as I told you
  601. 24:26security is a shared responsibility so
  602. 24:29as I create virtual private cloud and
  603. 24:31provide the IP address range AWS by
  604. 24:34default will create an internet gateway
  605. 24:36for me AWS by default will create NaCl
  606. 24:40with default configuration and AWS will
  607. 24:43create a route table additionally what
  608. 24:45I'll do is I will create an ec2 instance
  609. 24:48and attach a security group to this ec2
  610. 24:51instance now once we do this we will
  611. 24:54play with this Security Group
  612. 24:55configuration and NaCl and we will see
  613. 24:58how traffic flows into this ec2
  614. 25:00application sorry application inside the
  615. 25:03ec2 instance what happens if I block
  616. 25:05something in the security group what
  617. 25:07happens if I allow something in NaCl and
  618. 25:09block that thing in sorry allow
  619. 25:12something in Security Group and block
  620. 25:13that in NaCl right I love I love block I
  621. 25:16love will try a lot of things so let's
  622. 25:18see how does this configuration go and
  623. 25:21you can also try the same thing as your
  624. 25:23assignment so because I'll share you all
  625. 25:26the steps right now you can watch the
  626. 25:28video and you can follow the steps as I
  627. 25:30do
  628. 25:31so let's quickly go on to the AWS
  629. 25:33Management console here so this is the
  630. 25:36AWS Management console right so
  631. 25:39what I'll do now is move to the service
  632. 25:41called VPC so this is the VPC service
  633. 25:44some people might be watching this for
  634. 25:46the first time they might have not seen
  635. 25:48VPC before so what we will do here is
  636. 25:51once you go here you have lot of things
  637. 25:53within the VPC don't get scared some of
  638. 25:55these things you have already learned
  639. 25:57about in the previous classes what is
  640. 25:59VPC what is subnets Route tables
  641. 26:02internet gateway security groups today
  642. 26:04we learned about nacls as well if there
  643. 26:07are few things that you don't understand
  644. 26:08don't be scared eventually you will
  645. 26:10understand all of those things
  646. 26:12so click on VPC and let's click on
  647. 26:14create VPC
  648. 26:17okay so there is two options here I mean
  649. 26:20there are two options here VPC only VPC
  650. 26:23and more go for VPC and more because AWS
  651. 26:26will take care of creating the resources
  652. 26:29for you I mean the default resources for
  653. 26:31you for example when I create this VPC
  654. 26:34using VPC and more what AWS is going to
  655. 26:36do AWS is going to create public subnet
  656. 26:40for me as well as private subnet for me
  657. 26:42in both the availability zones right I
  658. 26:44am in the region North Virginia in North
  659. 26:46Virginia there are two availability
  660. 26:48zones us each one a U.S east 1B so AWS
  661. 26:53will create four subjects the public
  662. 26:55subnet and private subnet for me so that
  663. 26:57I don't have to create a lot of
  664. 26:58configuration in real time example like
  665. 27:01I told you public private subnet
  666. 27:02combination is used more
  667. 27:05then AWS is also going to create route
  668. 27:07tables for me finally it creates
  669. 27:10internet gateway igw stands for internet
  670. 27:12gateway and it also creates some VPC
  671. 27:15endpoints for S3 bucket which I'll tell
  672. 27:17you later right now S3 buckets is not
  673. 27:20taught in this series so don't worry
  674. 27:22perfect now what I'll do after this is
  675. 27:26you can provide any name or you can use
  676. 27:29the random name so I can provide some
  677. 27:31name here for this VPC let me call this
  678. 27:33name as demo VPC okay and
  679. 27:37this is exactly what I've been talking
  680. 27:39about so here if you see if I provide
  681. 27:42this configuration slash 1 6 what AWS is
  682. 27:45saying me that you will get
  683. 27:4765536 IPS if I want to modify if I just
  684. 27:50say this as 1.0
  685. 27:5324
  686. 27:55see what happened AWS said that you will
  687. 27:57get only 256 IP address so in future if
  688. 28:00you require more than 256 IP address
  689. 28:01then you have to modify this VPC but you
  690. 28:03have to add additional configuration so
  691. 28:06whenever you create the VPC if you have
  692. 28:08an understanding of what is this going
  693. 28:10to be what is the size then that's
  694. 28:12better and you can modify these things
  695. 28:13as well for example instead of 10.0.0.
  696. 28:17uh something you can also change this to
  697. 28:19192 series or whatever series that you
  698. 28:22would like to
  699. 28:23so let me just change this to
  700. 28:25whatever
  701. 28:27AWS was given by default and now what
  702. 28:30I'll do is here you can configure number
  703. 28:34of availability zones that you want
  704. 28:36technically I want only one availability
  705. 28:38Zone because this is just a demo thing
  706. 28:40but let it be you can go with the
  707. 28:42defaults at this point of time because
  708. 28:43you are just learning number of public
  709. 28:45subnets I want public subnet because if
  710. 28:48you go back to the diagram I am going to
  711. 28:50do this entire thing using public subnet
  712. 28:52only
  713. 28:55perfect
  714. 28:56uh all the configuration is provided now
  715. 28:59I can simply like this VPC endpoint uh
  716. 29:02right now you can put it as none as well
  717. 29:03but if you want to go with default let
  718. 29:05it be as S3 Gateway
  719. 29:06click on create VPC
  720. 29:10now the VPC configuration will be
  721. 29:12created see what exactly VPC is doing
  722. 29:14firstly it created the VPC then it is
  723. 29:17configuring the DNS we will learn about
  724. 29:19DNS tomorrow don't worry then VPC
  725. 29:22creation is done it has created subnet
  726. 29:24for me these are combinations of public
  727. 29:26and private subnet then it created
  728. 29:28internet gateway that's why I keep
  729. 29:30saying security is the shared
  730. 29:32responsibility AWS will create
  731. 29:34configurations for you Additionally you
  732. 29:36have to look at those configurations you
  733. 29:38have to modify those configurations if
  734. 29:41required add additional security if
  735. 29:43required AWS has then created route
  736. 29:45tables create route associate the route
  737. 29:48tables with the public private subnets
  738. 29:50and finally you know AWS has also done
  739. 29:53the route table creation okay so this is
  740. 29:56uh all the things that are created as
  741. 29:59part of this VPC workflow
  742. 30:01now let me go back to the VPC that is
  743. 30:03created for me
  744. 30:05and here you can also look at the rough
  745. 30:08diagram of how does this VPC look like
  746. 30:10just go to the resource map and here you
  747. 30:13will get a total picture of how we are
  748. 30:15newly created VPC is looking like so
  749. 30:17just spend some time here and try to
  750. 30:19understand what is happening here this
  751. 30:21is exactly what I have taught you on day
  752. 30:23four so you can understand if you don't
  753. 30:25understand you can ask me any specific
  754. 30:27question as well
  755. 30:29perfect now this part is done I've
  756. 30:32created the VPC AWS has created internet
  757. 30:35gateway for me see this is the default
  758. 30:36internet gateway in this picture you can
  759. 30:39see if you scroll down so this is the
  760. 30:41default Ingress Gateway that AWS has
  761. 30:43created for me and
  762. 30:45AWS also creates NaCl and security
  763. 30:48groups which you will see
  764. 30:50so let me go back and create the ec2
  765. 30:53instance now
  766. 30:54because I want to place the ec2 instance
  767. 30:56in the public subnet of the VPC and
  768. 30:59demonstrate security groups as well as
  769. 31:01NaCl
  770. 31:02go to instances
  771. 31:04click on launch instance
  772. 31:06what we will do different in today's
  773. 31:08class from the previous class where we
  774. 31:10created ec2 instance is let me call this
  775. 31:13as
  776. 31:14demo instance
  777. 31:16let me choose the flavor as Ubuntu
  778. 31:19T2 micro is fine for this class no
  779. 31:22problem
  780. 31:23provide the key value pair whatever you
  781. 31:25would like to use
  782. 31:26I'll use this one called AWS login for
  783. 31:30example
  784. 31:32here in the network configuration you
  785. 31:34have to edit this right so edit the
  786. 31:37network configuration and in the network
  787. 31:39configuration don't go with the default
  788. 31:41VPC default VPC is the one AWS creates
  789. 31:44for you so that you can start working
  790. 31:46with it if someone does not know the
  791. 31:48concept of VPC they just entered or they
  792. 31:51just started with AWS they can use this
  793. 31:53default VPC and they can play with it
  794. 31:55that's what we did on class 3 on the day
  795. 31:583 we use the default VPC which comes up
  796. 32:00with all the default configurations of
  797. 32:02AWS but now I want to play with my
  798. 32:04custom VPC
  799. 32:06in your organizations you will always
  800. 32:07use the custom VPC only so demo VPC let
  801. 32:10me click on this one
  802. 32:13and see what subnet is getting allocated
  803. 32:15to your instance right in this case AWS
  804. 32:19is saying that I will allocate the
  805. 32:20private subnet for you which is a
  806. 32:22General Industry practice by default you
  807. 32:24are easy to instance and the application
  808. 32:26should be in the private subnet but
  809. 32:27because today we are trying to
  810. 32:29understand this concept and not going in
  811. 32:31detail load balancer and all the other
  812. 32:33configurations so I will change this to
  813. 32:35the public subnet how do I do that just
  814. 32:38go back here and change the subnet demo
  815. 32:41subnet public one Us East one
  816. 32:44okay so because I mean the availability
  817. 32:47so I want to play with only one
  818. 32:49availability Zone I have choose the U.S
  819. 32:51east one availability Zone
  820. 32:53assign public IP address yes I need a
  821. 32:55public IP address for my ec2 instance
  822. 32:58create security group or select any
  823. 33:00existing Security Group like I told you
  824. 33:03if you are not aware of these Concepts
  825. 33:06then you can ask AWS you know to select
  826. 33:09any existing security groups but in this
  827. 33:11tutorial I'm going to play with the AWS
  828. 33:13use custom VPC so let me let AWS create
  829. 33:17Security Group for me and then let me
  830. 33:19tweak it
  831. 33:22rest all the configuration looks okay to
  832. 33:24me let me create on launch instance
  833. 33:27now what we will do is inside this
  834. 33:31AWS ec2 instance that is getting created
  835. 33:34for me I will install a python
  836. 33:36application okay I'll just use a very
  837. 33:39simple python application on this ec2
  838. 33:41instance and what I will do inside this
  839. 33:43python application is I'll run the
  840. 33:46application on Port 8000. and now I'll
  841. 33:49try to access by default you will I mean
  842. 33:52I think most of you already know that
  843. 33:54when you try to do this the security
  844. 33:56group will block because the default
  845. 33:58security group that AWS created for you
  846. 34:00will not allow the traffic directly you
  847. 34:03need to allow the traffic explicitly so
  848. 34:06I will enable all traffic I will enable
  849. 34:08Port 8000 and show you what happens and
  850. 34:11then we will try to block the traffic we
  851. 34:13will say block all traffic in NaCl and
  852. 34:16see what is going to happen
  853. 34:18okay so this is going to be interesting
  854. 34:20now the ec2 instance is also running
  855. 34:23let's get the IP address of the ec2
  856. 34:26instance and log into the ec2 instance
  857. 34:28using my terminal
  858. 34:30so this is my terminal
  859. 34:33what I'll do is SSH
  860. 34:41uh uh I hope I have that Pim key
  861. 34:45AWS login Pim perfect change the IP
  862. 34:48address also
  863. 34:52great so let's see uh login to the ec2
  864. 34:56instance and what is the first thing
  865. 34:57that you do after login to the ec2
  866. 34:59instance you need to update the packages
  867. 35:02right because I want to run the python
  868. 35:04application so firstly I want to update
  869. 35:06the packages see python is installed and
  870. 35:08then I will run a simple HTTP server so
  871. 35:13firstly do sudo
  872. 35:15apt update it will not take much time
  873. 35:21all the packages are getting updated
  874. 35:28it will not take much time here perfect
  875. 35:30all the packages are updated now now let
  876. 35:32me see if python is installed or not so
  877. 35:35let me just run Python 3 command perfect
  878. 35:36python is also installed now I will just
  879. 35:40run a very simple HTTP server on python
  880. 35:43for that you don't even write you don't
  881. 35:45even have to write a single command or
  882. 35:48you don't even have to write a single
  883. 35:49file just say Python 3 minus M HTTP dot
  884. 35:53server
  885. 35:54and provide the port whatever you would
  886. 35:57like to
  887. 35:58so a simple HTTP server is now running
  888. 36:01on Port 8000 ideally if you open this
  889. 36:04instance on this IP address and access
  890. 36:07the port 8000 you should be able to
  891. 36:09access but let's see what would happen
  892. 36:11so we saw the same thing in the last
  893. 36:13class as well on day three there I've
  894. 36:15used Jenkins and I start I try to access
  895. 36:18the IP address on Port 8000 which failed
  896. 36:22and then I enabled right so let's try to
  897. 36:24do the same thing now
  898. 36:26this is my instance
  899. 36:28copy the IP address
  900. 36:30just say HTTP colon IP address column
  901. 36:34Port 8000
  902. 36:36the application will not be accessed
  903. 36:38because what is happening let's go and
  904. 36:41see this is the ec2 instance this ec2
  905. 36:44instance is
  906. 36:45attached with the security group this is
  907. 36:48the default security group that is
  908. 36:49attached and what is happening in this
  909. 36:51default Security Group is that
  910. 36:54you know what AWS is saying is I will
  911. 36:57allow only Port 22 this is the port 22
  912. 37:00that is only allowed the reason is also
  913. 37:02because AWS want only you I mean AWS
  914. 37:06only wants to allow the SSH traffic if
  915. 37:08this is also not enough then we will not
  916. 37:10be able to even log into the ec2
  917. 37:11instance so only SSH is Aloft and let us
  918. 37:16see what is the NaCl configuration as
  919. 37:18well right so if we look at the NaCl
  920. 37:21configuration
  921. 37:24just go uh take I'll take a different
  922. 37:26tab here and open VPC
  923. 37:32Network ACLs
  924. 37:37so what is the network ACL attached to
  925. 37:39our VPC this is our VPC right demo VPC
  926. 37:41so let's go to that specific thing and
  927. 37:44see what are the inbound rules why are
  928. 37:46we looking at inbound rules because
  929. 37:47inbound rules is the one that is coming
  930. 37:50to our application so it says all the
  931. 37:54traffic is currently allowed so Network
  932. 37:57ACL which is the first layer of Defense
  933. 38:00okay which is the first layer of defense
  934. 38:02for the entire subnet what is configured
  935. 38:04here it said that okay allow all the
  936. 38:06traffic I don't have any problem you can
  937. 38:08say that there is also deny rule here
  938. 38:10but deny rule will only be triggered if
  939. 38:12this condition is not met okay so order
  940. 38:15goes with the order of priority whatever
  941. 38:18is here in the first row so it depends
  942. 38:20upon the number so least number will be
  943. 38:23here first let's say I'll configure one
  944. 38:25more Rule and the rule number is 200 so
  945. 38:28first rule 100 will be verified then
  946. 38:31rule 200 will be verified and finally it
  947. 38:33will go to rule star okay star is the
  948. 38:36last thing here this condition is matter
  949. 38:38right if this condition meets that is if
  950. 38:41all the traffic is allowed then there is
  951. 38:43no problem
  952. 38:45okay let's say here instead of all
  953. 38:47traffic I can also say only I love Uh
  954. 38:49custom TCP traffic of port 8000. or I
  955. 38:53can say I love only custom TCP traffic
  956. 38:56of Port 9000 which we will see but for
  957. 38:58now all traffic is enabled so no problem
  958. 39:00from NaCl what AWS did here is from the
  959. 39:04internet gateway you got entry into the
  960. 39:06subnet okay because NaCl is allowing all
  961. 39:10the traffic so internet gateway can
  962. 39:12forward the request to the route table
  963. 39:13if there is a load balancer here then
  964. 39:15the request would have gone to the load
  965. 39:17balancer from the route table request
  966. 39:18goes to the load balancer but because
  967. 39:20there is no load balancer here from
  968. 39:23internet gateway if NaCl accepts then
  969. 39:26the traffic goes to the route table
  970. 39:27right so let me add an arrow here so
  971. 39:30that it is much clearer
  972. 39:33so
  973. 39:35this is what has happened here from the
  974. 39:37NaCl Now traffic goes directly to the
  975. 39:40route table and routable would forward
  976. 39:42the request to the ec2 instance let's
  977. 39:44see what is happening and why if NaCl is
  978. 39:47accepting why the request is not going
  979. 39:49to the ec2 instance that is because
  980. 39:51Security Group is blocking it
  981. 39:53first layer of defense is clear but the
  982. 39:56second layer or the last layer of the
  983. 39:57defense which is Security Group is
  984. 39:59blocking the request now let's try to
  985. 40:01unblock it so for that go to the
  986. 40:05security group
  987. 40:08edit the inbound configuration
  988. 40:12add one more rule
  989. 40:16and inside this say
  990. 40:18I love Port 8000
  991. 40:20so custom DP TCP means the custom Port
  992. 40:248000 of TCP you are allowing Port 8000
  993. 40:27from any IP address for now you can say
  994. 40:30uh any IP address anywhere in the world
  995. 40:33uh the the resource that is using ipv
  996. 40:36for anywhere in the world just save the
  997. 40:37rules and as soon as it is saved you
  998. 40:40will see that the configuration will be
  999. 40:42applied to ec2 instance and if I just
  1000. 40:44refresh this page you will see the
  1001. 40:46output what is this output basically I'm
  1002. 40:49just running a simple HTTP server right
  1003. 40:51I'm not running anything more than that
  1004. 40:52this is a very simple HTTP server so
  1005. 40:55that's fine what is happening here is
  1006. 40:57the request that you have sent is
  1007. 40:59listing out the directories that are
  1008. 41:01available in that folder
  1009. 41:03anyways you got the request output you
  1010. 41:05can verify or validate this request
  1011. 41:07output here as well so you got 200
  1012. 41:09response that means the request is
  1013. 41:11successfully sent and you have got the
  1014. 41:13response back
  1015. 41:15now what if okay what if you have opened
  1016. 41:20this portrait so where is this in the
  1017. 41:22security inbound rules you have opened
  1018. 41:25this port let's say you are the instance
  1019. 41:26owner you are not the devops engineer
  1020. 41:28and as part of the instance ownership
  1021. 41:31what you have done is you have enabled
  1022. 41:33Port 8000 but your organization has a
  1023. 41:36very strict rule that the port 8000
  1024. 41:38should not be enabled so as devops
  1025. 41:40engineer you can configure this you can
  1026. 41:43control this thing at the NaCl level
  1027. 41:45itself because you cannot monitor each
  1028. 41:48and every ec2 instance and you cannot
  1029. 41:50control every ECU instance you can say
  1030. 41:52that for my organization or for this
  1031. 41:55particular VPC I will block Port 8000 in
  1032. 41:58the NaCl right or the network ACL
  1033. 42:01configuration see then what would happen
  1034. 42:03so the power of devops engineer using
  1035. 42:05nacls
  1036. 42:08this is Security Group where is NaCl
  1037. 42:10let's go to the NaCl Yep this is NaCl
  1038. 42:13this is the inbound rule what I will do
  1039. 42:16is edit inbound rules
  1040. 42:19instead of allowing all traffic just
  1041. 42:21remove this add new rule and what you
  1042. 42:24will say
  1043. 42:28is in this specific rule
  1044. 42:30let me call this rule as hundred
  1045. 42:33custom TCP me Port range 8000 I want to
  1046. 42:37block anything that is coming from
  1047. 42:38internet just deny
  1048. 42:41now let's save this change okay and
  1049. 42:44let's try to copy this URL take in a
  1050. 42:47different browser
  1051. 42:48and just try to enter it and see
  1052. 42:51now you will see that the request will
  1053. 42:53not reach the application that is
  1054. 42:55because devops engineering team has
  1055. 42:58blocked that specific IP range a devops
  1056. 43:01engineer has denied that particular
  1057. 43:03traffic in the NaCl so it will be
  1058. 43:05blocked for the entire subnet whether
  1059. 43:07you are easy to instance owner whether
  1060. 43:09you can be anything because the network
  1061. 43:11configuration is blocked you cannot
  1062. 43:13access now again let's try to edit this
  1063. 43:16inbound traffic rule
  1064. 43:18and say that for 100
  1065. 43:22I will just say all traffic
  1066. 43:25alert
  1067. 43:27save changes
  1068. 43:32edit inbound rule I will add one more
  1069. 43:35inbound rule okay and that inbound rule
  1070. 43:38foreign
  1071. 43:41okay custom TCP put 8 000 any guesses on
  1072. 43:46what would happen I will deny this let's
  1073. 43:49see how much you have understood here I
  1074. 43:51have added this rule number as 200 and
  1075. 43:53I've denied the traffic let's see if I
  1076. 43:56save changes and refresh this
  1077. 43:59you will see that the traffic is sent
  1078. 44:01even you have denied the configuration
  1079. 44:04in the NaCl because NaCl goes in this
  1080. 44:07specific order right so the order would
  1081. 44:10be first you will verify the I mean AWS
  1082. 44:14will verify the first lowest number the
  1083. 44:16lowest number is 100 or it goes with a
  1084. 44:19specific order that is mentioned here it
  1085. 44:21is mentioned in the ascending order
  1086. 44:22itself so firstly it will check rule
  1087. 44:25number 100 which says all traffic is
  1088. 44:27alarmed
  1089. 44:29so this rule is met AWS will forward the
  1090. 44:32request the request goes to Security
  1091. 44:34Group in the security group also you
  1092. 44:36have allowed that Port 8000 so it
  1093. 44:38directly reached the specific
  1094. 44:39application
  1095. 44:41what happens if I simply
  1096. 44:44rename this one like if I make this as
  1097. 44:46200
  1098. 44:48and if I make this as 100
  1099. 44:51save changes now
  1100. 44:54okay so let's say one by one
  1101. 44:58so let's keep this as uh
  1102. 45:02200 let's keep this as 110 okay you can
  1103. 45:06keep any number it just has to be the
  1104. 45:08order that's it now try to save the
  1105. 45:10changes so it will reflect and 110 goes
  1106. 45:13above enough so this is the first first
  1107. 45:15rule what it says is if the port number
  1108. 45:18is 8 000 block
  1109. 45:20if the port number is not 8000 then it
  1110. 45:22will go to the next rule what does the
  1111. 45:24next rule say I love all the traffic now
  1112. 45:26let us see what would happen just copy
  1113. 45:28this URL take this in a different Tab
  1114. 45:30and try to refresh again the traffic
  1115. 45:33will not reach the ec2 instance
  1116. 45:35the thing is now the application
  1117. 45:38developer will be confused hey what
  1118. 45:40happened I have I love the port 8000
  1119. 45:42here but still my application is not
  1120. 45:44getting the traffic because devops
  1121. 45:47engineer or the network Engineers have
  1122. 45:49blocked this specific Port now this port
  1123. 45:51they might have blocked because there
  1124. 45:53might be some security reasons there
  1125. 45:55might be some concerns it's not just
  1126. 45:57about the port but with the nacls you
  1127. 45:59can play around with different things
  1128. 46:01you can play around with the IP
  1129. 46:02addresses let's say you are worried
  1130. 46:04about some IP address that is coming
  1131. 46:06from XYZ country and you know the IP
  1132. 46:09address range you can say block the IP
  1133. 46:11address that is coming from
  1134. 46:133.4.5.6 range
  1135. 46:15or if you know the specific IP address
  1136. 46:17you can provide the specific IP address
  1137. 46:18if you know this if you don't know the
  1138. 46:20specific IP address you can provide the
  1139. 46:22range as well
  1140. 46:233.4.0.0 16.
  1141. 46:26right you can say anything you can block
  1142. 46:29on the IP address you can block on the
  1143. 46:31port range
  1144. 46:32you can play around with NaCl and
  1145. 46:34Security Group configuration so what you
  1146. 46:37have understood at the end even if you
  1147. 46:39allow the configuration in the security
  1148. 46:40groups NaCl acts as the first layer of
  1149. 46:43defense and devops Engineers as well as
  1150. 46:46system Engineers Network configurations
  1151. 46:48or the admins who has access to nacls
  1152. 46:51they can overall block the configuration
  1153. 46:53at the subnet level right so today we
  1154. 46:57understood the top topic of NaCl and
  1155. 46:59security groups with respect to allowing
  1156. 47:01the access and blocking the access
  1157. 47:03please take this as an assessment you
  1158. 47:05can watch this practical part one more
  1159. 47:07time and you can try this at your end
  1160. 47:09this is really really important today we
  1161. 47:12just tried with one public Subnet in
  1162. 47:14future we will enhance the scope we will
  1163. 47:16add the private subnets we will add load
  1164. 47:18balancers we will add API gateways We'll
  1165. 47:20add a lot of configuration multiple
  1166. 47:22availability zones so there this concept
  1167. 47:25you will understand even more in detail
  1168. 47:27way when we play with other components
  1169. 47:29of AWS but for that today you have to
  1170. 47:32practice this and let me know in the
  1171. 47:34comment section were you able to try the
  1172. 47:37assessment were you able to solve this
  1173. 47:39do you have any questions please let me
  1174. 47:41know in the comment section and I'll
  1175. 47:42more than happy to reply to it thank you
  1176. 47:45so much for watching today's video I
  1177. 47:46hope you found this informative please
  1178. 47:48share this video with your friends our
  1179. 47:50colleagues who are looking to learn AWS
  1180. 47:52see you all in the next video take care
  1181. 47:55bye

About this transcript

This page contains the full transcript of YouTube transcript (TtlKFgfN3PU) , generated from the public captions YouTube serves with the video. The transcript has 8,098 words across 1,181 segments, with the original timestamps preserved so you can click any line to jump to that moment in the embedded player.

What you can do with it

Use the transcript to take notes, quote the speaker, build a study guide, generate a summary with ChatGPT or Claude via the YouTube Summary tool, or export it as a timed subtitle file with YouTube to SRT. You can also re-open it in the transcriber to choose a caption track available on the video.

Free YouTube transcript tool

YouTube2Text is a free YouTube transcript generator — no signup, no daily limit. Paste any YouTube link and get the full transcript instantly, with timestamps, click-to-jump, caption language selection, AI prompts for ChatGPT, Claude, and Gemini, and exports to TXT, SRT, VTT, or Markdown.