Re: Is it possible to exclude a directory from listing?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Thank you for your reply.
The "wp-content" directory is a sub-directory of "wp" directory:
$ ls /var/www/wp/
cgi-bin                                              wp-content
error_log                                          wp-cron.php
googlee4e6cdb3b56c49dd.html      wp-includes
index.php                                         wp-links-opml.php
license.txt                                         wp-load.php
readme.html                                     wp-login.php
ssl                                                     wp-mail.php
wordfence-waf.php                           wp-settings.php
wp-activate.php                                wp-signup.php
wp-admin                                          wp-statistics.log
wp-blog-header.php                          wp-trackback.php
wp-comments-post.php                     xmlrpc.php
wp-config.php                                    zhupclient_key.1567309333.html
wp-config-sample.php                       zhupclient_key.1567317901.html


How about "AllowOverride All"? 
If I want to disable the Directory Listing for all directories then what should my settings be like?
If I want to disable the Directory Listing for all directories except "wp-includes" directory then what should my settings be like?

Thank you.





On Friday, January 22, 2021, 01:11:41 AM GMT+3:30, Antony Stone <antony.stone@xxxxxxxxxxxxxxxxxxxxx> wrote: 





On Thursday 21 January 2021 at 22:09:39, Jason Long wrote:

> I did:
> <Directory "/var/www/wp">
> Options -Indexes
> AllowOverride All
> Require all granted
> </Directory>
> 
> But when I browse "https://MyDomain.net/wp-content/plugins"; then I can see
> the content of the plugins directory! Why?

Perhaps because "wp-content" is not the same as "wp"?

You've told us what your settings are for "/var/www/wp".

We have no idea how this relates to "https://MyDomain.net/wp-content/plugins";

Show us more of your configuration and someone might be able to help.

Oh, and by the way, why do you want "AllowOverride All"?


Antony.

-- 
Never write it in Perl if you can do it in Awk.
Never do it in Awk if sed can handle it.
Never use sed when tr can do the job.
Never invoke tr when cat is sufficient.
Avoid using cat whenever possible.

                                                  Please reply to the list;
                                                        please *don't* CC me.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx





[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux