click-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sa...@apache.org
Subject svn commit: r782154 - in /incubator/click/trunk/click/examples: src/org/apache/click/examples/acegi/ src/org/apache/click/examples/page/acegi/ src/org/apache/click/examples/page/springsecurity/ src/org/apache/click/examples/page/springsecurity/secure/ ...
Date Fri, 05 Jun 2009 22:23:08 GMT
Author: sabob
Date: Fri Jun  5 22:23:07 2009
New Revision: 782154

URL: http://svn.apache.org/viewvc?rev=782154&view=rev
Log:
updated to spring security

Added:
    incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/
  (props changed)
      - copied from r781460, incubator/click/trunk/click/examples/src/org/apache/click/examples/page/acegi/
    incubator/click/trunk/click/examples/src/org/apache/click/examples/springsecurity/   (props
changed)
      - copied from r781460, incubator/click/trunk/click/examples/src/org/apache/click/examples/acegi/
    incubator/click/trunk/click/examples/webapp/springsecurity/   (props changed)
      - copied from r781460, incubator/click/trunk/click/examples/webapp/acegi/
Removed:
    incubator/click/trunk/click/examples/src/org/apache/click/examples/acegi/
    incubator/click/trunk/click/examples/src/org/apache/click/examples/page/acegi/
    incubator/click/trunk/click/examples/webapp/acegi/
Modified:
    incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/CreateAccountPage.java
    incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/LoginPage.java
    incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/LogoutPage.java
    incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/NotAuthorizedPage.java
    incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/package.html
    incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/secure/SecurePage.java
    incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/secure/package.html
    incubator/click/trunk/click/examples/src/org/apache/click/examples/springsecurity/UserDetailsAdaptor.java
    incubator/click/trunk/click/examples/src/org/apache/click/examples/springsecurity/UserDetailsService.java
    incubator/click/trunk/click/examples/src/org/apache/click/examples/springsecurity/package.html
    incubator/click/trunk/click/examples/webapp/springsecurity/login.htm
    incubator/click/trunk/click/examples/webapp/springsecurity/secure/secure.htm

Propchange: incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/
------------------------------------------------------------------------------
    svn:mergeinfo = 

Modified: incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/CreateAccountPage.java
URL: http://svn.apache.org/viewvc/incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/CreateAccountPage.java?rev=782154&r1=781460&r2=782154&view=diff
==============================================================================
--- incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/CreateAccountPage.java
(original)
+++ incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/CreateAccountPage.java
Fri Jun  5 22:23:07 2009
@@ -16,16 +16,10 @@
  * specific language governing permissions and limitations
  * under the License.
  */
-package org.apache.click.examples.page.acegi;
+package org.apache.click.examples.page.springsecurity;
 
 import javax.annotation.Resource;
 
-import org.acegisecurity.Authentication;
-import org.acegisecurity.AuthenticationManager;
-import org.acegisecurity.context.SecurityContext;
-import org.acegisecurity.context.SecurityContextHolder;
-import org.acegisecurity.context.SecurityContextImpl;
-import org.acegisecurity.providers.UsernamePasswordAuthenticationToken;
 import org.apache.click.ActionListener;
 import org.apache.click.Control;
 import org.apache.click.control.Form;
@@ -35,10 +29,16 @@
 import org.apache.click.control.TextField;
 import org.apache.click.examples.domain.User;
 import org.apache.click.examples.page.BorderPage;
-import org.apache.click.examples.page.acegi.secure.SecurePage;
+import org.apache.click.examples.page.springsecurity.secure.SecurePage;
 import org.apache.click.examples.service.UserService;
 import org.apache.click.extras.control.EmailField;
 import org.apache.commons.lang.StringUtils;
+import org.springframework.security.Authentication;
+import org.springframework.security.AuthenticationManager;
+import org.springframework.security.context.SecurityContext;
+import org.springframework.security.context.SecurityContextHolder;
+import org.springframework.security.context.SecurityContextImpl;
+import org.springframework.security.providers.UsernamePasswordAuthenticationToken;
 import org.springframework.stereotype.Component;
 
 @Component

