{"id":364,"date":"2020-05-29T16:49:32","date_gmt":"2020-05-29T23:49:32","guid":{"rendered":"https:\/\/SUMMALAI.COM\/?p=364"},"modified":"2020-05-29T16:49:32","modified_gmt":"2020-05-29T23:49:32","slug":"the-best-way-to-disable-directory-browsing-on-apache","status":"publish","type":"post","link":"https:\/\/SUMMALAI.COM\/?p=364","title":{"rendered":"The best way to disable directory browsing on Apache"},"content":{"rendered":"\n<p>The best way to do this is to disable it with webserver apache2. In Ubuntu open\u00a0<code>\/etc\/apache2\/apache2.conf<\/code>\u00a0 in Centos, open <strong> \/etc\/httpd\/conf\/httpd.conf<\/strong><\/p>\n\n\n\n<p>change from<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>&lt;Directory \/var\/www\/>\n        Options Indexes FollowSymLinks\n        AllowOverride None\n        Require all granted\n&lt;\/Directory>\n<\/code><\/pre>\n\n\n\n<p>to<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>&lt;Directory \/var\/www\/>\n        Options FollowSymLinks\n        AllowOverride None\n        Require all granted\n&lt;\/Directory>\n<\/code><\/pre>\n\n\n\n<p>then restart apache by:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo service apache2 reload\nor \nsystemctl reload httpd<\/code><\/pre>\n\n\n\n<p>This will disable directory listing from all folder that apache2 serves.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>The best way to do this is to disable it with webserver apache2. In Ubuntu open\u00a0\/etc\/apache2\/apache2.conf\u00a0 in Centos, open \/etc\/httpd\/conf\/httpd.conf change from to then restart apache by: This will disable directory listing from all folder that apache2 serves.<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_bbp_topic_count":0,"_bbp_reply_count":0,"_bbp_total_topic_count":0,"_bbp_total_reply_count":0,"_bbp_voice_count":0,"_bbp_anonymous_reply_count":0,"_bbp_topic_count_hidden":0,"_bbp_reply_count_hidden":0,"_bbp_forum_subforum_count":0,"om_disable_all_campaigns":false,"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[5],"tags":[],"class_list":["post-364","post","type-post","status-publish","format-standard","hentry","category-linux"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/SUMMALAI.COM\/index.php?rest_route=\/wp\/v2\/posts\/364","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/SUMMALAI.COM\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/SUMMALAI.COM\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/SUMMALAI.COM\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/SUMMALAI.COM\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=364"}],"version-history":[{"count":0,"href":"https:\/\/SUMMALAI.COM\/index.php?rest_route=\/wp\/v2\/posts\/364\/revisions"}],"wp:attachment":[{"href":"https:\/\/SUMMALAI.COM\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=364"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/SUMMALAI.COM\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=364"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/SUMMALAI.COM\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=364"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}