[Dovecot] v2.0 configuration parsing

Timo Sirainen tss at iki.fi
Mon Aug 10 20:57:53 EEST 2009


I'm trying to figure out how exactly v2.0 should be parsing
configuration files. The most annoying part is if it should always just
"use whatever comes first in config" or try some kind of a "use most
specific rule". The "most specific" kind of makes more sense initially,
but then you start wondering how to handle e.g.:

1) User logs in to imap from 192.168.0.1. What is foo's value?

protocol imap {
  remote_ip 192.168.0.0/16 {
    foo = foo
  }
}
remote_ip 192.168.0.0/24 {
  foo = bar
}

2) User logs in from 192.168.0.1 to 10.1.2.3. What is foo's value?

local_ip 192.168.0.1 {
  remote_ip 10.1.2.0/24 {
    foo = foo
  }
}
remote_ip 10.1.2.3 {
  local_ip 192.168.0.0/24 {
    foo = bar
  }
}

Any thoughts?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: This is a digitally signed message part
Url : http://dovecot.org/pipermail/dovecot/attachments/20090810/9b48afbf/attachment.bin 


More information about the dovecot mailing list