1 00:00:07,830 --> 00:00:09,903 - So useradd anna. 2 00:00:12,090 --> 00:00:16,480 And echo password | passwd standard in anna. 3 00:00:20,970 --> 00:00:22,980 Which is a cool way that you can use scripts 4 00:00:22,980 --> 00:00:24,570 to set passwords. 5 00:00:24,570 --> 00:00:26,640 The inconvenience is that echo password, 6 00:00:26,640 --> 00:00:28,410 well password is set to password 7 00:00:28,410 --> 00:00:31,230 and that's stored in history. 8 00:00:31,230 --> 00:00:32,130 Does that matter? 9 00:00:32,130 --> 00:00:34,380 No, not really for this demo. 10 00:00:34,380 --> 00:00:36,660 Now we need to make sure that user Anna 11 00:00:36,660 --> 00:00:41,190 can modify the content of ETCMOTD by using ACLs. 12 00:00:41,190 --> 00:00:42,630 So what are we going to do? 13 00:00:42,630 --> 00:00:47,630 Well setfacl -m for modify. 14 00:00:49,680 --> 00:00:54,483 U:anna:rw /etc/motd. 15 00:00:56,160 --> 00:01:01,160 Now I'm using getfacl /etc/motd. 16 00:01:01,440 --> 00:01:02,460 And what do we see? 17 00:01:02,460 --> 00:01:04,260 We see the user Anna has been added 18 00:01:04,260 --> 00:01:06,570 to read write permissions. 19 00:01:06,570 --> 00:01:08,400 So let's check if that is really working 20 00:01:08,400 --> 00:01:11,040 by opening a shell as user Anna, 21 00:01:11,040 --> 00:01:15,723 and by using vim on ETCMOTD. 22 00:01:17,370 --> 00:01:18,633 Hello world. 23 00:01:20,040 --> 00:01:22,680 And as you can see, user Anna can do that. 24 00:01:22,680 --> 00:01:25,050 That means that the ACL is successful. 25 00:01:25,050 --> 00:01:25,883 That's all.