Hi Jaya,
What kind of application is this (wht not use
JEE declerative security)? If this is a web application, and that's authentication you're after, then you have plenty of choices that can be configured easily like basic, digest, form based etc. by configuring your web application deployment descriptor.
TBH I never had to use this before, but here's how I guess you shall create a SASL client;
BTW, Sasl here is
javax.security.sasl.Sasl.
For detailed explanation and code snippets you may check out
Security Information of IBM Java 5 SDK (that's what WAS 6 uses).