How To Use .htaccess to Prevent Apache HTTPD Directory Listing Come utilizzare. Htaccess per prevenire httpd Apache Directory Listing
Apache HTTPD servers are configured by default to display directory listing, when index files like index.htm or index.html of index.php etc. are not present in the directory. Apache HTTPD server sono configurati per impostazione predefinita per visualizzare l'elenco directory, quando indice di file come index.htm o index.html index.php di ecc non sono presenti nella directory. This can expose sensitive information to prying eyes and are often indexed by search engines. Questo può esporre informazioni sensibili a occhi indiscreti e sono spesso indicizzati dai motori di ricerca. This can compromise your data by making it visible to unintended audience. Questo può compromettere i tuoi dati di renderlo visibile a involontaria pubblico. The solution is simple. La soluzione è semplice. You can add a line to your .htaccess file (create the file if not present) to prevent directory listing for that directory and its sub-directories: È possibile aggiungere una linea al file. Htaccess file (creare il file se non presente) per prevenire l'elenco directory per tale directory e per i suoi sotto-directory:
IndexIgnore * IndexIgnore *
The * matches all files in the directory. * Le partite di tutti i file nella directory. You can also restrict only a subset of file from being displayed. È anche possibile limitare solo un sottoinsieme di file da visualizzare. For example if you would want the directory content to be listed but not include the images in the listings then you should use this command: Per esempio, se si desidera che il contenuto di directory per essere elencati, ma non comprende le immagini nelle inserzioni allora dovreste usare questo comando:
IndexIgnore *.png *.gif *.jpg IndexIgnore *. png *. gif *. jpg
This would return a list of all files not ending in .png, .jpg or .gif, but would still list .txt, .html, etc. Ciò restituisce un elenco di tutti i file non terminano in. Png,. Jpg o. Gif, ma sarebbe ancora lista. Txt,. Html, ecc
On the other hand if your server is setup to prevent directory listing, but you want to list the directories by default, then add the following in your .htaccess file: D'altro canto, se il tuo server è configurato per impedire l'elenco directory, ma si desidera elencare le directory di default, quindi aggiungere il seguente nel file. Htaccess file:
Options +Indexes Opzioni + Indici
Filed under Elencato sotto Headline News Headline News , How To Come , Open Source Software Software open source , Web | |
| |
RSS 2.0 RSS 2,0 | |
Trackback this Article | questo articolo |
Email this Article Invia questo articolo
You may also like to read Si può anche leggere come |




