You may notice this error in the Apache logs : zend_mm_heap corrupted
Try to enable or increase this parameter either in your Apache config, htaccess or php.ini file :
output_buffering = 4096
You may notice this error in the Apache logs : zend_mm_heap corrupted
Try to enable or increase this parameter either in your Apache config, htaccess or php.ini file :
output_buffering = 4096
This article is about stopping theses sites who hot link your images, steal them and your bandwidth! I assume you are running Apache as Web server and have some basic knowledge of httpd.conf, htaccess and rewrite rules.
You have two choice, either put the rules directly inside your httpd.conf vhost or inside an Apache configuration file (well known as .htaccess). If you use the httpd.conf way, you can ignore the first step.
First, make sure your vhost is allowing htaccess usage (in httpd.conf) :
AccessFileName .htaccess
<Directory “/path/to/vhost”>
AllowOverride All
Options SymLinksIfOwnerMatch
Order allow,deny
Allow from all
</Directory>
Now, add theses rewrite rules into your config file (httpd.conf or htaccess) :
RewriteEngine On
RewriteCond %{HTTP_REFERER} !^$
RewriteCond %{HTTP_REFERER} !^http(s)?://(www\.)?domain.tld [NC]
RewriteRule \.(jpg|jpeg|png|gif)$ http://public.domain.tld/images/hotlinking_denied.jpg [NC,R,L]
Ok, let’s explain this a little bit… the following line contain the URL who is authorized to call images (your own site must be listed! – replace “domain.tld” with your own domain). You may add as many allowed URL you want, simply duplicate the line and domain.
RewriteCond %{HTTP_REFERER} !^http(s)?://(www\.)?domain.tld [NC]
The last line contain the image to return to theses stealers… their site will show this image instead of the one they tried to link (again, replace with your own URL/path) :
RewriteRule \.(jpg|jpeg|png|gif)$ http://public.domain.tld/images/hotlinking_denied.jpg [NC,R,L]
*Make sure the image you want to display is not contained into the same URL you are trying to protect. Infinite loop is expected!
Experiencing this error in Bind logs?
named[xxxxxx]: unexpected RCODE (REFUSED) resolving ‘xx.xx.xx.xx.in-addr.arpa/PTR/IN’: xxx.xxx.xxx.xxx#53
This is probably because you have a forwarder in your named.conf that refuse your requests. Simply look at the end of the previous line : “xxx.xxx.xxx.xxx#53″ and search this address in your named configuration file – it should be located inside the forwarders :
forwarders { xxx.xxx.xxx.xxx; };
You need to remove or comment this host to get rid of the error in log or allow your host to query this server if it belongs to you!
Tip : To make sure the remote DNS server you are trying to query is refusing your request, you can try to DIG a host like this replacing the domain and IP to meet your situation :
dig domain.tld @xxx.xxx.xxx.xxx
I recently notice this error on a master/slave Bind (named) DNS server setup (this error actually happened on slaves servers) :
transfer of ‘domain.tld/IN’ from xxx.xxx.xxx.xxx#53: failed while receiving responses: permission denied
First, make sure the “allow-transfer” directive is properly set on the primary master server :
allow-transfer { xxx.xxx.xxx.xxx; };
This is probably the case and the problem is more likely at the filesystem permission level on the slaves servers. This is a common error. So let’s fix this by reseting permission like this :
chmod 775 /var/named/chroot/var/named
For the record, everything contained in /var/named should belong to “named:named”. Feel free to correct this recursively if this is not the case :
chown -Rf named:named /var/named