READ Free Dumps For RedHat- RH302
Question ID 17474 | You want to deny to user1 and user2 users to access files via ftp. Configure to deny |
Option A | Answer : 1.vi /etc/vsftpd/ftpusers user1 user2 2.service vsftpd start| restart Using /etc/vsftpd/ftpusers file we can deny to certain users to access files via ftp. As well as there is another file named /etc/vsftpd.user_list can be used to allow or to deny to users. |
Correct Answer | A |
Question ID 17475 | Configure the web server for www.abc.com associated IP address is 192.100.0.1 by |
Option A | Answer : 1.vi /etc/httpd/conf/httpd.conf <VirtualHost 192.100.0.1> ServerName www.abc.com DocumentRoot /var/www/abc/ <Directory /var/www/abc> AllowOverrideauthconfig </Directory> DirectoryIndexindex.html ServerAdminwebmaster@abc.com ErrorLog logs/error_abc.logs CustomLog logs/custom_abc.logs common </VirtualHost> 2.Create the directory and index page on specified path. (Index page can download from //server1.example.com at exam time) httpd_sys_content_t /var/www/html/index.html If SELinux Context is mismatched, use the restorecon R /var command 3.vi /var/www/abc/.htaccess AuthNameOnly to Authorized Users AuthTypebasic AuthUserFile/etc/httpd/conf/mypasswd requirevalid-user httpd_sys_content_t .htaccess htpasswd c /etc/httpd/conf/mypasswd user5 htpasswd m /etc/httpd/conf/mypasswd user6 chgrp apache /etc/httpd/conf/mypasswd chmod g+r /etc/httpd/conf/mypasswd httpd_config_t /etc/httpd/conf/mypasswd Use restorecon command to restore the mismatched SELinux Context of the file. service httpd restart chkconfig httpd on AllowOverride Authconfig is used to specify which and how much configuration can be overridden by directory specific .htaccess files. One of the most common tasks performed in users .htaccess files is adding authorization. Typically, a user will setup authorization for directories that hold sensitive information with a configuration. |
Correct Answer | A |