users@glassfish.java.net

Re: How to add JAAS in WEB application

From: Nithya Subramanian <Nithya.Subramanian_at_Sun.COM>
Date: Tue, 30 Dec 2008 12:47:06 +0530

If this has fixed your issue, could this issue
(https://glassfish.dev.java.net/issues/show_bug.cgi?id=6976) be updated
and closed?

Thanks
Nithya

javafuns_at_baturu.com wrote:
> Hi
> Nithya Subramanian
>
>
> javafuns_at_baturu.com wrote:
>> Nithya Subramanian wrote:
>>> Hi,
>>>
>>> Have you tried dropping the customized jar files into the GF/lib
>>> directory ? Is there a specific reason why you are looking for
>>> packing them with your war file? Could you please elucidate the
>>> steps you are trying to create and deploy the customized JAAS module?
>> We want to make all necessary files in only one WAR file so that the
>> customers can deploy and run it easily.
>> It seems that JAAS only reads the config files that are configed via
>> System Property settings. Is there any work around?
> I found Java API provides this LoginContext constructor:
> public LoginContext(String name, Subject subject,
> CallbackHandler callbackHandler,
> Configuration config) throws LoginException {
> This can fix my issue.
>
>>>
>>> Thanks,
>>> Nithya
>>>
>>> javafuns_at_baturu.com wrote:
>>>> Hi
>>>> I'm new for GlassFish. I'd like to know how to add my customized
>>>> JAAS in my WAR to deploy into GlassFish.
>>>> I found if i directly placed the config files in WEB-INF/classes,
>>>> it does not take effect. Even that it makes me can not login the
>>>> GlassFish admin console.
>>>>
>>>> This is the log from GlassFish:
>>>>
>>>> [#|2008-12-25T16:19:56.000+0800|WARNING|glassfish|javax.enterprise.system.container.web|_ThreadID=17;_ThreadName=Thread-3;|Web
>>>> login failed: Login failed:
>>>> javax.security.auth.login.LoginException: 没有为 fileRealm 配置
>>>> LoginModules|#]
>>>>
>>>> Thanks for any help
>>>>
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe_at_glassfish.dev.java.net
>>> For additional commands, e-mail: users-help_at_glassfish.dev.java.net
>>>
>>>
>>
>>
>
>