Bump SSHD to 2.9.2 52/103252/1
authorRobert Varga <robert.varga@pantheon.tech>
Wed, 16 Nov 2022 22:30:08 +0000 (23:30 +0100)
committerRobert Varga <nite@hq.sk>
Thu, 17 Nov 2022 12:08:17 +0000 (12:08 +0000)
https://github.com/apache/mina-sshd/blob/master/docs/changes/2.9.2.md

Change-Id: I7bc6d261e0666929abde410cad64cfaabf8506e8
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit 6bac0befd20952fc07aab28b9575b690a04c0f06)

netconf/callhome-protocol/src/main/java/org/opendaylight/netconf/callhome/protocol/NetconfCallHomeServer.java
netconf/netconf-netty-util/src/main/java/org/opendaylight/netconf/nettyutil/handler/ssh/client/NettyAwareChannelSubsystem.java
netconf/shaded-sshd-jar/pom.xml

index 378ccbe2313d5432a8ef081e4fc5d9efead9a021..3577ac358b1407c8f6d80e7c55bca529eeebee27 100644 (file)
@@ -43,7 +43,7 @@ public final class NetconfCallHomeServer implements AutoCloseable, ServerKeyVeri
     NetconfCallHomeServer(final SshClient sshClient, final CallHomeAuthorizationProvider authProvider,
             final Factory factory, final InetSocketAddress socketAddress, final StatusRecorder recorder) {
         this(sshClient, authProvider, factory, socketAddress, recorder,
-            new NettyIoServiceFactory(factory.getNettyGroup()));
+            new NettyIoServiceFactory(sshClient, factory.getNettyGroup()));
     }
 
     @VisibleForTesting
index 035bbdcba04f9ed71485e1a5419fc56bbafe90e9..99bfca7f6cfb10947bd42ca97d34cdd5ef4426e2 100644 (file)
@@ -37,7 +37,7 @@ public class NettyAwareChannelSubsystem extends ChannelSubsystem {
         if (!isClosing()) {
             // TODO: consider using context's allocator for heap buffer here
             ctx.fireChannelRead(Unpooled.copiedBuffer(data, off, (int) len));
-            adjustWindow(len);
+            getLocalWindow().check();
         }
     }
 
@@ -46,14 +46,10 @@ public class NettyAwareChannelSubsystem extends ChannelSubsystem {
         // If we're already closing, ignore incoming data
         if (!isClosing()) {
             LOG.debug("Discarding {} bytes of extended data", len);
-            adjustWindow(len);
+            getLocalWindow().check();
         }
     }
 
-    private void adjustWindow(final long len) throws IOException {
-        getLocalWindow().consumeAndCheck(len);
-    }
-
     @Override
     public void close() {
         this.close(false);
index 4764a0f4a1f8b446bfcc147a07fc7889ad087890..91cf93d0ae25774e62d7e94a7b71a40a23780c5b 100644 (file)
         <dependency>
             <groupId>org.apache.sshd</groupId>
             <artifactId>sshd-osgi</artifactId>
-            <version>2.9.1</version>
+            <version>2.9.2</version>
         </dependency>
         <dependency>
             <groupId>org.apache.sshd</groupId>
             <artifactId>sshd-netty</artifactId>
-            <version>2.9.1</version>
+            <version>2.9.2</version>
             <exclusions>
                 <exclusion>
                     <groupId>org.apache.sshd</groupId>