COMMUNITY FORUM
Search Results (Searched for: 500 Internal Server Error)
- Gregor Berlisk
Internal server error 500
Category: English K2 Community
- Krikor Boghossian
Internal server error 500
Category: English K2 Community
Also please enable error reporting from your site's global configuration to see the actual issue.
- Gregor Berlisk
Internal server error 500
Category: English K2 Community
Any idea what is wrong?
- Krikor Boghossian
500 internal Server Error
Category: English K2 Community
You need to enable error reporting and set it to Development in your site's global configuration to see the actual issue.
- Michael Webster
500 internal Server Error
Category: English K2 Community
Anyway, hopefully all is well going forward. I'm making a backup of my site before importing the articles into K2, just in case.
- Mr_Anonymous
500 internal Server Error
Category: English K2 Community
- Michael Webster
500 internal Server Error
Category: English K2 Community
Here is the last time the error occurred, as reported by the Mac's Console:
12/20/14 8:13:27.175 AM Safari[56691]: Failed to save record: <CKError 0x608001a58ae0: "Internal Error" (1/5001); "Fetched zone had no protection data: <CKRecordZone: 0x7f8a1e7442c0; zoneID=History:__defaultOwner__, capabilities=(Atomic,Sync)>">
- Mr_Anonymous
500 internal Server Error
Category: English K2 Community
- Michael Webster
500 internal Server Error
Category: English K2 Community
First, I installed K2 and it appeared as K2.con, or something like that, in the component menu and I got the internal server error on everything. I uninstalled K2 by searching for all components that contained "k2" and then reinstalled it. Now, everything seems to work except when I try to go to Items.
I searched "500 internal server error" and saw a lot, but not the exact same problem. I noticed the advice was to turn on the error log, but I am unable to find that.
Any help will be greatly appreciated.
- Jesse Dockett
Items not showing up in generic view
Category: English K2 Community
it looks like I'm getting a 500 error for part of the filter:
GET http://www.newpages.com/index.php?option=com_jak2filter&view=cron 500 (Internal Server Error)
- Matthias O.
Error 500, can´t save articles in frontend
Category: English K2 Community
When I want to save K2 articles i always get an
"error 500" or "Internal Server Error"
Things I´ve done until now:
There was a problem with folder premissions for /log and /tmp folder.
I solved it - in configuration.php - i added two dotts before slash
public $log_path = '../logs/';
public $tmp_path = '../tmp/';
And via FTP program i set the premissions to 777...
In Joomla System Info the two folders are shown with the writeable tag.
In some forums i red about a "k2 smart search" plugin issue in context with the error 500.
I´ve deactivated the plugin. Then the "Internal Server Error" disapeared.
And in the backend now I can edit and save articles normally.
But in the frontend editor I can open the articles but i can`t save them.
There always is following error message:
JFolder::create: Der Pfad ist nicht in den „open_basedir“-Pfaden!
Call stack
# Function Location
1 JSite->dispatch() JROOT/index.php:43
2 JComponentHelper::renderComponent() JROOT/includes/application.php:197
3 JComponentHelper::executeComponent() JROOT/libraries/joomla/application/component/helper.php:351
4 require_once() JROOT/libraries/joomla/application/component/helper.php:383
5 JController->execute() JROOT/components/com_k2/k2.php:62
6 K2ControllerItem->save() JROOT/libraries/joomla/application/component/controller.php:761
7 K2ModelItem->save() JROOT/components/com_k2/controllers/item.php:164
8 JPluginHelper::importPlugin() JROOT/administrator/components/com_k2/models/item.php:186
9 JPluginHelper::_import() JROOT/libraries/joomla/plugin/helper.php:125
10 plgFinderCategories->__construct() JROOT/libraries/joomla/plugin/helper.php:194
11 FinderIndexerAdapter->__construct() JROOT/plugins/finder/categories/categories.php:85
12 FinderIndexerAdapter->getTypeId() JROOT/administrator/components/com_finder/helpers/indexer/adapter.php:135
13 JLog::add() JROOT/administrator/components/com_finder/helpers/indexer/adapter.php:765
14 JLog->addLogEntry() JROOT/libraries/joomla/log/log.php:171
15 JLoggerFormattedText->addEntry() JROOT/libraries/joomla/log/log.php:382
16 JLoggerFormattedText->initFile() JROOT/libraries/joomla/log/loggers/formattedtext.php:137
17 JFolder::create() JROOT/libraries/joomla/log/loggers/formattedtext.php:237
18 JFolder::create() JROOT/libraries/joomla/filesystem/folder.php:188
19 JError::raiseWarning() JROOT/libraries/joomla/filesystem/folder.php:249
20 JError::raise() JROOT/libraries/joomla/error/error.php:276
Call stack
# Function Location
1 JSite->dispatch() JROOT/index.php:43
2 JError::raiseError() JROOT/includes/application.php:208
3 JError::raise() JROOT/libraries/joomla/error/error.php:251
Here is the error message when I activate the smart search plugin:
k2 Internal Server Error The server encountered an internal error or misconfiguration and was unable to complete your request. Please contact the server administrator, root@localhost and inform them of the time the error occurred, and anything you might have done that may have caused the error. More information about this error may be available in the server error log.
I find many posts about "finder_tokens Tabelle is full" They describe a workearround to increase the memory for tables in com -> smartsearch -> options => but no success in my case.
versions:
Joomla! 2.5.14
K2 v2.6.7
Please help - thank you
- Matthias O.
Fehler 500, kann Artikel nicht speichern
Category: Offizielle deutsche Gemeinschaft
Ich kämpfe nun schon ewig mit einem Problem hab auch vieles in verschiedensten Foren und Suchen gefunden aber ohne großen Erfolg.
Ich bekomme beim Speichern von K2 Artikeln immer Fehlermeldungen.
"Fehler 500" oder "Internal Server Error"
Was ich bis jetzt getan habe:
Ich hatte ein Problem mit Schreibrechten für /log und /tmp Ordner.
Habe ich gelöst - im configuration.php zwei Punkte vor dem Slash hinzugefügt
public $log_path = '../logs/';
public $tmp_path = '../tmp/';
Und die Folder premissions via FTP Programm auf 777 gestellt...
Die beiden Ordner werden jetzt in der Systeminfo als beschreibbar angezeigt!
In einigen Foren habe ich gelesen, dass es mit dem "k2 smart search" plugin zu tun hat.
Ich habe das Plugin vorerst mal deaktiviert. Jetzt ist zumindest der "Internal Server Error" weg.
Und im backend kann ich ganz normal die Artikel bearbeiten und speichern ohne Fehlermeldung.
Aber im Frontend auf der Webseite kann ich zwar die Artikel öffnen und bearbeiten aber wenn ich auf speichern drücke kommt wieder ein Fehler 500
Hier der Text:
JFolder::create: Der Pfad ist nicht in den „open_basedir“-Pfaden!
Call stack
# Function Location
1 JSite->dispatch() JROOT/index.php:43
2 JComponentHelper::renderComponent() JROOT/includes/application.php:197
3 JComponentHelper::executeComponent() JROOT/libraries/joomla/application/component/helper.php:351
4 require_once() JROOT/libraries/joomla/application/component/helper.php:383
5 JController->execute() JROOT/components/com_k2/k2.php:62
6 K2ControllerItem->save() JROOT/libraries/joomla/application/component/controller.php:761
7 K2ModelItem->save() JROOT/components/com_k2/controllers/item.php:164
8 JPluginHelper::importPlugin() JROOT/administrator/components/com_k2/models/item.php:186
9 JPluginHelper::_import() JROOT/libraries/joomla/plugin/helper.php:125
10 plgFinderCategories->__construct() JROOT/libraries/joomla/plugin/helper.php:194
11 FinderIndexerAdapter->__construct() JROOT/plugins/finder/categories/categories.php:85
12 FinderIndexerAdapter->getTypeId() JROOT/administrator/components/com_finder/helpers/indexer/adapter.php:135
13 JLog::add() JROOT/administrator/components/com_finder/helpers/indexer/adapter.php:765
14 JLog->addLogEntry() JROOT/libraries/joomla/log/log.php:171
15 JLoggerFormattedText->addEntry() JROOT/libraries/joomla/log/log.php:382
16 JLoggerFormattedText->initFile() JROOT/libraries/joomla/log/loggers/formattedtext.php:137
17 JFolder::create() JROOT/libraries/joomla/log/loggers/formattedtext.php:237
18 JFolder::create() JROOT/libraries/joomla/filesystem/folder.php:188
19 JError::raiseWarning() JROOT/libraries/joomla/filesystem/folder.php:249
20 JError::raise() JROOT/libraries/joomla/error/error.php:276
Call stack
# Function Location
1 JSite->dispatch() JROOT/index.php:43
2 JError::raiseError() JROOT/includes/application.php:208
3 JError::raise() JROOT/libraries/joomla/error/error.php:251
Und hier der Text der Meldung wenn ich das SmartSearch Plugin aktiviere:
k2 Internal Server Error The server encountered an internal error or misconfiguration and was unable to complete your request. Please contact the server administrator, root@localhost and inform them of the time the error occurred, and anything you might have done that may have caused the error. More information about this error may be available in the server error log.
Versionen:
Joomla! 2.5.14
K2 v2.6.7
Bitte um eure Hilfe - Danke!!!
- Patrick
Server error 500
Category: English K2 Community
just receiving internal error when putting up pics (not 500 error code)
but figured same thing
i am on donhost hosting and was having major problems only able to put up really small images
look bad when viewed in a large window removed the code for converts image from true color, and fix transparency if needed
and all is working fine the upload is very fast using joomla 2x k2 2.6.8
hope this helps some body out there
code removed was from line 4948
as follows
// converts image from true color, and fix transparency if needed
$this->log .= '- converting...<br />';
switch($this->image_convert) {
case 'gif':
// if the image is true color, we convert it to a palette
if (imageistruecolor($image_dst)) {
$this->log .= ' true color to palette<br />';
// creates a black and white mask
$mask = array(array());
for ($x = 0; $x < $this->image_dst_x; $x++) {
for ($y = 0; $y < $this->image_dst_y; $y++) {
$pixel = imagecolorsforindex($image_dst, imagecolorat($image_dst, $x, $y));
$mask[$x][$y] = $pixel;
}
}
list($red, $green, $blue) = $this->getcolors($this->image_default_color);
// first, we merge the image with the background color, so we know which colors we will have
for ($x = 0; $x < $this->image_dst_x; $x++) {
for ($y = 0; $y < $this->image_dst_y; $y++) {
if ($mask[$x][$y] > 0){
// we have some transparency. we combine the color with the default color
$pixel = imagecolorsforindex($image_dst, imagecolorat($image_dst, $x, $y));
$alpha = ($mask[$x][$y] / 127);
$pixel = round(($pixel * (1 -$alpha) + $red * ($alpha)));
$pixel = round(($pixel * (1 -$alpha) + $green * ($alpha)));
$pixel = round(($pixel * (1 -$alpha) + $blue * ($alpha)));
$color = imagecolorallocate($image_dst, $pixel, $pixel, $pixel);
imagesetpixel($image_dst, $x, $y, $color);
}
}
}
// transforms the true color image into palette, with its merged default color
if (empty($this->image_background_color)) {
imagetruecolortopalette($image_dst, true, 255);
$transparency = imagecolorallocate($image_dst, 254, 1, 253);
imagecolortransparent($image_dst, $transparency);
// make the transparent areas transparent
for ($x = 0; $x < $this->image_dst_x; $x++) {
for ($y = 0; $y < $this->image_dst_y; $y++) {
// we test wether we have enough opacity to justify keeping the color
if ($mask[$x][$y] > 120) imagesetpixel($image_dst, $x, $y, $transparency);
}
}
}
unset($mask);
}
break;
case 'jpg':
case 'bmp':
// if the image doesn't support any transparency, then we merge it with the default color
$this->log .= ' fills in transparency with default color<br />';
list($red, $green, $blue) = $this->getcolors($this->image_default_color);
$transparency = imagecolorallocate($image_dst, $red, $green, $blue);
// make the transaparent areas transparent
for ($x = 0; $x < $this->image_dst_x; $x++) {
for ($y = 0; $y < $this->image_dst_y; $y++) {
// we test wether we have some transparency, in which case we will merge the colors
if (imageistruecolor($image_dst)) {
$rgba = imagecolorat($image_dst, $x, $y);
$pixel = array('red' => ($rgba >> 16) & 0xFF,
'green' => ($rgba >> 8) & 0xFF,
'blue' => $rgba & 0xFF,
'alpha' => ($rgba & 0x7F000000) >> 24);
} else {
$pixel = imagecolorsforindex($image_dst, imagecolorat($image_dst, $x, $y));
}
if ($pixel == 127) {
// we have full transparency. we make the pixel transparent
imagesetpixel($image_dst, $x, $y, $transparency);
} else if ($pixel > 0) {
// we have some transparency. we combine the color with the default color
$alpha = ($pixel / 127);
$pixel = round(($pixel * (1 -$alpha) + $red * ($alpha)));
$pixel = round(($pixel * (1 -$alpha) + $green * ($alpha)));
$pixel = round(($pixel * (1 -$alpha) + $blue * ($alpha)));
$color = imagecolorclosest($image_dst, $pixel, $pixel, $pixel);
imagesetpixel($image_dst, $x, $y, $color);
}
}
}
break;
default:
break;
}
- Krikor Boghossian
Error: 500 Internal Server Error .
Category: English K2 Community
This will print the error and which file you need to edit.
- Abriil Diaz
Error: 500 Internal Server Error
Category: Comunidad hispana oficial de K2
- Abriil Diaz
Error: 500 Internal Server Error .
Category: English K2 Community
I searched where I think you can put it, but I get nothing.
Where should I look?
I am very grateful I can help, :( Now page is not displayed.
Error: 500 Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator to inform of the time the error occurred and of anything you might have done that may have caused the error.
More information about this error may be available in the server error log.
- Abriil Diaz
Error: 500 Internal Server Error
Category: Comunidad hispana oficial de K2
He buscado donde creo puede colocarlo, pero no consigo nada, Donde debería buscar?
Agradezco mucho me puedan ayudar, :( Ahora la pagina no se muestra.
Error: 500 Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator to inform of the time the error occurred and of anything you might have done that may have caused the error.
More information about this error may be available in the server error log.
- joe mayo
[SOLVED] Install problems
Category: English K2 Community
- Nnov Leumik
Error 500 K2 saving an item with Image
Category: English K2 Community
When saving a ITEM with image it throws me to an error 500 internal server error.
I have joomla 3.3.3 and K2 v2.6.8.
Joomla is installed clean and K2 is also.
Your help is appreciated. :)
SEO Settings
Search Engine Friendly URLs - Yes
Use URL rewriting - No
Adds Suffix to URL - No
Unicode Aliases - No
Include Site Name in Page Titles - No
---additions---
if i make my joomla's htaccess.txt to .htaccess the error is now 404 category not found.
Category not found
Call stack
# Function Location
1 JApplicationCms->execute() /home/original/public_html/test/index.php:40
2 JApplicationSite->doExecute() /home/original/public_html/test/libraries/cms/application/cms.php:245
3 JApplicationSite->dispatch() /home/original/public_html/test/libraries/cms/application/site.php:224
4 JComponentHelper::renderComponent() /home/original/public_html/test/libraries/cms/application/site.php:178
5 JComponentHelper::executeComponent() /home/original/public_html/test/libraries/cms/component/helper.php:332
6 require_once() /home/original/public_html/test/libraries/cms/component/helper.php:352
7 JControllerLegacy->execute() /home/original/public_html/test/components/com_content/content.php:16
8 ContentController->display() /home/original/public_html/test/libraries/legacy/controller/legacy.php:722
9 JControllerLegacy->display() /home/original/public_html/test/components/com_content/controller.php:79
10 ContentViewCategory->display() /home/original/public_html/test/libraries/legacy/controller/legacy.php:685
11 JViewCategory->commonCategoryDisplay() /home/original/public_html/test/components/com_content/views/category/view.html.php:72
12 JError::raiseError() /home/original/public_html/test/libraries/legacy/view/category.php:129
13 JError::raise() /home/original/public_html/test/libraries/legacy/error/error.php:253
This is my htaccess
##
# @package Joomla
# @copyright Copyright (C) 2005 - 2014 Open Source Matters. All rights reserved.
# @license GNU General Public License version 2 or later; see LICENSE.txt
##
##
# READ THIS COMPLETELY IF YOU CHOOSE TO USE THIS FILE!
#
# The line just below this section: 'Options +FollowSymLinks' may cause problems
# with some server configurations. It is required for use of mod_rewrite, but may already
# be set by your server administrator in a way that dissallows changing it in
# your .htaccess file. If using it causes your server to error out, comment it out (add # to
# beginning of line), reload your site in your browser and test your sef url's. If they work,
# it has been set by your server administrator and you do not need it set here.
##
## Can be commented out if causes errors, see notes above.
# Options +FollowSymLinks #THIS PART IS COMMENTED to check whether this is the culprit
## Mod_rewrite in use.
RewriteEngine On
## Begin - Rewrite rules to block out some common exploits.
# If you experience problems on your site block out the operations listed below
# This attempts to block the most common type of exploit `attempts` to Joomla!
#
# Block out any script trying to base64_encode data within the URL.
RewriteCond %{QUERY_STRING} base64_encode[^(]*\([^)]*\) [OR]
# Block out any script that includes a <script> tag in URL.
RewriteCond %{QUERY_STRING} (<|%3C)([^s]*s)+cript.*(>|%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})
# Return 403 Forbidden header and show the content of the root homepage
RewriteRule .* index.php [F]
#
## End - Rewrite rules to block out some common exploits.
## Begin - Custom redirects
#
# If you need to redirect some pages, or set a canonical non-www to
# www redirect (or vice versa), place that code here. Ensure those
# redirects use the correct RewriteRule syntax and the [R=301,L] flags.
#
## End - Custom redirects
##
# Uncomment following line if your webserver's URL
# is not directly related to physical file paths.
# Update Your Joomla! Directory (just / for root).
##
# RewriteBase /
## Begin - Joomla! core SEF Section.
#
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
#
# If the requested path and file is not /index.php and the request
# has not already been internally rewritten to the index.php script
RewriteCond %{REQUEST_URI} !^/index\.php
# and the requested path and file doesn't directly match a physical file
RewriteCond %{REQUEST_FILENAME} !-f
# and the requested path and file doesn't directly match a physical folder
RewriteCond %{REQUEST_FILENAME} !-d
# internally rewrite the request to the index.php script
RewriteRule .* index.php [L]
#
## End - Joomla! core SEF Section.
- Ivan Shilin
K2 - css/js problem with .htaccess
Category: English K2 Community
No security extensions used by me.
Thx, for fast reply.
Here is the full .htaccess file, failed to put under spoiler sorry:
IndexIgnore *
Options +FollowSymLinks All -Indexes
## Mod_rewrite in use.
RewriteEngine On
########## Begin - File execution order, by Komra.de
DirectoryIndex index.php index.html
########## End - File execution order
## Удаляем .html c конца URL
RewriteRule ^index.html$ / [R=301,L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} \.html$
RewriteRule ^(.*)\.html$ /$1 [R,L]
## Удаляем .html c конца URL
RewriteCond %{HTTP_HOST} ^mysite\.ru
RewriteRule ^(.*)$ www.mysite.ru/$1 [R=permanent,L]
## Фильтруем кавычки в url
RewriteRule ^(.*) /$1 [R=301,L]
## Фильтруем кавычки в url
## Удаляем слеш с конца урл
RewriteCond %{REQUEST_URI} ^.*/$ [NC]
RewriteCond %{REQUEST_URI} !^/administrator
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)/$ /$1 [L,R=301]
## Удаляем слеш с конца урл
<IfModule mod_gzip.c>
mod_gzip_on Yes
mod_gzip_dechunk Yes
mod_gzip_item_include file \.(html?|txt|css|js|php)$
mod_gzip_item_include mime ^text/.*
mod_gzip_item_include mime ^application/x-javascript.*
mod_gzip_item_exclude mime ^image/.*
mod_gzip_item_exclude rspheader ^Content-Encoding:.*gzip.*
</IfModule>
########## Begin - Add optional bad user agent or IP blocking code
#
# If you need to block certain user agents or IP addresses and
# other signatures, place that code here. Ensure the rules use
# the correct RewriteRule syntax and the [F] flag.
#
########## End - Add optional bad user agent or IP blocking code
########## Begin - Rewrite rules to block out some common exploits
## If you experience problems on your site block out the operations listed below
## This attempts to block the most common type of exploit `attempts` to Joomla!
#
# If the request query string contains /proc/self/environ (by SigSiu.net)
RewriteCond %{QUERY_STRING} proc/self/environ [OR]
# Block out any script trying to set a mosConfig value through the URL
# (these attacks wouldn't work w/out Joomla! 1.5's Legacy Mode plugin)
RewriteCond %{QUERY_STRING} mosConfig_[a-zA-Z_]{1,21}(=|\%3D) [OR]
# Block out any script trying to base64_encode or base64_decode data within the URL
RewriteCond %{QUERY_STRING} base64_(en|de)code[^(]*\([^)]*\) [OR]
## IMPORTANT: If the above line throws an HTTP 500 error, replace it with these 2 lines:
# RewriteCond %{QUERY_STRING} base64_encode\(.*\) [OR]
# RewriteCond %{QUERY_STRING} base64_decode\(.*\) [OR]
# Block out any script that includes a <script> tag in URL
RewriteCond %{QUERY_STRING} (<|%3C)([^s]*s)+cript.*(>|%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})
# Return 403 Forbidden header and show the content of the root homepage
RewriteRule .* index.php [F]
#
########## End - Rewrite rules to block out some common exploits
########## Begin - File injection protection, by SigSiu.net
RewriteCond %{REQUEST_METHOD} GET
RewriteCond %{QUERY_STRING} [a-zA-Z0-9_]=http:// [OR]
RewriteCond %{QUERY_STRING} [a-zA-Z0-9_]=(\.\.//?)+ [OR]
RewriteCond %{QUERY_STRING} [a-zA-Z0-9_]=/([a-z0-9_.]//?)+ [NC]
RewriteRule .* - [F]
########## End - File injection protection
########## Begin - Basic antispam Filter, by SigSiu.net
## I removed some common words, tweak to your liking
## This code uses PCRE and works only with Apache 2.x.
## This code will NOT work with Apache 1.x servers.
RewriteCond %{QUERY_STRING} \b(ambien|blue\spill|cialis|cocaine|ejaculation|erectile)\b [NC,OR]
RewriteCond %{QUERY_STRING} \b(erections|hoodia|huronriveracres|impotence|levitra|libido)\b [NC,OR]
RewriteCond %{QUERY_STRING} \b(lipitor|phentermin|pro[sz]ac|sandyauer|tramadol|troyhamby)\b [NC,OR]
RewriteCond %{QUERY_STRING} \b(ultram|unicauca|valium|viagra|vicodin|xanax|ypxaieo)\b [NC]
## Note: The final RewriteCond must NOT use the [OR] flag.
RewriteRule .* - [F]
## Note: The previous lines are a "compressed" version
## of the filters. You can add your own filters as:
## RewriteCond %{QUERY_STRING} \bbadword\b [NC,OR]
## where "badword" is the word you want to exclude.
########## End - Basic antispam Filter, by SigSiu.net
########## Begin - Advanced server protection - query strings, referrer and config
# Advanced server protection, version 3.2 - May 2011
# by Nicholas K. Dionysopoulos
## Disallow PHP Easter Eggs (can be used in fingerprinting attacks to determine
## your PHP version). See www.0php.com/php_easter_egg.php and
## osvdb.org/12184 for more information
RewriteCond %{QUERY_STRING} \=PHP[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12} [NC]
RewriteRule .* - [F]
## SQLi first line of defense, thanks to Radek Suski (SigSiu.net) @
## www.sigsiu.net/presentations/fortifying_your_joomla_website.html
## May cause problems on legitimate requests
RewriteCond %{QUERY_STRING} concat[^\(]*\( [NC,OR]
RewriteCond %{QUERY_STRING} union([^s]*s)+elect [NC,OR]
RewriteCond %{QUERY_STRING} union([^a]*a)+ll([^s]*s)+elect [NC]
RewriteRule .* - [F]
## Referrer filtering for common media files. Replace with your own domain name.
## This blocks most common fingerprinting attacks ;)
## Note: Change www\.example\.com with your own domain name, substituting the
## dots with \. i.e. use www\.example\.com for www.example.com
RewriteRule ^(images/stories/([^.]+)\.(jpe[g2]?|jpg|png|gif|bmp|css|js|swf|ico|html?))$ - [L]
RewriteCond %{HTTP_REFERER} .
RewriteCond %{HTTP_REFERER} !^https?://(www\.)?mysite\.ru [NC]
RewriteCond %{REQUEST_FILENAME} -f
RewriteRule \.(jp(e?g|2)?|png|gif|bmp|css|js|swf|ico)$ - [F]
## Disallow visual fingerprinting of Joomla! sites (module position dump)
## Initial idea by Brian Teeman and Ken Crowder, see:
## www.slideshare.net/brianteeman/hidden-joomla-secrets
## Improved by @nikosdion to work more efficiently and handle template
## and tmpl query parameters
RewriteCond %{QUERY_STRING} (^|&)tmpl=(component|system) [NC]
RewriteRule .* - [L]
RewriteCond %{QUERY_STRING} (^|&)t(p|emplate|mpl)= [NC]
RewriteRule .* - [F]
## Disallow access to htaccess.txt, configuration.php, configuration.php-dist and php.ini
RewriteRule ^(htaccess\.txt|configuration\.php(-dist)?|php\.ini)$ - [F]
########## End - Advanced server protection - query strings, referrer and config
########## Begin - Advanced server protection rules exceptions ####
##
## These are sample exceptions to the Advanced Server Protection 3.1
## rule set further down this file.
##
## Allow UddeIM CAPTCHA
##RewriteRule ^components/com_uddeim/captcha15\.php$ - [L]
## Allow Phil Taylor's Turbo Gears
##RewriteRule ^plugins/system/GoogleGears/gears-manifest\.php$ - [L]
## Allow JoomlaWorks AllVideos
##RewriteRule ^plugins/content/jw_allvideos/includes/jw_allvideos_scripts\.php$ - [L]
## Allow Admin Tools Joomla! updater to run
##RewriteRule ^administrator/components/com_admintools/restore\.php$ - [L]
## Allow Akeeba Backup Professional's integrated restoration script to run
##RewriteRule ^administrator/components/com_akeeba/restore\.php$ - [L]
## Allow Akeeba Kickstart
##RewriteRule ^kickstart\.php$ - [L]
# Add more rules to single PHP files here
## Allow Agora attachments, but not PHP files in that directory!
##RewriteCond %{REQUEST_FILENAME} !(\.php)$
##RewriteCond %{REQUEST_FILENAME} -f
##RewriteRule ^components/com_agora/img/members/ - [L]
# Add more rules for allowing full access (except PHP files) on more directories here
## Uncomment to allow full access to the cache directory (strongly not recommended!)
#RewriteRule ^cache/ - [L]
## Uncomment to allow full access to the tmp directory (strongly not recommended!)
#RewriteRule ^tmp/ - [L]
# Add more full access rules here
########## End - Advanced server protection rules exceptions ####
########## Begin - Advanced server protection - paths and files
# Advanced server protection, version 3.2 - May 2011
# by Nicholas K. Dionysopoulos
## Back-end protection
## This also blocks fingerprinting attacks browsing for XML and INI files
RewriteRule ^administrator/?$ - [L]
RewriteRule ^administrator/index\.(php|html?)$ - [L]
RewriteRule ^administrator/index[23]\.php$ - [L]
RewriteRule ^administrator/(components|modules|templates|images|plugins)/([^/]+/)*([^/.]+\.)+(jp(e?g|2)?|png|gif|bmp|css|js|ico|swf|html?|mp(eg?|[34])|avi|wav|og[gv]|xlsx?|docx?|pptx?|zip|rar|pdf|xps|txt|7z|svg|od[tsp]|flv|mov)$ - [L]
RewriteRule ^administrator/ - [F]
## Explicitly allow access only to XML-RPC's xmlrpc/index.php or plain xmlrpc/ directory
RewriteRule ^xmlrpc/(index\.php)?$ - [L]
RewriteRule ^xmlrpc/ - [F]
## Disallow front-end access for certain Joomla! system directories
RewriteRule ^includes/js/ - [L]
RewriteRule ^(includes|language|libraries|logs|tmp)/ - [F]
## Allow limited access for certain Joomla! system directories with client-accessible content
RewriteRule ^(components|modules|plugins|templates)/([^/]+/)*([^/.]+\.)+(jp(e?g|2)?|png|gif|bmp|css|js|ico|swf|html?|mp(eg?|[34])|avi|wav|og[gv]|xlsx?|docx?|pptx?|zip|rar|pdf|xps|txt|7z|svg|od[tsp]|flv|mov)$ - [L]
## Uncomment this line if you have extensions which require direct access to their own
## custom index.php files. Note that this is UNSAFE and the developer should be ashamed
## for being so lame, lazy and security unconscious.
# RewriteRule ^(components|modules|plugins|templates)/([^/]+/)*(index\.php)?$ - [L]
## Uncomment the following line if your template requires direct access to PHP files
## inside its directory, e.g. GZip compressed copies of its CSS files
# RewriteRule ^templates/([^/]+/)*([^/.]+\.)+php$ - [L]
RewriteRule ^(components|modules|plugins|templates)/ - [F]
## Disallow access to rogue PHP files throughout the site, unless they are explicitly allowed
RewriteCond %{REQUEST_FILENAME} \.php$
RewriteCond %{REQUEST_FILENAME} !/index[23]?\.php$
## The next line is to explicitly allow the forum post assistant(fpa-xx)script to run
RewriteCond %{REQUEST_FILENAME} !/fpa-[a-z]{2}\.php
RewriteCond %{REQUEST_FILENAME} -f
RewriteRule ^([^/]+/)*([^/.]+\.)+php$ - [F]
########## End - Advanced server protection - paths and files
########## Begin - Google Apps redirection, by Komra.de
## Uncomment the following line to enable:
# RewriteRule ^mail mail.google.com/a/example.com [R=301,L]
## If the above doesn't work on your server, try this:
## RewriteRule ^mail mail.google.com/a/example.com [R,L]
########## End - Google Apps redirection
########## Begin - Redirect index.php to /
## Note: Change example.com to reflect your own domain name
RewriteCond %{THE_REQUEST} !^POST
RewriteCond %{THE_REQUEST} ^[A-Z]{3,9}\ /index\.php\ HTTP/
RewriteCond %{SERVER_PORT}>s ^(443>(s)|[0-9]+>s)$
RewriteRule ^index\.php$ http%2://www.mysite.ru/$1 [R=301,L]
## If the above line throws a 500 error, change [R=301,L] to [R,L]
########## End - Redirect index.php to /
########## Begin - Joomla! core SEF Section
#
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
#
# If the requested path and file is not /index.php and the request
# has not already been internally rewritten to the index.php script
RewriteCond %{REQUEST_URI} !^/index\.php
# and the request is for the site root, or for an extensionless URL,
# or the requested URL ends with one of the listed extensions
RewriteCond %{REQUEST_URI} /component/|(/[^.]*|\.(php|html?|feed|pdf|vcf|raw|ini|zip|json|file))$ [NC]
# and the requested path and file doesn't directly match a physical file
RewriteCond %{REQUEST_FILENAME} !-f
# and the requested path doesn't directly match a physical folder
RewriteCond %{REQUEST_FILENAME} !-d
# internally rewrite the request to the index.php script
RewriteRule .* index.php [L]
#
########## End - Joomla! core SEF Section
ServerSignature Off
RewriteCond %{REQUEST_METHOD} ^(HEAD|TRACE|DELETE|TRACK) [NC,OR]
RewriteCond %{THE_REQUEST} (\\r|\\n|%0A|%0D) [NC,OR]
RewriteCond %{HTTP_USER_AGENT} ^$ [OR]
RewriteCond %{HTTP_USER_AGENT} ^(java|curl|wget) [NC,OR]
RewriteCond %{HTTP_USER_AGENT} (winhttp|HTTrack|clshttp|archiver|loader|email|harvest|extract|grab|miner) [NC,OR]
RewriteCond %{HTTP_USER_AGENT} (libwww-perl|curl|wget|python|nikto|scan) [NC,OR]
RewriteCond %{HTTP_USER_AGENT} (<|>|’|%0A|%0D|%27|%3C|%3E|%00) [NC,OR]
#Block mySQL injects
RewriteCond %{QUERY_STRING} (;|<|>|’|”|\)|%0A|%0D|%22|%27|%3C|%3E|%00).*(/\*|union|select|insert|cast|set|declare|drop|update|md5|benchmark) [NC,OR]
RewriteCond %{QUERY_STRING} \.\./\.\. [OR]
RewriteCond %{QUERY_STRING} (localhost|loopback|127\.0\.0\.1) [NC,OR]
RewriteCond %{QUERY_STRING} \.[a-z0-9] [NC,OR]
RewriteCond %{QUERY_STRING} (<|>|’|%0A|%0D|%27|%3C|%3E|%00) [NC]
# Note: The final RewriteCond must NOT use the [OR] flag.
# Return 403 Forbidden error.
RewriteRule .* index.php [F]
AddDefaultCharset utf-8
php_value max_execution_time 180
php_value memory_limit 512M
ErrorDocument 404 www.mysite.ru/error404
########## Block bad user agents
## The following list may include bots that no longer exist or are not a problem
## for your site. The list will always be incomplete and it is therefore wise to
## follow discussions on one of the many "security" mailing lists or on a forum
## such as www.webmasterworld.com/search_engine_spiders/
## It is also unwise to rely on this list as your ONLY security mechanism.
RewriteCond %{HTTP_USER_AGENT} ^BlackWidow [OR]
RewriteCond %{HTTP_USER_AGENT} ^Bot\ This email address is being protected from spambots. You need JavaScript enabled to view it. [OR]
RewriteCond %{HTTP_USER_AGENT} ^ChinaClaw [OR]
RewriteCond %{HTTP_USER_AGENT} ^Custo [OR]
RewriteCond %{HTTP_USER_AGENT} ^DISCo [OR]
RewriteCond %{HTTP_USER_AGENT} ^Download\ Demon [OR]
RewriteCond %{HTTP_USER_AGENT} ^eCatch [OR]
RewriteCond %{HTTP_USER_AGENT} ^EirGrabber [OR]
RewriteCond %{HTTP_USER_AGENT} ^EmailSiphon [OR]
RewriteCond %{HTTP_USER_AGENT} ^EmailWolf [OR]
RewriteCond %{HTTP_USER_AGENT} ^Express\ WebPictures [OR]
RewriteCond %{HTTP_USER_AGENT} ^ExtractorPro [OR]
RewriteCond %{HTTP_USER_AGENT} ^EyeNetIE [OR]
RewriteCond %{HTTP_USER_AGENT} ^FlashGet [OR]
RewriteCond %{HTTP_USER_AGENT} ^GetRight [OR]
RewriteCond %{HTTP_USER_AGENT} ^GetWeb! [OR]
RewriteCond %{HTTP_USER_AGENT} ^Go!Zilla [OR]
RewriteCond %{HTTP_USER_AGENT} ^Go-Ahead-Got-It [OR]
RewriteCond %{HTTP_USER_AGENT} ^GrabNet [OR]
RewriteCond %{HTTP_USER_AGENT} ^Grafula [OR]
RewriteCond %{HTTP_USER_AGENT} ^HMView [OR]
RewriteCond %{HTTP_USER_AGENT} HTTrack [NC,OR]
RewriteCond %{HTTP_USER_AGENT} ^Image\ Stripper [OR]
RewriteCond %{HTTP_USER_AGENT} ^Image\ Sucker [OR]
RewriteCond %{HTTP_USER_AGENT} Indy\ Library [NC,OR]
RewriteCond %{HTTP_USER_AGENT} ^InterGET [OR]
RewriteCond %{HTTP_USER_AGENT} ^Internet\ Ninja [OR]
RewriteCond %{HTTP_USER_AGENT} ^JetCar [OR]
RewriteCond %{HTTP_USER_AGENT} ^JOC\ Web\ Spider [OR]
RewriteCond %{HTTP_USER_AGENT} ^larbin [OR]
RewriteCond %{HTTP_USER_AGENT} ^LeechFTP [OR]
RewriteCond %{HTTP_USER_AGENT} ^Mass\ Downloader [OR]
RewriteCond %{HTTP_USER_AGENT} ^MIDown\ tool [OR]
RewriteCond %{HTTP_USER_AGENT} ^Mister\ PiX [OR]
RewriteCond %{HTTP_USER_AGENT} ^Navroad [OR]
RewriteCond %{HTTP_USER_AGENT} ^NearSite [OR]
RewriteCond %{HTTP_USER_AGENT} ^NetAnts [OR]
RewriteCond %{HTTP_USER_AGENT} ^NetSpider [OR]
RewriteCond %{HTTP_USER_AGENT} ^Net\ Vampire [OR]
RewriteCond %{HTTP_USER_AGENT} ^NetZIP [OR]
RewriteCond %{HTTP_USER_AGENT} ^Octopus [OR]
RewriteCond %{HTTP_USER_AGENT} ^Offline\ Explorer [OR]
RewriteCond %{HTTP_USER_AGENT} ^Offline\ Navigator [OR]
RewriteCond %{HTTP_USER_AGENT} ^PageGrabber [OR]
RewriteCond %{HTTP_USER_AGENT} ^Papa\ Foto [OR]
RewriteCond %{HTTP_USER_AGENT} ^pavuk [OR]
RewriteCond %{HTTP_USER_AGENT} ^pcBrowser [OR]
RewriteCond %{HTTP_USER_AGENT} ^RealDownload [OR]
RewriteCond %{HTTP_USER_AGENT} ^ReGet [OR]
RewriteCond %{HTTP_USER_AGENT} ^SiteSnagger [OR]
RewriteCond %{HTTP_USER_AGENT} ^SmartDownload [OR]
RewriteCond %{HTTP_USER_AGENT} ^SuperBot [OR]
RewriteCond %{HTTP_USER_AGENT} ^SuperHTTP [OR]
RewriteCond %{HTTP_USER_AGENT} ^Surfbot [OR]
RewriteCond %{HTTP_USER_AGENT} ^tAkeOut [OR]
RewriteCond %{HTTP_USER_AGENT} ^Teleport\ Pro [OR]
RewriteCond %{HTTP_USER_AGENT} ^VoidEYE [OR]
RewriteCond %{HTTP_USER_AGENT} ^Web\ Image\ Collector [OR]
RewriteCond %{HTTP_USER_AGENT} ^Web\ Sucker [OR]
RewriteCond %{HTTP_USER_AGENT} ^WebAuto [OR]
RewriteCond %{HTTP_USER_AGENT} ^WebCopier [OR]
RewriteCond %{HTTP_USER_AGENT} ^WebFetch [OR]
RewriteCond %{HTTP_USER_AGENT} ^WebGo\ IS [OR]
RewriteCond %{HTTP_USER_AGENT} ^WebLeacher [OR]
RewriteCond %{HTTP_USER_AGENT} ^WebReaper [OR]
RewriteCond %{HTTP_USER_AGENT} ^WebSauger [OR]
RewriteCond %{HTTP_USER_AGENT} ^Website\ eXtractor [OR]
RewriteCond %{HTTP_USER_AGENT} ^Website\ Quester [OR]
RewriteCond %{HTTP_USER_AGENT} ^WebStripper [OR]
RewriteCond %{HTTP_USER_AGENT} ^WebWhacker [OR]
RewriteCond %{HTTP_USER_AGENT} ^WebZIP [OR]
RewriteCond %{HTTP_USER_AGENT} ^Widow [OR]
RewriteCond %{HTTP_USER_AGENT} ^WWWOFFLE [OR]
RewriteCond %{HTTP_USER_AGENT} ^Xaldon\ WebSpider [OR]
RewriteCond %{HTTP_USER_AGENT} ^Zeus
## Note: The final RewriteCond must NOT use the [OR] flag.
## Return 403 Forbidden error.
RewriteRule .* - [F]