Package upgrades for Istanbul
Code updates to support package upgrades in Istanbul
Issue-ID: CCSDK-3415
Signed-off-by: Dan Timoney <dtimoney@att.com>
Change-Id: I44efd0d335bc63cc627d6ba64df1d5e406deb72a
diff --git a/adaptors/ssh-adaptor/ssh-adaptor-bundle/pom.xml b/adaptors/ssh-adaptor/ssh-adaptor-bundle/pom.xml
index 359ecad..5661eed 100644
--- a/adaptors/ssh-adaptor/ssh-adaptor-bundle/pom.xml
+++ b/adaptors/ssh-adaptor/ssh-adaptor-bundle/pom.xml
@@ -57,6 +57,16 @@
<scope>provided</scope>
</dependency>
<dependency>
+ <groupId>org.apache.sshd</groupId>
+ <artifactId>sshd-scp</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.sshd</groupId>
+ <artifactId>sshd-sftp</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
<groupId>org.onap.ccsdk.sli.core</groupId>
<artifactId>dblib-provider</artifactId>
</dependency>
diff --git a/adaptors/ssh-adaptor/ssh-adaptor-bundle/src/main/java/org/onap/ccsdk/sli/adaptors/ssh/sshd/SshConnectionSshd.java b/adaptors/ssh-adaptor/ssh-adaptor-bundle/src/main/java/org/onap/ccsdk/sli/adaptors/ssh/sshd/SshConnectionSshd.java
index 4194159..34b2aa8 100644
--- a/adaptors/ssh-adaptor/ssh-adaptor-bundle/src/main/java/org/onap/ccsdk/sli/adaptors/ssh/sshd/SshConnectionSshd.java
+++ b/adaptors/ssh-adaptor/ssh-adaptor-bundle/src/main/java/org/onap/ccsdk/sli/adaptors/ssh/sshd/SshConnectionSshd.java
@@ -93,7 +93,7 @@
}
if (keyFile != null) {
KeyPairProvider keyPairProvider = new FileKeyPairProvider(Paths.get(keyFile));
- KeyPair keyPair = keyPairProvider.loadKeys().iterator().next();
+ KeyPair keyPair = keyPairProvider.loadKeys(clientSession).iterator().next();
clientSession.addPublicKeyIdentity(keyPair);
}
AuthFuture authFuture = clientSession.auth();
diff --git a/adaptors/ssh-adaptor/ssh-adaptor-bundle/src/test/java/org/onap/ccsdk/sli/adaptors/ssh/sshd/SshAdaptorTest.java b/adaptors/ssh-adaptor/ssh-adaptor-bundle/src/test/java/org/onap/ccsdk/sli/adaptors/ssh/sshd/SshAdaptorTest.java
index 5067deb..fecb42f 100644
--- a/adaptors/ssh-adaptor/ssh-adaptor-bundle/src/test/java/org/onap/ccsdk/sli/adaptors/ssh/sshd/SshAdaptorTest.java
+++ b/adaptors/ssh-adaptor/ssh-adaptor-bundle/src/test/java/org/onap/ccsdk/sli/adaptors/ssh/sshd/SshAdaptorTest.java
@@ -33,6 +33,7 @@
import java.util.Collections;
import org.apache.sshd.common.util.OsUtils;
import org.apache.sshd.server.SshServer;
+import org.apache.sshd.server.ServerFactoryManager;
import org.apache.sshd.server.keyprovider.SimpleGeneratorHostKeyProvider;
import org.apache.sshd.server.scp.ScpCommandFactory;
import org.apache.sshd.server.subsystem.sftp.SftpSubsystemFactory;
@@ -216,7 +217,8 @@
sshd.setKeyPairProvider(new SimpleGeneratorHostKeyProvider(Paths.get(System.getProperty("java.io.tmpdir") + "/key.ser")));
sshd.setPasswordAuthenticator((username, password, session) -> (SSH_USERNAME.equals(username) && SSH_PASSWORD.equals(password)));
sshd.setPublickeyAuthenticator((username, key, session) -> false);
- sshd.getProperties().put(SshServer.WELCOME_BANNER, "Welcome to SSHD\n");
+ // SshServer.WELCOME_BANNER no longer exists in apache sshd 2.7.0
+ // sshd.getProperties().put(SshServer.WELCOME_BANNER, "Welcome to SSHD\n");
startServer0();
try {
Thread.sleep(1000);
diff --git a/core/features/ccsdk-dblib/pom.xml b/core/features/ccsdk-dblib/pom.xml
index 313371b..63a21c2 100644
--- a/core/features/ccsdk-dblib/pom.xml
+++ b/core/features/ccsdk-dblib/pom.xml
@@ -29,7 +29,6 @@
<dependency>
<groupId>org.apache.tomcat</groupId>
<artifactId>tomcat-jdbc</artifactId>
- <version>9.0.30</version>
</dependency>
<dependency>
<groupId>org.onap.ccsdk.sli.core</groupId>
diff --git a/core/features/ccsdk-dblib/src/main/feature/feature.xml b/core/features/ccsdk-dblib/src/main/feature/feature.xml
index acb7a73..f8f53a7 100644
--- a/core/features/ccsdk-dblib/src/main/feature/feature.xml
+++ b/core/features/ccsdk-dblib/src/main/feature/feature.xml
@@ -6,7 +6,6 @@
<feature prerequisite="true" dependency="false">wrap</feature>
<bundle>mvn:org.onap.ccsdk.sli.core/dblib-provider/${project.version}</bundle>
<bundle>wrap:mvn:org.apache.tomcat/tomcat-jdbc/${tomcat-jdbc.version}/$DynamicImport-Package=org.mariadb.*,org.apache.derby.*&overwrite=merge</bundle>
- <bundle>wrap:mvn:org.apache.tomcat/tomcat-juli/${tomcat-jdbc.version}/$DynamicImport-Package=org.mariadb.*,org.apache.derby.*&overwrite=merge</bundle>
<bundle>mvn:org.onap.ccsdk.sli.core/utils-provider/${project.version}</bundle>
</feature>
</features>