Ok I saw it now, it was hidden:

<realm-name>Test Realm</realm-name>


Best regards,
Alex soto




> On May 11, 2020, at 8:31 AM, Alex Soto <[email protected]> wrote:
> 
> Thanks Achin and JB,
> 
> I looked at that example, but that is is WAR, and I am looking for WAB 
> example.  Still, in the ‘web.xml’ file there is no reference to JAAS realm.  
> Where do you indicate the realm name? (I have my own realm separate from the 
> default Karaf one).
> 
> Actually, it is not fun having to guess all this basic stuff, and also a 
> productivity drain, I am sorry to say.
> 
> 
> Best regards,
> Alex soto
> 
>> On May 11, 2020, at 3:12 AM, Jean-Baptiste Onofre <[email protected] 
>> <mailto:[email protected]>> wrote:
>> 
>> No rush, I think it’s easier for our users to find "how to" ;)
>> 
>> Thanks !
>> Regards
>> JB
>> 
>>> Le 11 mai 2020 à 09:09, Achim Nierbeck <[email protected] 
>>> <mailto:[email protected]>> a écrit :
>>> 
>>> Sure .. 
>>> maybe I find some time during this week to create this there ;) 
>>> 
>>> regards, Achim 
>>> 
>>> p.s. this just reminds me, that those samples are also in the "Apache Karaf 
>>> Cookbook" :) 
>>> 
>>> Am Mo., 11. Mai 2020 um 06:32 Uhr schrieb Jean-Baptiste Onofre 
>>> <[email protected] <mailto:[email protected]>>:
>>> Maybe worth to add this in the Karaf wab example as well.
>>> 
>>> I will.
>>> 
>>> Regards
>>> JB
>>> 
>>>> Le 10 mai 2020 à 13:45, Achim Nierbeck <[email protected] 
>>>> <mailto:[email protected]>> a écrit :
>>>> 
>>>> Hi, 
>>>> 
>>>> there is a sample app for Pax-Web, which is also used in the test-suite: 
>>>> https://github.com/ops4j/org.ops4j.pax.web/tree/master/samples/war-authentication
>>>>  
>>>> <https://github.com/ops4j/org.ops4j.pax.web/tree/master/samples/war-authentication>
>>>> And actually you just need to reference the jaas of the surrounding Karaf 
>>>> instance in your web.xml file. 
>>>> 
>>>> regards, Achim 
>>>> 
>>>> 
>>>> 
>>>> Am Fr., 8. Mai 2020 um 18:41 Uhr schrieb Alex Soto <[email protected] 
>>>> <mailto:[email protected]>>:
>>>> Hello,
>>>> 
>>>> Is there a good tutorial or documentation on how to protect a WAB (Web 
>>>> Application Bundle) with JAAS authentication?
>>>> My Karaf version is 4.2.8.  Documentation here 
>>>> https://karaf.apache.org/manual/latest/webcontainer 
>>>> <https://karaf.apache.org/manual/latest/webcontainer> is scarce, only 
>>>> referring to Jetty global config, (even that failed for me).  I have 
>>>> multiple WABs and WARs in the same Karaf container, and I don’t want to 
>>>> apply the same JAAS authentication to all of them.   From the comment:
>>>> 
>>>> <!-- =========================================================== -->
>>>>     <!-- Configure Authentication Realms -->
>>>>     <!-- Realms may be configured for the entire server here, or -->
>>>>     <!-- they can be configured for a specific web app in a context -->
>>>>     <!-- configuration (see $(jetty.home)/contexts/test.xml for an -->
>>>>     <!-- example). -->
>>>>     <!-- =========================================================== —>
>>>> 
>>>> It looks like is a way ($(jetty.home)/contexts/test.xml ).  But this is 
>>>> unclear on how to apply, and it is Jetty specific.
>>>> My preference is for a Jetty agnostic way, for portability reasons. (Maybe 
>>>> Karaf will change to Undertow in the future)
>>>> 
>>>> 
>>>> Best regards,
>>>> Alex soto
>>>> 
>>>> 
>>>> 
>>>> 
>>>> 
>>>> 
>>>> -- 
>>>> 
>>>> Apache Member
>>>> Apache Karaf <http://karaf.apache.org/ <http://karaf.apache.org/>> 
>>>> Committer & PMC
>>>> OPS4J Pax Web <http://wiki.ops4j.org/display/paxweb/Pax+Web/ 
>>>> <http://wiki.ops4j.org/display/paxweb/Pax+Web/>> Committer & Project Lead
>>>> blog <http://notizblog.nierbeck.de/ <http://notizblog.nierbeck.de/>>
>>>> Co-Author of Apache Karaf Cookbook <http://bit.ly/1ps9rkS 
>>>> <http://bit.ly/1ps9rkS>>
>>>> 
>>> 
>>> 
>>> 
>>> -- 
>>> 
>>> Apache Member
>>> Apache Karaf <http://karaf.apache.org/ <http://karaf.apache.org/>> 
>>> Committer & PMC
>>> OPS4J Pax Web <http://wiki.ops4j.org/display/paxweb/Pax+Web/ 
>>> <http://wiki.ops4j.org/display/paxweb/Pax+Web/>> Committer & Project Lead
>>> blog <http://notizblog.nierbeck.de/ <http://notizblog.nierbeck.de/>>
>>> Co-Author of Apache Karaf Cookbook <http://bit.ly/1ps9rkS 
>>> <http://bit.ly/1ps9rkS>>
>>> 
>> 
> 

Reply via email to