Not clear what's your exact requirement.
password cannot be visible in a cleartext
this has something to do with authentication?
Sun
JNDI tutorial might be helpful (contains LDAP Authenticaion details as well if you are interested)
[ November 05, 2008: Message edited by: Vijitha Kumara ]