GuppY Help Center, help online, documentation and tutorials

 
Search
 
Close
GuppY 5.02

telecharger.png

logo_nuxit_guppy.png
You are here :   Welcome » Htaccess file in the root of your site
 
Preview  Print...  Print this page...
Preview  Print...  Print this section...
FAQ GuppY <= 4.6.xx

In this menu you will find all the FAQs on earlier versions of GuppY.

 ↑  
FAQ GuppY v 5.01.xx

Here you will find FAQs on Guppy version 5.01.xx.

 ↑  
FAQ system

These FAQs address issues related to hosting and the system in general.

Documentation

In this box you will find documentation and tutorials

 ↑  
Legal

Here you will find important information regarding regulations and copyright

 ↑  
rss This article is available in the standard RSS format for publication on your website :
https://ghc.freeguppy.org/data/en-articles.xml

Translation by Google - Update the current translation

Htaccess native to the root of your site Guppy V5

Guppy is available with a. Htaccess file in the root. This file is only useful if your web server is running Apache (the most common web server). You may have to configure it to be effective.

 Configure Native htaccess.


The structure of this htaccess :

AddDefaultCharset UTF-8
[Files ~ ".inc"]
Order allow,deny
Deny from all
Satisfy All
[/Files]
[Files ~ ".dtb"]
Order allow,deny
Deny from all
Satisfy All
[/Files]
ErrorDocument 400 /error.php?err=400
ErrorDocument 403 /error.php?err=403
ErrorDocument 404 /error.php?err=404
ErrorDocument 500 /error.php?err=500

The first line below causes the server to use the default UTF-8 charset

The following 10 are used to protect the contents of your database prying eyes of malicious users (and there are!). are legible and can even be used to power a Spam file. These 10 lines are notto.

The following four lines are used to redirect users to the error page when requesting a non-existent page, etc ... These must be adapted by you (via a simple text editor like Notepad + + for example) depending on where placed your Guppy.

