<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
		>
<channel>
	<title>Comments on: Perform a JAAS programmatic login in Jboss &#8211; try to solve the &#8220;empty&#8221; remote user problem</title>
	<atom:link href="http://roneiv.wordpress.com/2008/02/19/perform-a-jaas-programmatic-login-in-jboss-try-to-solve-the-empty-remote-user-problem/feed/" rel="self" type="application/rss+xml" />
	<link>http://roneiv.wordpress.com/2008/02/19/perform-a-jaas-programmatic-login-in-jboss-try-to-solve-the-empty-remote-user-problem/</link>
	<description>Challenges and solutions within the world of web applications, Jboss and Jsf</description>
	<lastBuildDate>Thu, 01 Oct 2009 12:44:16 +0000</lastBuildDate>
	<generator>http://wordpress.com/</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: roneiv</title>
		<link>http://roneiv.wordpress.com/2008/02/19/perform-a-jaas-programmatic-login-in-jboss-try-to-solve-the-empty-remote-user-problem/#comment-502</link>
		<dc:creator>roneiv</dc:creator>
		<pubDate>Sat, 15 Aug 2009 15:13:13 +0000</pubDate>
		<guid isPermaLink="false">http://roneiv.wordpress.com/?p=20#comment-502</guid>
		<description>Mgibson,

I tried to follow your link but I ended up on the forum front page.. :)

