This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Security and the fly likes Callback Handlers Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Engineering » Security
Bookmark "Callback Handlers" Watch "Callback Handlers" New topic

Callback Handlers

Ed B.

Joined: Jul 21, 2003
Posts: 9
Hello All,
Is there a way to pass in extra parameters to a custom callback handler and fetch it back in the custom login module? My code is as follows:

LoginContext cntx = new LoginContext("test", new MyCallBackHandler(username, password, param1, param2));
The above call throws a classcastexception because callbackHandler is an instance of SecureCallbackHandler which is an inner class of LoginContext.

Is there any other way of accomplishing what I am trying to do here?

Thanks in advance.
Bear Bibeault
Author and ninkuma

Joined: Jan 10, 2002
Posts: 60785

"Ed B.", please check your private messages.

[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
I agree. Here's the link:
subject: Callback Handlers
Similar Threads
Securing Application for JBoss5.1.0
JAAS- "No LoginModule found for ur jaas_configinfo!"
jaas - Authentication in websphere 5.0
How to handle a failed login