Modified: incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/LoginPage.java
URL: http://svn.apache.org/viewvc/incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/LoginPage.java?rev=782154&r1=781460&r2=782154&view=diff
==============================================================================
--- incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/LoginPage.java
(original)
+++ incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/LoginPage.java
Fri Jun  5 22:23:07 2009
@@ -16,12 +16,12 @@
  * specific language governing permissions and limitations
  * under the License.
  */
-package org.apache.click.examples.page.acegi;
+package org.apache.click.examples.page.springsecurity;
 
 import org.apache.click.examples.page.BorderPage;
 
 /**
- * Provides a ACEGI Security login page.
+ * Provides a Spring Security (Acegi) login page.
  *
  * @author Malcolm Edgar
  */

Modified: incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/LogoutPage.java
URL: http://svn.apache.org/viewvc/incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/LogoutPage.java?rev=782154&r1=781460&r2=782154&view=diff
==============================================================================
--- incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/LogoutPage.java
(original)
+++ incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/LogoutPage.java
Fri Jun  5 22:23:07 2009
@@ -16,13 +16,13 @@
  * specific language governing permissions and limitations
  * under the License.
  */
-package org.apache.click.examples.page.acegi;
+package org.apache.click.examples.page.springsecurity;
 
 import org.apache.click.examples.page.BorderPage;
-import org.apache.click.examples.page.acegi.secure.SecurePage;
+import org.apache.click.examples.page.springsecurity.secure.SecurePage;
 
 /**
- * Provides a ACEGI Security logout page.
+ * Provides a Spring Security (Acegi) logout page.
  *
  * @author Malcolm Edgar
  */

Modified: incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/NotAuthorizedPage.java
URL: http://svn.apache.org/viewvc/incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/NotAuthorizedPage.java?rev=782154&r1=781460&r2=782154&view=diff
==============================================================================
--- incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/NotAuthorizedPage.java
(original)
+++ incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/NotAuthorizedPage.java
Fri Jun  5 22:23:07 2009
@@ -16,12 +16,12 @@
  * specific language governing permissions and limitations
  * under the License.
  */
-package org.apache.click.examples.page.acegi;
+package org.apache.click.examples.page.springsecurity;
 
 import org.apache.click.examples.page.BorderPage;
 
 /**
- * Provides a ACEGI Security logout page.
+ * Provides a Spring Security (Acegi) logout page.
  *
  * @author Malcolm Edgar
  */

Modified: incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/package.html
URL: http://svn.apache.org/viewvc/incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/package.html?rev=782154&r1=781460&r2=782154&view=diff
==============================================================================
--- incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/package.html
(original)
+++ incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/package.html
Fri Jun  5 22:23:07 2009
@@ -18,5 +18,5 @@
 -->
 
 <body>
-Provides ACEGI security example page classes.
+Provides Spring Security (Acegi) security example page classes.
 </body>
\ No newline at end of file

Modified: incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/secure/SecurePage.java
URL: http://svn.apache.org/viewvc/incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/secure/SecurePage.java?rev=782154&r1=781460&r2=782154&view=diff
==============================================================================
--- incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/secure/SecurePage.java
(original)
+++ incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/secure/SecurePage.java
Fri Jun  5 22:23:07 2009
@@ -1,4 +1,22 @@
-package org.apache.click.examples.page.acegi.secure;
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.click.examples.page.springsecurity.secure;
 
 import org.apache.click.examples.page.BorderPage;
 

Modified: incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/secure/package.html
URL: http://svn.apache.org/viewvc/incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/secure/package.html?rev=782154&r1=781460&r2=782154&view=diff
==============================================================================
--- incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/secure/package.html
(original)
+++ incubator/click/trunk/click/examples/src/org/apache/click/examples/page/springsecurity/secure/package.html
Fri Jun  5 22:23:07 2009
@@ -18,5 +18,5 @@
 -->
 
 <body>
-Provides ACEGI secured page classes.
+Provides Spring Security secured page classes.
 </body>
\ No newline at end of file

Propchange: incubator/click/trunk/click/examples/src/org/apache/click/examples/springsecurity/
------------------------------------------------------------------------------
    svn:mergeinfo = 