- E -</description>
		<content:encoded><![CDATA[<p>Mgibson,</p>
<p>I tried to follow your link but I ended up on the forum front page.. <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>- E -</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: mgibson77</title>
		<link>http://roneiv.wordpress.com/2008/02/19/perform-a-jaas-programmatic-login-in-jboss-try-to-solve-the-empty-remote-user-problem/#comment-501</link>
		<dc:creator>mgibson77</dc:creator>
		<pubDate>Sat, 15 Aug 2009 01:52:56 +0000</pubDate>
		<guid isPermaLink="false">http://roneiv.wordpress.com/?p=20#comment-501</guid>
		<description>Roneiv,
I&#039;ve been trying to do JAAS form based authentication on jboss but its failing all the time... 
please take a look at my posting, it has not been answered since I post it on the jobss community forum.

http://www.jboss.org/index.html?module=bb&amp;op=viewtopic&amp;t=158664</description>
		<content:encoded><![CDATA[<p>Roneiv,<br />
I&#8217;ve been trying to do JAAS form based authentication on jboss but its failing all the time&#8230;<br />
please take a look at my posting, it has not been answered since I post it on the jobss community forum.</p>
<p><a href="http://www.jboss.org/index.html?module=bb&amp;op=viewtopic&amp;t=158664" rel="nofollow">http://www.jboss.org/index.html?module=bb&amp;op=viewtopic&amp;t=158664</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: roneiv</title>
		<link>http://roneiv.wordpress.com/2008/02/19/perform-a-jaas-programmatic-login-in-jboss-try-to-solve-the-empty-remote-user-problem/#comment-255</link>
		<dc:creator>roneiv</dc:creator>
		<pubDate>Tue, 14 Apr 2009 23:23:55 +0000</pubDate>
		<guid isPermaLink="false">http://roneiv.wordpress.com/?p=20#comment-255</guid>
		<description>Thanks for sharing!</description>
		<content:encoded><![CDATA[<p>Thanks for sharing!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: anu</title>
		<link>http://roneiv.wordpress.com/2008/02/19/perform-a-jaas-programmatic-login-in-jboss-try-to-solve-the-empty-remote-user-problem/#comment-253</link>
		<dc:creator>anu</dc:creator>
		<pubDate>Thu, 09 Apr 2009 20:43:23 +0000</pubDate>
		<guid isPermaLink="false">http://roneiv.wordpress.com/?p=20#comment-253</guid>
		<description>thanks for the nice article...</description>
		<content:encoded><![CDATA[<p>thanks for the nice article&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: twistedmind</title>
		<link>http://roneiv.wordpress.com/2008/02/19/perform-a-jaas-programmatic-login-in-jboss-try-to-solve-the-empty-remote-user-problem/#comment-251</link>
		<dc:creator>twistedmind</dc:creator>
		<pubDate>Thu, 02 Apr 2009 10:15:28 +0000</pubDate>
		<guid isPermaLink="false">http://roneiv.wordpress.com/?p=20#comment-251</guid>
		<description>Hello,

I&#039;ve found the maven depencency for JBoss 5.0.0. Do be able to import the WebAuthentication add the following maven depencency to your pom:

			
				org.jboss.jbossas
				jboss-as-tomcat
provided
				5.0.0.GA
				

After that you can import the class:

import org.jboss.web.tomcat.security.login.WebAuthentication;</description>
		<content:encoded><![CDATA[<p>Hello,</p>
<p>I&#8217;ve found the maven depencency for JBoss 5.0.0. Do be able to import the WebAuthentication add the following maven depencency to your pom:</p>
<p>				org.jboss.jbossas<br />
				jboss-as-tomcat<br />
provided<br />
				5.0.0.GA</p>
<p>After that you can import the class:</p>
<p>import org.jboss.web.tomcat.security.login.WebAuthentication;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Kashi</title>
		<link>http://roneiv.wordpress.com/2008/02/19/perform-a-jaas-programmatic-login-in-jboss-try-to-solve-the-empty-remote-user-problem/#comment-230</link>
		<dc:creator>Kashi</dc:creator>
		<pubDate>Fri, 20 Feb 2009 08:33:33 +0000</pubDate>
		<guid isPermaLink="false">http://roneiv.wordpress.com/?p=20#comment-230</guid>
		<description>Hi Jigna,
resp.sendRedirect(”http://localhost:8080/portal/auth/dashboard”);
instead of sendredirect()
 plz use a dispathcer .</description>
		<content:encoded><![CDATA[<p>Hi Jigna,<br />
resp.sendRedirect(”http://localhost:8080/portal/auth/dashboard”);<br />
instead of sendredirect()<br />
 plz use a dispathcer .</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Richard</title>
		<link>http://roneiv.wordpress.com/2008/02/19/perform-a-jaas-programmatic-login-in-jboss-try-to-solve-the-empty-remote-user-problem/#comment-205</link>
		<dc:creator>Richard</dc:creator>
		<pubDate>Thu, 27 Nov 2008 13:36:11 +0000</pubDate>
		<guid isPermaLink="false">http://roneiv.wordpress.com/?p=20#comment-205</guid>
		<description>Fantastic tutorial m8. Thanks a million. This one really saved my day. :-)</description>
		<content:encoded><![CDATA[<p>Fantastic tutorial m8. Thanks a million. This one really saved my day. <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jigna Joshi</title>
		<link>http://roneiv.wordpress.com/2008/02/19/perform-a-jaas-programmatic-login-in-jboss-try-to-solve-the-empty-remote-user-problem/#comment-183</link>
		<dc:creator>Jigna Joshi</dc:creator>
		<pubDate>Fri, 17 Oct 2008 11:43:34 +0000</pubDate>
		<guid isPermaLink="false">http://roneiv.wordpress.com/?p=20#comment-183</guid>
		<description>Hi,
I have tried Programmic WebAuthentication in JBoss portal 2.6.6..
i m calling LoginServelt from login.jsp and it’s working fine..
in LoginServlet.java
WebAuthentication webAuthentication = new WebAuthentication();
if(webAuthentication.login(user, pass))
{
System.out.println(”In Web Authentication “);

System.out.println(”redirectUrl : “+redirectUrl);
String referer = req.getHeader(”Referer”);

resp.sendRedirect(”http://localhost:8080/portal/auth/dashboard”);

}
This is working fine if i login from login link on Portal home page..but, in my real scenario i ve to login it from outside..so i m running one simple html throgh apache
http://localhost/scripts/login.html..in this login.html i m calling LoginServlet of Portal..

it is doing Authentication but not doing authorization…and so if do do re-login..it works…
Am i missing something, please help me..
thanx in advance</description>
		<content:encoded><![CDATA[<p>Hi,<br />
I have tried Programmic WebAuthentication in JBoss portal 2.6.6..<br />
i m calling LoginServelt from login.jsp and it’s working fine..<br />
in LoginServlet.java<br />
WebAuthentication webAuthentication = new WebAuthentication();<br />
if(webAuthentication.login(user, pass))<br />
{<br />
System.out.println(”In Web Authentication “);</p>
<p>System.out.println(”redirectUrl : “+redirectUrl);<br />
String referer = req.getHeader(”Referer”);</p>
<p>resp.sendRedirect(”http://localhost:8080/portal/auth/dashboard”);</p>
<p>}<br />
This is working fine if i login from login link on Portal home page..but, in my real scenario i ve to login it from outside..so i m running one simple html throgh apache<br />
<a href="http://localhost/scripts/login.html..in" rel="nofollow">http://localhost/scripts/login.html..in</a> this login.html i m calling LoginServlet of Portal..</p>
<p>it is doing Authentication but not doing authorization…and so if do do re-login..it works…<br />
Am i missing something, please help me..<br />
thanx in advance</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Micah</title>
		<link>http://roneiv.wordpress.com/2008/02/19/perform-a-jaas-programmatic-login-in-jboss-try-to-solve-the-empty-remote-user-problem/#comment-162</link>
		<dc:creator>Micah</dc:creator>
		<pubDate>Wed, 03 Sep 2008 14:33:15 +0000</pubDate>
		<guid isPermaLink="false">http://roneiv.wordpress.com/?p=20#comment-162</guid>
		<description>Andrei.

Im running into the same problem with JBOSS 4.2.2.  Has anyone found a solution.

Thanks.

Micah</description>
		<content:encoded><![CDATA[<p>Andrei.</p>
<p>Im running into the same problem with JBOSS 4.2.2.  Has anyone found a solution.</p>
<p>Thanks.</p>
<p>Micah</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: roneiv</title>
		<link>http://roneiv.wordpress.com/2008/02/19/perform-a-jaas-programmatic-login-in-jboss-try-to-solve-the-empty-remote-user-problem/#comment-114</link>
		<dc:creator>roneiv</dc:creator>
		<pubDate>Tue, 08 Jul 2008 00:28:39 +0000</pubDate>
		<guid isPermaLink="false">http://roneiv.wordpress.com/?p=20#comment-114</guid>
		<description>Andrei,

If you have the time you could perhaps test the scenarios described in this post? http://roneiv.wordpress.com/2008/03/15/using-webauthentication-in-jboss/
Just to be able to discover where the error might be. :) 

The source of your problem could be different things, the login-config.xml, the web.xml etc.

In login-config, have you remembered to include the &quot;Roles&quot; role in your roles-query? It is a mandatory group in jboss, without it authentication fails.

Also, in your web.xml you need to have at least ONE role defined in auth-constraint that is a valid role for the user you try to log on with. :)

Possibly you could also add debugging statements of the security layer to see if something strange is going on. Follow the explanations here: http://www.jboss.org/community/docs/DOC-12198)

Good luck!</description>
		<content:encoded><![CDATA[<p>Andrei,</p>
<p>If you have the time you could perhaps test the scenarios described in this post? <a href="http://roneiv.wordpress.com/2008/03/15/using-webauthentication-in-jboss/" rel="nofollow">http://roneiv.wordpress.com/2008/03/15/using-webauthentication-in-jboss/</a><br />
Just to be able to discover where the error might be. <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  </p>
<p>The source of your problem could be different things, the login-config.xml, the web.xml etc.</p>
<p>In login-config, have you remembered to include the &#8220;Roles&#8221; role in your roles-query? It is a mandatory group in jboss, without it authentication fails.</p>
<p>Also, in your web.xml you need to have at least ONE role defined in auth-constraint that is a valid role for the user you try to log on with. <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>Possibly you could also add debugging statements of the security layer to see if something strange is going on. Follow the explanations here: <a href="http://www.jboss.org/community/docs/DOC-12198)" rel="nofollow">http://www.jboss.org/community/docs/DOC-12198)</a></p>
<p>Good luck!</p>
]]></content:encoded>
	</item>
</channel>
</rss>
