[jboss-svn-commits] JBL Code SVN: r18009 - in labs/jbosslabs/labs-3.0-build: views/admin/src/main/webapp and 1 other directories.

jboss-svn-commits at lists.jboss.org jboss-svn-commits at lists.jboss.org
Mon Jan 21 07:46:27 EST 2008


Author: wrzep
Date: 2008-01-21 07:46:27 -0500 (Mon, 21 Jan 2008)
New Revision: 18009

Added:
   labs/jbosslabs/labs-3.0-build/views/admin/src/main/webapp/login-redirect.jsp
Modified:
   labs/jbosslabs/labs-3.0-build/configuration/resources/to-copy/server/default/conf/josso-agent-config.xml
   labs/jbosslabs/labs-3.0-build/views/admin/src/main/webapp/WEB-INF/web.xml
Log:
JBLAB-904 sso integration


Modified: labs/jbosslabs/labs-3.0-build/configuration/resources/to-copy/server/default/conf/josso-agent-config.xml
===================================================================
--- labs/jbosslabs/labs-3.0-build/configuration/resources/to-copy/server/default/conf/josso-agent-config.xml	2008-01-21 12:44:52 UTC (rev 18008)
+++ labs/jbosslabs/labs-3.0-build/configuration/resources/to-copy/server/default/conf/josso-agent-config.xml	2008-01-21 12:46:27 UTC (rev 18009)
@@ -94,12 +94,15 @@
         <partner-app>
             <context>/foo-view</context>
         </partner-app>
-        
-        <partner-app>
-            <context>/jmx-console</context>
-        </partner-app>
         
+        <partner-app>
+            <context>/jmx-console</context>
+        </partner-app>
 
+        <partner-app>
+            <context>/admin</context>
+        </partner-app>
+
         <!-- Root context protection
         <partner-app>
             <context>/</context>

Modified: labs/jbosslabs/labs-3.0-build/views/admin/src/main/webapp/WEB-INF/web.xml
===================================================================
--- labs/jbosslabs/labs-3.0-build/views/admin/src/main/webapp/WEB-INF/web.xml	2008-01-21 12:44:52 UTC (rev 18008)
+++ labs/jbosslabs/labs-3.0-build/views/admin/src/main/webapp/WEB-INF/web.xml	2008-01-21 12:46:27 UTC (rev 18009)
@@ -36,7 +36,7 @@
       <servlet-name>Seam Resource Servlet</servlet-name>
       <url-pattern>/seam/resource/*</url-pattern>
    </servlet-mapping>
-   
+                                                                                                                              
    <!-- Facelets development mode (disable in production) -->
    
    <context-param>
@@ -55,6 +55,10 @@
       <servlet-name>Faces Servlet</servlet-name>
       <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
       <load-on-startup>1</load-on-startup>
+      <security-role-ref>
+			<role-name>user</role-name>
+			<role-link>user</role-link>
+		</security-role-ref>
    </servlet>
     
    <servlet-mapping>
@@ -71,6 +75,27 @@
        <auth-constraint/>
    </security-constraint>
    
-   
-   
+   <!-- Login -->
+   <login-config>
+		<auth-method>FORM</auth-method>
+		<form-login-config>
+			<form-login-page>/login-redirect.jsp</form-login-page>
+			<form-error-page>/login-redirect.jsp</form-error-page>
+		</form-login-config>
+   </login-config>
+
+   <security-constraint>
+		<web-resource-collection>
+			<web-resource-name>Authenticated</web-resource-name>
+			<url-pattern>/*</url-pattern>
+		</web-resource-collection>
+		<auth-constraint>
+			<role-name>user</role-name>
+		</auth-constraint>
+    </security-constraint>
+
+    <security-role>
+            <role-name>user</role-name>
+    </security-role>
+
 </web-app>

Added: labs/jbosslabs/labs-3.0-build/views/admin/src/main/webapp/login-redirect.jsp
===================================================================
--- labs/jbosslabs/labs-3.0-build/views/admin/src/main/webapp/login-redirect.jsp	                        (rev 0)
+++ labs/jbosslabs/labs-3.0-build/views/admin/src/main/webapp/login-redirect.jsp	2008-01-21 12:46:27 UTC (rev 18009)
@@ -0,0 +1,28 @@
+<%--
+  ~ JOSSO: Java Open Single Sign-On
+  ~
+  ~ Copyright 2004-2007, Atricore, Inc.
+  ~
+  ~ This is free software; you can redistribute it and/or modify it
+  ~ under the terms of the GNU Lesser General Public License as
+  ~ published by the Free Software Foundation; either version 2.1 of
+  ~ the License, or (at your option) any later version.
+  ~
+  ~ This software is distributed in the hope that it will be useful,
+  ~ but WITHOUT ANY WARRANTY; without even the implied warranty of
+  ~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+  ~ Lesser General Public License for more details.
+  ~
+  ~ You should have received a copy of the GNU Lesser General Public
+  ~ License along with this software; if not, write to the Free
+  ~ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+  ~ 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+  --%>
+
+<%@page contentType="text/html; charset=iso-8859-1" language="java" session="true" %>
+<!--
+Redirects the user to the propper login page.  Configured as the login url the web.xml for this application.
+-->
+<%
+    response.sendRedirect(request.getContextPath() + "/josso_login/");
+%>




More information about the jboss-svn-commits mailing list