sddns/.htaccess

38 lines
1.1 KiB
ApacheConf
Raw Normal View History

2017-08-05 17:29:32 +02:00
RewriteEngine on
2010-08-17 01:23:57 +02:00
2017-08-05 17:29:32 +02:00
# Frontend
RewriteCond %{REQUEST_URI} ^/simple$ [OR]
RewriteCond %{REQUEST_URI} ^/expert$
RewriteRule (.*) $1.php [QSA]
2010-08-17 01:23:57 +02:00
2017-08-05 17:29:32 +02:00
# Actions
RewriteCond %{REQUEST_URI} ^/ip [OR]
RewriteCond %{REQUEST_URI} ^/add [OR]
RewriteCond %{REQUEST_URI} ^/delete [OR]
RewriteCond %{REQUEST_URI} ^/update [OR]
RewriteCond %{REQUEST_URI} ^/admin/cleanup [OR]
RewriteCond %{REQUEST_URI} ^/admin/sync [OR]
RewriteCond %{REQUEST_URI} ^/admin/parse [OR]
RewriteCond %{REQUEST_URI} ^/admin/get [OR]
RewriteCond %{REQUEST_URI} ^/admin/stats/types [OR]
RewriteCond %{REQUEST_URI} ^/admin/stats/hosts
RewriteRule (.*)\.(xml|html|gif|png|txt|csv|json|) $1.php?format=$2 [QSA,S=1]
# Tiny URL
RewriteCond %{HTTP_HOST} ^(s|t).(0l.de)$
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} /(.+)
RewriteRule .* index.php?host=%1
# Querystring
2012-03-17 12:56:46 +01:00
RewriteCond %{QUERY_STRING} !zone=(0l.de)
2017-08-05 17:29:32 +02:00
RewriteCond %{HTTP_HOST} (0l.de)$
RewriteRule (.*)(\?)? $1?zone=%1 [QSA]
2010-08-17 01:23:57 +02:00
2017-08-05 17:29:32 +02:00
RewriteCond %{QUERY_STRING} !host=[a-z0-9.-]+
RewriteCond %{HTTP_HOST} !^(d|s|t|ip4|ip6)\.(0l.de)$
RewriteCond %{HTTP_HOST} ([a-z0-9.-]+)\.(0l.de)$
RewriteRule (.*)(\?)? $1?host=%1 [QSA]
2010-08-17 01:23:57 +02:00
ExpiresActive Off