clipbucket/upload/.htaccess

98 lines
3.4 KiB
ApacheConf
Raw Normal View History

2009-08-25 12:16:42 +00:00
#<IfModule mod_security.c>
# secfilterengine off
# secfilterscanPOST off
#</IfModule>
#Options +Indexes
2009-08-28 22:59:51 +00:00
#php_flag safe_mode off
#php_value max_execution_time 1000
#php_value session.gc_maxlifetime 14000
#php_value output_buffering on
#php_value upload_max_filesize 2147483648
#php_value post_max_size 2147483648
2009-08-25 12:16:42 +00:00
#php_flag display_errors off
Options All -Indexes
FileETag MTime Size
Options +FollowSymlinks
RewriteEngine on
<FilesMatch "\.(db|inc|tmpl|h|ihtml|sql|ini|configuration|config|class|bin|spd|theme|module|cfg|cpl|tmp|log|err|inc.php|class.php)$">
2009-08-25 12:16:42 +00:00
order allow,deny
satisfy all
</FilesMatch>
########## Begin - Rewrite rules to block out some common exploits
#
# Block out any script trying to set a mosConfig value through the URL
RewriteCond %{QUERY_STRING} mosConfig_[a-zA-Z_]{1,21}(=|\%3D) [OR]
# Block out any script trying to base64_encode crap to send via URL
RewriteCond %{QUERY_STRING} base64_encode.*\(.*\) [OR]
# Block out any script that includes a <script> tag in URL
RewriteCond %{QUERY_STRING} (\<|%3C).*script.*(\>|%3E) [NC,OR]
# Block out any script trying to set a PHP GLOBALS variable via URL
RewriteCond %{QUERY_STRING} GLOBALS(=|\[|\%[0-9A-Z]{0,2}) [OR]
# Block out any script trying to modify a _REQUEST variable via URL
RewriteCond %{QUERY_STRING} _REQUEST(=|\[|\%[0-9A-Z]{0,2})
# Send all blocked request to homepage with 403 Forbidden error!
#RewriteRule ^(.*)$ index.php [L]
RewriteRule ^([^.]*)/?$ index.php [L]
#
########## End - Rewrite rules to block out some common exploits
########## Begin - Rewrite rules For SEO urls ######################
#
#Options +FollowSymlinks
#RewriteEngine on
#
#
#
#URL Rewriting for Videos
2010-01-28 15:32:46 +00:00
RewriteRule ^videos/([0-9A-Za-z]+)/(.*)/(.*)/(.*)/(.*) videos.php?cat=$1&sort=$3&time=$4&page=$5&seo_cat_name=$2 [L]
RewriteRule ^videos videos.php [L]
RewriteRule ^video/(.*)/(.*) watch_video.php?v=$1&%{QUERY_STRING} [L]
2009-08-25 12:16:42 +00:00
#
#Users, Channel & Management
#
RewriteRule ^channels/([0-9A-Za-z]+)/(.*)/(.*)/(.*)/(.*) channels.php?cat=$1&sort=$3&time=$4&page=$5&seo_cat_name=$2 [L]
RewriteRule ^channels channels.php [L]
2009-08-25 12:16:42 +00:00
RewriteRule ^members/ channels.php [nc]
RewriteRule ^users/ channels.php [nc]
RewriteRule ^user/(.*) view_channel.php?user=$1 [nc]
2009-08-25 12:16:42 +00:00
RewriteRule ^channel/(.*) view_channel.php?user=$1 [nc]
RewriteRule ^my_account myaccount.php [nc]
2009-08-25 12:16:42 +00:00
#Pages
RewriteRule ^page/([0-9]+)/(.*) view_page.php?pid=$1 [nc]
2009-08-25 12:16:42 +00:00
#
#Miscellenous
RewriteRule ^search/result search_result.php [nc]
RewriteRule ^upload upload.php [nc]
#Group Section
RewriteRule ^group/([a-zA-Z0-9].+) view_group.php?url=$1&%{QUERY_STRING} [L]
RewriteRule ^view_topic/([a-zA-Z0-9].+)_tid_([0-9]+) view_topic.php?tid=$2&%{QUERY_STRING} [L]
RewriteRule ^groups/([0-9]+)/(.*)/(.*)/(.*)/(.*) groups.php?cat=$1&sort=$3&time=$4&page=$5&seo_cat_name=$2 [L]
RewriteRule ^groups groups.php [L]
RewriteRule ^create_group create_group.php [L]
2009-08-25 12:16:42 +00:00
RewriteRule ^sitemap.xml$ sitemap.php
RewriteRule ^signup signup.php
2009-08-25 12:16:42 +00:00
#Error Pages
ErrorDocument 404 /view_page.php?pid=6
ErrorDocument 403 /view_page.php?pid=5
2009-08-25 12:16:42 +00:00
########## End - Rewrite rules For SEO urls ######################
RewriteRule ^rss$ rss.php [nc]
2010-01-19 06:45:35 +00:00
RewriteRule ^rss/([a-zA-Z0-9].+)$ rss.php?mode=$1 [nc]
2009-08-25 12:16:42 +00:00
########## End - Rewrite rules For SEO urls ######################