I don't know what's your problem. Normaly the email address don't is encoded. There's a problem with your ldap.

khoa nguyen tan wrote:
Your code really works. However, because the data is
ldap database is encoded so that qmail-ldaplookup
cannot find out the entry and as a result when I try
to send a mail to a local user, it cann't parse the
info in the database correctly and I faced the error
``Sorry,_no_mail_box ... '' .


Any suggestion please?

--- David_Rodr�guez_Fern�ndez <[EMAIL PROTECTED]>
wrote:

I supossed you misspelled the conversion:

Nguyen Thanh Vinh -> Tmd1eWVuIFRoYW5oIFZpbmg=

You can use this perl script to decode:


------- decode.pl #!/usr/bin/perl -w use MIME::Base64; use Unicode::String qw(utf8 latin1 utf16);

$cn = shift;
print decode($cn);
#####
sub decode {
 my $text= shift;
 if ($text eq ""){
        return ("");
 }else{
        return utf8(decode_base64($text))->latin1;
 }
}
__END__

use:
        ./decode.pl Tmd1eWVuIFRoYW5oIFZpbmg=





khoa nguyen tan wrote:

Hi everyone,

Firstly I'm sorry for my long writing but I just

want


to describe the situation.

I've just setup a mailserver with:
 + qmail-1.03
 + qmail-ldap-patch-20031201
 + OpenLDAP 2.0.23-6.3

For OpenLDAP, I have built it from source and I

also


enabled the support for SSL (for managing user

logging


from LDAP database).

I have configured correctly qmail, pop3d, smtpd
services and everything work rather well.

However, after setting up the database for LDAP, I
faced problems when adding user into the database.

For


example, whenever I add the user:

---


dn:[EMAIL PROTECTED],ou=qmail-accounts,dc=hcmup,dc=edu,dc=vn

cn: Nguyen Thanh Vinh
sn: Nguyen
objectClass: top
objectClass: person
objectClass: qmailUser
userPassword: {MD5}...
uid: vinh
mail: [EMAIL PROTECTED]
mailHost: mail.hcmup.edu.vn
mailAlternateAddress: [EMAIL PROTECTED]
mailQuotaSize: 6000000
accountStatus: active
deliveryMode: noprogram
---

by ldapadd ...
everything works fine. However when I execute
qmail-ldaplookup for that user, some attribute

fields


have changed. For example, the field cn is not

Nguyen


Thanh Vinh but it turned to be hFktjtmfkjsdfj .

But when I use LDAPBrowser (written in Java) to

look


for the information in LDAP database, everything
appears correctly.

I really confuse whether OpenLDAP do something

wrong


when add new data or qmail.schema cause the

problem.


Anyone please help me (this is emergency).

__________________________________
Do you Yahoo!?
New Yahoo! Photos - easier uploading and sharing.
http://photos.yahoo.com/




__________________________________
Do you Yahoo!?
Protect your identity with Yahoo! Mail AddressGuard
http://antispam.yahoo.com/whatsnewfree




Reply via email to