Archive for January, 2008

29
Jan

Third-party cookie, P3P and Internet Explorer 7, a solution.

I nearly got crazy about that sh*t.
The goal was to bring up a tracking pixel to see the movement of single users. For that reason, you’ll need to set a cookie and read it on the page. In my case, the tracking pixel comes from another machine, than the website.
After I generating the p3p file with the ibm p3p generator, I checked and validated that stuff.
Normally that should work right now. It does in Firefox! But it doesn’t in Internet Explorer. After searching around, I found out, that I can also set the P3P stuff via the header, but that’s not all. You’ll have to send it on the site where you set the cookie and even on the page, you receive the cookie.
This is my header:

header ('P3P:CP="IDC DSP COR ADM DEVi TAIi PSA PSD IVAi IVDi CONi HIS OUR IND CNT"');


Good luck!

16
Jan

Howto set the correct server time

In the last years, I often had the problem that the system time of a linux server was not correct.
There’s a simple way the sync your internal clock with some of these ultra-correct clocks over the internet.
Just use ntpdate.

#ntpdate SERVERADDRESS

Here is a list with public timservers.

14
Jan

New year, new Spamcollect

As the new year begins, I decided not only to report little helpers for problems and starting blogging about software, development and hardware I use everyday.
I wish you all a happy new year 2008.

11
Jan

How to fix “transfer aborted. disk quota exceeded” -

If you try to upload something you get “transfer aborted. disk quota exceeded”.

If you bought a webhosting package somewhere, the answer is simple: “You don’t have anymore space left”.
If this happens before the quota is exceeded and you have a root access to that machine, simple use this:

quotacheck -v -c -F vfsold -m /

and restart the quota daemon

/etc/init.d/quota restart

11
Jan

All this Apple Rumours!

When I look into blogs these days, I see rumours about the stuff Apple is showing at the Macworld in the next days.
So I decided to post my own rumours.

I think Apple is gonna release Exchange compability to the iPhone. Why? Cause most of the business people are running around with Blackberrys. And what is the key feature here? Reading emails! More detailed, reading business emails, stored on the companys Exchange server. That’s what missing in the iPhone. It’s good for single persons or small companys, but if you like to use it in an Exchange environment, no chance right now.

Apple has, until now, no product that is like Exchange, so that would make sense!?

05
Jan

Howto install djbdns with autoaxfr

If you like to setup autoaxfr with djbdns, maybe this howto will help you.

First of all, I assume that you have already installed ucspi-tcp and daemontools. If not, look at D.J. Bernsteins Webseite
http://cr.yp.to and install it.

After that, you will have to download autoaxfr and the djbdns Package.
What I’m doing is a basic installation. If you need IPv6 support, watch out, there will be a patch somewhere for djbdns.

Now, add the necessary users:

groupadd dns
useradd -g dns -s /bin/false dnscache
useradd -g dns -s /bin/false tinydns
useradd -g dns -s /bin/false dnslog
useradd -g dns -s /bin/false axfrdns
useradd -g dns -s /bin/false autoaxfr


dnscache

First of all, we install dnscache to 127.0.0.1

dnscache-conf dnscache dnslog /etc/dnscache 127.0.0.1
If you like to distribute dns service to other machines in your network, add a real ip address.
WARNING: You can only use dnscache or tinydns on ONE ip address.

If you need dnscache to resolv domain names for other machines in your network, add the network or every machine by doing this.
touch /etc/dnscache/root/ip/192.168.0

Now it’s time to activate your dnscache.
ln -s /etc/dnscache /service

tinydns

You will need tinydns if you like to play dns server for domains.
First of all, configure it:
tinydns-conf tinydns dnslog /etc/tinydns 212.89.98.32
Use the external ip address, the server should be reachable at.

Now it’s time to setup autoaxfr.
autoaxfr-conf autoaxfr dnslog /etc/autoaxfr

You will now have to edit the file /etc/tinydns/root/Makefile
Replace everything with this:
data.cdb: data
/usr/local/bin/tinydns-data

data: mydata axfrdata
cat $^ > $@

axfrdata: /service/autoaxfr/root/zones/*
sort -u $^ > $@

Don’t forget to add the file mydata & axfrdata:

touch /etc/tinydns/root/axfrdata
touch /etc/tinydns/root/mydata

After every change of data, a secondary dns or whatever, you’ll have to type make in /etc/tinydns/root/
Just automate this with a cronjob.

*/10 * * * * cd /etc/tinydns/root && make > /dev/null 2>&1

Let’s start tinydns and autoaxfr.

ln -s /etc/tinydns /service
ln -s /etc/autoaxfr /service

Goto /etc/autoaxfr/root/slaves.
Add every domain you would like to distribute as secondary dns by adding the domain name as filename and the ip address of the primary dns controller as content in the file.

Example:
vi test.com
123.123.123.133

DONE! That’s the basic.

If you like to play primary dns server you’ll have to install axfrdns.
axfrdns-conf axfrdns dnslog /etc/axfrdns /etc/tinydns 212.89.98.32
Use the same ip address as for tinydns.

Set the servers that are allowed to be secondary dns servers.
cd /etc/axfrdns
vi /etc/axfrdns/tcp


insert to following.

122.22.22.22:allow
:deny


You can restrict that to networks, domains and so on. For that, see the axfrdns manuel from djb.

After you have changed the file, type make.

Start axfrdns.

ln -s /etc/axfrdns /service

Comments, questions, whatever are welcome.