| 1 | RewriteEngine on |
|---|
| 2 | |
|---|
| 3 | #SQL Injection Protection --Read More www.cybercrime.gov |
|---|
| 4 | #Please use these rules if below words does not conflict with your friendly-urls. You may modify accordingly |
|---|
| 5 | RewriteRule ^.*EXEC\(@.*$ /notfound.htm [L,F,NC] |
|---|
| 6 | RewriteRule ^.*CAST\(.*$ /notfound.htm [L,F,NC] |
|---|
| 7 | RewriteRule ^.*DECLARE.*$ /notfound.htm [L,F,NC] |
|---|
| 8 | RewriteRule ^.*DECLARE%20.*$ /notfound.htm [L,F,NC] |
|---|
| 9 | RewriteRule ^.*NVARCHAR.*$ /notfound.htm [L,F,NC] |
|---|
| 10 | RewriteRule ^.*sp_password.*$ /notfound.htm [L,F,NC] |
|---|
| 11 | RewriteRule ^.*%20xp_.*$ /notfound.htm [L,F,NC] |
|---|
| 12 | |
|---|
| 13 | #Ignore images and this would be last rule --if the condition matched |
|---|
| 14 | RewriteRule ^/(.*\.(png|gif|jpg|bmp)) /$1 [L,PT,NC] |
|---|
| 15 | |
|---|
| 16 | #Ignore CSS or JS files and this would be last rule --if the condition matched |
|---|
| 17 | RewriteRule ^/(.*\.(css|js)) /$1 [L,PT,NC] |
|---|
| 18 | |
|---|
| 19 | #Ignore txt/doc/pdf/xls files and this would be last rule --if the condition matched |
|---|
| 20 | RewriteRule ^/(.*\.(txt|pdf|doc|xls)) /$1 [L,PT,NC] |
|---|
| 21 | |
|---|
| 22 | RewriteRule ^$ index.cfm [QSA] |
|---|
| 23 | RewriteCond %{REQUEST_FILENAME} !-f |
|---|
| 24 | RewriteCond %{REQUEST_FILENAME} !-d |
|---|
| 25 | RewriteRule ^(.*)$ index.cfm/%{REQUEST_URI} [QSA,L] |
|---|