From 151f0cb82bacb678a4d0ff6eed4a04aacf1efa2e Mon Sep 17 00:00:00 2001 From: Thomas Wolf Date: Fri, 3 Jul 2020 20:43:00 +0200 Subject: Add a test for upstream bug SSHD-1028 SSHD-1028:[1] server doesn't close server-side sessions properly when client disconnects. [1] https://issues.apache.org/jira/projects/SSHD/issues/SSHD-1028 Change-Id: I0d67f49e35abe8375cb1370a494dc01d0fb2c9b1 Signed-off-by: Thomas Wolf --- .../src/org/eclipse/jgit/junit/ssh/SshTestGitServer.java | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'org.eclipse.jgit.junit.ssh/src') diff --git a/org.eclipse.jgit.junit.ssh/src/org/eclipse/jgit/junit/ssh/SshTestGitServer.java b/org.eclipse.jgit.junit.ssh/src/org/eclipse/jgit/junit/ssh/SshTestGitServer.java index 03e2855829..9aa4afcef1 100644 --- a/org.eclipse.jgit.junit.ssh/src/org/eclipse/jgit/junit/ssh/SshTestGitServer.java +++ b/org.eclipse.jgit.junit.ssh/src/org/eclipse/jgit/junit/ssh/SshTestGitServer.java @@ -22,6 +22,7 @@ import java.util.ArrayList; import java.util.Collections; import java.util.List; import java.util.Locale; +import java.util.Map; import org.apache.sshd.common.NamedResource; import org.apache.sshd.common.PropertyResolverUtils; @@ -297,6 +298,17 @@ public class SshTestGitServer { DefaultKeyboardInteractiveAuthenticator.INSTANCE); } + /** + * Retrieves the server's property map. This is a live map; changing it + * affects the server. + * + * @return a live map of the server's properties + * @since 5.9 + */ + public Map getProperties() { + return server.getProperties(); + } + /** * Starts the test server, listening on a random port. * -- cgit v1.2.3