Re: Cyrus Virtdomains (used to be: LDAP Queries HELP)

Pedro Algarvio <[email protected]> Sat, 10 Jun 2006 05:45:11 +0100
Newsgroups gmane.comp.isp.ispman.devel
Message-ID <[email protected]>
Quoting Pedro Algarvio <[email protected]>:

> Aparently we have made it run. We have been trying to "escape" the wrong @.
>
> LDAP entry:
> dn:    
> [email protected],ou=users,ispmanDomain=ufsoft.org,o=ispman,dc=ufsoft,dc=
>    org
> objectClass: posixAccount
> objectClass: ispmanDomainUser
> objectClass: radiusprofile
> radiusProfileDn: cn=default,ou=radiusprofiles,o=ispman,dc=ufsoft,dc=org
> uid: [email protected]
> uid: ufs_ufsoft_org
> uidNumber: 10063
> gidNumber: 10007
> homeDirectory: /ispman/domains/ufsoft.org/users/[email protected]
> loginShell: /bin/false
> ispmanStatus: active
> ispmanCreateTimestamp: 1149645350
> ispmanUserId: ufs
> ispmanDomain: ufsoft.org
> DestinationAddress: ispman
> DestinationPort: 21
> mailQuota: 51200
> mailHost: hosting
> fileHost: ispman
> cn: algarvio pedro
> mailRoutingAddress: [email protected]\@hosting
> FTPStatus: enabled
> FTPQuotaMBytes: 20
> sn: pedro
> mailLocalAddress: [email protected]
> givenName: algarvio
>
>
> Now the log when testing to deliver email to that user:
> Jun  9 04:34:49 ispman postfix/master[30941]: daemon started --
> version 2.2.10,
> configuration /etc/postfix
> Jun  9 04:35:30 ispman postfix/pickup[30946]: 9DA60A7B55: uid=81
> from=<[email protected]>
> Jun  9 04:35:30 ispman postfix/cleanup[30954]: 9DA60A7B55:
> message-id=<20060609043530.9udy8qysoo04cgco-rMGfsb4OVYeR6P+Kz0xyDFaTQe2KTcn/@public.gmane.org>
> Jun  9 04:35:30 ispman postfix/qmgr[30947]: 9DA60A7B55:
> from=<[email protected]>,
> size=799, nrcpt=1 (queue active)
> Jun  9 04:35:30 ispman postfix/smtp[30956]: connect to
> hosting[10.1.0.10]: Connection
> refused (port 25)
> Jun  9 04:35:31 ispman postfix/smtp[30956]: 9DA60A7B55:
> to=<[email protected]@hosting>,
> orig_to=<[email protected]>, relay=none, delay=1, status=deferred (connect to
> hosting[10.1.0.10]: Connection refused)
>
> * Now, how about that :) *
>
>
> Oh, that connection got refused because there's nothing running at
> that host, let's say it's a fake host in ispman's mail hostgroup.
>
> Still, now I have problems delivering to the domain that it's delivery
> is set to local.
>
> :(
>
> It works, If I have that domain in $mydestination, but then postfix   
>  also says:
> postfix/trivial-rewrite[32019]: warning: do not list domain
> tracforge.net in BOTH mydestination and virtual_alias_domains
>
> So, what's the next step?
>

I don't think this is going anywhere too, because:
ldapsearch -x mailRoutingAddress=ufs\@ufsoft.org\\@hosting
# extended LDIF
#
# LDAPv3
# base <> with scope sub
# filter: [email protected]\@hosting
# requesting: ALL
#

ldapsearch: ldap_search_ext: Bad search filter (-7)

ldapsearch -x '[email protected]\@hosting'
# extended LDIF
#
# LDAPv3
# base <> with scope sub
# filter: [email protected]\@hosting
# requesting: ALL
#

ldapsearch: ldap_search_ext: Bad search filter (-7)

ldapsearch -x "[email protected]\@hosting"
# extended LDIF
#
# LDAPv3
# base <> with scope sub
# filter: [email protected]\@hosting
# requesting: ALL
#

ldapsearch: ldap_search_ext: Bad search filter (-7)

ldapsearch -x "[email protected]@hosting"
# extended LDIF
#
# LDAPv3
# base <> with scope sub
# filter: [email protected]@hosting
# requesting: ALL
#

# search result
search: 2
result: 0 Success

# numResponses: 1


And ldapsearch won't retrieve anything with that escape.

So, once again, specially to Joerg, why couldn't we use transport_maps?

Sure it would require some fields added to the user ldap entry
because, mailRountingAddress is not a good place to store for example
lmtp:unix:/var/imap/socket/lmtp

Sure, I don't even know how we would define all possible values for
transport_maps from the web interface point of view.

What I do think I know is that 2 ldap queries could be dropped,
ldap_virtual_*, so why not change 2 ldap queries for only just one?

What does the transport_maps restrain that much that makes, for
example Joreg dislike it?

In his opinion ldap_virtual_* is more flexible.

*P.S.: This is now the full message. I accidently hit send instead of  
save.* :-)



-- 
Pedro Algarvio
    __ ___  ___ _______        ___ __
|   Y   .'  _|   _   .-----.'  _|  |_   .-----.----.-----.
|.  |   |   _|   1___|  _  |   _|   _|__|  _  |   _|  _  |
|.  |   |__| |____   |_____|__| |____|__|_____|__| |___  |
|:  1   |    |:  1   |                             |_____|
|::.. . |    |::.. . |  ufs [AT] ufsoft [DOT] org
`-------'    `-------'    ufs [AT] sapo [DOT] pt