So if you installed it to the root of your site (URL = http://www.yoursite.com/) then you have nothing to do. By cons, if you installed it in a directory of your site (URL = http://www.yoursite.com/ici/ for example) and then you need to change these 4 lines:

ErrorDocument 400 /ici/error.php?err=400
ErrorDocument 403 /ici/error.php?err=403
ErrorDocument 404 /ici/error.php?err=404
ErrorDocument 500 /ici/error.php?err=500

In some cases, you may need to change these and 4 lines (for a site whose URL is http://www.yoursite.com/). This is particularly true when we installed a htaccess authentication for admin and that following the installation site is in error 500:


ErrorDocument 400 http://www.votresite.com/error.php?err=400
ErrorDocument 403 http://www.votresite.com/error.php?err=403
ErrorDocument 404 http://www.votresite.com/error.php?err=404
ErrorDocument 500 http://www.votresite.com/error.php?err=500

Or, if installed in the subdirectory here / :

ErrorDocument 400 http://www.votresite.com/ici/error.php?err=400
ErrorDocument 403 http://www.votresite.com/ici/error.php?err=403
ErrorDocument 404 http://www.votresite.com/ici/error.php?err=404
ErrorDocument 500 http://www.votresite.com/ici/error.php?err=500
------------------------------------------------------------------

Note: As a way of asking htaccess is usually specific to your web host, thank you to consult its documentation about it.. For more information on protecting your site. Htaccess, refer to the official Apache documentation.

  • Since March 2013 spam attacks extensively by robots led us to propose a htaccess file "spam" for the root of your site.

It is a native as that described above but includes more lines deny from the IP block for most of known spammers file. This file is available for download on freeguppy.org and is updated periodically.

We strongly advise you to use to block spam using these intensive much bandwidth is allocated to you even if these hackers can not post on your site because of other securities offered in Guppy Version 5. smile

Below is an excerpt from that. Htaccess file:

Salmon in a directive that forces UTF-8 - In Orange extract the part of htaccess "spam" - In Yellow part of the standard htaccess

# Beginning of file. Htaccess

# Lapremière line below causes the server to use the default UTF-8 charset

AddDefaultCharset UTF-8

<Files *>

order deny,allow

# Cambodia (KH)

deny from 114.134.184.0/21

# Chinese (CN)

deny from 1.80.0.0/13 1.192.0.0/13 1.202.0.0/15 14.144.0.0/12 14.208.0.0/12 27.8.0.0/13 27.16.0.0/12 27.36.0.0/14 27.40.0.0/13 27.54.192.0/18 27.106.128.0/18 27.115.0.0/17 27.152.0.0/13 27.184.0.0/13 36.248.0.0/14 42.96.128.0/17 58.16.0.0/15 58.20.0.0/16 58.21.0.0/16 58.22.0.0/15 58.34.0.0/16 58.37.0.0/16 58.38.0.0/16 58.40.0.0/16 58.42.0.0/16 58.44.0.0/14 58.48.0.0/13 220.160.0.0/15 220.162.0.0/16 220.250.32.0/20

# ajout 27.07.2013

deny from 5.254.142.0/24 37.59.67.192/29 199.68.216.0/22

# ajout 29.07.2013

deny from 5.9.88.64/27 75.98.0.0/18 75.98.64.0/19 81.144.138.32/27 174.129.0.0/16 199.188.105.24/29

# ajout 01.08.2013

deny from 36.40.0.0/13 37.139.52.0/24 62.75.236.0/26 62.141.36.0/22 62.141.40.0/23 62.141.42.0/24 62.141.43.0/25 87.117.229.0/24 94.156.12.128/25 101.32.0.0/12 107.6.0.0/18 109.238.231.0/24 109.238.232.0/21 113.200.0.0/15 123.139.12.0/22 123.139.76.0/24 173.252.192.0/18 192.210.48.0/20 195.199.214.144/29 199.187.122.88/29 202.110.64.0/18 204.232.128.0/17 216.99.144.0/20 220.168.0.0/17

</Files>

<Files ~ "^.ht">

Order allow,deny

Deny from all

Satisfy All

</Files>

<Files ~ "^.*.(inc|dtb)">

Order allow,deny

Deny from all

Satisfy all

</Files>

ErrorDocument 400 http://www.votre_site.com/error.php?err=400

ErrorDocument 403 http://www.votre_site.com/error.php?err=403

ErrorDocument 404 http://www.votre_site.com/error.php?err=404

ErrorDocument 500 http://www.votre_site.com/error.php?err=500

# End of file

  • From version 5 Guppy this file is also used for URL rewriting which added to the htaccess root lines generated by Guppy when this mode is selected and that the host permits the n is not the case for example of free.fr.

Version 5 Guppy writes url rewriting rules at the end of the file. Htaccess at the root of your site Guppy Version 5

Below is an excerpt from the end of the htaccess file if URL rewriting is enabled.:

# URL rewriting

# this section applies URL rewriting and must be placed at the end
Options +FollowSymlinks
RewriteEngine On
RewriteCond %{ENV:REDIRECT_STATUS} 200
RewriteRule .* - [S=200]
RewriteCond %{ENV:REDIRECT_STATUS} 200
RewriteRule .* - [S=200]
RewriteRule ^([a-z]{2})-(accueil)$ index.php?lng=$1 [L]
RewriteRule ^([a-z]{2})-(accueil-1)-(-?[123])$ index.php?lng=$1&prt=$3 [L]
RewriteRule ^admin/([a-z]{2})-(accueil-19)$ admin/admin.php?lng=$1 [L]

  • Specific "guidelines" can also be written in the same file for many reasons. Below is a directive that is in the first line. Htaccess file in the root of your site Guppy Version 5.xx

AddDefaultCharset UTF-8

See the Apache documentation for more details.

* additional htaccess


You must also protect your admin / directory using a username and password specific, installing a second htaccess follow this procedure.


Creation date : 06/02/2014 @ 09:26
Category : - Securing your website
Page read 8975 times

You are here :   Welcome » Htaccess file in the root of your site
 
Preview  Print...  Print this page...
Preview  Print...  Print this section...
Visits

 1508475 visitors

 137 visitors online

Webmaster - Infos
Help

aide_help.png
On each page in admin, if you click on this icon, you get the online help page.

Site registered in the CNIL under agrément 1040387.
You have a right of access, modification, rectification and deletion
of the data according to the Computer law and Freedom (article 34) of January 6th, 1978.

 

The FreeGuppY.org hosting is provided by Nuxit.com our partner