AuthProvider.java - sonar fixes 61/75861/1
authorDriptaroop Das <driptaroop.das@in.ibm.com>
Wed, 16 Jan 2019 10:17:39 +0000 (15:47 +0530)
committerDriptaroop Das <driptaroop.das@in.ibm.com>
Wed, 16 Jan 2019 10:17:47 +0000 (15:47 +0530)
AuthProvider.java - sonar fixes

Issue-ID: OPTFRA-414
Change-Id: I6ae6b9ab960035a1a61f90b18ebdfd7de783bb64
Signed-off-by: Driptaroop Das <driptaroop.das@in.ibm.com>
cmso-service/src/main/java/org/onap/optf/cmso/AuthProvider.java

index e002b7d..0f497b7 100644 (file)
@@ -1,6 +1,6 @@
 /*
  * Copyright © 2018 AT&T Intellectual Property.
- * Modifications Copyright © 2018 IBM.
+ * Modifications Copyright © 2019 IBM.
  * 
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
 */
 package org.onap.optf.cmso;
 
-import java.util.ArrayList;
-
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.core.env.Environment;
 import org.springframework.security.authentication.AuthenticationProvider;
 import org.springframework.security.authentication.UsernamePasswordAuthenticationToken;
 import org.springframework.security.core.Authentication;
-import org.springframework.security.core.AuthenticationException;
 import org.springframework.stereotype.Component;
 
+import java.util.ArrayList;
+
 @Component
 public class AuthProvider
   implements AuthenticationProvider {
@@ -48,9 +47,7 @@ public class AuthProvider
        Environment env;
        
     @Override
-    public Authentication authenticate(Authentication authentication) 
-      throws AuthenticationException {
-       org.springframework.security.web.authentication.www.BasicAuthenticationFilter f = null;
+    public Authentication authenticate(Authentication authentication) {
         String name = authentication.getName();
         String password = authentication.getCredentials().toString();
         //TODO check credentials until we enable AAF