Monthly Archive for March, 2005

superKaramba & kxdocker

Oooooh. lots and lots of lovely eyecandy.

Exim Forwarding Entire Domains

A client has a stroppy email admin who says Exchange can’t receive email for multiple domains. It can, but there’s not much we can do about the admin. So he asked me to set up a forward, with rewriting, on one domain to send all email to the other.

This means that if you send email to quux@foo.com it will be delivered to quux@bar.com. You also have to rewrite all the headers and the envelope, to ensure the receiving mailserver actually receives them (if it was happy receiving mail for foo.com you could just set the MX records to point to it yourself, after all).

There are lots of ways to do this, but I don’t really want a separate process (a la ‘vacation’) and I’d like the config to be neatly encapsulated to minimize the chance of me breaking it inadvertently.

So, for google’s sake, here’s the Exim config. First, in your rewrite section, add a rewrite rule:

*@foo.com $1@bar.com E

Then add a new router:

foo:
  verify = false
  domains = foo.com
  driver = redirect
  data = $local_part@bar.com
  no_more

And that’s it.

Google looking over your shoulder

I was doing some work for one of my clients this morning, setting up some online payment stuff. There were a sequence of forms, and you had to view them in order.

If you view one form out of order you’ll get an error, as it tries to examine the data posted by the previous form.

I noticed that while I was debugging, after I submitted, I’d get three or four errors from intermediate forms, after i’d posted. This was really weird.

After a lot of being confused I realised it was google, examining the pages because they had google ads on them. Presumably the google ad transmits some data about the current page to google, and if google hasn’t looked at it recently it goes and has a butchers to see what it looks like.

Presumably the ad was displaying ok, so it told google about it, but when google visited it would get a 500 response, because of the error, and so wouldn’t store the visit - so every time it gets displayed, google goes and has a look.

The Internet can be very weird sometimes.