Modified: incubator/click/trunk/click/examples/src/org/apache/click/examples/springsecurity/UserDetailsAdaptor.java
URL: http://svn.apache.org/viewvc/incubator/click/trunk/click/examples/src/org/apache/click/examples/springsecurity/UserDetailsAdaptor.java?rev=782154&r1=781460&r2=782154&view=diff
==============================================================================
--- incubator/click/trunk/click/examples/src/org/apache/click/examples/springsecurity/UserDetailsAdaptor.java
(original)
+++ incubator/click/trunk/click/examples/src/org/apache/click/examples/springsecurity/UserDetailsAdaptor.java
Fri Jun  5 22:23:07 2009
@@ -16,11 +16,11 @@
  * specific language governing permissions and limitations
  * under the License.
  */
-package org.apache.click.examples.acegi;
+package org.apache.click.examples.springsecurity;
 
-import org.acegisecurity.GrantedAuthority;
-import org.acegisecurity.userdetails.UserDetails;
 import org.apache.click.examples.domain.User;
+import org.springframework.security.GrantedAuthority;
+import org.springframework.security.userdetails.UserDetails;
 
 public class UserDetailsAdaptor implements UserDetails {
 

Modified: incubator/click/trunk/click/examples/src/org/apache/click/examples/springsecurity/UserDetailsService.java
URL: http://svn.apache.org/viewvc/incubator/click/trunk/click/examples/src/org/apache/click/examples/springsecurity/UserDetailsService.java?rev=782154&r1=781460&r2=782154&view=diff
==============================================================================
--- incubator/click/trunk/click/examples/src/org/apache/click/examples/springsecurity/UserDetailsService.java
(original)
+++ incubator/click/trunk/click/examples/src/org/apache/click/examples/springsecurity/UserDetailsService.java
Fri Jun  5 22:23:07 2009
@@ -16,25 +16,25 @@
  * specific language governing permissions and limitations
  * under the License.
  */
-package org.apache.click.examples.acegi;
+package org.apache.click.examples.springsecurity;
 
 import javax.annotation.Resource;
 
-import org.acegisecurity.userdetails.UserDetails;
-import org.acegisecurity.userdetails.UsernameNotFoundException;
 import org.apache.click.examples.domain.User;
 import org.apache.click.examples.service.UserService;
 import org.springframework.dao.DataAccessException;
+import org.springframework.security.userdetails.UserDetails;
+import org.springframework.security.userdetails.UsernameNotFoundException;
 import org.springframework.stereotype.Component;
 
 @Component
-public class UserDetailsService implements org.acegisecurity.userdetails.UserDetailsService
{
+public class UserDetailsService implements org.springframework.security.userdetails.UserDetailsService
{
 
     @Resource(name="userService")
     private UserService userService;
 
     /**
-     * @see org.acegisecurity.userdetails.UserDetailsService#loadUserByUsername(String)
+     * @see org.springframework.security.userdetails.UserDetailsService#loadUserByUsername(String)
      */
     public UserDetails loadUserByUsername(String username) throws UsernameNotFoundException,
DataAccessException {
 

Modified: incubator/click/trunk/click/examples/src/org/apache/click/examples/springsecurity/package.html
URL: http://svn.apache.org/viewvc/incubator/click/trunk/click/examples/src/org/apache/click/examples/springsecurity/package.html?rev=782154&r1=781460&r2=782154&view=diff
==============================================================================
--- incubator/click/trunk/click/examples/src/org/apache/click/examples/springsecurity/package.html
(original)
+++ incubator/click/trunk/click/examples/src/org/apache/click/examples/springsecurity/package.html
Fri Jun  5 22:23:07 2009
@@ -18,5 +18,5 @@
 -->
 
 <body>
-Provides the Spring ACEGI Security example.
+Provides the Spring Security (Acegi) example.
 </body>
\ No newline at end of file

Propchange: incubator/click/trunk/click/examples/webapp/springsecurity/
------------------------------------------------------------------------------
    svn:mergeinfo = 

Modified: incubator/click/trunk/click/examples/webapp/springsecurity/login.htm
URL: http://svn.apache.org/viewvc/incubator/click/trunk/click/examples/webapp/springsecurity/login.htm?rev=782154&r1=781460&r2=782154&view=diff
==============================================================================
--- incubator/click/trunk/click/examples/webapp/springsecurity/login.htm (original)
+++ incubator/click/trunk/click/examples/webapp/springsecurity/login.htm Fri Jun  5 22:23:07
2009
@@ -19,34 +19,38 @@
 
 <center>
 
-<div class="dialogForm" style="width:305px;">
+<div class="dialogForm" style="width:315px;">
 
-<form method="post" action="$context/j_acegi_security_check" name="form">
+<form method="post" action="$context/j_spring_security_check" name="form">
 <table class="login" border="0" width="100%">
  <tr>
 #if ($request.getParameter("auth-error"))
-   <td colspan="3" style="color:red">
+   <td colspan="2" style="color:red">
 	Invalid Username or Password, please try again.<br/>Please ensure Caps Lock is off.
    </td>
 #else
-   <td colspan="3" style="font-weight:bold;font-size:10pt;">Please login</td>
+   <td colspan="2" style="font-weight:bold;font-size:10pt;">Please login</td>
 #end
-   <td width="100%">&nbsp;</td>
  </tr>
  <tr>
-   <td colspan="4">&nbsp;</td>
+   <td colspan="2">&nbsp;</td>
  </tr>
  <tr>
    <td><label>Username</label></td>
    <td><input type="text" name="j_username" style="width:200px;"/></td>
-   <td>&nbsp;</td>
-   <td width="100%">&nbsp;</td>
  </tr>
  <tr>
    <td style="vertical-align:middle;"><label>Password</label></td>
    <td style="vertical-align:middle;"><input type="password" name="j_password" style="width:200px;"/></td>
-   <td style="vertical-align:middle;"><input type="image" src="$context/assets/images/intro.png"
title="Click to Login"/></td>
-   <td width="100%">&nbsp;</td>
+ </tr>
+ <tr>
+   <td width="100"><label>Remember Me?</label></td>
+   <td><input type="checkbox" name="_spring_security_remember_me"/></td>
+   
+ </tr>
+ <tr>
+     <td width="100">&nbsp;</td>
+     <td style="vertical-align:middle;"><input type="image" src="$context/assets/images/intro.png"
title="Click to Login"/></td>
  </tr>
 </table>
 </form>
@@ -58,7 +62,7 @@
 </div>
 
 
-<div class="dialogForm" style="width:305px;margin-top:40px;">
+<div class="dialogForm" style="width:315px;margin-top:40px;">
 
 <table class="login" border="0" width="100%">
  <tr>
@@ -68,7 +72,7 @@
  </tr>
  <tr>
    <td colspan="4" style="padding-top:15px;">
-   	<input type="button" style="font-weight:bold;" value="Create an account &#187;"
onclick="javascript:document.location.href='${context}/acegi/create-account.htm';"/>
+   	<input type="button" style="font-weight:bold;" value="Create an account &#187;"
onclick="javascript:document.location.href='${context}/springsecurity/create-account.htm';"/>
    </td>
   </tr>
 </table>

Modified: incubator/click/trunk/click/examples/webapp/springsecurity/secure/secure.htm
URL: http://svn.apache.org/viewvc/incubator/click/trunk/click/examples/webapp/springsecurity/secure/secure.htm?rev=782154&r1=781460&r2=782154&view=diff
==============================================================================
--- incubator/click/trunk/click/examples/webapp/springsecurity/secure/secure.htm (original)
+++ incubator/click/trunk/click/examples/webapp/springsecurity/secure/secure.htm Fri Jun 
5 22:23:07 2009
@@ -18,12 +18,12 @@
 -->
 
 <p>
-You are now logged into an <a class="external" target="_blank" href="http://www.acegisecurity.org/">ACEGI
Security</a> protected page.
-To logout click <a href="$context/acegi/logout.htm">here</a>.
+You are now logged into a <a class="external" target="_blank" href="http://static.springsource.org/spring-security/site/">Spring
Security (Acegi)</a> protected page.
+To logout click <a href="$context/springsecurity/logout">here</a>.
 </p>
 
 <p>
-ACEGI security is provided by a <tt>FilterToBeanProxy</tt> filter configured
in
+Spring Security is provided by a <tt>DelegatingFilterProxy</tt> filter configured
in
 <a target="_blank" href="$context/source-viewer.htm?filename=WEB-INF/web.xml">web.xml</a>,

 which is itself configured using Spring beans in the 
 <a target="_blank" href="$context/source-viewer.htm?filename=WEB-INF/spring-beans.xml">spring-bean.xml</a>



Mime
View raw message