You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by lm...@apache.org on 2010/08/13 11:07:57 UTC

svn commit: r985138 - in /cxf/sandbox/oauth_1.0a: distribution/src/main/release/samples/oauth_1.0a/server/src/main/webapp/WEB-INF/views/registeredClientsList.jsp rt/rs/oauth/src/main/java/org/apache/cxf/auth/oauth/provider/MemoryOauthDataProvider.java

Author: lmoren
Date: Fri Aug 13 09:07:56 2010
New Revision: 985138

URL: http://svn.apache.org/viewvc?rev=985138&view=rev
Log:
- oauth demo update

Modified:
    cxf/sandbox/oauth_1.0a/distribution/src/main/release/samples/oauth_1.0a/server/src/main/webapp/WEB-INF/views/registeredClientsList.jsp
    cxf/sandbox/oauth_1.0a/rt/rs/oauth/src/main/java/org/apache/cxf/auth/oauth/provider/MemoryOauthDataProvider.java

Modified: cxf/sandbox/oauth_1.0a/distribution/src/main/release/samples/oauth_1.0a/server/src/main/webapp/WEB-INF/views/registeredClientsList.jsp
URL: http://svn.apache.org/viewvc/cxf/sandbox/oauth_1.0a/distribution/src/main/release/samples/oauth_1.0a/server/src/main/webapp/WEB-INF/views/registeredClientsList.jsp?rev=985138&r1=985137&r2=985138&view=diff
==============================================================================
--- cxf/sandbox/oauth_1.0a/distribution/src/main/release/samples/oauth_1.0a/server/src/main/webapp/WEB-INF/views/registeredClientsList.jsp (original)
+++ cxf/sandbox/oauth_1.0a/distribution/src/main/release/samples/oauth_1.0a/server/src/main/webapp/WEB-INF/views/registeredClientsList.jsp Fri Aug 13 09:07:56 2010
@@ -20,6 +20,7 @@ under the License.
 <%@ page contentType="text/html;charset=UTF-8" language="java" %>
 <%@ page isELIgnored="false" %>
 <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
+<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>
 <html>
 <head><title>Registered clients</title></head>
 <body>

Modified: cxf/sandbox/oauth_1.0a/rt/rs/oauth/src/main/java/org/apache/cxf/auth/oauth/provider/MemoryOauthDataProvider.java
URL: http://svn.apache.org/viewvc/cxf/sandbox/oauth_1.0a/rt/rs/oauth/src/main/java/org/apache/cxf/auth/oauth/provider/MemoryOauthDataProvider.java?rev=985138&r1=985137&r2=985138&view=diff
==============================================================================
--- cxf/sandbox/oauth_1.0a/rt/rs/oauth/src/main/java/org/apache/cxf/auth/oauth/provider/MemoryOauthDataProvider.java (original)
+++ cxf/sandbox/oauth_1.0a/rt/rs/oauth/src/main/java/org/apache/cxf/auth/oauth/provider/MemoryOauthDataProvider.java Fri Aug 13 09:07:56 2010
@@ -202,14 +202,16 @@ public class MemoryOauthDataProvider imp
         }
     }
 
-    public void removeRegisteredClient(Principal user, String consumerKey) {
+    public synchronized void removeRegisteredClient(Principal user, String consumerKey) {
         List<String> registeredApps = this.userRegisteredClients.get(user.getName());
+        this.clientAuthInfo.remove(consumerKey);
+        
         registeredApps.remove(consumerKey);
         removeTokenCredentials(user, consumerKey);
     }
 
     protected String generateToken() throws OAuthException {
-        String token = null;
+        String token;
         try {
             token = tokenGenerator.generateToken(UUID.randomUUID().toString().getBytes("UTF-8"));
         } catch (Exception e) {