Author: rbaxter85
Date: Fri Nov  1 20:33:05 2013
New Revision: 1538053

URL: http://svn.apache.org/r1538053
Log:
SHINDIG-1943
Committed For Andreas Kohn
Fix reversed condition in AuthCodeGrantValidator#validateRequest()

Added:
    
shindig/trunk/java/social-api/src/main/java/org/apache/shindig/social/core/oauth2/package-info.java
   (with props)
Modified:
    
shindig/trunk/java/social-api/src/main/java/org/apache/shindig/social/core/oauth2/validators/AuthCodeGrantValidator.java

Added: 
shindig/trunk/java/social-api/src/main/java/org/apache/shindig/social/core/oauth2/package-info.java
URL: 
http://svn.apache.org/viewvc/shindig/trunk/java/social-api/src/main/java/org/apache/shindig/social/core/oauth2/package-info.java?rev=1538053&view=auto
==============================================================================
--- 
shindig/trunk/java/social-api/src/main/java/org/apache/shindig/social/core/oauth2/package-info.java
 (added)
+++ 
shindig/trunk/java/social-api/src/main/java/org/apache/shindig/social/core/oauth2/package-info.java
 Fri Nov  1 20:33:05 2013
@@ -0,0 +1,25 @@
+/*
+ * 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.
+ */
+/**
+ * Implementation of OAuth 2.0.
+ * 
+ * This implementation currently complies to
+ * <a href="http://tools.ietf.org/html/draft-ietf-oauth-v2-21";>OAuth 2.0 DRAFT 
21</a>
+ */
+package org.apache.shindig.social.core.oauth2;
\ No newline at end of file

Propchange: 
shindig/trunk/java/social-api/src/main/java/org/apache/shindig/social/core/oauth2/package-info.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Modified: 
shindig/trunk/java/social-api/src/main/java/org/apache/shindig/social/core/oauth2/validators/AuthCodeGrantValidator.java
URL: 
http://svn.apache.org/viewvc/shindig/trunk/java/social-api/src/main/java/org/apache/shindig/social/core/oauth2/validators/AuthCodeGrantValidator.java?rev=1538053&r1=1538052&r2=1538053&view=diff
==============================================================================
--- 
shindig/trunk/java/social-api/src/main/java/org/apache/shindig/social/core/oauth2/validators/AuthCodeGrantValidator.java
 (original)
+++ 
shindig/trunk/java/social-api/src/main/java/org/apache/shindig/social/core/oauth2/validators/AuthCodeGrantValidator.java
 Fri Nov  1 20:33:05 2013
@@ -64,8 +64,8 @@ public class AuthCodeGrantValidator impl
       response.setBodyReturned(true);
       throw new OAuth2Exception(response);
     }
-    if (servletRequest.getRedirectURI() != null
-        && !servletRequest.getRedirectURI().equals(authCode.getRedirectURI())) 
{
+    if (authCode.getRedirectURI() != null
+        && !authCode.getRedirectURI().equals(servletRequest.getRedirectURI())) 
{
       OAuth2NormalizedResponse response = new OAuth2NormalizedResponse();
       response.setStatus(HttpServletResponse.SC_BAD_REQUEST);
       response.setError(ErrorType.INVALID_GRANT.toString());


Reply via email to