2
0
Fork 0
mirror of https://github.com/phanan/htaccess.git synced 2018-11-08 13:39:40 +01:00

Backtick and unbacktick

This commit is contained in:
An Phan 2015-07-12 23:41:27 +08:00
parent 9b4c724140
commit 4280ced0e6

View file

@ -196,7 +196,7 @@ Allow from xxx.xxx.xxx.xxx
# Require all denied # Require all denied
# Require ip xxx.xxx.xxx.xxx # Require ip xxx.xxx.xxx.xxx
``` ```
`xxx.xxx.xxx.xxx` is your IP. If you replace the last three digits with 0/12 for example, this will specify a range of IPs within the same network, thus saving you the trouble to list all allowed IPs separately. [Source](http://speckyboy.com/2013/01/08/useful-htaccess-snippets-and-hacks/) `xxx.xxx.xxx.xxx` is your IP. If you replace the last three digits with `0/12` for example, this will specify a range of IPs within the same network, thus saving you the trouble to list all allowed IPs separately. [Source](http://speckyboy.com/2013/01/08/useful-htaccess-snippets-and-hacks/)
Now of course there's a reversed version: Now of course there's a reversed version:
@ -221,7 +221,7 @@ RewriteCond %{SCRIPT_FILENAME} -f
RewriteRule "(^|/)\." - [F] RewriteRule "(^|/)\." - [F]
``` ```
Alternatively, you can just raise a `Not Found` error, giving the attacker dude no clue: Alternatively, you can just raise a "Not Found" error, giving the attacker dude no clue:
``` apacheconf ``` apacheconf
RedirectMatch 404 /\..*$ RedirectMatch 404 /\..*$
``` ```